You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

v1_json.tmpl 215KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922
  1. {
  2. "consumes": [
  3. "application/json",
  4. "text/plain"
  5. ],
  6. "produces": [
  7. "application/json",
  8. "text/html"
  9. ],
  10. "schemes": [
  11. "http",
  12. "https"
  13. ],
  14. "swagger": "2.0",
  15. "info": {
  16. "description": "This documentation describes the Gitea API.",
  17. "title": "Gitea API.",
  18. "license": {
  19. "name": "MIT",
  20. "url": "http://opensource.org/licenses/MIT"
  21. },
  22. "version": "1.1.1"
  23. },
  24. "basePath": "{{AppSubUrl}}/api/v1",
  25. "paths": {
  26. "/admin/orgs": {
  27. "get": {
  28. "produces": [
  29. "application/json"
  30. ],
  31. "tags": [
  32. "admin"
  33. ],
  34. "summary": "List all organizations",
  35. "operationId": "adminGetAllOrgs",
  36. "responses": {
  37. "200": {
  38. "$ref": "#/responses/OrganizationList"
  39. },
  40. "403": {
  41. "$ref": "#/responses/forbidden"
  42. }
  43. }
  44. }
  45. },
  46. "/admin/users": {
  47. "get": {
  48. "produces": [
  49. "application/json"
  50. ],
  51. "tags": [
  52. "admin"
  53. ],
  54. "summary": "List all users",
  55. "operationId": "adminGetAllUsers",
  56. "responses": {
  57. "200": {
  58. "$ref": "#/responses/UserList"
  59. },
  60. "403": {
  61. "$ref": "#/responses/forbidden"
  62. }
  63. }
  64. },
  65. "post": {
  66. "consumes": [
  67. "application/json"
  68. ],
  69. "produces": [
  70. "application/json"
  71. ],
  72. "tags": [
  73. "admin"
  74. ],
  75. "summary": "Create a user",
  76. "operationId": "adminCreateUser",
  77. "parameters": [
  78. {
  79. "name": "body",
  80. "in": "body",
  81. "schema": {
  82. "$ref": "#/definitions/CreateUserOption"
  83. }
  84. }
  85. ],
  86. "responses": {
  87. "201": {
  88. "$ref": "#/responses/User"
  89. },
  90. "403": {
  91. "$ref": "#/responses/forbidden"
  92. },
  93. "422": {
  94. "$ref": "#/responses/validationError"
  95. }
  96. }
  97. }
  98. },
  99. "/admin/users/{username}": {
  100. "delete": {
  101. "produces": [
  102. "application/json"
  103. ],
  104. "tags": [
  105. "admin"
  106. ],
  107. "summary": "Delete a user",
  108. "operationId": "adminDeleteUser",
  109. "parameters": [
  110. {
  111. "type": "string",
  112. "description": "username of user to delete",
  113. "name": "username",
  114. "in": "path",
  115. "required": true
  116. }
  117. ],
  118. "responses": {
  119. "204": {
  120. "$ref": "#/responses/empty"
  121. },
  122. "403": {
  123. "$ref": "#/responses/forbidden"
  124. },
  125. "422": {
  126. "$ref": "#/responses/validationError"
  127. }
  128. }
  129. },
  130. "patch": {
  131. "consumes": [
  132. "application/json"
  133. ],
  134. "produces": [
  135. "application/json"
  136. ],
  137. "tags": [
  138. "admin"
  139. ],
  140. "summary": "Edit an existing user",
  141. "operationId": "adminEditUser",
  142. "parameters": [
  143. {
  144. "type": "string",
  145. "description": "username of user to edit",
  146. "name": "username",
  147. "in": "path",
  148. "required": true
  149. },
  150. {
  151. "name": "body",
  152. "in": "body",
  153. "schema": {
  154. "$ref": "#/definitions/EditUserOption"
  155. }
  156. }
  157. ],
  158. "responses": {
  159. "200": {
  160. "$ref": "#/responses/User"
  161. },
  162. "403": {
  163. "$ref": "#/responses/forbidden"
  164. },
  165. "422": {
  166. "$ref": "#/responses/validationError"
  167. }
  168. }
  169. }
  170. },
  171. "/admin/users/{username}/keys": {
  172. "post": {
  173. "consumes": [
  174. "application/json"
  175. ],
  176. "produces": [
  177. "application/json"
  178. ],
  179. "tags": [
  180. "admin"
  181. ],
  182. "summary": "Add a public key on behalf of a user",
  183. "operationId": "adminCreatePublicKey",
  184. "parameters": [
  185. {
  186. "type": "string",
  187. "description": "username of the user",
  188. "name": "username",
  189. "in": "path",
  190. "required": true
  191. },
  192. {
  193. "name": "key",
  194. "in": "body",
  195. "schema": {
  196. "$ref": "#/definitions/CreateKeyOption"
  197. }
  198. }
  199. ],
  200. "responses": {
  201. "201": {
  202. "$ref": "#/responses/PublicKey"
  203. },
  204. "403": {
  205. "$ref": "#/responses/forbidden"
  206. },
  207. "422": {
  208. "$ref": "#/responses/validationError"
  209. }
  210. }
  211. }
  212. },
  213. "/admin/users/{username}/keys/{id}": {
  214. "delete": {
  215. "produces": [
  216. "application/json"
  217. ],
  218. "tags": [
  219. "admin"
  220. ],
  221. "summary": "Delete a user's public key",
  222. "operationId": "adminDeleteUserPublicKey",
  223. "parameters": [
  224. {
  225. "type": "string",
  226. "description": "username of user",
  227. "name": "username",
  228. "in": "path",
  229. "required": true
  230. },
  231. {
  232. "type": "integer",
  233. "format": "int64",
  234. "description": "id of the key to delete",
  235. "name": "id",
  236. "in": "path",
  237. "required": true
  238. }
  239. ],
  240. "responses": {
  241. "204": {
  242. "$ref": "#/responses/empty"
  243. },
  244. "403": {
  245. "$ref": "#/responses/forbidden"
  246. },
  247. "404": {
  248. "$ref": "#/responses/notFound"
  249. }
  250. }
  251. }
  252. },
  253. "/admin/users/{username}/orgs": {
  254. "post": {
  255. "consumes": [
  256. "application/json"
  257. ],
  258. "produces": [
  259. "application/json"
  260. ],
  261. "tags": [
  262. "admin"
  263. ],
  264. "summary": "Create an organization",
  265. "operationId": "adminCreateOrg",
  266. "parameters": [
  267. {
  268. "type": "string",
  269. "description": "username of the user that will own the created organization",
  270. "name": "username",
  271. "in": "path",
  272. "required": true
  273. },
  274. {
  275. "name": "organization",
  276. "in": "body",
  277. "required": true,
  278. "schema": {
  279. "$ref": "#/definitions/CreateOrgOption"
  280. }
  281. }
  282. ],
  283. "responses": {
  284. "201": {
  285. "$ref": "#/responses/Organization"
  286. },
  287. "403": {
  288. "$ref": "#/responses/forbidden"
  289. },
  290. "422": {
  291. "$ref": "#/responses/validationError"
  292. }
  293. }
  294. }
  295. },
  296. "/admin/users/{username}/repos": {
  297. "post": {
  298. "consumes": [
  299. "application/json"
  300. ],
  301. "produces": [
  302. "application/json"
  303. ],
  304. "tags": [
  305. "admin"
  306. ],
  307. "summary": "Create a repository on behalf a user",
  308. "operationId": "adminCreateRepo",
  309. "parameters": [
  310. {
  311. "type": "string",
  312. "description": "username of the user. This user will own the created repository",
  313. "name": "username",
  314. "in": "path",
  315. "required": true
  316. },
  317. {
  318. "name": "repository",
  319. "in": "body",
  320. "required": true,
  321. "schema": {
  322. "$ref": "#/definitions/CreateRepoOption"
  323. }
  324. }
  325. ],
  326. "responses": {
  327. "201": {
  328. "$ref": "#/responses/Repository"
  329. },
  330. "403": {
  331. "$ref": "#/responses/forbidden"
  332. },
  333. "422": {
  334. "$ref": "#/responses/validationError"
  335. }
  336. }
  337. }
  338. },
  339. "/markdown": {
  340. "post": {
  341. "consumes": [
  342. "application/json"
  343. ],
  344. "produces": [
  345. "text/html"
  346. ],
  347. "tags": [
  348. "miscellaneous"
  349. ],
  350. "summary": "Render a markdown document as HTML",
  351. "operationId": "renderMarkdown",
  352. "parameters": [
  353. {
  354. "name": "body",
  355. "in": "body",
  356. "schema": {
  357. "$ref": "#/definitions/MarkdownOption"
  358. }
  359. }
  360. ],
  361. "responses": {
  362. "200": {
  363. "$ref": "#/responses/MarkdownRender"
  364. },
  365. "422": {
  366. "$ref": "#/responses/validationError"
  367. }
  368. }
  369. }
  370. },
  371. "/markdown/raw": {
  372. "post": {
  373. "consumes": [
  374. "text/plain"
  375. ],
  376. "produces": [
  377. "text/html"
  378. ],
  379. "tags": [
  380. "miscellaneous"
  381. ],
  382. "summary": "Render raw markdown as HTML",
  383. "operationId": "renderMarkdownRaw",
  384. "parameters": [
  385. {
  386. "description": "Request body to render",
  387. "name": "body",
  388. "in": "body",
  389. "required": true,
  390. "schema": {
  391. "type": "string"
  392. }
  393. }
  394. ],
  395. "responses": {
  396. "200": {
  397. "$ref": "#/responses/MarkdownRender"
  398. },
  399. "422": {
  400. "$ref": "#/responses/validationError"
  401. }
  402. }
  403. }
  404. },
  405. "/org/{org}/repos": {
  406. "post": {
  407. "consumes": [
  408. "application/json"
  409. ],
  410. "produces": [
  411. "application/json"
  412. ],
  413. "tags": [
  414. "organization"
  415. ],
  416. "summary": "Create a repository in an organization",
  417. "operationId": "createOrgRepo",
  418. "parameters": [
  419. {
  420. "type": "string",
  421. "description": "name of organization",
  422. "name": "org",
  423. "in": "path",
  424. "required": true
  425. },
  426. {
  427. "name": "body",
  428. "in": "body",
  429. "schema": {
  430. "$ref": "#/definitions/CreateRepoOption"
  431. }
  432. }
  433. ],
  434. "responses": {
  435. "201": {
  436. "$ref": "#/responses/Repository"
  437. },
  438. "403": {
  439. "$ref": "#/responses/forbidden"
  440. },
  441. "422": {
  442. "$ref": "#/responses/validationError"
  443. }
  444. }
  445. }
  446. },
  447. "/orgs": {
  448. "post": {
  449. "consumes": [
  450. "application/json"
  451. ],
  452. "produces": [
  453. "application/json"
  454. ],
  455. "tags": [
  456. "organization"
  457. ],
  458. "summary": "Create an organization",
  459. "operationId": "orgCreate",
  460. "parameters": [
  461. {
  462. "name": "organization",
  463. "in": "body",
  464. "required": true,
  465. "schema": {
  466. "$ref": "#/definitions/CreateOrgOption"
  467. }
  468. }
  469. ],
  470. "responses": {
  471. "201": {
  472. "$ref": "#/responses/Organization"
  473. },
  474. "403": {
  475. "$ref": "#/responses/forbidden"
  476. },
  477. "422": {
  478. "$ref": "#/responses/validationError"
  479. }
  480. }
  481. }
  482. },
  483. "/orgs/{org}": {
  484. "get": {
  485. "produces": [
  486. "application/json"
  487. ],
  488. "tags": [
  489. "organization"
  490. ],
  491. "summary": "Get an organization",
  492. "operationId": "orgGet",
  493. "parameters": [
  494. {
  495. "type": "string",
  496. "description": "name of the organization to get",
  497. "name": "org",
  498. "in": "path",
  499. "required": true
  500. }
  501. ],
  502. "responses": {
  503. "200": {
  504. "$ref": "#/responses/Organization"
  505. }
  506. }
  507. },
  508. "delete": {
  509. "produces": [
  510. "application/json"
  511. ],
  512. "tags": [
  513. "organization"
  514. ],
  515. "summary": "Delete an organization",
  516. "operationId": "orgDelete",
  517. "parameters": [
  518. {
  519. "type": "string",
  520. "description": "organization that is to be deleted",
  521. "name": "org",
  522. "in": "path",
  523. "required": true
  524. }
  525. ],
  526. "responses": {
  527. "204": {
  528. "$ref": "#/responses/empty"
  529. }
  530. }
  531. },
  532. "patch": {
  533. "consumes": [
  534. "application/json"
  535. ],
  536. "produces": [
  537. "application/json"
  538. ],
  539. "tags": [
  540. "organization"
  541. ],
  542. "summary": "Edit an organization",
  543. "operationId": "orgEdit",
  544. "parameters": [
  545. {
  546. "type": "string",
  547. "description": "name of the organization to edit",
  548. "name": "org",
  549. "in": "path",
  550. "required": true
  551. },
  552. {
  553. "name": "body",
  554. "in": "body",
  555. "schema": {
  556. "$ref": "#/definitions/EditOrgOption"
  557. }
  558. }
  559. ],
  560. "responses": {
  561. "200": {
  562. "$ref": "#/responses/Organization"
  563. }
  564. }
  565. }
  566. },
  567. "/orgs/{org}/hooks": {
  568. "get": {
  569. "produces": [
  570. "application/json"
  571. ],
  572. "tags": [
  573. "organization"
  574. ],
  575. "summary": "List an organization's webhooks",
  576. "operationId": "orgListHooks",
  577. "parameters": [
  578. {
  579. "type": "string",
  580. "description": "name of the organization",
  581. "name": "org",
  582. "in": "path",
  583. "required": true
  584. }
  585. ],
  586. "responses": {
  587. "200": {
  588. "$ref": "#/responses/HookList"
  589. }
  590. }
  591. }
  592. },
  593. "/orgs/{org}/hooks/": {
  594. "post": {
  595. "consumes": [
  596. "application/json"
  597. ],
  598. "produces": [
  599. "application/json"
  600. ],
  601. "tags": [
  602. "organization"
  603. ],
  604. "summary": "Create a hook",
  605. "operationId": "orgCreateHook",
  606. "parameters": [
  607. {
  608. "type": "string",
  609. "description": "name of the organization",
  610. "name": "org",
  611. "in": "path",
  612. "required": true
  613. },
  614. {
  615. "name": "body",
  616. "in": "body",
  617. "required": true,
  618. "schema": {
  619. "$ref": "#/definitions/CreateHookOption"
  620. }
  621. }
  622. ],
  623. "responses": {
  624. "201": {
  625. "$ref": "#/responses/Hook"
  626. }
  627. }
  628. }
  629. },
  630. "/orgs/{org}/hooks/{id}": {
  631. "get": {
  632. "produces": [
  633. "application/json"
  634. ],
  635. "tags": [
  636. "organization"
  637. ],
  638. "summary": "Get a hook",
  639. "operationId": "orgGetHook",
  640. "parameters": [
  641. {
  642. "type": "string",
  643. "description": "name of the organization",
  644. "name": "org",
  645. "in": "path",
  646. "required": true
  647. },
  648. {
  649. "type": "integer",
  650. "format": "int64",
  651. "description": "id of the hook to get",
  652. "name": "id",
  653. "in": "path",
  654. "required": true
  655. }
  656. ],
  657. "responses": {
  658. "200": {
  659. "$ref": "#/responses/Hook"
  660. }
  661. }
  662. },
  663. "delete": {
  664. "produces": [
  665. "application/json"
  666. ],
  667. "tags": [
  668. "organization"
  669. ],
  670. "summary": "Delete a hook",
  671. "operationId": "orgDeleteHook",
  672. "parameters": [
  673. {
  674. "type": "string",
  675. "description": "name of the organization",
  676. "name": "org",
  677. "in": "path",
  678. "required": true
  679. },
  680. {
  681. "type": "integer",
  682. "format": "int64",
  683. "description": "id of the hook to delete",
  684. "name": "id",
  685. "in": "path",
  686. "required": true
  687. }
  688. ],
  689. "responses": {
  690. "204": {
  691. "$ref": "#/responses/empty"
  692. }
  693. }
  694. },
  695. "patch": {
  696. "consumes": [
  697. "application/json"
  698. ],
  699. "produces": [
  700. "application/json"
  701. ],
  702. "tags": [
  703. "organization"
  704. ],
  705. "summary": "Update a hook",
  706. "operationId": "orgEditHook",
  707. "parameters": [
  708. {
  709. "type": "string",
  710. "description": "name of the organization",
  711. "name": "org",
  712. "in": "path",
  713. "required": true
  714. },
  715. {
  716. "type": "integer",
  717. "format": "int64",
  718. "description": "id of the hook to update",
  719. "name": "id",
  720. "in": "path",
  721. "required": true
  722. },
  723. {
  724. "name": "body",
  725. "in": "body",
  726. "schema": {
  727. "$ref": "#/definitions/EditHookOption"
  728. }
  729. }
  730. ],
  731. "responses": {
  732. "200": {
  733. "$ref": "#/responses/Hook"
  734. }
  735. }
  736. }
  737. },
  738. "/orgs/{org}/members": {
  739. "get": {
  740. "produces": [
  741. "application/json"
  742. ],
  743. "tags": [
  744. "organization"
  745. ],
  746. "summary": "List an organization's members",
  747. "operationId": "orgListMembers",
  748. "parameters": [
  749. {
  750. "type": "string",
  751. "description": "name of the organization",
  752. "name": "org",
  753. "in": "path",
  754. "required": true
  755. }
  756. ],
  757. "responses": {
  758. "200": {
  759. "$ref": "#/responses/UserList"
  760. }
  761. }
  762. }
  763. },
  764. "/orgs/{org}/members/{username}": {
  765. "get": {
  766. "tags": [
  767. "organization"
  768. ],
  769. "summary": "Check if a user is a member of an organization",
  770. "operationId": "orgIsMember",
  771. "parameters": [
  772. {
  773. "type": "string",
  774. "description": "name of the organization",
  775. "name": "org",
  776. "in": "path",
  777. "required": true
  778. },
  779. {
  780. "type": "string",
  781. "description": "username of the user",
  782. "name": "username",
  783. "in": "path",
  784. "required": true
  785. }
  786. ],
  787. "responses": {
  788. "204": {
  789. "description": "user is a member"
  790. },
  791. "404": {
  792. "description": "user is not a member"
  793. }
  794. }
  795. },
  796. "delete": {
  797. "produces": [
  798. "application/json"
  799. ],
  800. "tags": [
  801. "organization"
  802. ],
  803. "summary": "Remove a member from an organization",
  804. "operationId": "orgDeleteMember",
  805. "parameters": [
  806. {
  807. "type": "string",
  808. "description": "name of the organization",
  809. "name": "org",
  810. "in": "path",
  811. "required": true
  812. },
  813. {
  814. "type": "string",
  815. "description": "username of the user",
  816. "name": "username",
  817. "in": "path",
  818. "required": true
  819. }
  820. ],
  821. "responses": {
  822. "204": {
  823. "description": "member removed"
  824. }
  825. }
  826. }
  827. },
  828. "/orgs/{org}/public_members": {
  829. "get": {
  830. "produces": [
  831. "application/json"
  832. ],
  833. "tags": [
  834. "organization"
  835. ],
  836. "summary": "List an organization's public members",
  837. "operationId": "orgListPublicMembers",
  838. "parameters": [
  839. {
  840. "type": "string",
  841. "description": "name of the organization",
  842. "name": "org",
  843. "in": "path",
  844. "required": true
  845. }
  846. ],
  847. "responses": {
  848. "200": {
  849. "$ref": "#/responses/UserList"
  850. }
  851. }
  852. }
  853. },
  854. "/orgs/{org}/public_members/{username}": {
  855. "get": {
  856. "tags": [
  857. "organization"
  858. ],
  859. "summary": "Check if a user is a public member of an organization",
  860. "operationId": "orgIsPublicMember",
  861. "parameters": [
  862. {
  863. "type": "string",
  864. "description": "name of the organization",
  865. "name": "org",
  866. "in": "path",
  867. "required": true
  868. },
  869. {
  870. "type": "string",
  871. "description": "username of the user",
  872. "name": "username",
  873. "in": "path",
  874. "required": true
  875. }
  876. ],
  877. "responses": {
  878. "204": {
  879. "description": "user is a public member"
  880. },
  881. "404": {
  882. "description": "user is not a public member"
  883. }
  884. }
  885. },
  886. "put": {
  887. "produces": [
  888. "application/json"
  889. ],
  890. "tags": [
  891. "organization"
  892. ],
  893. "summary": "Publicize a user's membership",
  894. "operationId": "orgPublicizeMember",
  895. "parameters": [
  896. {
  897. "type": "string",
  898. "description": "name of the organization",
  899. "name": "org",
  900. "in": "path",
  901. "required": true
  902. },
  903. {
  904. "type": "string",
  905. "description": "username of the user",
  906. "name": "username",
  907. "in": "path",
  908. "required": true
  909. }
  910. ],
  911. "responses": {
  912. "204": {
  913. "description": "membership publicized"
  914. }
  915. }
  916. },
  917. "delete": {
  918. "produces": [
  919. "application/json"
  920. ],
  921. "tags": [
  922. "organization"
  923. ],
  924. "summary": "Conceal a user's membership",
  925. "operationId": "orgConcealMember",
  926. "parameters": [
  927. {
  928. "type": "string",
  929. "description": "name of the organization",
  930. "name": "org",
  931. "in": "path",
  932. "required": true
  933. },
  934. {
  935. "type": "string",
  936. "description": "username of the user",
  937. "name": "username",
  938. "in": "path",
  939. "required": true
  940. }
  941. ],
  942. "responses": {
  943. "204": {
  944. "$ref": "#/responses/empty"
  945. }
  946. }
  947. }
  948. },
  949. "/orgs/{org}/repos": {
  950. "get": {
  951. "produces": [
  952. "application/json"
  953. ],
  954. "tags": [
  955. "organization"
  956. ],
  957. "summary": "List an organization's repos",
  958. "operationId": "orgListRepos",
  959. "parameters": [
  960. {
  961. "type": "string",
  962. "description": "name of the organization",
  963. "name": "org",
  964. "in": "path",
  965. "required": true
  966. }
  967. ],
  968. "responses": {
  969. "200": {
  970. "$ref": "#/responses/RepositoryList"
  971. }
  972. }
  973. }
  974. },
  975. "/orgs/{org}/teams": {
  976. "get": {
  977. "produces": [
  978. "application/json"
  979. ],
  980. "tags": [
  981. "organization"
  982. ],
  983. "summary": "List an organization's teams",
  984. "operationId": "orgListTeams",
  985. "parameters": [
  986. {
  987. "type": "string",
  988. "description": "name of the organization",
  989. "name": "org",
  990. "in": "path",
  991. "required": true
  992. }
  993. ],
  994. "responses": {
  995. "200": {
  996. "$ref": "#/responses/TeamList"
  997. }
  998. }
  999. },
  1000. "post": {
  1001. "consumes": [
  1002. "application/json"
  1003. ],
  1004. "produces": [
  1005. "application/json"
  1006. ],
  1007. "tags": [
  1008. "organization"
  1009. ],
  1010. "summary": "Create a team",
  1011. "operationId": "orgCreateTeam",
  1012. "parameters": [
  1013. {
  1014. "type": "string",
  1015. "description": "name of the organization",
  1016. "name": "org",
  1017. "in": "path",
  1018. "required": true
  1019. },
  1020. {
  1021. "name": "body",
  1022. "in": "body",
  1023. "schema": {
  1024. "$ref": "#/definitions/CreateTeamOption"
  1025. }
  1026. }
  1027. ],
  1028. "responses": {
  1029. "201": {
  1030. "$ref": "#/responses/Team"
  1031. }
  1032. }
  1033. }
  1034. },
  1035. "/repos/migrate": {
  1036. "post": {
  1037. "consumes": [
  1038. "application/json"
  1039. ],
  1040. "produces": [
  1041. "application/json"
  1042. ],
  1043. "tags": [
  1044. "repository"
  1045. ],
  1046. "summary": "Migrate a remote git repository",
  1047. "operationId": "repoMigrate",
  1048. "parameters": [
  1049. {
  1050. "name": "body",
  1051. "in": "body",
  1052. "schema": {
  1053. "$ref": "#/definitions/MigrateRepoForm"
  1054. }
  1055. }
  1056. ],
  1057. "responses": {
  1058. "201": {
  1059. "$ref": "#/responses/Repository"
  1060. }
  1061. }
  1062. }
  1063. },
  1064. "/repos/search": {
  1065. "get": {
  1066. "produces": [
  1067. "application/json"
  1068. ],
  1069. "tags": [
  1070. "repository"
  1071. ],
  1072. "summary": "Search for repositories",
  1073. "operationId": "repoSearch",
  1074. "parameters": [
  1075. {
  1076. "type": "string",
  1077. "description": "keyword",
  1078. "name": "q",
  1079. "in": "query"
  1080. },
  1081. {
  1082. "type": "integer",
  1083. "format": "int64",
  1084. "description": "search only for repos that the user with the given id owns or contributes to",
  1085. "name": "uid",
  1086. "in": "query"
  1087. },
  1088. {
  1089. "type": "integer",
  1090. "description": "page number of results to return (1-based)",
  1091. "name": "page",
  1092. "in": "query"
  1093. },
  1094. {
  1095. "type": "integer",
  1096. "description": "page size of results, maximum page size is 50",
  1097. "name": "limit",
  1098. "in": "query"
  1099. },
  1100. {
  1101. "type": "string",
  1102. "description": "type of repository to search for. Supported values are \"fork\", \"source\", \"mirror\" and \"collaborative\"",
  1103. "name": "mode",
  1104. "in": "query"
  1105. },
  1106. {
  1107. "type": "boolean",
  1108. "description": "if `uid` is given, search only for repos that the user owns",
  1109. "name": "exclusive",
  1110. "in": "query"
  1111. },
  1112. {
  1113. "type": "string",
  1114. "description": "sort repos by attribute. Supported values are \"alpha\", \"created\", \"updated\", \"size\", and \"id\". Default is \"alpha\"",
  1115. "name": "sort",
  1116. "in": "query"
  1117. },
  1118. {
  1119. "type": "string",
  1120. "description": "sort order, either \"asc\" (ascending) or \"desc\" (descending). Default is \"asc\", ignored if \"sort\" is not specified.",
  1121. "name": "order",
  1122. "in": "query"
  1123. }
  1124. ],
  1125. "responses": {
  1126. "200": {
  1127. "$ref": "#/responses/SearchResults"
  1128. },
  1129. "422": {
  1130. "$ref": "#/responses/validationError"
  1131. }
  1132. }
  1133. }
  1134. },
  1135. "/repos/{owner}/{repo}": {
  1136. "get": {
  1137. "produces": [
  1138. "application/json"
  1139. ],
  1140. "tags": [
  1141. "repository"
  1142. ],
  1143. "summary": "Get a repository",
  1144. "operationId": "repoGet",
  1145. "parameters": [
  1146. {
  1147. "type": "string",
  1148. "description": "owner of the repo",
  1149. "name": "owner",
  1150. "in": "path",
  1151. "required": true
  1152. },
  1153. {
  1154. "type": "string",
  1155. "description": "name of the repo",
  1156. "name": "repo",
  1157. "in": "path",
  1158. "required": true
  1159. }
  1160. ],
  1161. "responses": {
  1162. "200": {
  1163. "$ref": "#/responses/Repository"
  1164. }
  1165. }
  1166. },
  1167. "delete": {
  1168. "produces": [
  1169. "application/json"
  1170. ],
  1171. "tags": [
  1172. "repository"
  1173. ],
  1174. "summary": "Delete a repository",
  1175. "operationId": "repoDelete",
  1176. "parameters": [
  1177. {
  1178. "type": "string",
  1179. "description": "owner of the repo to delete",
  1180. "name": "owner",
  1181. "in": "path",
  1182. "required": true
  1183. },
  1184. {
  1185. "type": "string",
  1186. "description": "name of the repo to delete",
  1187. "name": "repo",
  1188. "in": "path",
  1189. "required": true
  1190. }
  1191. ],
  1192. "responses": {
  1193. "204": {
  1194. "$ref": "#/responses/empty"
  1195. },
  1196. "403": {
  1197. "$ref": "#/responses/forbidden"
  1198. }
  1199. }
  1200. }
  1201. },
  1202. "/repos/{owner}/{repo}/archive/{archive}": {
  1203. "get": {
  1204. "produces": [
  1205. "application/json"
  1206. ],
  1207. "tags": [
  1208. "repository"
  1209. ],
  1210. "summary": "Get an archive of a repository",
  1211. "operationId": "repoGetArchive",
  1212. "parameters": [
  1213. {
  1214. "type": "string",
  1215. "description": "owner of the repo",
  1216. "name": "owner",
  1217. "in": "path",
  1218. "required": true
  1219. },
  1220. {
  1221. "type": "string",
  1222. "description": "name of the repo",
  1223. "name": "repo",
  1224. "in": "path",
  1225. "required": true
  1226. },
  1227. {
  1228. "type": "string",
  1229. "description": "archive to download, consisting of a git reference and archive",
  1230. "name": "archive",
  1231. "in": "path",
  1232. "required": true
  1233. }
  1234. ],
  1235. "responses": {
  1236. "200": {
  1237. "description": "success"
  1238. }
  1239. }
  1240. }
  1241. },
  1242. "/repos/{owner}/{repo}/branches": {
  1243. "get": {
  1244. "produces": [
  1245. "application/json"
  1246. ],
  1247. "tags": [
  1248. "repository"
  1249. ],
  1250. "summary": "List a repository's branches",
  1251. "operationId": "repoListBranches",
  1252. "parameters": [
  1253. {
  1254. "type": "string",
  1255. "description": "owner of the repo",
  1256. "name": "owner",
  1257. "in": "path",
  1258. "required": true
  1259. },
  1260. {
  1261. "type": "string",
  1262. "description": "name of the repo",
  1263. "name": "repo",
  1264. "in": "path",
  1265. "required": true
  1266. }
  1267. ],
  1268. "responses": {
  1269. "200": {
  1270. "$ref": "#/responses/BranchList"
  1271. }
  1272. }
  1273. }
  1274. },
  1275. "/repos/{owner}/{repo}/branches/{branch}": {
  1276. "get": {
  1277. "produces": [
  1278. "application/json"
  1279. ],
  1280. "tags": [
  1281. "repository"
  1282. ],
  1283. "summary": "Retrieve a specific branch from a repository",
  1284. "operationId": "repoGetBranch",
  1285. "parameters": [
  1286. {
  1287. "type": "string",
  1288. "description": "owner of the repo",
  1289. "name": "owner",
  1290. "in": "path",
  1291. "required": true
  1292. },
  1293. {
  1294. "type": "string",
  1295. "description": "name of the repo",
  1296. "name": "repo",
  1297. "in": "path",
  1298. "required": true
  1299. },
  1300. {
  1301. "type": "string",
  1302. "description": "branch to get",
  1303. "name": "branch",
  1304. "in": "path",
  1305. "required": true
  1306. }
  1307. ],
  1308. "responses": {
  1309. "200": {
  1310. "$ref": "#/responses/Branch"
  1311. }
  1312. }
  1313. }
  1314. },
  1315. "/repos/{owner}/{repo}/collaborators": {
  1316. "get": {
  1317. "produces": [
  1318. "application/json"
  1319. ],
  1320. "tags": [
  1321. "repository"
  1322. ],
  1323. "summary": "List a repository's collaborators",
  1324. "operationId": "repoListCollaborators",
  1325. "parameters": [
  1326. {
  1327. "type": "string",
  1328. "description": "owner of the repo",
  1329. "name": "owner",
  1330. "in": "path",
  1331. "required": true
  1332. },
  1333. {
  1334. "type": "string",
  1335. "description": "name of the repo",
  1336. "name": "repo",
  1337. "in": "path",
  1338. "required": true
  1339. }
  1340. ],
  1341. "responses": {
  1342. "200": {
  1343. "$ref": "#/responses/UserList"
  1344. }
  1345. }
  1346. }
  1347. },
  1348. "/repos/{owner}/{repo}/collaborators/{collaborator}": {
  1349. "get": {
  1350. "produces": [
  1351. "application/json"
  1352. ],
  1353. "tags": [
  1354. "repository"
  1355. ],
  1356. "summary": "Check if a user is a collaborator of a repository",
  1357. "operationId": "repoCheckCollaborator",
  1358. "parameters": [
  1359. {
  1360. "type": "string",
  1361. "description": "owner of the repo",
  1362. "name": "owner",
  1363. "in": "path",
  1364. "required": true
  1365. },
  1366. {
  1367. "type": "string",
  1368. "description": "name of the repo",
  1369. "name": "repo",
  1370. "in": "path",
  1371. "required": true
  1372. },
  1373. {
  1374. "type": "string",
  1375. "description": "username of the collaborator",
  1376. "name": "collaborator",
  1377. "in": "path",
  1378. "required": true
  1379. }
  1380. ],
  1381. "responses": {
  1382. "204": {
  1383. "$ref": "#/responses/empty"
  1384. },
  1385. "404": {
  1386. "$ref": "#/responses/empty"
  1387. }
  1388. }
  1389. },
  1390. "put": {
  1391. "produces": [
  1392. "application/json"
  1393. ],
  1394. "tags": [
  1395. "repository"
  1396. ],
  1397. "summary": "Add a collaborator to a repository",
  1398. "operationId": "repoAddCollaborator",
  1399. "parameters": [
  1400. {
  1401. "type": "string",
  1402. "description": "owner of the repo",
  1403. "name": "owner",
  1404. "in": "path",
  1405. "required": true
  1406. },
  1407. {
  1408. "type": "string",
  1409. "description": "name of the repo",
  1410. "name": "repo",
  1411. "in": "path",
  1412. "required": true
  1413. },
  1414. {
  1415. "type": "string",
  1416. "description": "username of the collaborator to add",
  1417. "name": "collaborator",
  1418. "in": "path",
  1419. "required": true
  1420. },
  1421. {
  1422. "name": "body",
  1423. "in": "body",
  1424. "schema": {
  1425. "$ref": "#/definitions/AddCollaboratorOption"
  1426. }
  1427. }
  1428. ],
  1429. "responses": {
  1430. "204": {
  1431. "$ref": "#/responses/empty"
  1432. }
  1433. }
  1434. },
  1435. "delete": {
  1436. "produces": [
  1437. "application/json"
  1438. ],
  1439. "tags": [
  1440. "repository"
  1441. ],
  1442. "summary": "Delete a collaborator from a repository",
  1443. "operationId": "repoDeleteCollaborator",
  1444. "parameters": [
  1445. {
  1446. "type": "string",
  1447. "description": "owner of the repo",
  1448. "name": "owner",
  1449. "in": "path",
  1450. "required": true
  1451. },
  1452. {
  1453. "type": "string",
  1454. "description": "name of the repo",
  1455. "name": "repo",
  1456. "in": "path",
  1457. "required": true
  1458. },
  1459. {
  1460. "type": "string",
  1461. "description": "username of the collaborator to delete",
  1462. "name": "collaborator",
  1463. "in": "path",
  1464. "required": true
  1465. }
  1466. ],
  1467. "responses": {
  1468. "204": {
  1469. "$ref": "#/responses/empty"
  1470. }
  1471. }
  1472. }
  1473. },
  1474. "/repos/{owner}/{repo}/commits/{ref}/statuses": {
  1475. "get": {
  1476. "produces": [
  1477. "application/json"
  1478. ],
  1479. "tags": [
  1480. "repository"
  1481. ],
  1482. "summary": "Get a commit's combined status, by branch/tag/commit reference",
  1483. "operationId": "repoGetCombinedStatusByRef",
  1484. "parameters": [
  1485. {
  1486. "type": "string",
  1487. "description": "owner of the repo",
  1488. "name": "owner",
  1489. "in": "path",
  1490. "required": true
  1491. },
  1492. {
  1493. "type": "string",
  1494. "description": "name of the repo",
  1495. "name": "repo",
  1496. "in": "path",
  1497. "required": true
  1498. },
  1499. {
  1500. "type": "string",
  1501. "description": "name of branch/tag/commit",
  1502. "name": "ref",
  1503. "in": "path",
  1504. "required": true
  1505. }
  1506. ],
  1507. "responses": {
  1508. "200": {
  1509. "$ref": "#/responses/Status"
  1510. }
  1511. }
  1512. }
  1513. },
  1514. "/repos/{owner}/{repo}/editorconfig/{filepath}": {
  1515. "get": {
  1516. "produces": [
  1517. "application/json"
  1518. ],
  1519. "tags": [
  1520. "repository"
  1521. ],
  1522. "summary": "Get the EditorConfig definitions of a file in a repository",
  1523. "operationId": "repoGetEditorConfig",
  1524. "parameters": [
  1525. {
  1526. "type": "string",
  1527. "description": "owner of the repo",
  1528. "name": "owner",
  1529. "in": "path",
  1530. "required": true
  1531. },
  1532. {
  1533. "type": "string",
  1534. "description": "name of the repo",
  1535. "name": "repo",
  1536. "in": "path",
  1537. "required": true
  1538. },
  1539. {
  1540. "type": "string",
  1541. "description": "filepath of file to get",
  1542. "name": "filepath",
  1543. "in": "path",
  1544. "required": true
  1545. }
  1546. ],
  1547. "responses": {
  1548. "200": {
  1549. "description": "success"
  1550. }
  1551. }
  1552. }
  1553. },
  1554. "/repos/{owner}/{repo}/forks": {
  1555. "get": {
  1556. "produces": [
  1557. "application/json"
  1558. ],
  1559. "tags": [
  1560. "repository"
  1561. ],
  1562. "summary": "List a repository's forks",
  1563. "operationId": "listForks",
  1564. "parameters": [
  1565. {
  1566. "type": "string",
  1567. "description": "owner of the repo",
  1568. "name": "owner",
  1569. "in": "path",
  1570. "required": true
  1571. },
  1572. {
  1573. "type": "string",
  1574. "description": "name of the repo",
  1575. "name": "repo",
  1576. "in": "path",
  1577. "required": true
  1578. }
  1579. ],
  1580. "responses": {
  1581. "200": {
  1582. "$ref": "#/responses/RepositoryList"
  1583. }
  1584. }
  1585. },
  1586. "post": {
  1587. "produces": [
  1588. "application/json"
  1589. ],
  1590. "tags": [
  1591. "repository"
  1592. ],
  1593. "summary": "Fork a repository",
  1594. "operationId": "createFork",
  1595. "parameters": [
  1596. {
  1597. "type": "string",
  1598. "description": "owner of the repo to fork",
  1599. "name": "owner",
  1600. "in": "path",
  1601. "required": true
  1602. },
  1603. {
  1604. "type": "string",
  1605. "description": "name of the repo to fork",
  1606. "name": "repo",
  1607. "in": "path",
  1608. "required": true
  1609. },
  1610. {
  1611. "name": "body",
  1612. "in": "body",
  1613. "schema": {
  1614. "$ref": "#/definitions/CreateForkOption"
  1615. }
  1616. }
  1617. ],
  1618. "responses": {
  1619. "202": {
  1620. "$ref": "#/responses/Repository"
  1621. }
  1622. }
  1623. }
  1624. },
  1625. "/repos/{owner}/{repo}/git/commits/{sha}": {
  1626. "get": {
  1627. "produces": [
  1628. "application/json"
  1629. ],
  1630. "tags": [
  1631. "repository"
  1632. ],
  1633. "summary": "Get a single commit from a repository",
  1634. "operationId": "repoGetSingleCommit",
  1635. "parameters": [
  1636. {
  1637. "type": "string",
  1638. "description": "owner of the repo",
  1639. "name": "owner",
  1640. "in": "path",
  1641. "required": true
  1642. },
  1643. {
  1644. "type": "string",
  1645. "description": "name of the repo",
  1646. "name": "repo",
  1647. "in": "path",
  1648. "required": true
  1649. },
  1650. {
  1651. "type": "string",
  1652. "description": "the commit hash",
  1653. "name": "sha",
  1654. "in": "path",
  1655. "required": true
  1656. }
  1657. ],
  1658. "responses": {
  1659. "200": {
  1660. "$ref": "#/responses/Commit"
  1661. },
  1662. "404": {
  1663. "$ref": "#/responses/notFound"
  1664. }
  1665. }
  1666. }
  1667. },
  1668. "/repos/{owner}/{repo}/git/refs": {
  1669. "get": {
  1670. "produces": [
  1671. "application/json"
  1672. ],
  1673. "tags": [
  1674. "repository"
  1675. ],
  1676. "summary": "Get specified ref or filtered repository's refs",
  1677. "operationId": "repoListAllGitRefs",
  1678. "parameters": [
  1679. {
  1680. "type": "string",
  1681. "description": "owner of the repo",
  1682. "name": "owner",
  1683. "in": "path",
  1684. "required": true
  1685. },
  1686. {
  1687. "type": "string",
  1688. "description": "name of the repo",
  1689. "name": "repo",
  1690. "in": "path",
  1691. "required": true
  1692. }
  1693. ],
  1694. "responses": {
  1695. "200": {
  1696. "$ref": "#/responses/ReferenceList"
  1697. },
  1698. "404": {
  1699. "$ref": "#/responses/notFound"
  1700. }
  1701. }
  1702. }
  1703. },
  1704. "/repos/{owner}/{repo}/git/refs/{ref}": {
  1705. "get": {
  1706. "produces": [
  1707. "application/json"
  1708. ],
  1709. "tags": [
  1710. "repository"
  1711. ],
  1712. "summary": "Get specified ref or filtered repository's refs",
  1713. "operationId": "repoListGitRefs",
  1714. "parameters": [
  1715. {
  1716. "type": "string",
  1717. "description": "owner of the repo",
  1718. "name": "owner",
  1719. "in": "path",
  1720. "required": true
  1721. },
  1722. {
  1723. "type": "string",
  1724. "description": "name of the repo",
  1725. "name": "repo",
  1726. "in": "path",
  1727. "required": true
  1728. },
  1729. {
  1730. "type": "string",
  1731. "description": "part or full name of the ref",
  1732. "name": "ref",
  1733. "in": "path",
  1734. "required": true
  1735. }
  1736. ],
  1737. "responses": {
  1738. "200": {
  1739. "$ref": "#/responses/ReferenceList"
  1740. },
  1741. "404": {
  1742. "$ref": "#/responses/notFound"
  1743. }
  1744. }
  1745. }
  1746. },
  1747. "/repos/{owner}/{repo}/git/trees/{sha}": {
  1748. "get": {
  1749. "produces": [
  1750. "application/json"
  1751. ],
  1752. "tags": [
  1753. "repository"
  1754. ],
  1755. "summary": "Gets the tree of a repository.",
  1756. "operationId": "GetTree",
  1757. "parameters": [
  1758. {
  1759. "type": "string",
  1760. "description": "owner of the repo",
  1761. "name": "owner",
  1762. "in": "path",
  1763. "required": true
  1764. },
  1765. {
  1766. "type": "string",
  1767. "description": "name of the repo",
  1768. "name": "repo",
  1769. "in": "path",
  1770. "required": true
  1771. },
  1772. {
  1773. "type": "string",
  1774. "description": "sha of the commit",
  1775. "name": "sha",
  1776. "in": "path",
  1777. "required": true
  1778. }
  1779. ],
  1780. "responses": {
  1781. "200": {
  1782. "$ref": "#/responses/GitTreeResponse"
  1783. }
  1784. }
  1785. }
  1786. },
  1787. "/repos/{owner}/{repo}/hooks": {
  1788. "get": {
  1789. "produces": [
  1790. "application/json"
  1791. ],
  1792. "tags": [
  1793. "repository"
  1794. ],
  1795. "summary": "List the hooks in a repository",
  1796. "operationId": "repoListHooks",
  1797. "parameters": [
  1798. {
  1799. "type": "string",
  1800. "description": "owner of the repo",
  1801. "name": "owner",
  1802. "in": "path",
  1803. "required": true
  1804. },
  1805. {
  1806. "type": "string",
  1807. "description": "name of the repo",
  1808. "name": "repo",
  1809. "in": "path",
  1810. "required": true
  1811. }
  1812. ],
  1813. "responses": {
  1814. "200": {
  1815. "$ref": "#/responses/HookList"
  1816. }
  1817. }
  1818. },
  1819. "post": {
  1820. "consumes": [
  1821. "application/json"
  1822. ],
  1823. "produces": [
  1824. "application/json"
  1825. ],
  1826. "tags": [
  1827. "repository"
  1828. ],
  1829. "summary": "Create a hook",
  1830. "operationId": "repoCreateHook",
  1831. "parameters": [
  1832. {
  1833. "type": "string",
  1834. "description": "owner of the repo",
  1835. "name": "owner",
  1836. "in": "path",
  1837. "required": true
  1838. },
  1839. {
  1840. "type": "string",
  1841. "description": "name of the repo",
  1842. "name": "repo",
  1843. "in": "path",
  1844. "required": true
  1845. },
  1846. {
  1847. "name": "body",
  1848. "in": "body",
  1849. "schema": {
  1850. "$ref": "#/definitions/CreateHookOption"
  1851. }
  1852. }
  1853. ],
  1854. "responses": {
  1855. "201": {
  1856. "$ref": "#/responses/Hook"
  1857. }
  1858. }
  1859. }
  1860. },
  1861. "/repos/{owner}/{repo}/hooks/{id}": {
  1862. "get": {
  1863. "produces": [
  1864. "application/json"
  1865. ],
  1866. "tags": [
  1867. "repository"
  1868. ],
  1869. "summary": "Get a hook",
  1870. "operationId": "repoGetHook",
  1871. "parameters": [
  1872. {
  1873. "type": "string",
  1874. "description": "owner of the repo",
  1875. "name": "owner",
  1876. "in": "path",
  1877. "required": true
  1878. },
  1879. {
  1880. "type": "string",
  1881. "description": "name of the repo",
  1882. "name": "repo",
  1883. "in": "path",
  1884. "required": true
  1885. },
  1886. {
  1887. "type": "integer",
  1888. "format": "int64",
  1889. "description": "id of the hook to get",
  1890. "name": "id",
  1891. "in": "path",
  1892. "required": true
  1893. }
  1894. ],
  1895. "responses": {
  1896. "200": {
  1897. "$ref": "#/responses/Hook"
  1898. }
  1899. }
  1900. },
  1901. "delete": {
  1902. "produces": [
  1903. "application/json"
  1904. ],
  1905. "tags": [
  1906. "repository"
  1907. ],
  1908. "summary": "Delete a hook in a repository",
  1909. "operationId": "repoDeleteHook",
  1910. "parameters": [
  1911. {
  1912. "type": "string",
  1913. "description": "owner of the repo",
  1914. "name": "owner",
  1915. "in": "path",
  1916. "required": true
  1917. },
  1918. {
  1919. "type": "string",
  1920. "description": "name of the repo",
  1921. "name": "repo",
  1922. "in": "path",
  1923. "required": true
  1924. },
  1925. {
  1926. "type": "integer",
  1927. "format": "int64",
  1928. "description": "id of the hook to delete",
  1929. "name": "id",
  1930. "in": "path",
  1931. "required": true
  1932. }
  1933. ],
  1934. "responses": {
  1935. "204": {
  1936. "$ref": "#/responses/empty"
  1937. },
  1938. "404": {
  1939. "$ref": "#/responses/notFound"
  1940. }
  1941. }
  1942. },
  1943. "patch": {
  1944. "produces": [
  1945. "application/json"
  1946. ],
  1947. "tags": [
  1948. "repository"
  1949. ],
  1950. "summary": "Edit a hook in a repository",
  1951. "operationId": "repoEditHook",
  1952. "parameters": [
  1953. {
  1954. "type": "string",
  1955. "description": "owner of the repo",
  1956. "name": "owner",
  1957. "in": "path",
  1958. "required": true
  1959. },
  1960. {
  1961. "type": "string",
  1962. "description": "name of the repo",
  1963. "name": "repo",
  1964. "in": "path",
  1965. "required": true
  1966. },
  1967. {
  1968. "type": "integer",
  1969. "format": "int64",
  1970. "description": "index of the hook",
  1971. "name": "id",
  1972. "in": "path",
  1973. "required": true
  1974. },
  1975. {
  1976. "name": "body",
  1977. "in": "body",
  1978. "schema": {
  1979. "$ref": "#/definitions/EditHookOption"
  1980. }
  1981. }
  1982. ],
  1983. "responses": {
  1984. "200": {
  1985. "$ref": "#/responses/Hook"
  1986. }
  1987. }
  1988. }
  1989. },
  1990. "/repos/{owner}/{repo}/hooks/{id}/tests": {
  1991. "post": {
  1992. "produces": [
  1993. "application/json"
  1994. ],
  1995. "tags": [
  1996. "repository"
  1997. ],
  1998. "summary": "Test a push webhook",
  1999. "operationId": "repoTestHook",
  2000. "parameters": [
  2001. {
  2002. "type": "string",
  2003. "description": "owner of the repo",
  2004. "name": "owner",
  2005. "in": "path",
  2006. "required": true
  2007. },
  2008. {
  2009. "type": "string",
  2010. "description": "name of the repo",
  2011. "name": "repo",
  2012. "in": "path",
  2013. "required": true
  2014. },
  2015. {
  2016. "type": "integer",
  2017. "format": "int64",
  2018. "description": "id of the hook to test",
  2019. "name": "id",
  2020. "in": "path",
  2021. "required": true
  2022. }
  2023. ],
  2024. "responses": {
  2025. "204": {
  2026. "$ref": "#/responses/empty"
  2027. }
  2028. }
  2029. }
  2030. },
  2031. "/repos/{owner}/{repo}/issues": {
  2032. "get": {
  2033. "produces": [
  2034. "application/json"
  2035. ],
  2036. "tags": [
  2037. "issue"
  2038. ],
  2039. "summary": "List a repository's issues",
  2040. "operationId": "issueListIssues",
  2041. "parameters": [
  2042. {
  2043. "type": "string",
  2044. "description": "owner of the repo",
  2045. "name": "owner",
  2046. "in": "path",
  2047. "required": true
  2048. },
  2049. {
  2050. "type": "string",
  2051. "description": "name of the repo",
  2052. "name": "repo",
  2053. "in": "path",
  2054. "required": true
  2055. },
  2056. {
  2057. "type": "string",
  2058. "description": "whether issue is open or closed",
  2059. "name": "state",
  2060. "in": "query"
  2061. },
  2062. {
  2063. "type": "integer",
  2064. "description": "page number of requested issues",
  2065. "name": "page",
  2066. "in": "query"
  2067. },
  2068. {
  2069. "type": "string",
  2070. "description": "search string",
  2071. "name": "q",
  2072. "in": "query"
  2073. }
  2074. ],
  2075. "responses": {
  2076. "200": {
  2077. "$ref": "#/responses/IssueList"
  2078. }
  2079. }
  2080. },
  2081. "post": {
  2082. "consumes": [
  2083. "application/json"
  2084. ],
  2085. "produces": [
  2086. "application/json"
  2087. ],
  2088. "tags": [
  2089. "issue"
  2090. ],
  2091. "summary": "Create an issue. If using deadline only the date will be taken into account, and time of day ignored.",
  2092. "operationId": "issueCreateIssue",
  2093. "parameters": [
  2094. {
  2095. "type": "string",
  2096. "description": "owner of the repo",
  2097. "name": "owner",
  2098. "in": "path",
  2099. "required": true
  2100. },
  2101. {
  2102. "type": "string",
  2103. "description": "name of the repo",
  2104. "name": "repo",
  2105. "in": "path",
  2106. "required": true
  2107. },
  2108. {
  2109. "name": "body",
  2110. "in": "body",
  2111. "schema": {
  2112. "$ref": "#/definitions/CreateIssueOption"
  2113. }
  2114. }
  2115. ],
  2116. "responses": {
  2117. "201": {
  2118. "$ref": "#/responses/Issue"
  2119. }
  2120. }
  2121. }
  2122. },
  2123. "/repos/{owner}/{repo}/issues/comments": {
  2124. "get": {
  2125. "produces": [
  2126. "application/json"
  2127. ],
  2128. "tags": [
  2129. "issue"
  2130. ],
  2131. "summary": "List all comments in a repository",
  2132. "operationId": "issueGetRepoComments",
  2133. "parameters": [
  2134. {
  2135. "type": "string",
  2136. "description": "owner of the repo",
  2137. "name": "owner",
  2138. "in": "path",
  2139. "required": true
  2140. },
  2141. {
  2142. "type": "string",
  2143. "description": "name of the repo",
  2144. "name": "repo",
  2145. "in": "path",
  2146. "required": true
  2147. },
  2148. {
  2149. "type": "string",
  2150. "description": "if provided, only comments updated since the provided time are returned.",
  2151. "name": "since",
  2152. "in": "query"
  2153. }
  2154. ],
  2155. "responses": {
  2156. "200": {
  2157. "$ref": "#/responses/CommentList"
  2158. }
  2159. }
  2160. }
  2161. },
  2162. "/repos/{owner}/{repo}/issues/comments/{id}": {
  2163. "delete": {
  2164. "tags": [
  2165. "issue"
  2166. ],
  2167. "summary": "Delete a comment",
  2168. "operationId": "issueDeleteComment",
  2169. "parameters": [
  2170. {
  2171. "type": "string",
  2172. "description": "owner of the repo",
  2173. "name": "owner",
  2174. "in": "path",
  2175. "required": true
  2176. },
  2177. {
  2178. "type": "string",
  2179. "description": "name of the repo",
  2180. "name": "repo",
  2181. "in": "path",
  2182. "required": true
  2183. },
  2184. {
  2185. "type": "integer",
  2186. "format": "int64",
  2187. "description": "id of comment to delete",
  2188. "name": "id",
  2189. "in": "path",
  2190. "required": true
  2191. }
  2192. ],
  2193. "responses": {
  2194. "204": {
  2195. "$ref": "#/responses/empty"
  2196. }
  2197. }
  2198. },
  2199. "patch": {
  2200. "consumes": [
  2201. "application/json"
  2202. ],
  2203. "produces": [
  2204. "application/json"
  2205. ],
  2206. "tags": [
  2207. "issue"
  2208. ],
  2209. "summary": "Edit a comment",
  2210. "operationId": "issueEditComment",
  2211. "parameters": [
  2212. {
  2213. "type": "string",
  2214. "description": "owner of the repo",
  2215. "name": "owner",
  2216. "in": "path",
  2217. "required": true
  2218. },
  2219. {
  2220. "type": "string",
  2221. "description": "name of the repo",
  2222. "name": "repo",
  2223. "in": "path",
  2224. "required": true
  2225. },
  2226. {
  2227. "type": "integer",
  2228. "format": "int64",
  2229. "description": "id of the comment to edit",
  2230. "name": "id",
  2231. "in": "path",
  2232. "required": true
  2233. },
  2234. {
  2235. "name": "body",
  2236. "in": "body",
  2237. "schema": {
  2238. "$ref": "#/definitions/EditIssueCommentOption"
  2239. }
  2240. }
  2241. ],
  2242. "responses": {
  2243. "200": {
  2244. "$ref": "#/responses/Comment"
  2245. }
  2246. }
  2247. }
  2248. },
  2249. "/repos/{owner}/{repo}/issues/{id}/times": {
  2250. "get": {
  2251. "produces": [
  2252. "application/json"
  2253. ],
  2254. "tags": [
  2255. "issue"
  2256. ],
  2257. "summary": "List an issue's tracked times",
  2258. "operationId": "issueTrackedTimes",
  2259. "parameters": [
  2260. {
  2261. "type": "string",
  2262. "description": "owner of the repo",
  2263. "name": "owner",
  2264. "in": "path",
  2265. "required": true
  2266. },
  2267. {
  2268. "type": "string",
  2269. "description": "name of the repo",
  2270. "name": "repo",
  2271. "in": "path",
  2272. "required": true
  2273. },
  2274. {
  2275. "type": "integer",
  2276. "format": "int64",
  2277. "description": "index of the issue",
  2278. "name": "id",
  2279. "in": "path",
  2280. "required": true
  2281. }
  2282. ],
  2283. "responses": {
  2284. "200": {
  2285. "$ref": "#/responses/TrackedTimeList"
  2286. }
  2287. }
  2288. },
  2289. "post": {
  2290. "consumes": [
  2291. "application/json"
  2292. ],
  2293. "produces": [
  2294. "application/json"
  2295. ],
  2296. "tags": [
  2297. "issue"
  2298. ],
  2299. "summary": "Add a tracked time to a issue",
  2300. "operationId": "issueAddTime",
  2301. "parameters": [
  2302. {
  2303. "type": "string",
  2304. "description": "owner of the repo",
  2305. "name": "owner",
  2306. "in": "path",
  2307. "required": true
  2308. },
  2309. {
  2310. "type": "string",
  2311. "description": "name of the repo",
  2312. "name": "repo",
  2313. "in": "path",
  2314. "required": true
  2315. },
  2316. {
  2317. "type": "integer",
  2318. "format": "int64",
  2319. "description": "index of the issue to add tracked time to",
  2320. "name": "id",
  2321. "in": "path",
  2322. "required": true
  2323. },
  2324. {
  2325. "name": "body",
  2326. "in": "body",
  2327. "schema": {
  2328. "$ref": "#/definitions/AddTimeOption"
  2329. }
  2330. }
  2331. ],
  2332. "responses": {
  2333. "200": {
  2334. "$ref": "#/responses/TrackedTime"
  2335. },
  2336. "400": {
  2337. "$ref": "#/responses/error"
  2338. },
  2339. "403": {
  2340. "$ref": "#/responses/error"
  2341. }
  2342. }
  2343. }
  2344. },
  2345. "/repos/{owner}/{repo}/issues/{index}": {
  2346. "get": {
  2347. "produces": [
  2348. "application/json"
  2349. ],
  2350. "tags": [
  2351. "issue"
  2352. ],
  2353. "summary": "Get an issue",
  2354. "operationId": "issueGetIssue",
  2355. "parameters": [
  2356. {
  2357. "type": "string",
  2358. "description": "owner of the repo",
  2359. "name": "owner",
  2360. "in": "path",
  2361. "required": true
  2362. },
  2363. {
  2364. "type": "string",
  2365. "description": "name of the repo",
  2366. "name": "repo",
  2367. "in": "path",
  2368. "required": true
  2369. },
  2370. {
  2371. "type": "integer",
  2372. "format": "int64",
  2373. "description": "index of the issue to get",
  2374. "name": "index",
  2375. "in": "path",
  2376. "required": true
  2377. }
  2378. ],
  2379. "responses": {
  2380. "200": {
  2381. "$ref": "#/responses/Issue"
  2382. }
  2383. }
  2384. },
  2385. "patch": {
  2386. "consumes": [
  2387. "application/json"
  2388. ],
  2389. "produces": [
  2390. "application/json"
  2391. ],
  2392. "tags": [
  2393. "issue"
  2394. ],
  2395. "summary": "Edit an issue. If using deadline only the date will be taken into account, and time of day ignored.",
  2396. "operationId": "issueEditIssue",
  2397. "parameters": [
  2398. {
  2399. "type": "string",
  2400. "description": "owner of the repo",
  2401. "name": "owner",
  2402. "in": "path",
  2403. "required": true
  2404. },
  2405. {
  2406. "type": "string",
  2407. "description": "name of the repo",
  2408. "name": "repo",
  2409. "in": "path",
  2410. "required": true
  2411. },
  2412. {
  2413. "type": "integer",
  2414. "format": "int64",
  2415. "description": "index of the issue to edit",
  2416. "name": "index",
  2417. "in": "path",
  2418. "required": true
  2419. },
  2420. {
  2421. "name": "body",
  2422. "in": "body",
  2423. "schema": {
  2424. "$ref": "#/definitions/EditIssueOption"
  2425. }
  2426. }
  2427. ],
  2428. "responses": {
  2429. "201": {
  2430. "$ref": "#/responses/Issue"
  2431. }
  2432. }
  2433. }
  2434. },
  2435. "/repos/{owner}/{repo}/issues/{index}/comments": {
  2436. "get": {
  2437. "produces": [
  2438. "application/json"
  2439. ],
  2440. "tags": [
  2441. "issue"
  2442. ],
  2443. "summary": "List all comments on an issue",
  2444. "operationId": "issueGetComments",
  2445. "parameters": [
  2446. {
  2447. "type": "string",
  2448. "description": "owner of the repo",
  2449. "name": "owner",
  2450. "in": "path",
  2451. "required": true
  2452. },
  2453. {
  2454. "type": "string",
  2455. "description": "name of the repo",
  2456. "name": "repo",
  2457. "in": "path",
  2458. "required": true
  2459. },
  2460. {
  2461. "type": "integer",
  2462. "format": "int64",
  2463. "description": "index of the issue",
  2464. "name": "index",
  2465. "in": "path",
  2466. "required": true
  2467. },
  2468. {
  2469. "type": "string",
  2470. "description": "if provided, only comments updated since the specified time are returned.",
  2471. "name": "since",
  2472. "in": "query"
  2473. }
  2474. ],
  2475. "responses": {
  2476. "200": {
  2477. "$ref": "#/responses/CommentList"
  2478. }
  2479. }
  2480. },
  2481. "post": {
  2482. "consumes": [
  2483. "application/json"
  2484. ],
  2485. "produces": [
  2486. "application/json"
  2487. ],
  2488. "tags": [
  2489. "issue"
  2490. ],
  2491. "summary": "Add a comment to an issue",
  2492. "operationId": "issueCreateComment",
  2493. "parameters": [
  2494. {
  2495. "type": "string",
  2496. "description": "owner of the repo",
  2497. "name": "owner",
  2498. "in": "path",
  2499. "required": true
  2500. },
  2501. {
  2502. "type": "string",
  2503. "description": "name of the repo",
  2504. "name": "repo",
  2505. "in": "path",
  2506. "required": true
  2507. },
  2508. {
  2509. "type": "integer",
  2510. "format": "int64",
  2511. "description": "index of the issue",
  2512. "name": "index",
  2513. "in": "path",
  2514. "required": true
  2515. },
  2516. {
  2517. "name": "body",
  2518. "in": "body",
  2519. "schema": {
  2520. "$ref": "#/definitions/CreateIssueCommentOption"
  2521. }
  2522. }
  2523. ],
  2524. "responses": {
  2525. "201": {
  2526. "$ref": "#/responses/Comment"
  2527. }
  2528. }
  2529. }
  2530. },
  2531. "/repos/{owner}/{repo}/issues/{index}/comments/{id}": {
  2532. "delete": {
  2533. "tags": [
  2534. "issue"
  2535. ],
  2536. "summary": "Delete a comment",
  2537. "operationId": "issueDeleteCommentDeprecated",
  2538. "deprecated": true,
  2539. "parameters": [
  2540. {
  2541. "type": "string",
  2542. "description": "owner of the repo",
  2543. "name": "owner",
  2544. "in": "path",
  2545. "required": true
  2546. },
  2547. {
  2548. "type": "string",
  2549. "description": "name of the repo",
  2550. "name": "repo",
  2551. "in": "path",
  2552. "required": true
  2553. },
  2554. {
  2555. "type": "integer",
  2556. "description": "this parameter is ignored",
  2557. "name": "index",
  2558. "in": "path",
  2559. "required": true
  2560. },
  2561. {
  2562. "type": "integer",
  2563. "format": "int64",
  2564. "description": "id of comment to delete",
  2565. "name": "id",
  2566. "in": "path",
  2567. "required": true
  2568. }
  2569. ],
  2570. "responses": {
  2571. "204": {
  2572. "$ref": "#/responses/empty"
  2573. }
  2574. }
  2575. },
  2576. "patch": {
  2577. "consumes": [
  2578. "application/json"
  2579. ],
  2580. "produces": [
  2581. "application/json"
  2582. ],
  2583. "tags": [
  2584. "issue"
  2585. ],
  2586. "summary": "Edit a comment",
  2587. "operationId": "issueEditCommentDeprecated",
  2588. "deprecated": true,
  2589. "parameters": [
  2590. {
  2591. "type": "string",
  2592. "description": "owner of the repo",
  2593. "name": "owner",
  2594. "in": "path",
  2595. "required": true
  2596. },
  2597. {
  2598. "type": "string",
  2599. "description": "name of the repo",
  2600. "name": "repo",
  2601. "in": "path",
  2602. "required": true
  2603. },
  2604. {
  2605. "type": "integer",
  2606. "description": "this parameter is ignored",
  2607. "name": "index",
  2608. "in": "path",
  2609. "required": true
  2610. },
  2611. {
  2612. "type": "integer",
  2613. "format": "int64",
  2614. "description": "id of the comment to edit",
  2615. "name": "id",
  2616. "in": "path",
  2617. "required": true
  2618. },
  2619. {
  2620. "name": "body",
  2621. "in": "body",
  2622. "schema": {
  2623. "$ref": "#/definitions/EditIssueCommentOption"
  2624. }
  2625. }
  2626. ],
  2627. "responses": {
  2628. "200": {
  2629. "$ref": "#/responses/Comment"
  2630. }
  2631. }
  2632. }
  2633. },
  2634. "/repos/{owner}/{repo}/issues/{index}/deadline": {
  2635. "post": {
  2636. "consumes": [
  2637. "application/json"
  2638. ],
  2639. "produces": [
  2640. "application/json"
  2641. ],
  2642. "tags": [
  2643. "issue"
  2644. ],
  2645. "summary": "Set an issue deadline. If set to null, the deadline is deleted. If using deadline only the date will be taken into account, and time of day ignored.",
  2646. "operationId": "issueEditIssueDeadline",
  2647. "parameters": [
  2648. {
  2649. "type": "string",
  2650. "description": "owner of the repo",
  2651. "name": "owner",
  2652. "in": "path",
  2653. "required": true
  2654. },
  2655. {
  2656. "type": "string",
  2657. "description": "name of the repo",
  2658. "name": "repo",
  2659. "in": "path",
  2660. "required": true
  2661. },
  2662. {
  2663. "type": "integer",
  2664. "format": "int64",
  2665. "description": "index of the issue to create or update a deadline on",
  2666. "name": "index",
  2667. "in": "path",
  2668. "required": true
  2669. },
  2670. {
  2671. "name": "body",
  2672. "in": "body",
  2673. "schema": {
  2674. "$ref": "#/definitions/EditDeadlineOption"
  2675. }
  2676. }
  2677. ],
  2678. "responses": {
  2679. "201": {
  2680. "$ref": "#/responses/IssueDeadline"
  2681. },
  2682. "403": {
  2683. "description": "Not repo writer"
  2684. },
  2685. "404": {
  2686. "description": "Issue not found"
  2687. }
  2688. }
  2689. }
  2690. },
  2691. "/repos/{owner}/{repo}/issues/{index}/labels": {
  2692. "get": {
  2693. "produces": [
  2694. "application/json"
  2695. ],
  2696. "tags": [
  2697. "issue"
  2698. ],
  2699. "summary": "Get an issue's labels",
  2700. "operationId": "issueGetLabels",
  2701. "parameters": [
  2702. {
  2703. "type": "string",
  2704. "description": "owner of the repo",
  2705. "name": "owner",
  2706. "in": "path",
  2707. "required": true
  2708. },
  2709. {
  2710. "type": "string",
  2711. "description": "name of the repo",
  2712. "name": "repo",
  2713. "in": "path",
  2714. "required": true
  2715. },
  2716. {
  2717. "type": "integer",
  2718. "format": "int64",
  2719. "description": "index of the issue",
  2720. "name": "index",
  2721. "in": "path",
  2722. "required": true
  2723. }
  2724. ],
  2725. "responses": {
  2726. "200": {
  2727. "$ref": "#/responses/LabelList"
  2728. },
  2729. "404": {
  2730. "$ref": "#/responses/notFound"
  2731. }
  2732. }
  2733. },
  2734. "put": {
  2735. "consumes": [
  2736. "application/json"
  2737. ],
  2738. "produces": [
  2739. "application/json"
  2740. ],
  2741. "tags": [
  2742. "issue"
  2743. ],
  2744. "summary": "Replace an issue's labels",
  2745. "operationId": "issueReplaceLabels",
  2746. "parameters": [
  2747. {
  2748. "type": "string",
  2749. "description": "owner of the repo",
  2750. "name": "owner",
  2751. "in": "path",
  2752. "required": true
  2753. },
  2754. {
  2755. "type": "string",
  2756. "description": "name of the repo",
  2757. "name": "repo",
  2758. "in": "path",
  2759. "required": true
  2760. },
  2761. {
  2762. "type": "integer",
  2763. "format": "int64",
  2764. "description": "index of the issue",
  2765. "name": "index",
  2766. "in": "path",
  2767. "required": true
  2768. },
  2769. {
  2770. "name": "body",
  2771. "in": "body",
  2772. "schema": {
  2773. "$ref": "#/definitions/IssueLabelsOption"
  2774. }
  2775. }
  2776. ],
  2777. "responses": {
  2778. "200": {
  2779. "$ref": "#/responses/LabelList"
  2780. }
  2781. }
  2782. },
  2783. "post": {
  2784. "consumes": [
  2785. "application/json"
  2786. ],
  2787. "produces": [
  2788. "application/json"
  2789. ],
  2790. "tags": [
  2791. "issue"
  2792. ],
  2793. "summary": "Add a label to an issue",
  2794. "operationId": "issueAddLabel",
  2795. "parameters": [
  2796. {
  2797. "type": "string",
  2798. "description": "owner of the repo",
  2799. "name": "owner",
  2800. "in": "path",
  2801. "required": true
  2802. },
  2803. {
  2804. "type": "string",
  2805. "description": "name of the repo",
  2806. "name": "repo",
  2807. "in": "path",
  2808. "required": true
  2809. },
  2810. {
  2811. "type": "integer",
  2812. "format": "int64",
  2813. "description": "index of the issue",
  2814. "name": "index",
  2815. "in": "path",
  2816. "required": true
  2817. },
  2818. {
  2819. "name": "body",
  2820. "in": "body",
  2821. "schema": {
  2822. "$ref": "#/definitions/IssueLabelsOption"
  2823. }
  2824. }
  2825. ],
  2826. "responses": {
  2827. "200": {
  2828. "$ref": "#/responses/LabelList"
  2829. }
  2830. }
  2831. },
  2832. "delete": {
  2833. "produces": [
  2834. "application/json"
  2835. ],
  2836. "tags": [
  2837. "issue"
  2838. ],
  2839. "summary": "Remove all labels from an issue",
  2840. "operationId": "issueClearLabels",
  2841. "parameters": [
  2842. {
  2843. "type": "string",
  2844. "description": "owner of the repo",
  2845. "name": "owner",
  2846. "in": "path",
  2847. "required": true
  2848. },
  2849. {
  2850. "type": "string",
  2851. "description": "name of the repo",
  2852. "name": "repo",
  2853. "in": "path",
  2854. "required": true
  2855. },
  2856. {
  2857. "type": "integer",
  2858. "format": "int64",
  2859. "description": "index of the issue",
  2860. "name": "index",
  2861. "in": "path",
  2862. "required": true
  2863. }
  2864. ],
  2865. "responses": {
  2866. "204": {
  2867. "$ref": "#/responses/empty"
  2868. }
  2869. }
  2870. }
  2871. },
  2872. "/repos/{owner}/{repo}/issues/{index}/labels/{id}": {
  2873. "delete": {
  2874. "produces": [
  2875. "application/json"
  2876. ],
  2877. "tags": [
  2878. "issue"
  2879. ],
  2880. "summary": "Remove a label from an issue",
  2881. "operationId": "issueRemoveLabel",
  2882. "parameters": [
  2883. {
  2884. "type": "string",
  2885. "description": "owner of the repo",
  2886. "name": "owner",
  2887. "in": "path",
  2888. "required": true
  2889. },
  2890. {
  2891. "type": "string",
  2892. "description": "name of the repo",
  2893. "name": "repo",
  2894. "in": "path",
  2895. "required": true
  2896. },
  2897. {
  2898. "type": "integer",
  2899. "format": "int64",
  2900. "description": "index of the issue",
  2901. "name": "index",
  2902. "in": "path",
  2903. "required": true
  2904. },
  2905. {
  2906. "type": "integer",
  2907. "format": "int64",
  2908. "description": "id of the label to remove",
  2909. "name": "id",
  2910. "in": "path",
  2911. "required": true
  2912. }
  2913. ],
  2914. "responses": {
  2915. "204": {
  2916. "$ref": "#/responses/empty"
  2917. }
  2918. }
  2919. }
  2920. },
  2921. "/repos/{owner}/{repo}/keys": {
  2922. "get": {
  2923. "produces": [
  2924. "application/json"
  2925. ],
  2926. "tags": [
  2927. "repository"
  2928. ],
  2929. "summary": "List a repository's keys",
  2930. "operationId": "repoListKeys",
  2931. "parameters": [
  2932. {
  2933. "type": "string",
  2934. "description": "owner of the repo",
  2935. "name": "owner",
  2936. "in": "path",
  2937. "required": true
  2938. },
  2939. {
  2940. "type": "string",
  2941. "description": "name of the repo",
  2942. "name": "repo",
  2943. "in": "path",
  2944. "required": true
  2945. },
  2946. {
  2947. "type": "integer",
  2948. "description": "the key_id to search for",
  2949. "name": "key_id",
  2950. "in": "query"
  2951. },
  2952. {
  2953. "type": "string",
  2954. "description": "fingerprint of the key",
  2955. "name": "fingerprint",
  2956. "in": "query"
  2957. }
  2958. ],
  2959. "responses": {
  2960. "200": {
  2961. "$ref": "#/responses/DeployKeyList"
  2962. }
  2963. }
  2964. },
  2965. "post": {
  2966. "consumes": [
  2967. "application/json"
  2968. ],
  2969. "produces": [
  2970. "application/json"
  2971. ],
  2972. "tags": [
  2973. "repository"
  2974. ],
  2975. "summary": "Add a key to a repository",
  2976. "operationId": "repoCreateKey",
  2977. "parameters": [
  2978. {
  2979. "type": "string",
  2980. "description": "owner of the repo",
  2981. "name": "owner",
  2982. "in": "path",
  2983. "required": true
  2984. },
  2985. {
  2986. "type": "string",
  2987. "description": "name of the repo",
  2988. "name": "repo",
  2989. "in": "path",
  2990. "required": true
  2991. },
  2992. {
  2993. "name": "body",
  2994. "in": "body",
  2995. "schema": {
  2996. "$ref": "#/definitions/CreateKeyOption"
  2997. }
  2998. }
  2999. ],
  3000. "responses": {
  3001. "201": {
  3002. "$ref": "#/responses/DeployKey"
  3003. }
  3004. }
  3005. }
  3006. },
  3007. "/repos/{owner}/{repo}/keys/{id}": {
  3008. "get": {
  3009. "produces": [
  3010. "application/json"
  3011. ],
  3012. "tags": [
  3013. "repository"
  3014. ],
  3015. "summary": "Get a repository's key by id",
  3016. "operationId": "repoGetKey",
  3017. "parameters": [
  3018. {
  3019. "type": "string",
  3020. "description": "owner of the repo",
  3021. "name": "owner",
  3022. "in": "path",
  3023. "required": true
  3024. },
  3025. {
  3026. "type": "string",
  3027. "description": "name of the repo",
  3028. "name": "repo",
  3029. "in": "path",
  3030. "required": true
  3031. },
  3032. {
  3033. "type": "integer",
  3034. "format": "int64",
  3035. "description": "id of the key to get",
  3036. "name": "id",
  3037. "in": "path",
  3038. "required": true
  3039. }
  3040. ],
  3041. "responses": {
  3042. "200": {
  3043. "$ref": "#/responses/DeployKey"
  3044. }
  3045. }
  3046. },
  3047. "delete": {
  3048. "tags": [
  3049. "repository"
  3050. ],
  3051. "summary": "Delete a key from a repository",
  3052. "operationId": "repoDeleteKey",
  3053. "parameters": [
  3054. {
  3055. "type": "string",
  3056. "description": "owner of the repo",
  3057. "name": "owner",
  3058. "in": "path",
  3059. "required": true
  3060. },
  3061. {
  3062. "type": "string",
  3063. "description": "name of the repo",
  3064. "name": "repo",
  3065. "in": "path",
  3066. "required": true
  3067. },
  3068. {
  3069. "type": "integer",
  3070. "format": "int64",
  3071. "description": "id of the key to delete",
  3072. "name": "id",
  3073. "in": "path",
  3074. "required": true
  3075. }
  3076. ],
  3077. "responses": {
  3078. "204": {
  3079. "$ref": "#/responses/empty"
  3080. }
  3081. }
  3082. }
  3083. },
  3084. "/repos/{owner}/{repo}/labels": {
  3085. "get": {
  3086. "produces": [
  3087. "application/json"
  3088. ],
  3089. "tags": [
  3090. "issue"
  3091. ],
  3092. "summary": "Get all of a repository's labels",
  3093. "operationId": "issueListLabels",
  3094. "parameters": [
  3095. {
  3096. "type": "string",
  3097. "description": "owner of the repo",
  3098. "name": "owner",
  3099. "in": "path",
  3100. "required": true
  3101. },
  3102. {
  3103. "type": "string",
  3104. "description": "name of the repo",
  3105. "name": "repo",
  3106. "in": "path",
  3107. "required": true
  3108. }
  3109. ],
  3110. "responses": {
  3111. "200": {
  3112. "$ref": "#/responses/LabelList"
  3113. }
  3114. }
  3115. },
  3116. "post": {
  3117. "consumes": [
  3118. "application/json"
  3119. ],
  3120. "produces": [
  3121. "application/json"
  3122. ],
  3123. "tags": [
  3124. "issue"
  3125. ],
  3126. "summary": "Create a label",
  3127. "operationId": "issueCreateLabel",
  3128. "parameters": [
  3129. {
  3130. "type": "string",
  3131. "description": "owner of the repo",
  3132. "name": "owner",
  3133. "in": "path",
  3134. "required": true
  3135. },
  3136. {
  3137. "type": "string",
  3138. "description": "name of the repo",
  3139. "name": "repo",
  3140. "in": "path",
  3141. "required": true
  3142. },
  3143. {
  3144. "name": "body",
  3145. "in": "body",
  3146. "schema": {
  3147. "$ref": "#/definitions/CreateLabelOption"
  3148. }
  3149. }
  3150. ],
  3151. "responses": {
  3152. "201": {
  3153. "$ref": "#/responses/Label"
  3154. }
  3155. }
  3156. }
  3157. },
  3158. "/repos/{owner}/{repo}/labels/{id}": {
  3159. "get": {
  3160. "produces": [
  3161. "application/json"
  3162. ],
  3163. "tags": [
  3164. "issue"
  3165. ],
  3166. "summary": "Get a single label",
  3167. "operationId": "issueGetLabel",
  3168. "parameters": [
  3169. {
  3170. "type": "string",
  3171. "description": "owner of the repo",
  3172. "name": "owner",
  3173. "in": "path",
  3174. "required": true
  3175. },
  3176. {
  3177. "type": "string",
  3178. "description": "name of the repo",
  3179. "name": "repo",
  3180. "in": "path",
  3181. "required": true
  3182. },
  3183. {
  3184. "type": "integer",
  3185. "format": "int64",
  3186. "description": "id of the label to get",
  3187. "name": "id",
  3188. "in": "path",
  3189. "required": true
  3190. }
  3191. ],
  3192. "responses": {
  3193. "200": {
  3194. "$ref": "#/responses/Label"
  3195. }
  3196. }
  3197. },
  3198. "delete": {
  3199. "tags": [
  3200. "issue"
  3201. ],
  3202. "summary": "Delete a label",
  3203. "operationId": "issueDeleteLabel",
  3204. "parameters": [
  3205. {
  3206. "type": "string",
  3207. "description": "owner of the repo",
  3208. "name": "owner",
  3209. "in": "path",
  3210. "required": true
  3211. },
  3212. {
  3213. "type": "string",
  3214. "description": "name of the repo",
  3215. "name": "repo",
  3216. "in": "path",
  3217. "required": true
  3218. },
  3219. {
  3220. "type": "integer",
  3221. "format": "int64",
  3222. "description": "id of the label to delete",
  3223. "name": "id",
  3224. "in": "path",
  3225. "required": true
  3226. }
  3227. ],
  3228. "responses": {
  3229. "204": {
  3230. "$ref": "#/responses/empty"
  3231. }
  3232. }
  3233. },
  3234. "patch": {
  3235. "consumes": [
  3236. "application/json"
  3237. ],
  3238. "produces": [
  3239. "application/json"
  3240. ],
  3241. "tags": [
  3242. "issue"
  3243. ],
  3244. "summary": "Update a label",
  3245. "operationId": "issueEditLabel",
  3246. "parameters": [
  3247. {
  3248. "type": "string",
  3249. "description": "owner of the repo",
  3250. "name": "owner",
  3251. "in": "path",
  3252. "required": true
  3253. },
  3254. {
  3255. "type": "string",
  3256. "description": "name of the repo",
  3257. "name": "repo",
  3258. "in": "path",
  3259. "required": true
  3260. },
  3261. {
  3262. "type": "integer",
  3263. "format": "int64",
  3264. "description": "id of the label to edit",
  3265. "name": "id",
  3266. "in": "path",
  3267. "required": true
  3268. },
  3269. {
  3270. "name": "body",
  3271. "in": "body",
  3272. "schema": {
  3273. "$ref": "#/definitions/EditLabelOption"
  3274. }
  3275. }
  3276. ],
  3277. "responses": {
  3278. "200": {
  3279. "$ref": "#/responses/Label"
  3280. }
  3281. }
  3282. }
  3283. },
  3284. "/repos/{owner}/{repo}/milestones": {
  3285. "get": {
  3286. "produces": [
  3287. "application/json"
  3288. ],
  3289. "tags": [
  3290. "issue"
  3291. ],
  3292. "summary": "Get all of a repository's opened milestones",
  3293. "operationId": "issueGetMilestonesList",
  3294. "parameters": [
  3295. {
  3296. "type": "string",
  3297. "description": "owner of the repo",
  3298. "name": "owner",
  3299. "in": "path",
  3300. "required": true
  3301. },
  3302. {
  3303. "type": "string",
  3304. "description": "name of the repo",
  3305. "name": "repo",
  3306. "in": "path",
  3307. "required": true
  3308. }
  3309. ],
  3310. "responses": {
  3311. "200": {
  3312. "$ref": "#/responses/MilestoneList"
  3313. }
  3314. }
  3315. },
  3316. "post": {
  3317. "consumes": [
  3318. "application/json"
  3319. ],
  3320. "produces": [
  3321. "application/json"
  3322. ],
  3323. "tags": [
  3324. "issue"
  3325. ],
  3326. "summary": "Create a milestone",
  3327. "operationId": "issueCreateMilestone",
  3328. "parameters": [
  3329. {
  3330. "type": "string",
  3331. "description": "owner of the repo",
  3332. "name": "owner",
  3333. "in": "path",
  3334. "required": true
  3335. },
  3336. {
  3337. "type": "string",
  3338. "description": "name of the repo",
  3339. "name": "repo",
  3340. "in": "path",
  3341. "required": true
  3342. },
  3343. {
  3344. "name": "body",
  3345. "in": "body",
  3346. "schema": {
  3347. "$ref": "#/definitions/CreateMilestoneOption"
  3348. }
  3349. }
  3350. ],
  3351. "responses": {
  3352. "201": {
  3353. "$ref": "#/responses/Milestone"
  3354. }
  3355. }
  3356. }
  3357. },
  3358. "/repos/{owner}/{repo}/milestones/{id}": {
  3359. "get": {
  3360. "produces": [
  3361. "application/json"
  3362. ],
  3363. "tags": [
  3364. "issue"
  3365. ],
  3366. "summary": "Get a milestone",
  3367. "operationId": "issueGetMilestone",
  3368. "parameters": [
  3369. {
  3370. "type": "string",
  3371. "description": "owner of the repo",
  3372. "name": "owner",
  3373. "in": "path",
  3374. "required": true
  3375. },
  3376. {
  3377. "type": "string",
  3378. "description": "name of the repo",
  3379. "name": "repo",
  3380. "in": "path",
  3381. "required": true
  3382. },
  3383. {
  3384. "type": "integer",
  3385. "format": "int64",
  3386. "description": "id of the milestone",
  3387. "name": "id",
  3388. "in": "path",
  3389. "required": true
  3390. }
  3391. ],
  3392. "responses": {
  3393. "200": {
  3394. "$ref": "#/responses/Milestone"
  3395. }
  3396. }
  3397. },
  3398. "delete": {
  3399. "tags": [
  3400. "issue"
  3401. ],
  3402. "summary": "Delete a milestone",
  3403. "operationId": "issueDeleteMilestone",
  3404. "parameters": [
  3405. {
  3406. "type": "string",
  3407. "description": "owner of the repo",
  3408. "name": "owner",
  3409. "in": "path",
  3410. "required": true
  3411. },
  3412. {
  3413. "type": "string",
  3414. "description": "name of the repo",
  3415. "name": "repo",
  3416. "in": "path",
  3417. "required": true
  3418. },
  3419. {
  3420. "type": "integer",
  3421. "format": "int64",
  3422. "description": "id of the milestone to delete",
  3423. "name": "id",
  3424. "in": "path",
  3425. "required": true
  3426. }
  3427. ],
  3428. "responses": {
  3429. "204": {
  3430. "$ref": "#/responses/empty"
  3431. }
  3432. }
  3433. },
  3434. "patch": {
  3435. "consumes": [
  3436. "application/json"
  3437. ],
  3438. "produces": [
  3439. "application/json"
  3440. ],
  3441. "tags": [
  3442. "issue"
  3443. ],
  3444. "summary": "Update a milestone",
  3445. "operationId": "issueEditMilestone",
  3446. "parameters": [
  3447. {
  3448. "type": "string",
  3449. "description": "owner of the repo",
  3450. "name": "owner",
  3451. "in": "path",
  3452. "required": true
  3453. },
  3454. {
  3455. "type": "string",
  3456. "description": "name of the repo",
  3457. "name": "repo",
  3458. "in": "path",
  3459. "required": true
  3460. },
  3461. {
  3462. "type": "integer",
  3463. "format": "int64",
  3464. "description": "id of the milestone",
  3465. "name": "id",
  3466. "in": "path",
  3467. "required": true
  3468. },
  3469. {
  3470. "name": "body",
  3471. "in": "body",
  3472. "schema": {
  3473. "$ref": "#/definitions/EditMilestoneOption"
  3474. }
  3475. }
  3476. ],
  3477. "responses": {
  3478. "200": {
  3479. "$ref": "#/responses/Milestone"
  3480. }
  3481. }
  3482. }
  3483. },
  3484. "/repos/{owner}/{repo}/mirror-sync": {
  3485. "post": {
  3486. "produces": [
  3487. "application/json"
  3488. ],
  3489. "tags": [
  3490. "repository"
  3491. ],
  3492. "summary": "Sync a mirrored repository",
  3493. "operationId": "repoMirrorSync",
  3494. "parameters": [
  3495. {
  3496. "type": "string",
  3497. "description": "owner of the repo to sync",
  3498. "name": "owner",
  3499. "in": "path",
  3500. "required": true
  3501. },
  3502. {
  3503. "type": "string",
  3504. "description": "name of the repo to sync",
  3505. "name": "repo",
  3506. "in": "path",
  3507. "required": true
  3508. }
  3509. ],
  3510. "responses": {
  3511. "200": {
  3512. "$ref": "#/responses/empty"
  3513. }
  3514. }
  3515. }
  3516. },
  3517. "/repos/{owner}/{repo}/pulls": {
  3518. "get": {
  3519. "produces": [
  3520. "application/json"
  3521. ],
  3522. "tags": [
  3523. "repository"
  3524. ],
  3525. "summary": "List a repo's pull requests",
  3526. "operationId": "repoListPullRequests",
  3527. "parameters": [
  3528. {
  3529. "type": "string",
  3530. "description": "owner of the repo",
  3531. "name": "owner",
  3532. "in": "path",
  3533. "required": true
  3534. },
  3535. {
  3536. "type": "string",
  3537. "description": "name of the repo",
  3538. "name": "repo",
  3539. "in": "path",
  3540. "required": true
  3541. },
  3542. {
  3543. "type": "integer",
  3544. "description": "Page number",
  3545. "name": "page",
  3546. "in": "query"
  3547. },
  3548. {
  3549. "enum": [
  3550. "closed",
  3551. "open",
  3552. "all"
  3553. ],
  3554. "type": "string",
  3555. "description": "State of pull request: open or closed (optional)",
  3556. "name": "state",
  3557. "in": "query"
  3558. },
  3559. {
  3560. "enum": [
  3561. "oldest",
  3562. "recentupdate",
  3563. "leastupdate",
  3564. "mostcomment",
  3565. "leastcomment",
  3566. "priority"
  3567. ],
  3568. "type": "string",
  3569. "description": "Type of sort",
  3570. "name": "sort",
  3571. "in": "query"
  3572. },
  3573. {
  3574. "type": "integer",
  3575. "format": "int64",
  3576. "description": "ID of the milestone",
  3577. "name": "milestone",
  3578. "in": "query"
  3579. },
  3580. {
  3581. "type": "array",
  3582. "items": {
  3583. "type": "integer",
  3584. "format": "int64"
  3585. },
  3586. "collectionFormat": "multi",
  3587. "description": "Label IDs",
  3588. "name": "labels",
  3589. "in": "query"
  3590. }
  3591. ],
  3592. "responses": {
  3593. "200": {
  3594. "$ref": "#/responses/PullRequestList"
  3595. }
  3596. }
  3597. },
  3598. "post": {
  3599. "consumes": [
  3600. "application/json"
  3601. ],
  3602. "produces": [
  3603. "application/json"
  3604. ],
  3605. "tags": [
  3606. "repository"
  3607. ],
  3608. "summary": "Create a pull request",
  3609. "operationId": "repoCreatePullRequest",
  3610. "parameters": [
  3611. {
  3612. "type": "string",
  3613. "description": "owner of the repo",
  3614. "name": "owner",
  3615. "in": "path",
  3616. "required": true
  3617. },
  3618. {
  3619. "type": "string",
  3620. "description": "name of the repo",
  3621. "name": "repo",
  3622. "in": "path",
  3623. "required": true
  3624. },
  3625. {
  3626. "name": "body",
  3627. "in": "body",
  3628. "schema": {
  3629. "$ref": "#/definitions/CreatePullRequestOption"
  3630. }
  3631. }
  3632. ],
  3633. "responses": {
  3634. "201": {
  3635. "$ref": "#/responses/PullRequest"
  3636. }
  3637. }
  3638. }
  3639. },
  3640. "/repos/{owner}/{repo}/pulls/{index}": {
  3641. "get": {
  3642. "produces": [
  3643. "application/json"
  3644. ],
  3645. "tags": [
  3646. "repository"
  3647. ],
  3648. "summary": "Get a pull request",
  3649. "operationId": "repoGetPullRequest",
  3650. "parameters": [
  3651. {
  3652. "type": "string",
  3653. "description": "owner of the repo",
  3654. "name": "owner",
  3655. "in": "path",
  3656. "required": true
  3657. },
  3658. {
  3659. "type": "string",
  3660. "description": "name of the repo",
  3661. "name": "repo",
  3662. "in": "path",
  3663. "required": true
  3664. },
  3665. {
  3666. "type": "integer",
  3667. "format": "int64",
  3668. "description": "index of the pull request to get",
  3669. "name": "index",
  3670. "in": "path",
  3671. "required": true
  3672. }
  3673. ],
  3674. "responses": {
  3675. "200": {
  3676. "$ref": "#/responses/PullRequest"
  3677. }
  3678. }
  3679. },
  3680. "patch": {
  3681. "consumes": [
  3682. "application/json"
  3683. ],
  3684. "produces": [
  3685. "application/json"
  3686. ],
  3687. "tags": [
  3688. "repository"
  3689. ],
  3690. "summary": "Update a pull request",
  3691. "operationId": "repoEditPullRequest",
  3692. "parameters": [
  3693. {
  3694. "type": "string",
  3695. "description": "owner of the repo",
  3696. "name": "owner",
  3697. "in": "path",
  3698. "required": true
  3699. },
  3700. {
  3701. "type": "string",
  3702. "description": "name of the repo",
  3703. "name": "repo",
  3704. "in": "path",
  3705. "required": true
  3706. },
  3707. {
  3708. "type": "integer",
  3709. "format": "int64",
  3710. "description": "index of the pull request to edit",
  3711. "name": "index",
  3712. "in": "path",
  3713. "required": true
  3714. },
  3715. {
  3716. "name": "body",
  3717. "in": "body",
  3718. "schema": {
  3719. "$ref": "#/definitions/EditPullRequestOption"
  3720. }
  3721. }
  3722. ],
  3723. "responses": {
  3724. "201": {
  3725. "$ref": "#/responses/PullRequest"
  3726. }
  3727. }
  3728. }
  3729. },
  3730. "/repos/{owner}/{repo}/pulls/{index}/merge": {
  3731. "get": {
  3732. "produces": [
  3733. "application/json"
  3734. ],
  3735. "tags": [
  3736. "repository"
  3737. ],
  3738. "summary": "Check if a pull request has been merged",
  3739. "operationId": "repoPullRequestIsMerged",
  3740. "parameters": [
  3741. {
  3742. "type": "string",
  3743. "description": "owner of the repo",
  3744. "name": "owner",
  3745. "in": "path",
  3746. "required": true
  3747. },
  3748. {
  3749. "type": "string",
  3750. "description": "name of the repo",
  3751. "name": "repo",
  3752. "in": "path",
  3753. "required": true
  3754. },
  3755. {
  3756. "type": "integer",
  3757. "format": "int64",
  3758. "description": "index of the pull request",
  3759. "name": "index",
  3760. "in": "path",
  3761. "required": true
  3762. }
  3763. ],
  3764. "responses": {
  3765. "204": {
  3766. "description": "pull request has been merged"
  3767. },
  3768. "404": {
  3769. "description": "pull request has not been merged"
  3770. }
  3771. }
  3772. },
  3773. "post": {
  3774. "produces": [
  3775. "application/json"
  3776. ],
  3777. "tags": [
  3778. "repository"
  3779. ],
  3780. "summary": "Merge a pull request",
  3781. "operationId": "repoMergePullRequest",
  3782. "parameters": [
  3783. {
  3784. "type": "string",
  3785. "description": "owner of the repo",
  3786. "name": "owner",
  3787. "in": "path",
  3788. "required": true
  3789. },
  3790. {
  3791. "type": "string",
  3792. "description": "name of the repo",
  3793. "name": "repo",
  3794. "in": "path",
  3795. "required": true
  3796. },
  3797. {
  3798. "type": "integer",
  3799. "format": "int64",
  3800. "description": "index of the pull request to merge",
  3801. "name": "index",
  3802. "in": "path",
  3803. "required": true
  3804. }
  3805. ],
  3806. "responses": {
  3807. "200": {
  3808. "$ref": "#/responses/empty"
  3809. },
  3810. "405": {
  3811. "$ref": "#/responses/empty"
  3812. }
  3813. }
  3814. }
  3815. },
  3816. "/repos/{owner}/{repo}/raw/{filepath}": {
  3817. "get": {
  3818. "produces": [
  3819. "application/json"
  3820. ],
  3821. "tags": [
  3822. "repository"
  3823. ],
  3824. "summary": "Get a file from a repository",
  3825. "operationId": "repoGetRawFile",
  3826. "parameters": [
  3827. {
  3828. "type": "string",
  3829. "description": "owner of the repo",
  3830. "name": "owner",
  3831. "in": "path",
  3832. "required": true
  3833. },
  3834. {
  3835. "type": "string",
  3836. "description": "name of the repo",
  3837. "name": "repo",
  3838. "in": "path",
  3839. "required": true
  3840. },
  3841. {
  3842. "type": "string",
  3843. "description": "filepath of the file to get",
  3844. "name": "filepath",
  3845. "in": "path",
  3846. "required": true
  3847. }
  3848. ],
  3849. "responses": {
  3850. "200": {
  3851. "description": "success"
  3852. }
  3853. }
  3854. }
  3855. },
  3856. "/repos/{owner}/{repo}/releases": {
  3857. "get": {
  3858. "produces": [
  3859. "application/json"
  3860. ],
  3861. "tags": [
  3862. "repository"
  3863. ],
  3864. "summary": "List a repo's releases",
  3865. "operationId": "repoListReleases",
  3866. "parameters": [
  3867. {
  3868. "type": "string",
  3869. "description": "owner of the repo",
  3870. "name": "owner",
  3871. "in": "path",
  3872. "required": true
  3873. },
  3874. {
  3875. "type": "string",
  3876. "description": "name of the repo",
  3877. "name": "repo",
  3878. "in": "path",
  3879. "required": true
  3880. },
  3881. {
  3882. "type": "integer",
  3883. "description": "page wants to load",
  3884. "name": "page",
  3885. "in": "query"
  3886. },
  3887. {
  3888. "type": "integer",
  3889. "description": "items count every page wants to load",
  3890. "name": "per_page",
  3891. "in": "query"
  3892. }
  3893. ],
  3894. "responses": {
  3895. "200": {
  3896. "$ref": "#/responses/ReleaseList"
  3897. }
  3898. }
  3899. },
  3900. "post": {
  3901. "consumes": [
  3902. "application/json"
  3903. ],
  3904. "produces": [
  3905. "application/json"
  3906. ],
  3907. "tags": [
  3908. "repository"
  3909. ],
  3910. "summary": "Create a release",
  3911. "operationId": "repoCreateRelease",
  3912. "parameters": [
  3913. {
  3914. "type": "string",
  3915. "description": "owner of the repo",
  3916. "name": "owner",
  3917. "in": "path",
  3918. "required": true
  3919. },
  3920. {
  3921. "type": "string",
  3922. "description": "name of the repo",
  3923. "name": "repo",
  3924. "in": "path",
  3925. "required": true
  3926. },
  3927. {
  3928. "name": "body",
  3929. "in": "body",
  3930. "schema": {
  3931. "$ref": "#/definitions/CreateReleaseOption"
  3932. }
  3933. }
  3934. ],
  3935. "responses": {
  3936. "201": {
  3937. "$ref": "#/responses/Release"
  3938. }
  3939. }
  3940. }
  3941. },
  3942. "/repos/{owner}/{repo}/releases/{id}": {
  3943. "get": {
  3944. "produces": [
  3945. "application/json"
  3946. ],
  3947. "tags": [
  3948. "repository"
  3949. ],
  3950. "summary": "Get a release",
  3951. "operationId": "repoGetRelease",
  3952. "parameters": [
  3953. {
  3954. "type": "string",
  3955. "description": "owner of the repo",
  3956. "name": "owner",
  3957. "in": "path",
  3958. "required": true
  3959. },
  3960. {
  3961. "type": "string",
  3962. "description": "name of the repo",
  3963. "name": "repo",
  3964. "in": "path",
  3965. "required": true
  3966. },
  3967. {
  3968. "type": "integer",
  3969. "format": "int64",
  3970. "description": "id of the release to get",
  3971. "name": "id",
  3972. "in": "path",
  3973. "required": true
  3974. }
  3975. ],
  3976. "responses": {
  3977. "200": {
  3978. "$ref": "#/responses/Release"
  3979. }
  3980. }
  3981. },
  3982. "delete": {
  3983. "tags": [
  3984. "repository"
  3985. ],
  3986. "summary": "Delete a release",
  3987. "operationId": "repoDeleteRelease",
  3988. "parameters": [
  3989. {
  3990. "type": "string",
  3991. "description": "owner of the repo",
  3992. "name": "owner",
  3993. "in": "path",
  3994. "required": true
  3995. },
  3996. {
  3997. "type": "string",
  3998. "description": "name of the repo",
  3999. "name": "repo",
  4000. "in": "path",
  4001. "required": true
  4002. },
  4003. {
  4004. "type": "integer",
  4005. "format": "int64",
  4006. "description": "id of the release to delete",
  4007. "name": "id",
  4008. "in": "path",
  4009. "required": true
  4010. }
  4011. ],
  4012. "responses": {
  4013. "204": {
  4014. "$ref": "#/responses/empty"
  4015. }
  4016. }
  4017. },
  4018. "patch": {
  4019. "consumes": [
  4020. "application/json"
  4021. ],
  4022. "produces": [
  4023. "application/json"
  4024. ],
  4025. "tags": [
  4026. "repository"
  4027. ],
  4028. "summary": "Update a release",
  4029. "operationId": "repoEditRelease",
  4030. "parameters": [
  4031. {
  4032. "type": "string",
  4033. "description": "owner of the repo",
  4034. "name": "owner",
  4035. "in": "path",
  4036. "required": true
  4037. },
  4038. {
  4039. "type": "string",
  4040. "description": "name of the repo",
  4041. "name": "repo",
  4042. "in": "path",
  4043. "required": true
  4044. },
  4045. {
  4046. "type": "integer",
  4047. "format": "int64",
  4048. "description": "id of the release to edit",
  4049. "name": "id",
  4050. "in": "path",
  4051. "required": true
  4052. },
  4053. {
  4054. "name": "body",
  4055. "in": "body",
  4056. "schema": {
  4057. "$ref": "#/definitions/EditReleaseOption"
  4058. }
  4059. }
  4060. ],
  4061. "responses": {
  4062. "200": {
  4063. "$ref": "#/responses/Release"
  4064. }
  4065. }
  4066. }
  4067. },
  4068. "/repos/{owner}/{repo}/releases/{id}/assets": {
  4069. "get": {
  4070. "produces": [
  4071. "application/json"
  4072. ],
  4073. "tags": [
  4074. "repository"
  4075. ],
  4076. "summary": "List release's attachments",
  4077. "operationId": "repoListReleaseAttachments",
  4078. "parameters": [
  4079. {
  4080. "type": "string",
  4081. "description": "owner of the repo",
  4082. "name": "owner",
  4083. "in": "path",
  4084. "required": true
  4085. },
  4086. {
  4087. "type": "string",
  4088. "description": "name of the repo",
  4089. "name": "repo",
  4090. "in": "path",
  4091. "required": true
  4092. },
  4093. {
  4094. "type": "integer",
  4095. "format": "int64",
  4096. "description": "id of the release",
  4097. "name": "id",
  4098. "in": "path",
  4099. "required": true
  4100. }
  4101. ],
  4102. "responses": {
  4103. "200": {
  4104. "$ref": "#/responses/AttachmentList"
  4105. }
  4106. }
  4107. },
  4108. "post": {
  4109. "consumes": [
  4110. "multipart/form-data"
  4111. ],
  4112. "produces": [
  4113. "application/json"
  4114. ],
  4115. "tags": [
  4116. "repository"
  4117. ],
  4118. "summary": "Create a release attachment",
  4119. "operationId": "repoCreateReleaseAttachment",
  4120. "parameters": [
  4121. {
  4122. "type": "string",
  4123. "description": "owner of the repo",
  4124. "name": "owner",
  4125. "in": "path",
  4126. "required": true
  4127. },
  4128. {
  4129. "type": "string",
  4130. "description": "name of the repo",
  4131. "name": "repo",
  4132. "in": "path",
  4133. "required": true
  4134. },
  4135. {
  4136. "type": "integer",
  4137. "format": "int64",
  4138. "description": "id of the release",
  4139. "name": "id",
  4140. "in": "path",
  4141. "required": true
  4142. },
  4143. {
  4144. "type": "string",
  4145. "description": "name of the attachment",
  4146. "name": "name",
  4147. "in": "query"
  4148. },
  4149. {
  4150. "type": "file",
  4151. "description": "attachment to upload",
  4152. "name": "attachment",
  4153. "in": "formData",
  4154. "required": true
  4155. }
  4156. ],
  4157. "responses": {
  4158. "201": {
  4159. "$ref": "#/responses/Attachment"
  4160. }
  4161. }
  4162. }
  4163. },
  4164. "/repos/{owner}/{repo}/releases/{id}/assets/{attachment_id}": {
  4165. "get": {
  4166. "produces": [
  4167. "application/json"
  4168. ],
  4169. "tags": [
  4170. "repository"
  4171. ],
  4172. "summary": "Get a release attachment",
  4173. "operationId": "repoGetReleaseAttachment",
  4174. "parameters": [
  4175. {
  4176. "type": "string",
  4177. "description": "owner of the repo",
  4178. "name": "owner",
  4179. "in": "path",
  4180. "required": true
  4181. },
  4182. {
  4183. "type": "string",
  4184. "description": "name of the repo",
  4185. "name": "repo",
  4186. "in": "path",
  4187. "required": true
  4188. },
  4189. {
  4190. "type": "integer",
  4191. "format": "int64",
  4192. "description": "id of the release",
  4193. "name": "id",
  4194. "in": "path",
  4195. "required": true
  4196. },
  4197. {
  4198. "type": "integer",
  4199. "format": "int64",
  4200. "description": "id of the attachment to get",
  4201. "name": "attachment_id",
  4202. "in": "path",
  4203. "required": true
  4204. }
  4205. ],
  4206. "responses": {
  4207. "200": {
  4208. "$ref": "#/responses/Attachment"
  4209. }
  4210. }
  4211. },
  4212. "delete": {
  4213. "produces": [
  4214. "application/json"
  4215. ],
  4216. "tags": [
  4217. "repository"
  4218. ],
  4219. "summary": "Delete a release attachment",
  4220. "operationId": "repoDeleteReleaseAttachment",
  4221. "parameters": [
  4222. {
  4223. "type": "string",
  4224. "description": "owner of the repo",
  4225. "name": "owner",
  4226. "in": "path",
  4227. "required": true
  4228. },
  4229. {
  4230. "type": "string",
  4231. "description": "name of the repo",
  4232. "name": "repo",
  4233. "in": "path",
  4234. "required": true
  4235. },
  4236. {
  4237. "type": "integer",
  4238. "format": "int64",
  4239. "description": "id of the release",
  4240. "name": "id",
  4241. "in": "path",
  4242. "required": true
  4243. },
  4244. {
  4245. "type": "integer",
  4246. "format": "int64",
  4247. "description": "id of the attachment to delete",
  4248. "name": "attachment_id",
  4249. "in": "path",
  4250. "required": true
  4251. }
  4252. ],
  4253. "responses": {
  4254. "204": {
  4255. "$ref": "#/responses/empty"
  4256. }
  4257. }
  4258. },
  4259. "patch": {
  4260. "consumes": [
  4261. "application/json"
  4262. ],
  4263. "produces": [
  4264. "application/json"
  4265. ],
  4266. "tags": [
  4267. "repository"
  4268. ],
  4269. "summary": "Edit a release attachment",
  4270. "operationId": "repoEditReleaseAttachment",
  4271. "parameters": [
  4272. {
  4273. "type": "string",
  4274. "description": "owner of the repo",
  4275. "name": "owner",
  4276. "in": "path",
  4277. "required": true
  4278. },
  4279. {
  4280. "type": "string",
  4281. "description": "name of the repo",
  4282. "name": "repo",
  4283. "in": "path",
  4284. "required": true
  4285. },
  4286. {
  4287. "type": "integer",
  4288. "format": "int64",
  4289. "description": "id of the release",
  4290. "name": "id",
  4291. "in": "path",
  4292. "required": true
  4293. },
  4294. {
  4295. "type": "integer",
  4296. "format": "int64",
  4297. "description": "id of the attachment to edit",
  4298. "name": "attachment_id",
  4299. "in": "path",
  4300. "required": true
  4301. },
  4302. {
  4303. "name": "body",
  4304. "in": "body",
  4305. "schema": {
  4306. "$ref": "#/definitions/EditAttachmentOptions"
  4307. }
  4308. }
  4309. ],
  4310. "responses": {
  4311. "201": {
  4312. "$ref": "#/responses/Attachment"
  4313. }
  4314. }
  4315. }
  4316. },
  4317. "/repos/{owner}/{repo}/stargazers": {
  4318. "get": {
  4319. "produces": [
  4320. "application/json"
  4321. ],
  4322. "tags": [
  4323. "repository"
  4324. ],
  4325. "summary": "List a repo's stargazers",
  4326. "operationId": "repoListStargazers",
  4327. "parameters": [
  4328. {
  4329. "type": "string",
  4330. "description": "owner of the repo",
  4331. "name": "owner",
  4332. "in": "path",
  4333. "required": true
  4334. },
  4335. {
  4336. "type": "string",
  4337. "description": "name of the repo",
  4338. "name": "repo",
  4339. "in": "path",
  4340. "required": true
  4341. }
  4342. ],
  4343. "responses": {
  4344. "200": {
  4345. "$ref": "#/responses/UserList"
  4346. }
  4347. }
  4348. }
  4349. },
  4350. "/repos/{owner}/{repo}/statuses/{sha}": {
  4351. "get": {
  4352. "produces": [
  4353. "application/json"
  4354. ],
  4355. "tags": [
  4356. "repository"
  4357. ],
  4358. "summary": "Get a commit's statuses",
  4359. "operationId": "repoListStatuses",
  4360. "parameters": [
  4361. {
  4362. "type": "string",
  4363. "description": "owner of the repo",
  4364. "name": "owner",
  4365. "in": "path",
  4366. "required": true
  4367. },
  4368. {
  4369. "type": "string",
  4370. "description": "name of the repo",
  4371. "name": "repo",
  4372. "in": "path",
  4373. "required": true
  4374. },
  4375. {
  4376. "type": "string",
  4377. "description": "sha of the commit",
  4378. "name": "sha",
  4379. "in": "path",
  4380. "required": true
  4381. }
  4382. ],
  4383. "responses": {
  4384. "200": {
  4385. "$ref": "#/responses/StatusList"
  4386. }
  4387. }
  4388. },
  4389. "post": {
  4390. "produces": [
  4391. "application/json"
  4392. ],
  4393. "tags": [
  4394. "repository"
  4395. ],
  4396. "summary": "Create a commit status",
  4397. "operationId": "repoCreateStatus",
  4398. "parameters": [
  4399. {
  4400. "type": "string",
  4401. "description": "owner of the repo",
  4402. "name": "owner",
  4403. "in": "path",
  4404. "required": true
  4405. },
  4406. {
  4407. "type": "string",
  4408. "description": "name of the repo",
  4409. "name": "repo",
  4410. "in": "path",
  4411. "required": true
  4412. },
  4413. {
  4414. "type": "string",
  4415. "description": "sha of the commit",
  4416. "name": "sha",
  4417. "in": "path",
  4418. "required": true
  4419. },
  4420. {
  4421. "name": "body",
  4422. "in": "body",
  4423. "schema": {
  4424. "$ref": "#/definitions/CreateStatusOption"
  4425. }
  4426. }
  4427. ],
  4428. "responses": {
  4429. "200": {
  4430. "$ref": "#/responses/StatusList"
  4431. }
  4432. }
  4433. }
  4434. },
  4435. "/repos/{owner}/{repo}/subscribers": {
  4436. "get": {
  4437. "produces": [
  4438. "application/json"
  4439. ],
  4440. "tags": [
  4441. "repository"
  4442. ],
  4443. "summary": "List a repo's watchers",
  4444. "operationId": "repoListSubscribers",
  4445. "parameters": [
  4446. {
  4447. "type": "string",
  4448. "description": "owner of the repo",
  4449. "name": "owner",
  4450. "in": "path",
  4451. "required": true
  4452. },
  4453. {
  4454. "type": "string",
  4455. "description": "name of the repo",
  4456. "name": "repo",
  4457. "in": "path",
  4458. "required": true
  4459. }
  4460. ],
  4461. "responses": {
  4462. "200": {
  4463. "$ref": "#/responses/UserList"
  4464. }
  4465. }
  4466. }
  4467. },
  4468. "/repos/{owner}/{repo}/subscription": {
  4469. "get": {
  4470. "tags": [
  4471. "repository"
  4472. ],
  4473. "summary": "Check if the current user is watching a repo",
  4474. "operationId": "userCurrentCheckSubscription",
  4475. "parameters": [
  4476. {
  4477. "type": "string",
  4478. "description": "owner of the repo",
  4479. "name": "owner",
  4480. "in": "path",
  4481. "required": true
  4482. },
  4483. {
  4484. "type": "string",
  4485. "description": "name of the repo",
  4486. "name": "repo",
  4487. "in": "path",
  4488. "required": true
  4489. }
  4490. ],
  4491. "responses": {
  4492. "200": {
  4493. "$ref": "#/responses/WatchInfo"
  4494. }
  4495. }
  4496. },
  4497. "put": {
  4498. "tags": [
  4499. "repository"
  4500. ],
  4501. "summary": "Watch a repo",
  4502. "operationId": "userCurrentPutSubscription",
  4503. "parameters": [
  4504. {
  4505. "type": "string",
  4506. "description": "owner of the repo",
  4507. "name": "owner",
  4508. "in": "path",
  4509. "required": true
  4510. },
  4511. {
  4512. "type": "string",
  4513. "description": "name of the repo",
  4514. "name": "repo",
  4515. "in": "path",
  4516. "required": true
  4517. }
  4518. ],
  4519. "responses": {
  4520. "200": {
  4521. "$ref": "#/responses/WatchInfo"
  4522. }
  4523. }
  4524. },
  4525. "delete": {
  4526. "tags": [
  4527. "repository"
  4528. ],
  4529. "summary": "Unwatch a repo",
  4530. "operationId": "userCurrentDeleteSubscription",
  4531. "parameters": [
  4532. {
  4533. "type": "string",
  4534. "description": "owner of the repo",
  4535. "name": "owner",
  4536. "in": "path",
  4537. "required": true
  4538. },
  4539. {
  4540. "type": "string",
  4541. "description": "name of the repo",
  4542. "name": "repo",
  4543. "in": "path",
  4544. "required": true
  4545. }
  4546. ],
  4547. "responses": {
  4548. "204": {
  4549. "$ref": "#/responses/empty"
  4550. }
  4551. }
  4552. }
  4553. },
  4554. "/repos/{owner}/{repo}/times": {
  4555. "get": {
  4556. "produces": [
  4557. "application/json"
  4558. ],
  4559. "tags": [
  4560. "repository"
  4561. ],
  4562. "summary": "List a repo's tracked times",
  4563. "operationId": "repoTrackedTimes",
  4564. "parameters": [
  4565. {
  4566. "type": "string",
  4567. "description": "owner of the repo",
  4568. "name": "owner",
  4569. "in": "path",
  4570. "required": true
  4571. },
  4572. {
  4573. "type": "string",
  4574. "description": "name of the repo",
  4575. "name": "repo",
  4576. "in": "path",
  4577. "required": true
  4578. }
  4579. ],
  4580. "responses": {
  4581. "200": {
  4582. "$ref": "#/responses/TrackedTimeList"
  4583. }
  4584. }
  4585. }
  4586. },
  4587. "/repos/{owner}/{repo}/times/{user}": {
  4588. "get": {
  4589. "produces": [
  4590. "application/json"
  4591. ],
  4592. "tags": [
  4593. "user"
  4594. ],
  4595. "summary": "List a user's tracked times in a repo",
  4596. "operationId": "userTrackedTimes",
  4597. "parameters": [
  4598. {
  4599. "type": "string",
  4600. "description": "owner of the repo",
  4601. "name": "owner",
  4602. "in": "path",
  4603. "required": true
  4604. },
  4605. {
  4606. "type": "string",
  4607. "description": "name of the repo",
  4608. "name": "repo",
  4609. "in": "path",
  4610. "required": true
  4611. },
  4612. {
  4613. "type": "string",
  4614. "description": "username of user",
  4615. "name": "user",
  4616. "in": "path",
  4617. "required": true
  4618. }
  4619. ],
  4620. "responses": {
  4621. "200": {
  4622. "$ref": "#/responses/TrackedTimeList"
  4623. }
  4624. }
  4625. }
  4626. },
  4627. "/repositories/{id}": {
  4628. "get": {
  4629. "produces": [
  4630. "application/json"
  4631. ],
  4632. "tags": [
  4633. "repository"
  4634. ],
  4635. "summary": "Get a repository by id",
  4636. "operationId": "repoGetByID",
  4637. "parameters": [
  4638. {
  4639. "type": "integer",
  4640. "format": "int64",
  4641. "description": "id of the repo to get",
  4642. "name": "id",
  4643. "in": "path",
  4644. "required": true
  4645. }
  4646. ],
  4647. "responses": {
  4648. "200": {
  4649. "$ref": "#/responses/Repository"
  4650. }
  4651. }
  4652. }
  4653. },
  4654. "/teams/{id}": {
  4655. "get": {
  4656. "produces": [
  4657. "application/json"
  4658. ],
  4659. "tags": [
  4660. "organization"
  4661. ],
  4662. "summary": "Get a team",
  4663. "operationId": "orgGetTeam",
  4664. "parameters": [
  4665. {
  4666. "type": "integer",
  4667. "format": "int64",
  4668. "description": "id of the team to get",
  4669. "name": "id",
  4670. "in": "path",
  4671. "required": true
  4672. }
  4673. ],
  4674. "responses": {
  4675. "200": {
  4676. "$ref": "#/responses/Team"
  4677. }
  4678. }
  4679. },
  4680. "delete": {
  4681. "tags": [
  4682. "organization"
  4683. ],
  4684. "summary": "Delete a team",
  4685. "operationId": "orgDeleteTeam",
  4686. "parameters": [
  4687. {
  4688. "type": "integer",
  4689. "format": "int64",
  4690. "description": "id of the team to delete",
  4691. "name": "id",
  4692. "in": "path",
  4693. "required": true
  4694. }
  4695. ],
  4696. "responses": {
  4697. "204": {
  4698. "description": "team deleted"
  4699. }
  4700. }
  4701. },
  4702. "patch": {
  4703. "consumes": [
  4704. "application/json"
  4705. ],
  4706. "produces": [
  4707. "application/json"
  4708. ],
  4709. "tags": [
  4710. "organization"
  4711. ],
  4712. "summary": "Edit a team",
  4713. "operationId": "orgEditTeam",
  4714. "parameters": [
  4715. {
  4716. "type": "integer",
  4717. "description": "id of the team to edit",
  4718. "name": "id",
  4719. "in": "path",
  4720. "required": true
  4721. },
  4722. {
  4723. "name": "body",
  4724. "in": "body",
  4725. "schema": {
  4726. "$ref": "#/definitions/EditTeamOption"
  4727. }
  4728. }
  4729. ],
  4730. "responses": {
  4731. "200": {
  4732. "$ref": "#/responses/Team"
  4733. }
  4734. }
  4735. }
  4736. },
  4737. "/teams/{id}/members": {
  4738. "get": {
  4739. "produces": [
  4740. "application/json"
  4741. ],
  4742. "tags": [
  4743. "organization"
  4744. ],
  4745. "summary": "List a team's members",
  4746. "operationId": "orgListTeamMembers",
  4747. "parameters": [
  4748. {
  4749. "type": "integer",
  4750. "format": "int64",
  4751. "description": "id of the team",
  4752. "name": "id",
  4753. "in": "path",
  4754. "required": true
  4755. }
  4756. ],
  4757. "responses": {
  4758. "200": {
  4759. "$ref": "#/responses/UserList"
  4760. }
  4761. }
  4762. }
  4763. },
  4764. "/teams/{id}/members/{username}": {
  4765. "get": {
  4766. "produces": [
  4767. "application/json"
  4768. ],
  4769. "tags": [
  4770. "organization"
  4771. ],
  4772. "summary": "List a particular member of team",
  4773. "operationId": "orgListTeamMember",
  4774. "parameters": [
  4775. {
  4776. "type": "integer",
  4777. "format": "int64",
  4778. "description": "id of the team",
  4779. "name": "id",
  4780. "in": "path",
  4781. "required": true
  4782. },
  4783. {
  4784. "type": "string",
  4785. "description": "username of the member to list",
  4786. "name": "username",
  4787. "in": "path",
  4788. "required": true
  4789. }
  4790. ],
  4791. "responses": {
  4792. "200": {
  4793. "$ref": "#/responses/User"
  4794. }
  4795. }
  4796. },
  4797. "put": {
  4798. "produces": [
  4799. "application/json"
  4800. ],
  4801. "tags": [
  4802. "organization"
  4803. ],
  4804. "summary": "Add a team member",
  4805. "operationId": "orgAddTeamMember",
  4806. "parameters": [
  4807. {
  4808. "type": "integer",
  4809. "format": "int64",
  4810. "description": "id of the team",
  4811. "name": "id",
  4812. "in": "path",
  4813. "required": true
  4814. },
  4815. {
  4816. "type": "string",
  4817. "description": "username of the user to add",
  4818. "name": "username",
  4819. "in": "path",
  4820. "required": true
  4821. }
  4822. ],
  4823. "responses": {
  4824. "204": {
  4825. "$ref": "#/responses/empty"
  4826. }
  4827. }
  4828. },
  4829. "delete": {
  4830. "produces": [
  4831. "application/json"
  4832. ],
  4833. "tags": [
  4834. "organization"
  4835. ],
  4836. "summary": "Remove a team member",
  4837. "operationId": "orgRemoveTeamMember",
  4838. "parameters": [
  4839. {
  4840. "type": "integer",
  4841. "format": "int64",
  4842. "description": "id of the team",
  4843. "name": "id",
  4844. "in": "path",
  4845. "required": true
  4846. },
  4847. {
  4848. "type": "string",
  4849. "description": "username of the user to remove",
  4850. "name": "username",
  4851. "in": "path",
  4852. "required": true
  4853. }
  4854. ],
  4855. "responses": {
  4856. "204": {
  4857. "$ref": "#/responses/empty"
  4858. }
  4859. }
  4860. }
  4861. },
  4862. "/teams/{id}/repos": {
  4863. "get": {
  4864. "produces": [
  4865. "application/json"
  4866. ],
  4867. "tags": [
  4868. "organization"
  4869. ],
  4870. "summary": "List a team's repos",
  4871. "operationId": "orgListTeamRepos",
  4872. "parameters": [
  4873. {
  4874. "type": "integer",
  4875. "format": "int64",
  4876. "description": "id of the team",
  4877. "name": "id",
  4878. "in": "path",
  4879. "required": true
  4880. }
  4881. ],
  4882. "responses": {
  4883. "200": {
  4884. "$ref": "#/responses/RepositoryList"
  4885. }
  4886. }
  4887. }
  4888. },
  4889. "/teams/{id}/repos/{org}/{repo}": {
  4890. "put": {
  4891. "produces": [
  4892. "application/json"
  4893. ],
  4894. "tags": [
  4895. "organization"
  4896. ],
  4897. "summary": "Add a repository to a team",
  4898. "operationId": "orgAddTeamRepository",
  4899. "parameters": [
  4900. {
  4901. "type": "integer",
  4902. "format": "int64",
  4903. "description": "id of the team",
  4904. "name": "id",
  4905. "in": "path",
  4906. "required": true
  4907. },
  4908. {
  4909. "type": "string",
  4910. "description": "organization that owns the repo to add",
  4911. "name": "org",
  4912. "in": "path",
  4913. "required": true
  4914. },
  4915. {
  4916. "type": "string",
  4917. "description": "name of the repo to add",
  4918. "name": "repo",
  4919. "in": "path",
  4920. "required": true
  4921. }
  4922. ],
  4923. "responses": {
  4924. "204": {
  4925. "$ref": "#/responses/empty"
  4926. }
  4927. }
  4928. },
  4929. "delete": {
  4930. "description": "This does not delete the repository, it only removes the repository from the team.",
  4931. "produces": [
  4932. "application/json"
  4933. ],
  4934. "tags": [
  4935. "organization"
  4936. ],
  4937. "summary": "Remove a repository from a team",
  4938. "operationId": "orgRemoveTeamRepository",
  4939. "parameters": [
  4940. {
  4941. "type": "integer",
  4942. "format": "int64",
  4943. "description": "id of the team",
  4944. "name": "id",
  4945. "in": "path",
  4946. "required": true
  4947. },
  4948. {
  4949. "type": "string",
  4950. "description": "organization that owns the repo to remove",
  4951. "name": "org",
  4952. "in": "path",
  4953. "required": true
  4954. },
  4955. {
  4956. "type": "string",
  4957. "description": "name of the repo to remove",
  4958. "name": "repo",
  4959. "in": "path",
  4960. "required": true
  4961. }
  4962. ],
  4963. "responses": {
  4964. "204": {
  4965. "$ref": "#/responses/empty"
  4966. }
  4967. }
  4968. }
  4969. },
  4970. "/topics/search": {
  4971. "get": {
  4972. "produces": [
  4973. "application/json"
  4974. ],
  4975. "tags": [
  4976. "repository"
  4977. ],
  4978. "summary": "search topics via keyword",
  4979. "operationId": "topicSearch",
  4980. "parameters": [
  4981. {
  4982. "type": "string",
  4983. "description": "keywords to search",
  4984. "name": "q",
  4985. "in": "query",
  4986. "required": true
  4987. }
  4988. ],
  4989. "responses": {
  4990. "200": {
  4991. "$ref": "#/responses/Repository"
  4992. }
  4993. }
  4994. }
  4995. },
  4996. "/user": {
  4997. "get": {
  4998. "produces": [
  4999. "application/json"
  5000. ],
  5001. "tags": [
  5002. "user"
  5003. ],
  5004. "summary": "Get the authenticated user",
  5005. "operationId": "userGetCurrent",
  5006. "responses": {
  5007. "200": {
  5008. "$ref": "#/responses/User"
  5009. }
  5010. }
  5011. }
  5012. },
  5013. "/user/emails": {
  5014. "get": {
  5015. "produces": [
  5016. "application/json"
  5017. ],
  5018. "tags": [
  5019. "user"
  5020. ],
  5021. "summary": "List the authenticated user's email addresses",
  5022. "operationId": "userListEmails",
  5023. "responses": {
  5024. "200": {
  5025. "$ref": "#/responses/EmailList"
  5026. }
  5027. }
  5028. },
  5029. "post": {
  5030. "produces": [
  5031. "application/json"
  5032. ],
  5033. "tags": [
  5034. "user"
  5035. ],
  5036. "summary": "Add email addresses",
  5037. "operationId": "userAddEmail",
  5038. "parameters": [
  5039. {
  5040. "name": "body",
  5041. "in": "body",
  5042. "schema": {
  5043. "$ref": "#/definitions/CreateEmailOption"
  5044. }
  5045. }
  5046. ],
  5047. "responses": {
  5048. "201": {
  5049. "$ref": "#/responses/EmailList"
  5050. }
  5051. }
  5052. },
  5053. "delete": {
  5054. "produces": [
  5055. "application/json"
  5056. ],
  5057. "tags": [
  5058. "user"
  5059. ],
  5060. "summary": "Delete email addresses",
  5061. "operationId": "userDeleteEmail",
  5062. "parameters": [
  5063. {
  5064. "name": "body",
  5065. "in": "body",
  5066. "schema": {
  5067. "$ref": "#/definitions/DeleteEmailOption"
  5068. }
  5069. }
  5070. ],
  5071. "responses": {
  5072. "204": {
  5073. "$ref": "#/responses/empty"
  5074. }
  5075. }
  5076. }
  5077. },
  5078. "/user/followers": {
  5079. "get": {
  5080. "produces": [
  5081. "application/json"
  5082. ],
  5083. "tags": [
  5084. "user"
  5085. ],
  5086. "summary": "List the authenticated user's followers",
  5087. "operationId": "userCurrentListFollowers",
  5088. "responses": {
  5089. "200": {
  5090. "$ref": "#/responses/UserList"
  5091. }
  5092. }
  5093. }
  5094. },
  5095. "/user/following": {
  5096. "get": {
  5097. "produces": [
  5098. "application/json"
  5099. ],
  5100. "tags": [
  5101. "user"
  5102. ],
  5103. "summary": "List the users that the authenticated user is following",
  5104. "operationId": "userCurrentListFollowing",
  5105. "responses": {
  5106. "200": {
  5107. "$ref": "#/responses/UserList"
  5108. }
  5109. }
  5110. }
  5111. },
  5112. "/user/following/{username}": {
  5113. "get": {
  5114. "tags": [
  5115. "user"
  5116. ],
  5117. "summary": "Check whether a user is followed by the authenticated user",
  5118. "operationId": "userCurrentCheckFollowing",
  5119. "parameters": [
  5120. {
  5121. "type": "string",
  5122. "description": "username of followed user",
  5123. "name": "username",
  5124. "in": "path",
  5125. "required": true
  5126. }
  5127. ],
  5128. "responses": {
  5129. "204": {
  5130. "$ref": "#/responses/empty"
  5131. },
  5132. "404": {
  5133. "$ref": "#/responses/notFound"
  5134. }
  5135. }
  5136. },
  5137. "put": {
  5138. "tags": [
  5139. "user"
  5140. ],
  5141. "summary": "Follow a user",
  5142. "operationId": "userCurrentPutFollow",
  5143. "parameters": [
  5144. {
  5145. "type": "string",
  5146. "description": "username of user to follow",
  5147. "name": "username",
  5148. "in": "path",
  5149. "required": true
  5150. }
  5151. ],
  5152. "responses": {
  5153. "204": {
  5154. "$ref": "#/responses/empty"
  5155. }
  5156. }
  5157. },
  5158. "delete": {
  5159. "tags": [
  5160. "user"
  5161. ],
  5162. "summary": "Unfollow a user",
  5163. "operationId": "userCurrentDeleteFollow",
  5164. "parameters": [
  5165. {
  5166. "type": "string",
  5167. "description": "username of user to unfollow",
  5168. "name": "username",
  5169. "in": "path",
  5170. "required": true
  5171. }
  5172. ],
  5173. "responses": {
  5174. "204": {
  5175. "$ref": "#/responses/empty"
  5176. }
  5177. }
  5178. }
  5179. },
  5180. "/user/gpg_keys": {
  5181. "get": {
  5182. "produces": [
  5183. "application/json"
  5184. ],
  5185. "tags": [
  5186. "user"
  5187. ],
  5188. "summary": "List the authenticated user's GPG keys",
  5189. "operationId": "userCurrentListGPGKeys",
  5190. "responses": {
  5191. "200": {
  5192. "$ref": "#/responses/GPGKeyList"
  5193. }
  5194. }
  5195. },
  5196. "post": {
  5197. "consumes": [
  5198. "application/json"
  5199. ],
  5200. "produces": [
  5201. "application/json"
  5202. ],
  5203. "tags": [
  5204. "user"
  5205. ],
  5206. "summary": "Create a GPG key",
  5207. "operationId": "userCurrentPostGPGKey",
  5208. "parameters": [
  5209. {
  5210. "name": "Form",
  5211. "in": "body",
  5212. "schema": {
  5213. "$ref": "#/definitions/CreateGPGKeyOption"
  5214. }
  5215. }
  5216. ],
  5217. "responses": {
  5218. "201": {
  5219. "$ref": "#/responses/GPGKey"
  5220. },
  5221. "422": {
  5222. "$ref": "#/responses/validationError"
  5223. }
  5224. }
  5225. }
  5226. },
  5227. "/user/gpg_keys/{id}": {
  5228. "get": {
  5229. "produces": [
  5230. "application/json"
  5231. ],
  5232. "tags": [
  5233. "user"
  5234. ],
  5235. "summary": "Get a GPG key",
  5236. "operationId": "userCurrentGetGPGKey",
  5237. "parameters": [
  5238. {
  5239. "type": "integer",
  5240. "format": "int64",
  5241. "description": "id of key to get",
  5242. "name": "id",
  5243. "in": "path",
  5244. "required": true
  5245. }
  5246. ],
  5247. "responses": {
  5248. "200": {
  5249. "$ref": "#/responses/GPGKey"
  5250. },
  5251. "404": {
  5252. "$ref": "#/responses/notFound"
  5253. }
  5254. }
  5255. },
  5256. "delete": {
  5257. "produces": [
  5258. "application/json"
  5259. ],
  5260. "tags": [
  5261. "user"
  5262. ],
  5263. "summary": "Remove a GPG key",
  5264. "operationId": "userCurrentDeleteGPGKey",
  5265. "parameters": [
  5266. {
  5267. "type": "integer",
  5268. "format": "int64",
  5269. "description": "id of key to delete",
  5270. "name": "id",
  5271. "in": "path",
  5272. "required": true
  5273. }
  5274. ],
  5275. "responses": {
  5276. "204": {
  5277. "$ref": "#/responses/empty"
  5278. },
  5279. "403": {
  5280. "$ref": "#/responses/forbidden"
  5281. }
  5282. }
  5283. }
  5284. },
  5285. "/user/keys": {
  5286. "get": {
  5287. "produces": [
  5288. "application/json"
  5289. ],
  5290. "tags": [
  5291. "user"
  5292. ],
  5293. "summary": "List the authenticated user's public keys",
  5294. "operationId": "userCurrentListKeys",
  5295. "parameters": [
  5296. {
  5297. "type": "string",
  5298. "description": "fingerprint of the key",
  5299. "name": "fingerprint",
  5300. "in": "query"
  5301. }
  5302. ],
  5303. "responses": {
  5304. "200": {
  5305. "$ref": "#/responses/PublicKeyList"
  5306. }
  5307. }
  5308. },
  5309. "post": {
  5310. "consumes": [
  5311. "application/json"
  5312. ],
  5313. "produces": [
  5314. "application/json"
  5315. ],
  5316. "tags": [
  5317. "user"
  5318. ],
  5319. "summary": "Create a public key",
  5320. "operationId": "userCurrentPostKey",
  5321. "parameters": [
  5322. {
  5323. "name": "body",
  5324. "in": "body",
  5325. "schema": {
  5326. "$ref": "#/definitions/CreateKeyOption"
  5327. }
  5328. }
  5329. ],
  5330. "responses": {
  5331. "201": {
  5332. "$ref": "#/responses/PublicKey"
  5333. },
  5334. "422": {
  5335. "$ref": "#/responses/validationError"
  5336. }
  5337. }
  5338. }
  5339. },
  5340. "/user/keys/{id}": {
  5341. "get": {
  5342. "produces": [
  5343. "application/json"
  5344. ],
  5345. "tags": [
  5346. "user"
  5347. ],
  5348. "summary": "Get a public key",
  5349. "operationId": "userCurrentGetKey",
  5350. "parameters": [
  5351. {
  5352. "type": "integer",
  5353. "format": "int64",
  5354. "description": "id of key to get",
  5355. "name": "id",
  5356. "in": "path",
  5357. "required": true
  5358. }
  5359. ],
  5360. "responses": {
  5361. "200": {
  5362. "$ref": "#/responses/PublicKey"
  5363. },
  5364. "404": {
  5365. "$ref": "#/responses/notFound"
  5366. }
  5367. }
  5368. },
  5369. "delete": {
  5370. "produces": [
  5371. "application/json"
  5372. ],
  5373. "tags": [
  5374. "user"
  5375. ],
  5376. "summary": "Delete a public key",
  5377. "operationId": "userCurrentDeleteKey",
  5378. "parameters": [
  5379. {
  5380. "type": "integer",
  5381. "format": "int64",
  5382. "description": "id of key to delete",
  5383. "name": "id",
  5384. "in": "path",
  5385. "required": true
  5386. }
  5387. ],
  5388. "responses": {
  5389. "204": {
  5390. "$ref": "#/responses/empty"
  5391. },
  5392. "403": {
  5393. "$ref": "#/responses/forbidden"
  5394. },
  5395. "404": {
  5396. "$ref": "#/responses/notFound"
  5397. }
  5398. }
  5399. }
  5400. },
  5401. "/user/orgs": {
  5402. "get": {
  5403. "produces": [
  5404. "application/json"
  5405. ],
  5406. "tags": [
  5407. "organization"
  5408. ],
  5409. "summary": "List the current user's organizations",
  5410. "operationId": "orgListCurrentUserOrgs",
  5411. "responses": {
  5412. "200": {
  5413. "$ref": "#/responses/OrganizationList"
  5414. }
  5415. }
  5416. }
  5417. },
  5418. "/user/repos": {
  5419. "get": {
  5420. "produces": [
  5421. "application/json"
  5422. ],
  5423. "tags": [
  5424. "user"
  5425. ],
  5426. "summary": "List the repos that the authenticated user owns or has access to",
  5427. "operationId": "userCurrentListRepos",
  5428. "responses": {
  5429. "200": {
  5430. "$ref": "#/responses/RepositoryList"
  5431. }
  5432. }
  5433. },
  5434. "post": {
  5435. "consumes": [
  5436. "application/json"
  5437. ],
  5438. "produces": [
  5439. "application/json"
  5440. ],
  5441. "tags": [
  5442. "repository",
  5443. "user"
  5444. ],
  5445. "summary": "Create a repository",
  5446. "operationId": "createCurrentUserRepo",
  5447. "parameters": [
  5448. {
  5449. "name": "body",
  5450. "in": "body",
  5451. "schema": {
  5452. "$ref": "#/definitions/CreateRepoOption"
  5453. }
  5454. }
  5455. ],
  5456. "responses": {
  5457. "201": {
  5458. "$ref": "#/responses/Repository"
  5459. }
  5460. }
  5461. }
  5462. },
  5463. "/user/starred": {
  5464. "get": {
  5465. "produces": [
  5466. "application/json"
  5467. ],
  5468. "tags": [
  5469. "user"
  5470. ],
  5471. "summary": "The repos that the authenticated user has starred",
  5472. "operationId": "userCurrentListStarred",
  5473. "responses": {
  5474. "200": {
  5475. "$ref": "#/responses/RepositoryList"
  5476. }
  5477. }
  5478. }
  5479. },
  5480. "/user/starred/{owner}/{repo}": {
  5481. "get": {
  5482. "tags": [
  5483. "user"
  5484. ],
  5485. "summary": "Whether the authenticated is starring the repo",
  5486. "operationId": "userCurrentCheckStarring",
  5487. "parameters": [
  5488. {
  5489. "type": "string",
  5490. "description": "owner of the repo",
  5491. "name": "owner",
  5492. "in": "path",
  5493. "required": true
  5494. },
  5495. {
  5496. "type": "string",
  5497. "description": "name of the repo",
  5498. "name": "repo",
  5499. "in": "path",
  5500. "required": true
  5501. }
  5502. ],
  5503. "responses": {
  5504. "204": {
  5505. "$ref": "#/responses/empty"
  5506. },
  5507. "404": {
  5508. "$ref": "#/responses/notFound"
  5509. }
  5510. }
  5511. },
  5512. "put": {
  5513. "tags": [
  5514. "user"
  5515. ],
  5516. "summary": "Star the given repo",
  5517. "operationId": "userCurrentPutStar",
  5518. "parameters": [
  5519. {
  5520. "type": "string",
  5521. "description": "owner of the repo to star",
  5522. "name": "owner",
  5523. "in": "path",
  5524. "required": true
  5525. },
  5526. {
  5527. "type": "string",
  5528. "description": "name of the repo to star",
  5529. "name": "repo",
  5530. "in": "path",
  5531. "required": true
  5532. }
  5533. ],
  5534. "responses": {
  5535. "204": {
  5536. "$ref": "#/responses/empty"
  5537. }
  5538. }
  5539. },
  5540. "delete": {
  5541. "tags": [
  5542. "user"
  5543. ],
  5544. "summary": "Unstar the given repo",
  5545. "operationId": "userCurrentDeleteStar",
  5546. "parameters": [
  5547. {
  5548. "type": "string",
  5549. "description": "owner of the repo to unstar",
  5550. "name": "owner",
  5551. "in": "path",
  5552. "required": true
  5553. },
  5554. {
  5555. "type": "string",
  5556. "description": "name of the repo to unstar",
  5557. "name": "repo",
  5558. "in": "path",
  5559. "required": true
  5560. }
  5561. ],
  5562. "responses": {
  5563. "204": {
  5564. "$ref": "#/responses/empty"
  5565. }
  5566. }
  5567. }
  5568. },
  5569. "/user/subscriptions": {
  5570. "get": {
  5571. "produces": [
  5572. "application/json"
  5573. ],
  5574. "tags": [
  5575. "user"
  5576. ],
  5577. "summary": "List repositories watched by the authenticated user",
  5578. "operationId": "userCurrentListSubscriptions",
  5579. "responses": {
  5580. "200": {
  5581. "$ref": "#/responses/RepositoryList"
  5582. }
  5583. }
  5584. }
  5585. },
  5586. "/user/teams": {
  5587. "get": {
  5588. "produces": [
  5589. "application/json"
  5590. ],
  5591. "tags": [
  5592. "user"
  5593. ],
  5594. "summary": "List all the teams a user belongs to",
  5595. "operationId": "userListTeams",
  5596. "responses": {
  5597. "200": {
  5598. "$ref": "#/responses/TeamList"
  5599. }
  5600. }
  5601. }
  5602. },
  5603. "/user/times": {
  5604. "get": {
  5605. "produces": [
  5606. "application/json"
  5607. ],
  5608. "tags": [
  5609. "user"
  5610. ],
  5611. "summary": "List the current user's tracked times",
  5612. "operationId": "userCurrentTrackedTimes",
  5613. "responses": {
  5614. "200": {
  5615. "$ref": "#/responses/TrackedTimeList"
  5616. }
  5617. }
  5618. }
  5619. },
  5620. "/users/search": {
  5621. "get": {
  5622. "produces": [
  5623. "application/json"
  5624. ],
  5625. "tags": [
  5626. "user"
  5627. ],
  5628. "summary": "Search for users",
  5629. "operationId": "userSearch",
  5630. "parameters": [
  5631. {
  5632. "type": "string",
  5633. "description": "keyword",
  5634. "name": "q",
  5635. "in": "query"
  5636. },
  5637. {
  5638. "type": "integer",
  5639. "format": "int64",
  5640. "description": "ID of the user to search for",
  5641. "name": "uid",
  5642. "in": "query"
  5643. },
  5644. {
  5645. "type": "integer",
  5646. "description": "maximum number of users to return",
  5647. "name": "limit",
  5648. "in": "query"
  5649. }
  5650. ],
  5651. "responses": {
  5652. "200": {
  5653. "description": "SearchResults of a successful search",
  5654. "schema": {
  5655. "type": "object",
  5656. "properties": {
  5657. "data": {
  5658. "type": "array",
  5659. "items": {
  5660. "$ref": "#/definitions/User"
  5661. }
  5662. },
  5663. "ok": {
  5664. "type": "boolean"
  5665. }
  5666. }
  5667. }
  5668. }
  5669. }
  5670. }
  5671. },
  5672. "/users/{follower}/following/{followee}": {
  5673. "get": {
  5674. "tags": [
  5675. "user"
  5676. ],
  5677. "summary": "Check if one user is following another user",
  5678. "operationId": "userCheckFollowing",
  5679. "parameters": [
  5680. {
  5681. "type": "string",
  5682. "description": "username of following user",
  5683. "name": "follower",
  5684. "in": "path",
  5685. "required": true
  5686. },
  5687. {
  5688. "type": "string",
  5689. "description": "username of followed user",
  5690. "name": "followee",
  5691. "in": "path",
  5692. "required": true
  5693. }
  5694. ],
  5695. "responses": {
  5696. "204": {
  5697. "$ref": "#/responses/empty"
  5698. },
  5699. "404": {
  5700. "$ref": "#/responses/notFound"
  5701. }
  5702. }
  5703. }
  5704. },
  5705. "/users/{username}": {
  5706. "get": {
  5707. "produces": [
  5708. "application/json"
  5709. ],
  5710. "tags": [
  5711. "user"
  5712. ],
  5713. "summary": "Get a user",
  5714. "operationId": "userGet",
  5715. "parameters": [
  5716. {
  5717. "type": "string",
  5718. "description": "username of user to get",
  5719. "name": "username",
  5720. "in": "path",
  5721. "required": true
  5722. }
  5723. ],
  5724. "responses": {
  5725. "200": {
  5726. "$ref": "#/responses/User"
  5727. },
  5728. "404": {
  5729. "$ref": "#/responses/notFound"
  5730. }
  5731. }
  5732. }
  5733. },
  5734. "/users/{username}/followers": {
  5735. "get": {
  5736. "produces": [
  5737. "application/json"
  5738. ],
  5739. "tags": [
  5740. "user"
  5741. ],
  5742. "summary": "List the given user's followers",
  5743. "operationId": "userListFollowers",
  5744. "parameters": [
  5745. {
  5746. "type": "string",
  5747. "description": "username of user",
  5748. "name": "username",
  5749. "in": "path",
  5750. "required": true
  5751. }
  5752. ],
  5753. "responses": {
  5754. "200": {
  5755. "$ref": "#/responses/UserList"
  5756. }
  5757. }
  5758. }
  5759. },
  5760. "/users/{username}/following": {
  5761. "get": {
  5762. "produces": [
  5763. "application/json"
  5764. ],
  5765. "tags": [
  5766. "user"
  5767. ],
  5768. "summary": "List the users that the given user is following",
  5769. "operationId": "userListFollowing",
  5770. "parameters": [
  5771. {
  5772. "type": "string",
  5773. "description": "username of user",
  5774. "name": "username",
  5775. "in": "path",
  5776. "required": true
  5777. }
  5778. ],
  5779. "responses": {
  5780. "200": {
  5781. "$ref": "#/responses/UserList"
  5782. }
  5783. }
  5784. }
  5785. },
  5786. "/users/{username}/gpg_keys": {
  5787. "get": {
  5788. "produces": [
  5789. "application/json"
  5790. ],
  5791. "tags": [
  5792. "user"
  5793. ],
  5794. "summary": "List the given user's GPG keys",
  5795. "operationId": "userListGPGKeys",
  5796. "parameters": [
  5797. {
  5798. "type": "string",
  5799. "description": "username of user",
  5800. "name": "username",
  5801. "in": "path",
  5802. "required": true
  5803. }
  5804. ],
  5805. "responses": {
  5806. "200": {
  5807. "$ref": "#/responses/GPGKeyList"
  5808. }
  5809. }
  5810. }
  5811. },
  5812. "/users/{username}/heatmap": {
  5813. "get": {
  5814. "produces": [
  5815. "application/json"
  5816. ],
  5817. "tags": [
  5818. "user"
  5819. ],
  5820. "summary": "Get a user's heatmap",
  5821. "operationId": "userGetHeatmapData",
  5822. "parameters": [
  5823. {
  5824. "type": "string",
  5825. "description": "username of user to get",
  5826. "name": "username",
  5827. "in": "path",
  5828. "required": true
  5829. }
  5830. ],
  5831. "responses": {
  5832. "200": {
  5833. "$ref": "#/responses/UserHeatmapData"
  5834. },
  5835. "404": {
  5836. "$ref": "#/responses/notFound"
  5837. }
  5838. }
  5839. }
  5840. },
  5841. "/users/{username}/keys": {
  5842. "get": {
  5843. "produces": [
  5844. "application/json"
  5845. ],
  5846. "tags": [
  5847. "user"
  5848. ],
  5849. "summary": "List the given user's public keys",
  5850. "operationId": "userListKeys",
  5851. "parameters": [
  5852. {
  5853. "type": "string",
  5854. "description": "username of user",
  5855. "name": "username",
  5856. "in": "path",
  5857. "required": true
  5858. },
  5859. {
  5860. "type": "string",
  5861. "description": "fingerprint of the key",
  5862. "name": "fingerprint",
  5863. "in": "query"
  5864. }
  5865. ],
  5866. "responses": {
  5867. "200": {
  5868. "$ref": "#/responses/PublicKeyList"
  5869. }
  5870. }
  5871. }
  5872. },
  5873. "/users/{username}/orgs": {
  5874. "get": {
  5875. "produces": [
  5876. "application/json"
  5877. ],
  5878. "tags": [
  5879. "organization"
  5880. ],
  5881. "summary": "List a user's organizations",
  5882. "operationId": "orgListUserOrgs",
  5883. "parameters": [
  5884. {
  5885. "type": "string",
  5886. "description": "username of user",
  5887. "name": "username",
  5888. "in": "path",
  5889. "required": true
  5890. }
  5891. ],
  5892. "responses": {
  5893. "200": {
  5894. "$ref": "#/responses/OrganizationList"
  5895. }
  5896. }
  5897. }
  5898. },
  5899. "/users/{username}/repos": {
  5900. "get": {
  5901. "produces": [
  5902. "application/json"
  5903. ],
  5904. "tags": [
  5905. "user"
  5906. ],
  5907. "summary": "List the repos owned by the given user",
  5908. "operationId": "userListRepos",
  5909. "parameters": [
  5910. {
  5911. "type": "string",
  5912. "description": "username of user",
  5913. "name": "username",
  5914. "in": "path",
  5915. "required": true
  5916. }
  5917. ],
  5918. "responses": {
  5919. "200": {
  5920. "$ref": "#/responses/RepositoryList"
  5921. }
  5922. }
  5923. }
  5924. },
  5925. "/users/{username}/starred": {
  5926. "get": {
  5927. "produces": [
  5928. "application/json"
  5929. ],
  5930. "tags": [
  5931. "user"
  5932. ],
  5933. "summary": "The repos that the given user has starred",
  5934. "operationId": "userListStarred",
  5935. "parameters": [
  5936. {
  5937. "type": "string",
  5938. "description": "username of user",
  5939. "name": "username",
  5940. "in": "path",
  5941. "required": true
  5942. }
  5943. ],
  5944. "responses": {
  5945. "200": {
  5946. "$ref": "#/responses/RepositoryList"
  5947. }
  5948. }
  5949. }
  5950. },
  5951. "/users/{username}/subscriptions": {
  5952. "get": {
  5953. "produces": [
  5954. "application/json"
  5955. ],
  5956. "tags": [
  5957. "user"
  5958. ],
  5959. "summary": "List the repositories watched by a user",
  5960. "operationId": "userListSubscriptions",
  5961. "parameters": [
  5962. {
  5963. "type": "string",
  5964. "description": "username of the user",
  5965. "name": "username",
  5966. "in": "path",
  5967. "required": true
  5968. }
  5969. ],
  5970. "responses": {
  5971. "200": {
  5972. "$ref": "#/responses/RepositoryList"
  5973. }
  5974. }
  5975. }
  5976. },
  5977. "/users/{username}/tokens": {
  5978. "get": {
  5979. "produces": [
  5980. "application/json"
  5981. ],
  5982. "tags": [
  5983. "user"
  5984. ],
  5985. "summary": "List the authenticated user's access tokens",
  5986. "operationId": "userGetTokens",
  5987. "parameters": [
  5988. {
  5989. "type": "string",
  5990. "description": "username of user",
  5991. "name": "username",
  5992. "in": "path",
  5993. "required": true
  5994. }
  5995. ],
  5996. "responses": {
  5997. "200": {
  5998. "$ref": "#/responses/AccessTokenList"
  5999. }
  6000. }
  6001. },
  6002. "post": {
  6003. "consumes": [
  6004. "application/json"
  6005. ],
  6006. "produces": [
  6007. "application/json"
  6008. ],
  6009. "tags": [
  6010. "user"
  6011. ],
  6012. "summary": "Create an access token",
  6013. "operationId": "userCreateToken",
  6014. "parameters": [
  6015. {
  6016. "type": "string",
  6017. "x-go-name": "Name",
  6018. "description": "username of user",
  6019. "name": "username",
  6020. "in": "path",
  6021. "required": true
  6022. },
  6023. {
  6024. "name": "accessToken",
  6025. "in": "body",
  6026. "schema": {
  6027. "type": "object",
  6028. "required": [
  6029. "name"
  6030. ],
  6031. "properties": {
  6032. "name": {
  6033. "type": "string"
  6034. }
  6035. }
  6036. }
  6037. }
  6038. ],
  6039. "responses": {
  6040. "200": {
  6041. "$ref": "#/responses/AccessToken"
  6042. }
  6043. }
  6044. }
  6045. },
  6046. "/users/{username}/tokens/{token}": {
  6047. "delete": {
  6048. "produces": [
  6049. "application/json"
  6050. ],
  6051. "tags": [
  6052. "user"
  6053. ],
  6054. "summary": "delete an access token",
  6055. "operationId": "userDeleteAccessToken",
  6056. "parameters": [
  6057. {
  6058. "type": "string",
  6059. "description": "username of user",
  6060. "name": "username",
  6061. "in": "path",
  6062. "required": true
  6063. },
  6064. {
  6065. "type": "integer",
  6066. "format": "int64",
  6067. "description": "token to be deleted",
  6068. "name": "token",
  6069. "in": "path",
  6070. "required": true
  6071. }
  6072. ],
  6073. "responses": {
  6074. "204": {
  6075. "$ref": "#/responses/empty"
  6076. }
  6077. }
  6078. }
  6079. },
  6080. "/version": {
  6081. "get": {
  6082. "produces": [
  6083. "application/json"
  6084. ],
  6085. "tags": [
  6086. "miscellaneous"
  6087. ],
  6088. "summary": "Returns the version of the Gitea application",
  6089. "operationId": "getVersion",
  6090. "responses": {
  6091. "200": {
  6092. "$ref": "#/responses/ServerVersion"
  6093. }
  6094. }
  6095. }
  6096. }
  6097. },
  6098. "definitions": {
  6099. "AddCollaboratorOption": {
  6100. "description": "AddCollaboratorOption options when adding a user as a collaborator of a repository",
  6101. "type": "object",
  6102. "properties": {
  6103. "permission": {
  6104. "type": "string",
  6105. "x-go-name": "Permission"
  6106. }
  6107. },
  6108. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6109. },
  6110. "AddTimeOption": {
  6111. "description": "AddTimeOption options for adding time to an issue",
  6112. "type": "object",
  6113. "required": [
  6114. "time"
  6115. ],
  6116. "properties": {
  6117. "time": {
  6118. "description": "time in seconds",
  6119. "type": "integer",
  6120. "format": "int64",
  6121. "x-go-name": "Time"
  6122. }
  6123. },
  6124. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6125. },
  6126. "Attachment": {
  6127. "description": "Attachment a generic attachment",
  6128. "type": "object",
  6129. "properties": {
  6130. "browser_download_url": {
  6131. "type": "string",
  6132. "x-go-name": "DownloadURL"
  6133. },
  6134. "created_at": {
  6135. "type": "string",
  6136. "format": "date-time",
  6137. "x-go-name": "Created"
  6138. },
  6139. "download_count": {
  6140. "type": "integer",
  6141. "format": "int64",
  6142. "x-go-name": "DownloadCount"
  6143. },
  6144. "id": {
  6145. "type": "integer",
  6146. "format": "int64",
  6147. "x-go-name": "ID"
  6148. },
  6149. "name": {
  6150. "type": "string",
  6151. "x-go-name": "Name"
  6152. },
  6153. "size": {
  6154. "type": "integer",
  6155. "format": "int64",
  6156. "x-go-name": "Size"
  6157. },
  6158. "uuid": {
  6159. "type": "string",
  6160. "x-go-name": "UUID"
  6161. }
  6162. },
  6163. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6164. },
  6165. "Branch": {
  6166. "description": "Branch represents a repository branch",
  6167. "type": "object",
  6168. "properties": {
  6169. "commit": {
  6170. "$ref": "#/definitions/PayloadCommit"
  6171. },
  6172. "name": {
  6173. "type": "string",
  6174. "x-go-name": "Name"
  6175. }
  6176. },
  6177. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6178. },
  6179. "Comment": {
  6180. "description": "Comment represents a comment on a commit or issue",
  6181. "type": "object",
  6182. "properties": {
  6183. "body": {
  6184. "type": "string",
  6185. "x-go-name": "Body"
  6186. },
  6187. "created_at": {
  6188. "type": "string",
  6189. "format": "date-time",
  6190. "x-go-name": "Created"
  6191. },
  6192. "html_url": {
  6193. "type": "string",
  6194. "x-go-name": "HTMLURL"
  6195. },
  6196. "id": {
  6197. "type": "integer",
  6198. "format": "int64",
  6199. "x-go-name": "ID"
  6200. },
  6201. "issue_url": {
  6202. "type": "string",
  6203. "x-go-name": "IssueURL"
  6204. },
  6205. "pull_request_url": {
  6206. "type": "string",
  6207. "x-go-name": "PRURL"
  6208. },
  6209. "updated_at": {
  6210. "type": "string",
  6211. "format": "date-time",
  6212. "x-go-name": "Updated"
  6213. },
  6214. "user": {
  6215. "$ref": "#/definitions/User"
  6216. }
  6217. },
  6218. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6219. },
  6220. "Commit": {
  6221. "type": "object",
  6222. "title": "Commit contains information generated from a Git commit.",
  6223. "properties": {
  6224. "author": {
  6225. "$ref": "#/definitions/User"
  6226. },
  6227. "commit": {
  6228. "$ref": "#/definitions/RepoCommit"
  6229. },
  6230. "committer": {
  6231. "$ref": "#/definitions/User"
  6232. },
  6233. "html_url": {
  6234. "type": "string",
  6235. "x-go-name": "HTMLURL"
  6236. },
  6237. "parents": {
  6238. "type": "array",
  6239. "items": {
  6240. "$ref": "#/definitions/CommitMeta"
  6241. },
  6242. "x-go-name": "Parents"
  6243. },
  6244. "sha": {
  6245. "type": "string",
  6246. "x-go-name": "SHA"
  6247. },
  6248. "url": {
  6249. "type": "string",
  6250. "x-go-name": "URL"
  6251. }
  6252. },
  6253. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6254. },
  6255. "CommitMeta": {
  6256. "type": "object",
  6257. "title": "CommitMeta contains meta information of a commit in terms of API.",
  6258. "properties": {
  6259. "sha": {
  6260. "type": "string",
  6261. "x-go-name": "SHA"
  6262. },
  6263. "url": {
  6264. "type": "string",
  6265. "x-go-name": "URL"
  6266. }
  6267. },
  6268. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6269. },
  6270. "CommitUser": {
  6271. "type": "object",
  6272. "title": "CommitUser contains information of a user in the context of a commit.",
  6273. "properties": {
  6274. "date": {
  6275. "type": "string",
  6276. "x-go-name": "Date"
  6277. },
  6278. "email": {
  6279. "type": "string",
  6280. "x-go-name": "Email"
  6281. },
  6282. "name": {
  6283. "type": "string",
  6284. "x-go-name": "Name"
  6285. }
  6286. },
  6287. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6288. },
  6289. "CreateEmailOption": {
  6290. "description": "CreateEmailOption options when creating email addresses",
  6291. "type": "object",
  6292. "properties": {
  6293. "emails": {
  6294. "description": "email addresses to add",
  6295. "type": "array",
  6296. "items": {
  6297. "type": "string"
  6298. },
  6299. "x-go-name": "Emails"
  6300. }
  6301. },
  6302. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6303. },
  6304. "CreateForkOption": {
  6305. "description": "CreateForkOption options for creating a fork",
  6306. "type": "object",
  6307. "properties": {
  6308. "organization": {
  6309. "description": "organization name, if forking into an organization",
  6310. "type": "string",
  6311. "x-go-name": "Organization"
  6312. }
  6313. },
  6314. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6315. },
  6316. "CreateGPGKeyOption": {
  6317. "description": "CreateGPGKeyOption options create user GPG key",
  6318. "type": "object",
  6319. "required": [
  6320. "armored_public_key"
  6321. ],
  6322. "properties": {
  6323. "armored_public_key": {
  6324. "description": "An armored GPG key to add",
  6325. "type": "string",
  6326. "uniqueItems": true,
  6327. "x-go-name": "ArmoredKey"
  6328. }
  6329. },
  6330. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6331. },
  6332. "CreateHookOption": {
  6333. "description": "CreateHookOption options when create a hook",
  6334. "type": "object",
  6335. "required": [
  6336. "type",
  6337. "config"
  6338. ],
  6339. "properties": {
  6340. "active": {
  6341. "type": "boolean",
  6342. "default": false,
  6343. "x-go-name": "Active"
  6344. },
  6345. "config": {
  6346. "type": "object",
  6347. "additionalProperties": {
  6348. "type": "string"
  6349. },
  6350. "x-go-name": "Config"
  6351. },
  6352. "events": {
  6353. "type": "array",
  6354. "items": {
  6355. "type": "string"
  6356. },
  6357. "x-go-name": "Events"
  6358. },
  6359. "type": {
  6360. "type": "string",
  6361. "enum": [
  6362. "gitea",
  6363. "gogs",
  6364. "slack",
  6365. "discord"
  6366. ],
  6367. "x-go-name": "Type"
  6368. }
  6369. },
  6370. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6371. },
  6372. "CreateIssueCommentOption": {
  6373. "description": "CreateIssueCommentOption options for creating a comment on an issue",
  6374. "type": "object",
  6375. "required": [
  6376. "body"
  6377. ],
  6378. "properties": {
  6379. "body": {
  6380. "type": "string",
  6381. "x-go-name": "Body"
  6382. }
  6383. },
  6384. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6385. },
  6386. "CreateIssueOption": {
  6387. "description": "CreateIssueOption options to create one issue",
  6388. "type": "object",
  6389. "required": [
  6390. "title"
  6391. ],
  6392. "properties": {
  6393. "assignee": {
  6394. "description": "username of assignee",
  6395. "type": "string",
  6396. "x-go-name": "Assignee"
  6397. },
  6398. "assignees": {
  6399. "type": "array",
  6400. "items": {
  6401. "type": "string"
  6402. },
  6403. "x-go-name": "Assignees"
  6404. },
  6405. "body": {
  6406. "type": "string",
  6407. "x-go-name": "Body"
  6408. },
  6409. "closed": {
  6410. "type": "boolean",
  6411. "x-go-name": "Closed"
  6412. },
  6413. "due_date": {
  6414. "type": "string",
  6415. "format": "date-time",
  6416. "x-go-name": "Deadline"
  6417. },
  6418. "labels": {
  6419. "description": "list of label ids",
  6420. "type": "array",
  6421. "items": {
  6422. "type": "integer",
  6423. "format": "int64"
  6424. },
  6425. "x-go-name": "Labels"
  6426. },
  6427. "milestone": {
  6428. "description": "milestone id",
  6429. "type": "integer",
  6430. "format": "int64",
  6431. "x-go-name": "Milestone"
  6432. },
  6433. "title": {
  6434. "type": "string",
  6435. "x-go-name": "Title"
  6436. }
  6437. },
  6438. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6439. },
  6440. "CreateKeyOption": {
  6441. "description": "CreateKeyOption options when creating a key",
  6442. "type": "object",
  6443. "required": [
  6444. "title",
  6445. "key"
  6446. ],
  6447. "properties": {
  6448. "key": {
  6449. "description": "An armored SSH key to add",
  6450. "type": "string",
  6451. "uniqueItems": true,
  6452. "x-go-name": "Key"
  6453. },
  6454. "read_only": {
  6455. "description": "Describe if the key has only read access or read/write",
  6456. "type": "boolean",
  6457. "x-go-name": "ReadOnly"
  6458. },
  6459. "title": {
  6460. "description": "Title of the key to add",
  6461. "type": "string",
  6462. "uniqueItems": true,
  6463. "x-go-name": "Title"
  6464. }
  6465. },
  6466. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6467. },
  6468. "CreateLabelOption": {
  6469. "description": "CreateLabelOption options for creating a label",
  6470. "type": "object",
  6471. "required": [
  6472. "name",
  6473. "color"
  6474. ],
  6475. "properties": {
  6476. "color": {
  6477. "type": "string",
  6478. "x-go-name": "Color",
  6479. "example": "#00aabb"
  6480. },
  6481. "name": {
  6482. "type": "string",
  6483. "x-go-name": "Name"
  6484. }
  6485. },
  6486. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6487. },
  6488. "CreateMilestoneOption": {
  6489. "description": "CreateMilestoneOption options for creating a milestone",
  6490. "type": "object",
  6491. "properties": {
  6492. "description": {
  6493. "type": "string",
  6494. "x-go-name": "Description"
  6495. },
  6496. "due_on": {
  6497. "type": "string",
  6498. "format": "date-time",
  6499. "x-go-name": "Deadline"
  6500. },
  6501. "title": {
  6502. "type": "string",
  6503. "x-go-name": "Title"
  6504. }
  6505. },
  6506. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6507. },
  6508. "CreateOrgOption": {
  6509. "description": "CreateOrgOption options for creating an organization",
  6510. "type": "object",
  6511. "required": [
  6512. "username"
  6513. ],
  6514. "properties": {
  6515. "description": {
  6516. "type": "string",
  6517. "x-go-name": "Description"
  6518. },
  6519. "full_name": {
  6520. "type": "string",
  6521. "x-go-name": "FullName"
  6522. },
  6523. "location": {
  6524. "type": "string",
  6525. "x-go-name": "Location"
  6526. },
  6527. "username": {
  6528. "type": "string",
  6529. "x-go-name": "UserName"
  6530. },
  6531. "website": {
  6532. "type": "string",
  6533. "x-go-name": "Website"
  6534. }
  6535. },
  6536. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6537. },
  6538. "CreatePullRequestOption": {
  6539. "description": "CreatePullRequestOption options when creating a pull request",
  6540. "type": "object",
  6541. "properties": {
  6542. "assignee": {
  6543. "type": "string",
  6544. "x-go-name": "Assignee"
  6545. },
  6546. "assignees": {
  6547. "type": "array",
  6548. "items": {
  6549. "type": "string"
  6550. },
  6551. "x-go-name": "Assignees"
  6552. },
  6553. "base": {
  6554. "type": "string",
  6555. "x-go-name": "Base"
  6556. },
  6557. "body": {
  6558. "type": "string",
  6559. "x-go-name": "Body"
  6560. },
  6561. "due_date": {
  6562. "type": "string",
  6563. "format": "date-time",
  6564. "x-go-name": "Deadline"
  6565. },
  6566. "head": {
  6567. "type": "string",
  6568. "x-go-name": "Head"
  6569. },
  6570. "labels": {
  6571. "type": "array",
  6572. "items": {
  6573. "type": "integer",
  6574. "format": "int64"
  6575. },
  6576. "x-go-name": "Labels"
  6577. },
  6578. "milestone": {
  6579. "type": "integer",
  6580. "format": "int64",
  6581. "x-go-name": "Milestone"
  6582. },
  6583. "title": {
  6584. "type": "string",
  6585. "x-go-name": "Title"
  6586. }
  6587. },
  6588. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6589. },
  6590. "CreateReleaseOption": {
  6591. "description": "CreateReleaseOption options when creating a release",
  6592. "type": "object",
  6593. "required": [
  6594. "tag_name"
  6595. ],
  6596. "properties": {
  6597. "body": {
  6598. "type": "string",
  6599. "x-go-name": "Note"
  6600. },
  6601. "draft": {
  6602. "type": "boolean",
  6603. "x-go-name": "IsDraft"
  6604. },
  6605. "name": {
  6606. "type": "string",
  6607. "x-go-name": "Title"
  6608. },
  6609. "prerelease": {
  6610. "type": "boolean",
  6611. "x-go-name": "IsPrerelease"
  6612. },
  6613. "tag_name": {
  6614. "type": "string",
  6615. "x-go-name": "TagName"
  6616. },
  6617. "target_commitish": {
  6618. "type": "string",
  6619. "x-go-name": "Target"
  6620. }
  6621. },
  6622. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6623. },
  6624. "CreateRepoOption": {
  6625. "description": "CreateRepoOption options when creating repository",
  6626. "type": "object",
  6627. "required": [
  6628. "name"
  6629. ],
  6630. "properties": {
  6631. "auto_init": {
  6632. "description": "Whether the repository should be auto-intialized?",
  6633. "type": "boolean",
  6634. "x-go-name": "AutoInit"
  6635. },
  6636. "description": {
  6637. "description": "Description of the repository to create",
  6638. "type": "string",
  6639. "x-go-name": "Description"
  6640. },
  6641. "gitignores": {
  6642. "description": "Gitignores to use",
  6643. "type": "string",
  6644. "x-go-name": "Gitignores"
  6645. },
  6646. "license": {
  6647. "description": "License to use",
  6648. "type": "string",
  6649. "x-go-name": "License"
  6650. },
  6651. "name": {
  6652. "description": "Name of the repository to create",
  6653. "type": "string",
  6654. "uniqueItems": true,
  6655. "x-go-name": "Name"
  6656. },
  6657. "private": {
  6658. "description": "Whether the repository is private",
  6659. "type": "boolean",
  6660. "x-go-name": "Private"
  6661. },
  6662. "readme": {
  6663. "description": "Readme of the repository to create",
  6664. "type": "string",
  6665. "x-go-name": "Readme"
  6666. }
  6667. },
  6668. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6669. },
  6670. "CreateStatusOption": {
  6671. "description": "CreateStatusOption holds the information needed to create a new Status for a Commit",
  6672. "type": "object",
  6673. "properties": {
  6674. "context": {
  6675. "type": "string",
  6676. "x-go-name": "Context"
  6677. },
  6678. "description": {
  6679. "type": "string",
  6680. "x-go-name": "Description"
  6681. },
  6682. "state": {
  6683. "$ref": "#/definitions/StatusState"
  6684. },
  6685. "target_url": {
  6686. "type": "string",
  6687. "x-go-name": "TargetURL"
  6688. }
  6689. },
  6690. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6691. },
  6692. "CreateTeamOption": {
  6693. "description": "CreateTeamOption options for creating a team",
  6694. "type": "object",
  6695. "required": [
  6696. "name"
  6697. ],
  6698. "properties": {
  6699. "description": {
  6700. "type": "string",
  6701. "x-go-name": "Description"
  6702. },
  6703. "name": {
  6704. "type": "string",
  6705. "x-go-name": "Name"
  6706. },
  6707. "permission": {
  6708. "type": "string",
  6709. "enum": [
  6710. "read",
  6711. "write",
  6712. "admin"
  6713. ],
  6714. "x-go-name": "Permission"
  6715. },
  6716. "units": {
  6717. "type": "array",
  6718. "enum": [
  6719. "repo.code",
  6720. "repo.issues",
  6721. "repo.ext_issues",
  6722. "repo.wiki",
  6723. "repo.pulls",
  6724. "repo.releases",
  6725. "repo.ext_wiki"
  6726. ],
  6727. "items": {
  6728. "type": "string"
  6729. },
  6730. "x-go-name": "Units"
  6731. }
  6732. },
  6733. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6734. },
  6735. "CreateUserOption": {
  6736. "description": "CreateUserOption create user options",
  6737. "type": "object",
  6738. "required": [
  6739. "username",
  6740. "email",
  6741. "password"
  6742. ],
  6743. "properties": {
  6744. "email": {
  6745. "type": "string",
  6746. "format": "email",
  6747. "x-go-name": "Email"
  6748. },
  6749. "full_name": {
  6750. "type": "string",
  6751. "x-go-name": "FullName"
  6752. },
  6753. "login_name": {
  6754. "type": "string",
  6755. "x-go-name": "LoginName"
  6756. },
  6757. "password": {
  6758. "type": "string",
  6759. "x-go-name": "Password"
  6760. },
  6761. "send_notify": {
  6762. "type": "boolean",
  6763. "x-go-name": "SendNotify"
  6764. },
  6765. "source_id": {
  6766. "type": "integer",
  6767. "format": "int64",
  6768. "x-go-name": "SourceID"
  6769. },
  6770. "username": {
  6771. "type": "string",
  6772. "x-go-name": "Username"
  6773. }
  6774. },
  6775. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6776. },
  6777. "DeleteEmailOption": {
  6778. "description": "DeleteEmailOption options when deleting email addresses",
  6779. "type": "object",
  6780. "properties": {
  6781. "emails": {
  6782. "description": "email addresses to delete",
  6783. "type": "array",
  6784. "items": {
  6785. "type": "string"
  6786. },
  6787. "x-go-name": "Emails"
  6788. }
  6789. },
  6790. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6791. },
  6792. "DeployKey": {
  6793. "description": "DeployKey a deploy key",
  6794. "type": "object",
  6795. "properties": {
  6796. "created_at": {
  6797. "type": "string",
  6798. "format": "date-time",
  6799. "x-go-name": "Created"
  6800. },
  6801. "fingerprint": {
  6802. "type": "string",
  6803. "x-go-name": "Fingerprint"
  6804. },
  6805. "id": {
  6806. "type": "integer",
  6807. "format": "int64",
  6808. "x-go-name": "ID"
  6809. },
  6810. "key": {
  6811. "type": "string",
  6812. "x-go-name": "Key"
  6813. },
  6814. "key_id": {
  6815. "type": "integer",
  6816. "format": "int64",
  6817. "x-go-name": "KeyID"
  6818. },
  6819. "read_only": {
  6820. "type": "boolean",
  6821. "x-go-name": "ReadOnly"
  6822. },
  6823. "repository": {
  6824. "$ref": "#/definitions/Repository"
  6825. },
  6826. "title": {
  6827. "type": "string",
  6828. "x-go-name": "Title"
  6829. },
  6830. "url": {
  6831. "type": "string",
  6832. "x-go-name": "URL"
  6833. }
  6834. },
  6835. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6836. },
  6837. "EditAttachmentOptions": {
  6838. "description": "EditAttachmentOptions options for editing attachments",
  6839. "type": "object",
  6840. "properties": {
  6841. "name": {
  6842. "type": "string",
  6843. "x-go-name": "Name"
  6844. }
  6845. },
  6846. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6847. },
  6848. "EditDeadlineOption": {
  6849. "description": "EditDeadlineOption options for creating a deadline",
  6850. "type": "object",
  6851. "required": [
  6852. "due_date"
  6853. ],
  6854. "properties": {
  6855. "due_date": {
  6856. "type": "string",
  6857. "format": "date-time",
  6858. "x-go-name": "Deadline"
  6859. }
  6860. },
  6861. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6862. },
  6863. "EditHookOption": {
  6864. "description": "EditHookOption options when modify one hook",
  6865. "type": "object",
  6866. "properties": {
  6867. "active": {
  6868. "type": "boolean",
  6869. "x-go-name": "Active"
  6870. },
  6871. "config": {
  6872. "type": "object",
  6873. "additionalProperties": {
  6874. "type": "string"
  6875. },
  6876. "x-go-name": "Config"
  6877. },
  6878. "events": {
  6879. "type": "array",
  6880. "items": {
  6881. "type": "string"
  6882. },
  6883. "x-go-name": "Events"
  6884. }
  6885. },
  6886. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6887. },
  6888. "EditIssueCommentOption": {
  6889. "description": "EditIssueCommentOption options for editing a comment",
  6890. "type": "object",
  6891. "required": [
  6892. "body"
  6893. ],
  6894. "properties": {
  6895. "body": {
  6896. "type": "string",
  6897. "x-go-name": "Body"
  6898. }
  6899. },
  6900. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6901. },
  6902. "EditIssueOption": {
  6903. "description": "EditIssueOption options for editing an issue",
  6904. "type": "object",
  6905. "properties": {
  6906. "assignee": {
  6907. "type": "string",
  6908. "x-go-name": "Assignee"
  6909. },
  6910. "assignees": {
  6911. "type": "array",
  6912. "items": {
  6913. "type": "string"
  6914. },
  6915. "x-go-name": "Assignees"
  6916. },
  6917. "body": {
  6918. "type": "string",
  6919. "x-go-name": "Body"
  6920. },
  6921. "due_date": {
  6922. "type": "string",
  6923. "format": "date-time",
  6924. "x-go-name": "Deadline"
  6925. },
  6926. "milestone": {
  6927. "type": "integer",
  6928. "format": "int64",
  6929. "x-go-name": "Milestone"
  6930. },
  6931. "state": {
  6932. "type": "string",
  6933. "x-go-name": "State"
  6934. },
  6935. "title": {
  6936. "type": "string",
  6937. "x-go-name": "Title"
  6938. }
  6939. },
  6940. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6941. },
  6942. "EditLabelOption": {
  6943. "description": "EditLabelOption options for editing a label",
  6944. "type": "object",
  6945. "properties": {
  6946. "color": {
  6947. "type": "string",
  6948. "x-go-name": "Color"
  6949. },
  6950. "name": {
  6951. "type": "string",
  6952. "x-go-name": "Name"
  6953. }
  6954. },
  6955. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6956. },
  6957. "EditMilestoneOption": {
  6958. "description": "EditMilestoneOption options for editing a milestone",
  6959. "type": "object",
  6960. "properties": {
  6961. "description": {
  6962. "type": "string",
  6963. "x-go-name": "Description"
  6964. },
  6965. "due_on": {
  6966. "type": "string",
  6967. "format": "date-time",
  6968. "x-go-name": "Deadline"
  6969. },
  6970. "state": {
  6971. "type": "string",
  6972. "x-go-name": "State"
  6973. },
  6974. "title": {
  6975. "type": "string",
  6976. "x-go-name": "Title"
  6977. }
  6978. },
  6979. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  6980. },
  6981. "EditOrgOption": {
  6982. "description": "EditOrgOption options for editing an organization",
  6983. "type": "object",
  6984. "properties": {
  6985. "description": {
  6986. "type": "string",
  6987. "x-go-name": "Description"
  6988. },
  6989. "full_name": {
  6990. "type": "string",
  6991. "x-go-name": "FullName"
  6992. },
  6993. "location": {
  6994. "type": "string",
  6995. "x-go-name": "Location"
  6996. },
  6997. "website": {
  6998. "type": "string",
  6999. "x-go-name": "Website"
  7000. }
  7001. },
  7002. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7003. },
  7004. "EditPullRequestOption": {
  7005. "description": "EditPullRequestOption options when modify pull request",
  7006. "type": "object",
  7007. "properties": {
  7008. "assignee": {
  7009. "type": "string",
  7010. "x-go-name": "Assignee"
  7011. },
  7012. "assignees": {
  7013. "type": "array",
  7014. "items": {
  7015. "type": "string"
  7016. },
  7017. "x-go-name": "Assignees"
  7018. },
  7019. "body": {
  7020. "type": "string",
  7021. "x-go-name": "Body"
  7022. },
  7023. "due_date": {
  7024. "type": "string",
  7025. "format": "date-time",
  7026. "x-go-name": "Deadline"
  7027. },
  7028. "labels": {
  7029. "type": "array",
  7030. "items": {
  7031. "type": "integer",
  7032. "format": "int64"
  7033. },
  7034. "x-go-name": "Labels"
  7035. },
  7036. "milestone": {
  7037. "type": "integer",
  7038. "format": "int64",
  7039. "x-go-name": "Milestone"
  7040. },
  7041. "state": {
  7042. "type": "string",
  7043. "x-go-name": "State"
  7044. },
  7045. "title": {
  7046. "type": "string",
  7047. "x-go-name": "Title"
  7048. }
  7049. },
  7050. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7051. },
  7052. "EditReleaseOption": {
  7053. "description": "EditReleaseOption options when editing a release",
  7054. "type": "object",
  7055. "properties": {
  7056. "body": {
  7057. "type": "string",
  7058. "x-go-name": "Note"
  7059. },
  7060. "draft": {
  7061. "type": "boolean",
  7062. "x-go-name": "IsDraft"
  7063. },
  7064. "name": {
  7065. "type": "string",
  7066. "x-go-name": "Title"
  7067. },
  7068. "prerelease": {
  7069. "type": "boolean",
  7070. "x-go-name": "IsPrerelease"
  7071. },
  7072. "tag_name": {
  7073. "type": "string",
  7074. "x-go-name": "TagName"
  7075. },
  7076. "target_commitish": {
  7077. "type": "string",
  7078. "x-go-name": "Target"
  7079. }
  7080. },
  7081. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7082. },
  7083. "EditTeamOption": {
  7084. "description": "EditTeamOption options for editing a team",
  7085. "type": "object",
  7086. "required": [
  7087. "name"
  7088. ],
  7089. "properties": {
  7090. "description": {
  7091. "type": "string",
  7092. "x-go-name": "Description"
  7093. },
  7094. "name": {
  7095. "type": "string",
  7096. "x-go-name": "Name"
  7097. },
  7098. "permission": {
  7099. "type": "string",
  7100. "enum": [
  7101. "read",
  7102. "write",
  7103. "admin"
  7104. ],
  7105. "x-go-name": "Permission"
  7106. },
  7107. "units": {
  7108. "type": "array",
  7109. "enum": [
  7110. "repo.code",
  7111. "repo.issues",
  7112. "repo.ext_issues",
  7113. "repo.wiki",
  7114. "repo.pulls",
  7115. "repo.releases",
  7116. "repo.ext_wiki"
  7117. ],
  7118. "items": {
  7119. "type": "string"
  7120. },
  7121. "x-go-name": "Units"
  7122. }
  7123. },
  7124. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7125. },
  7126. "EditUserOption": {
  7127. "description": "EditUserOption edit user options",
  7128. "type": "object",
  7129. "required": [
  7130. "email"
  7131. ],
  7132. "properties": {
  7133. "active": {
  7134. "type": "boolean",
  7135. "x-go-name": "Active"
  7136. },
  7137. "admin": {
  7138. "type": "boolean",
  7139. "x-go-name": "Admin"
  7140. },
  7141. "allow_create_organization": {
  7142. "type": "boolean",
  7143. "x-go-name": "AllowCreateOrganization"
  7144. },
  7145. "allow_git_hook": {
  7146. "type": "boolean",
  7147. "x-go-name": "AllowGitHook"
  7148. },
  7149. "allow_import_local": {
  7150. "type": "boolean",
  7151. "x-go-name": "AllowImportLocal"
  7152. },
  7153. "email": {
  7154. "type": "string",
  7155. "format": "email",
  7156. "x-go-name": "Email"
  7157. },
  7158. "full_name": {
  7159. "type": "string",
  7160. "x-go-name": "FullName"
  7161. },
  7162. "location": {
  7163. "type": "string",
  7164. "x-go-name": "Location"
  7165. },
  7166. "login_name": {
  7167. "type": "string",
  7168. "x-go-name": "LoginName"
  7169. },
  7170. "max_repo_creation": {
  7171. "type": "integer",
  7172. "format": "int64",
  7173. "x-go-name": "MaxRepoCreation"
  7174. },
  7175. "password": {
  7176. "type": "string",
  7177. "x-go-name": "Password"
  7178. },
  7179. "prohibit_login": {
  7180. "type": "boolean",
  7181. "x-go-name": "ProhibitLogin"
  7182. },
  7183. "source_id": {
  7184. "type": "integer",
  7185. "format": "int64",
  7186. "x-go-name": "SourceID"
  7187. },
  7188. "website": {
  7189. "type": "string",
  7190. "x-go-name": "Website"
  7191. }
  7192. },
  7193. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7194. },
  7195. "Email": {
  7196. "description": "Email an email address belonging to a user",
  7197. "type": "object",
  7198. "properties": {
  7199. "email": {
  7200. "type": "string",
  7201. "format": "email",
  7202. "x-go-name": "Email"
  7203. },
  7204. "primary": {
  7205. "type": "boolean",
  7206. "x-go-name": "Primary"
  7207. },
  7208. "verified": {
  7209. "type": "boolean",
  7210. "x-go-name": "Verified"
  7211. }
  7212. },
  7213. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7214. },
  7215. "GPGKey": {
  7216. "description": "GPGKey a user GPG key to sign commit and tag in repository",
  7217. "type": "object",
  7218. "properties": {
  7219. "can_certify": {
  7220. "type": "boolean",
  7221. "x-go-name": "CanCertify"
  7222. },
  7223. "can_encrypt_comms": {
  7224. "type": "boolean",
  7225. "x-go-name": "CanEncryptComms"
  7226. },
  7227. "can_encrypt_storage": {
  7228. "type": "boolean",
  7229. "x-go-name": "CanEncryptStorage"
  7230. },
  7231. "can_sign": {
  7232. "type": "boolean",
  7233. "x-go-name": "CanSign"
  7234. },
  7235. "created_at": {
  7236. "type": "string",
  7237. "format": "date-time",
  7238. "x-go-name": "Created"
  7239. },
  7240. "emails": {
  7241. "type": "array",
  7242. "items": {
  7243. "$ref": "#/definitions/GPGKeyEmail"
  7244. },
  7245. "x-go-name": "Emails"
  7246. },
  7247. "expires_at": {
  7248. "type": "string",
  7249. "format": "date-time",
  7250. "x-go-name": "Expires"
  7251. },
  7252. "id": {
  7253. "type": "integer",
  7254. "format": "int64",
  7255. "x-go-name": "ID"
  7256. },
  7257. "key_id": {
  7258. "type": "string",
  7259. "x-go-name": "KeyID"
  7260. },
  7261. "primary_key_id": {
  7262. "type": "string",
  7263. "x-go-name": "PrimaryKeyID"
  7264. },
  7265. "public_key": {
  7266. "type": "string",
  7267. "x-go-name": "PublicKey"
  7268. },
  7269. "subkeys": {
  7270. "type": "array",
  7271. "items": {
  7272. "$ref": "#/definitions/GPGKey"
  7273. },
  7274. "x-go-name": "SubsKey"
  7275. }
  7276. },
  7277. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7278. },
  7279. "GPGKeyEmail": {
  7280. "description": "GPGKeyEmail an email attached to a GPGKey",
  7281. "type": "object",
  7282. "properties": {
  7283. "email": {
  7284. "type": "string",
  7285. "x-go-name": "Email"
  7286. },
  7287. "verified": {
  7288. "type": "boolean",
  7289. "x-go-name": "Verified"
  7290. }
  7291. },
  7292. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7293. },
  7294. "GitEntry": {
  7295. "description": "GitEntry represents a git tree",
  7296. "type": "object",
  7297. "properties": {
  7298. "mode": {
  7299. "type": "string",
  7300. "x-go-name": "Mode"
  7301. },
  7302. "path": {
  7303. "type": "string",
  7304. "x-go-name": "Path"
  7305. },
  7306. "sha": {
  7307. "type": "string",
  7308. "x-go-name": "SHA"
  7309. },
  7310. "size": {
  7311. "type": "integer",
  7312. "format": "int64",
  7313. "x-go-name": "Size"
  7314. },
  7315. "type": {
  7316. "type": "string",
  7317. "x-go-name": "Type"
  7318. },
  7319. "url": {
  7320. "type": "string",
  7321. "x-go-name": "URL"
  7322. }
  7323. },
  7324. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7325. },
  7326. "GitObject": {
  7327. "type": "object",
  7328. "title": "GitObject represents a Git object.",
  7329. "properties": {
  7330. "sha": {
  7331. "type": "string",
  7332. "x-go-name": "SHA"
  7333. },
  7334. "type": {
  7335. "type": "string",
  7336. "x-go-name": "Type"
  7337. },
  7338. "url": {
  7339. "type": "string",
  7340. "x-go-name": "URL"
  7341. }
  7342. },
  7343. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7344. },
  7345. "GitTreeResponse": {
  7346. "description": "GitTreeResponse returns a git tree",
  7347. "type": "object",
  7348. "properties": {
  7349. "sha": {
  7350. "type": "string",
  7351. "x-go-name": "SHA"
  7352. },
  7353. "tree": {
  7354. "type": "array",
  7355. "items": {
  7356. "$ref": "#/definitions/GitEntry"
  7357. },
  7358. "x-go-name": "Entries"
  7359. },
  7360. "truncated": {
  7361. "type": "boolean",
  7362. "x-go-name": "Truncated"
  7363. },
  7364. "url": {
  7365. "type": "string",
  7366. "x-go-name": "URL"
  7367. }
  7368. },
  7369. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7370. },
  7371. "Issue": {
  7372. "description": "Issue represents an issue in a repository",
  7373. "type": "object",
  7374. "properties": {
  7375. "assignee": {
  7376. "$ref": "#/definitions/User"
  7377. },
  7378. "assignees": {
  7379. "type": "array",
  7380. "items": {
  7381. "$ref": "#/definitions/User"
  7382. },
  7383. "x-go-name": "Assignees"
  7384. },
  7385. "body": {
  7386. "type": "string",
  7387. "x-go-name": "Body"
  7388. },
  7389. "closed_at": {
  7390. "type": "string",
  7391. "format": "date-time",
  7392. "x-go-name": "Closed"
  7393. },
  7394. "comments": {
  7395. "type": "integer",
  7396. "format": "int64",
  7397. "x-go-name": "Comments"
  7398. },
  7399. "created_at": {
  7400. "type": "string",
  7401. "format": "date-time",
  7402. "x-go-name": "Created"
  7403. },
  7404. "due_date": {
  7405. "type": "string",
  7406. "format": "date-time",
  7407. "x-go-name": "Deadline"
  7408. },
  7409. "id": {
  7410. "type": "integer",
  7411. "format": "int64",
  7412. "x-go-name": "ID"
  7413. },
  7414. "labels": {
  7415. "type": "array",
  7416. "items": {
  7417. "$ref": "#/definitions/Label"
  7418. },
  7419. "x-go-name": "Labels"
  7420. },
  7421. "milestone": {
  7422. "$ref": "#/definitions/Milestone"
  7423. },
  7424. "number": {
  7425. "type": "integer",
  7426. "format": "int64",
  7427. "x-go-name": "Index"
  7428. },
  7429. "pull_request": {
  7430. "$ref": "#/definitions/PullRequestMeta"
  7431. },
  7432. "state": {
  7433. "$ref": "#/definitions/StateType"
  7434. },
  7435. "title": {
  7436. "type": "string",
  7437. "x-go-name": "Title"
  7438. },
  7439. "updated_at": {
  7440. "type": "string",
  7441. "format": "date-time",
  7442. "x-go-name": "Updated"
  7443. },
  7444. "url": {
  7445. "type": "string",
  7446. "x-go-name": "URL"
  7447. },
  7448. "user": {
  7449. "$ref": "#/definitions/User"
  7450. }
  7451. },
  7452. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7453. },
  7454. "IssueDeadline": {
  7455. "description": "IssueDeadline represents an issue deadline",
  7456. "type": "object",
  7457. "properties": {
  7458. "due_date": {
  7459. "type": "string",
  7460. "format": "date-time",
  7461. "x-go-name": "Deadline"
  7462. }
  7463. },
  7464. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7465. },
  7466. "IssueLabelsOption": {
  7467. "description": "IssueLabelsOption a collection of labels",
  7468. "type": "object",
  7469. "properties": {
  7470. "labels": {
  7471. "description": "list of label IDs",
  7472. "type": "array",
  7473. "items": {
  7474. "type": "integer",
  7475. "format": "int64"
  7476. },
  7477. "x-go-name": "Labels"
  7478. }
  7479. },
  7480. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7481. },
  7482. "Label": {
  7483. "description": "Label a label to an issue or a pr",
  7484. "type": "object",
  7485. "properties": {
  7486. "color": {
  7487. "type": "string",
  7488. "x-go-name": "Color",
  7489. "example": "00aabb"
  7490. },
  7491. "id": {
  7492. "type": "integer",
  7493. "format": "int64",
  7494. "x-go-name": "ID"
  7495. },
  7496. "name": {
  7497. "type": "string",
  7498. "x-go-name": "Name"
  7499. },
  7500. "url": {
  7501. "type": "string",
  7502. "x-go-name": "URL"
  7503. }
  7504. },
  7505. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7506. },
  7507. "MarkdownOption": {
  7508. "description": "MarkdownOption markdown options",
  7509. "type": "object",
  7510. "properties": {
  7511. "Context": {
  7512. "description": "Context to render\n\nin: body",
  7513. "type": "string"
  7514. },
  7515. "Mode": {
  7516. "description": "Mode to render\n\nin: body",
  7517. "type": "string"
  7518. },
  7519. "Text": {
  7520. "description": "Text markdown to render\n\nin: body",
  7521. "type": "string"
  7522. },
  7523. "Wiki": {
  7524. "description": "Is it a wiki page ?\n\nin: body",
  7525. "type": "boolean"
  7526. }
  7527. },
  7528. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7529. },
  7530. "MigrateRepoForm": {
  7531. "description": "MigrateRepoForm form for migrating repository",
  7532. "type": "object",
  7533. "required": [
  7534. "clone_addr",
  7535. "uid",
  7536. "repo_name"
  7537. ],
  7538. "properties": {
  7539. "auth_password": {
  7540. "type": "string",
  7541. "x-go-name": "AuthPassword"
  7542. },
  7543. "auth_username": {
  7544. "type": "string",
  7545. "x-go-name": "AuthUsername"
  7546. },
  7547. "clone_addr": {
  7548. "type": "string",
  7549. "x-go-name": "CloneAddr"
  7550. },
  7551. "description": {
  7552. "type": "string",
  7553. "x-go-name": "Description"
  7554. },
  7555. "mirror": {
  7556. "type": "boolean",
  7557. "x-go-name": "Mirror"
  7558. },
  7559. "private": {
  7560. "type": "boolean",
  7561. "x-go-name": "Private"
  7562. },
  7563. "repo_name": {
  7564. "type": "string",
  7565. "x-go-name": "RepoName"
  7566. },
  7567. "uid": {
  7568. "type": "integer",
  7569. "format": "int64",
  7570. "x-go-name": "UID"
  7571. }
  7572. },
  7573. "x-go-package": "code.gitea.io/gitea/modules/auth"
  7574. },
  7575. "Milestone": {
  7576. "description": "Milestone milestone is a collection of issues on one repository",
  7577. "type": "object",
  7578. "properties": {
  7579. "closed_at": {
  7580. "type": "string",
  7581. "format": "date-time",
  7582. "x-go-name": "Closed"
  7583. },
  7584. "closed_issues": {
  7585. "type": "integer",
  7586. "format": "int64",
  7587. "x-go-name": "ClosedIssues"
  7588. },
  7589. "description": {
  7590. "type": "string",
  7591. "x-go-name": "Description"
  7592. },
  7593. "due_on": {
  7594. "type": "string",
  7595. "format": "date-time",
  7596. "x-go-name": "Deadline"
  7597. },
  7598. "id": {
  7599. "type": "integer",
  7600. "format": "int64",
  7601. "x-go-name": "ID"
  7602. },
  7603. "open_issues": {
  7604. "type": "integer",
  7605. "format": "int64",
  7606. "x-go-name": "OpenIssues"
  7607. },
  7608. "state": {
  7609. "$ref": "#/definitions/StateType"
  7610. },
  7611. "title": {
  7612. "type": "string",
  7613. "x-go-name": "Title"
  7614. }
  7615. },
  7616. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7617. },
  7618. "Organization": {
  7619. "description": "Organization represents an organization",
  7620. "type": "object",
  7621. "properties": {
  7622. "avatar_url": {
  7623. "type": "string",
  7624. "x-go-name": "AvatarURL"
  7625. },
  7626. "description": {
  7627. "type": "string",
  7628. "x-go-name": "Description"
  7629. },
  7630. "full_name": {
  7631. "type": "string",
  7632. "x-go-name": "FullName"
  7633. },
  7634. "id": {
  7635. "type": "integer",
  7636. "format": "int64",
  7637. "x-go-name": "ID"
  7638. },
  7639. "location": {
  7640. "type": "string",
  7641. "x-go-name": "Location"
  7642. },
  7643. "username": {
  7644. "type": "string",
  7645. "x-go-name": "UserName"
  7646. },
  7647. "website": {
  7648. "type": "string",
  7649. "x-go-name": "Website"
  7650. }
  7651. },
  7652. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7653. },
  7654. "PRBranchInfo": {
  7655. "description": "PRBranchInfo information about a branch",
  7656. "type": "object",
  7657. "properties": {
  7658. "label": {
  7659. "type": "string",
  7660. "x-go-name": "Name"
  7661. },
  7662. "ref": {
  7663. "type": "string",
  7664. "x-go-name": "Ref"
  7665. },
  7666. "repo": {
  7667. "$ref": "#/definitions/Repository"
  7668. },
  7669. "repo_id": {
  7670. "type": "integer",
  7671. "format": "int64",
  7672. "x-go-name": "RepoID"
  7673. },
  7674. "sha": {
  7675. "type": "string",
  7676. "x-go-name": "Sha"
  7677. }
  7678. },
  7679. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7680. },
  7681. "PayloadCommit": {
  7682. "description": "PayloadCommit represents a commit",
  7683. "type": "object",
  7684. "properties": {
  7685. "added": {
  7686. "type": "array",
  7687. "items": {
  7688. "type": "string"
  7689. },
  7690. "x-go-name": "Added"
  7691. },
  7692. "author": {
  7693. "$ref": "#/definitions/PayloadUser"
  7694. },
  7695. "committer": {
  7696. "$ref": "#/definitions/PayloadUser"
  7697. },
  7698. "id": {
  7699. "description": "sha1 hash of the commit",
  7700. "type": "string",
  7701. "x-go-name": "ID"
  7702. },
  7703. "message": {
  7704. "type": "string",
  7705. "x-go-name": "Message"
  7706. },
  7707. "modified": {
  7708. "type": "array",
  7709. "items": {
  7710. "type": "string"
  7711. },
  7712. "x-go-name": "Modified"
  7713. },
  7714. "removed": {
  7715. "type": "array",
  7716. "items": {
  7717. "type": "string"
  7718. },
  7719. "x-go-name": "Removed"
  7720. },
  7721. "timestamp": {
  7722. "type": "string",
  7723. "format": "date-time",
  7724. "x-go-name": "Timestamp"
  7725. },
  7726. "url": {
  7727. "type": "string",
  7728. "x-go-name": "URL"
  7729. },
  7730. "verification": {
  7731. "$ref": "#/definitions/PayloadCommitVerification"
  7732. }
  7733. },
  7734. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7735. },
  7736. "PayloadCommitVerification": {
  7737. "description": "PayloadCommitVerification represents the GPG verification of a commit",
  7738. "type": "object",
  7739. "properties": {
  7740. "payload": {
  7741. "type": "string",
  7742. "x-go-name": "Payload"
  7743. },
  7744. "reason": {
  7745. "type": "string",
  7746. "x-go-name": "Reason"
  7747. },
  7748. "signature": {
  7749. "type": "string",
  7750. "x-go-name": "Signature"
  7751. },
  7752. "verified": {
  7753. "type": "boolean",
  7754. "x-go-name": "Verified"
  7755. }
  7756. },
  7757. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7758. },
  7759. "PayloadUser": {
  7760. "description": "PayloadUser represents the author or committer of a commit",
  7761. "type": "object",
  7762. "properties": {
  7763. "email": {
  7764. "type": "string",
  7765. "format": "email",
  7766. "x-go-name": "Email"
  7767. },
  7768. "name": {
  7769. "description": "Full name of the commit author",
  7770. "type": "string",
  7771. "x-go-name": "Name"
  7772. },
  7773. "username": {
  7774. "type": "string",
  7775. "x-go-name": "UserName"
  7776. }
  7777. },
  7778. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7779. },
  7780. "Permission": {
  7781. "description": "Permission represents a set of permissions",
  7782. "type": "object",
  7783. "properties": {
  7784. "admin": {
  7785. "type": "boolean",
  7786. "x-go-name": "Admin"
  7787. },
  7788. "pull": {
  7789. "type": "boolean",
  7790. "x-go-name": "Pull"
  7791. },
  7792. "push": {
  7793. "type": "boolean",
  7794. "x-go-name": "Push"
  7795. }
  7796. },
  7797. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7798. },
  7799. "PublicKey": {
  7800. "description": "PublicKey publickey is a user key to push code to repository",
  7801. "type": "object",
  7802. "properties": {
  7803. "created_at": {
  7804. "type": "string",
  7805. "format": "date-time",
  7806. "x-go-name": "Created"
  7807. },
  7808. "fingerprint": {
  7809. "type": "string",
  7810. "x-go-name": "Fingerprint"
  7811. },
  7812. "id": {
  7813. "type": "integer",
  7814. "format": "int64",
  7815. "x-go-name": "ID"
  7816. },
  7817. "key": {
  7818. "type": "string",
  7819. "x-go-name": "Key"
  7820. },
  7821. "key_type": {
  7822. "type": "string",
  7823. "x-go-name": "KeyType"
  7824. },
  7825. "read_only": {
  7826. "type": "boolean",
  7827. "x-go-name": "ReadOnly"
  7828. },
  7829. "title": {
  7830. "type": "string",
  7831. "x-go-name": "Title"
  7832. },
  7833. "url": {
  7834. "type": "string",
  7835. "x-go-name": "URL"
  7836. },
  7837. "user": {
  7838. "$ref": "#/definitions/User"
  7839. }
  7840. },
  7841. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7842. },
  7843. "PullRequest": {
  7844. "description": "PullRequest represents a pull request",
  7845. "type": "object",
  7846. "properties": {
  7847. "assignee": {
  7848. "$ref": "#/definitions/User"
  7849. },
  7850. "assignees": {
  7851. "type": "array",
  7852. "items": {
  7853. "$ref": "#/definitions/User"
  7854. },
  7855. "x-go-name": "Assignees"
  7856. },
  7857. "base": {
  7858. "$ref": "#/definitions/PRBranchInfo"
  7859. },
  7860. "body": {
  7861. "type": "string",
  7862. "x-go-name": "Body"
  7863. },
  7864. "closed_at": {
  7865. "type": "string",
  7866. "format": "date-time",
  7867. "x-go-name": "Closed"
  7868. },
  7869. "comments": {
  7870. "type": "integer",
  7871. "format": "int64",
  7872. "x-go-name": "Comments"
  7873. },
  7874. "created_at": {
  7875. "type": "string",
  7876. "format": "date-time",
  7877. "x-go-name": "Created"
  7878. },
  7879. "diff_url": {
  7880. "type": "string",
  7881. "x-go-name": "DiffURL"
  7882. },
  7883. "due_date": {
  7884. "type": "string",
  7885. "format": "date-time",
  7886. "x-go-name": "Deadline"
  7887. },
  7888. "head": {
  7889. "$ref": "#/definitions/PRBranchInfo"
  7890. },
  7891. "html_url": {
  7892. "type": "string",
  7893. "x-go-name": "HTMLURL"
  7894. },
  7895. "id": {
  7896. "type": "integer",
  7897. "format": "int64",
  7898. "x-go-name": "ID"
  7899. },
  7900. "labels": {
  7901. "type": "array",
  7902. "items": {
  7903. "$ref": "#/definitions/Label"
  7904. },
  7905. "x-go-name": "Labels"
  7906. },
  7907. "merge_base": {
  7908. "type": "string",
  7909. "x-go-name": "MergeBase"
  7910. },
  7911. "merge_commit_sha": {
  7912. "type": "string",
  7913. "x-go-name": "MergedCommitID"
  7914. },
  7915. "mergeable": {
  7916. "type": "boolean",
  7917. "x-go-name": "Mergeable"
  7918. },
  7919. "merged": {
  7920. "type": "boolean",
  7921. "x-go-name": "HasMerged"
  7922. },
  7923. "merged_at": {
  7924. "type": "string",
  7925. "format": "date-time",
  7926. "x-go-name": "Merged"
  7927. },
  7928. "merged_by": {
  7929. "$ref": "#/definitions/User"
  7930. },
  7931. "milestone": {
  7932. "$ref": "#/definitions/Milestone"
  7933. },
  7934. "number": {
  7935. "type": "integer",
  7936. "format": "int64",
  7937. "x-go-name": "Index"
  7938. },
  7939. "patch_url": {
  7940. "type": "string",
  7941. "x-go-name": "PatchURL"
  7942. },
  7943. "state": {
  7944. "$ref": "#/definitions/StateType"
  7945. },
  7946. "title": {
  7947. "type": "string",
  7948. "x-go-name": "Title"
  7949. },
  7950. "updated_at": {
  7951. "type": "string",
  7952. "format": "date-time",
  7953. "x-go-name": "Updated"
  7954. },
  7955. "url": {
  7956. "type": "string",
  7957. "x-go-name": "URL"
  7958. },
  7959. "user": {
  7960. "$ref": "#/definitions/User"
  7961. }
  7962. },
  7963. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7964. },
  7965. "PullRequestMeta": {
  7966. "description": "PullRequestMeta PR info if an issue is a PR",
  7967. "type": "object",
  7968. "properties": {
  7969. "merged": {
  7970. "type": "boolean",
  7971. "x-go-name": "HasMerged"
  7972. },
  7973. "merged_at": {
  7974. "type": "string",
  7975. "format": "date-time",
  7976. "x-go-name": "Merged"
  7977. }
  7978. },
  7979. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7980. },
  7981. "Reference": {
  7982. "type": "object",
  7983. "title": "Reference represents a Git reference.",
  7984. "properties": {
  7985. "object": {
  7986. "$ref": "#/definitions/GitObject"
  7987. },
  7988. "ref": {
  7989. "type": "string",
  7990. "x-go-name": "Ref"
  7991. },
  7992. "url": {
  7993. "type": "string",
  7994. "x-go-name": "URL"
  7995. }
  7996. },
  7997. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  7998. },
  7999. "Release": {
  8000. "description": "Release represents a repository release",
  8001. "type": "object",
  8002. "properties": {
  8003. "assets": {
  8004. "type": "array",
  8005. "items": {
  8006. "$ref": "#/definitions/Attachment"
  8007. },
  8008. "x-go-name": "Attachments"
  8009. },
  8010. "author": {
  8011. "$ref": "#/definitions/User"
  8012. },
  8013. "body": {
  8014. "type": "string",
  8015. "x-go-name": "Note"
  8016. },
  8017. "created_at": {
  8018. "type": "string",
  8019. "format": "date-time",
  8020. "x-go-name": "CreatedAt"
  8021. },
  8022. "draft": {
  8023. "type": "boolean",
  8024. "x-go-name": "IsDraft"
  8025. },
  8026. "id": {
  8027. "type": "integer",
  8028. "format": "int64",
  8029. "x-go-name": "ID"
  8030. },
  8031. "name": {
  8032. "type": "string",
  8033. "x-go-name": "Title"
  8034. },
  8035. "prerelease": {
  8036. "type": "boolean",
  8037. "x-go-name": "IsPrerelease"
  8038. },
  8039. "published_at": {
  8040. "type": "string",
  8041. "format": "date-time",
  8042. "x-go-name": "PublishedAt"
  8043. },
  8044. "tag_name": {
  8045. "type": "string",
  8046. "x-go-name": "TagName"
  8047. },
  8048. "tarball_url": {
  8049. "type": "string",
  8050. "x-go-name": "TarURL"
  8051. },
  8052. "target_commitish": {
  8053. "type": "string",
  8054. "x-go-name": "Target"
  8055. },
  8056. "url": {
  8057. "type": "string",
  8058. "x-go-name": "URL"
  8059. },
  8060. "zipball_url": {
  8061. "type": "string",
  8062. "x-go-name": "ZipURL"
  8063. }
  8064. },
  8065. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8066. },
  8067. "RepoCommit": {
  8068. "type": "object",
  8069. "title": "RepoCommit contains information of a commit in the context of a repository.",
  8070. "properties": {
  8071. "author": {
  8072. "$ref": "#/definitions/CommitUser"
  8073. },
  8074. "committer": {
  8075. "$ref": "#/definitions/CommitUser"
  8076. },
  8077. "message": {
  8078. "type": "string",
  8079. "x-go-name": "Message"
  8080. },
  8081. "tree": {
  8082. "$ref": "#/definitions/CommitMeta"
  8083. },
  8084. "url": {
  8085. "type": "string",
  8086. "x-go-name": "URL"
  8087. }
  8088. },
  8089. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8090. },
  8091. "Repository": {
  8092. "description": "Repository represents a repository",
  8093. "type": "object",
  8094. "properties": {
  8095. "archived": {
  8096. "type": "boolean",
  8097. "x-go-name": "Archived"
  8098. },
  8099. "clone_url": {
  8100. "type": "string",
  8101. "x-go-name": "CloneURL"
  8102. },
  8103. "created_at": {
  8104. "type": "string",
  8105. "format": "date-time",
  8106. "x-go-name": "Created"
  8107. },
  8108. "default_branch": {
  8109. "type": "string",
  8110. "x-go-name": "DefaultBranch"
  8111. },
  8112. "description": {
  8113. "type": "string",
  8114. "x-go-name": "Description"
  8115. },
  8116. "empty": {
  8117. "type": "boolean",
  8118. "x-go-name": "Empty"
  8119. },
  8120. "fork": {
  8121. "type": "boolean",
  8122. "x-go-name": "Fork"
  8123. },
  8124. "forks_count": {
  8125. "type": "integer",
  8126. "format": "int64",
  8127. "x-go-name": "Forks"
  8128. },
  8129. "full_name": {
  8130. "type": "string",
  8131. "x-go-name": "FullName"
  8132. },
  8133. "html_url": {
  8134. "type": "string",
  8135. "x-go-name": "HTMLURL"
  8136. },
  8137. "id": {
  8138. "type": "integer",
  8139. "format": "int64",
  8140. "x-go-name": "ID"
  8141. },
  8142. "mirror": {
  8143. "type": "boolean",
  8144. "x-go-name": "Mirror"
  8145. },
  8146. "name": {
  8147. "type": "string",
  8148. "x-go-name": "Name"
  8149. },
  8150. "open_issues_count": {
  8151. "type": "integer",
  8152. "format": "int64",
  8153. "x-go-name": "OpenIssues"
  8154. },
  8155. "owner": {
  8156. "$ref": "#/definitions/User"
  8157. },
  8158. "parent": {
  8159. "$ref": "#/definitions/Repository"
  8160. },
  8161. "permissions": {
  8162. "$ref": "#/definitions/Permission"
  8163. },
  8164. "private": {
  8165. "type": "boolean",
  8166. "x-go-name": "Private"
  8167. },
  8168. "size": {
  8169. "type": "integer",
  8170. "format": "int64",
  8171. "x-go-name": "Size"
  8172. },
  8173. "ssh_url": {
  8174. "type": "string",
  8175. "x-go-name": "SSHURL"
  8176. },
  8177. "stars_count": {
  8178. "type": "integer",
  8179. "format": "int64",
  8180. "x-go-name": "Stars"
  8181. },
  8182. "updated_at": {
  8183. "type": "string",
  8184. "format": "date-time",
  8185. "x-go-name": "Updated"
  8186. },
  8187. "watchers_count": {
  8188. "type": "integer",
  8189. "format": "int64",
  8190. "x-go-name": "Watchers"
  8191. },
  8192. "website": {
  8193. "type": "string",
  8194. "x-go-name": "Website"
  8195. }
  8196. },
  8197. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8198. },
  8199. "SearchResults": {
  8200. "description": "SearchResults results of a successful search",
  8201. "type": "object",
  8202. "properties": {
  8203. "data": {
  8204. "type": "array",
  8205. "items": {
  8206. "$ref": "#/definitions/Repository"
  8207. },
  8208. "x-go-name": "Data"
  8209. },
  8210. "ok": {
  8211. "type": "boolean",
  8212. "x-go-name": "OK"
  8213. }
  8214. },
  8215. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8216. },
  8217. "ServerVersion": {
  8218. "description": "ServerVersion wraps the version of the server",
  8219. "type": "object",
  8220. "properties": {
  8221. "version": {
  8222. "type": "string",
  8223. "x-go-name": "Version"
  8224. }
  8225. },
  8226. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8227. },
  8228. "StateType": {
  8229. "description": "StateType issue state type",
  8230. "type": "string",
  8231. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8232. },
  8233. "Status": {
  8234. "description": "Status holds a single Status of a single Commit",
  8235. "type": "object",
  8236. "properties": {
  8237. "context": {
  8238. "type": "string",
  8239. "x-go-name": "Context"
  8240. },
  8241. "created_at": {
  8242. "type": "string",
  8243. "format": "date-time",
  8244. "x-go-name": "Created"
  8245. },
  8246. "creator": {
  8247. "$ref": "#/definitions/User"
  8248. },
  8249. "description": {
  8250. "type": "string",
  8251. "x-go-name": "Description"
  8252. },
  8253. "id": {
  8254. "type": "integer",
  8255. "format": "int64",
  8256. "x-go-name": "ID"
  8257. },
  8258. "status": {
  8259. "$ref": "#/definitions/StatusState"
  8260. },
  8261. "target_url": {
  8262. "type": "string",
  8263. "x-go-name": "TargetURL"
  8264. },
  8265. "updated_at": {
  8266. "type": "string",
  8267. "format": "date-time",
  8268. "x-go-name": "Updated"
  8269. },
  8270. "url": {
  8271. "type": "string",
  8272. "x-go-name": "URL"
  8273. }
  8274. },
  8275. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8276. },
  8277. "StatusState": {
  8278. "description": "StatusState holds the state of a Status\nIt can be \"pending\", \"success\", \"error\", \"failure\", and \"warning\"",
  8279. "type": "string",
  8280. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8281. },
  8282. "Team": {
  8283. "description": "Team represents a team in an organization",
  8284. "type": "object",
  8285. "properties": {
  8286. "description": {
  8287. "type": "string",
  8288. "x-go-name": "Description"
  8289. },
  8290. "id": {
  8291. "type": "integer",
  8292. "format": "int64",
  8293. "x-go-name": "ID"
  8294. },
  8295. "name": {
  8296. "type": "string",
  8297. "x-go-name": "Name"
  8298. },
  8299. "organization": {
  8300. "$ref": "#/definitions/Organization"
  8301. },
  8302. "permission": {
  8303. "type": "string",
  8304. "enum": [
  8305. "none",
  8306. "read",
  8307. "write",
  8308. "admin",
  8309. "owner"
  8310. ],
  8311. "x-go-name": "Permission"
  8312. },
  8313. "units": {
  8314. "type": "array",
  8315. "enum": [
  8316. "repo.code",
  8317. "repo.issues",
  8318. "repo.ext_issues",
  8319. "repo.wiki",
  8320. "repo.pulls",
  8321. "repo.releases",
  8322. "repo.ext_wiki"
  8323. ],
  8324. "items": {
  8325. "type": "string"
  8326. },
  8327. "x-go-name": "Units"
  8328. }
  8329. },
  8330. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8331. },
  8332. "TimeStamp": {
  8333. "description": "TimeStamp defines a timestamp",
  8334. "type": "integer",
  8335. "format": "int64",
  8336. "x-go-package": "code.gitea.io/gitea/modules/util"
  8337. },
  8338. "TrackedTime": {
  8339. "description": "TrackedTime worked time for an issue / pr",
  8340. "type": "object",
  8341. "properties": {
  8342. "created": {
  8343. "type": "string",
  8344. "format": "date-time",
  8345. "x-go-name": "Created"
  8346. },
  8347. "id": {
  8348. "type": "integer",
  8349. "format": "int64",
  8350. "x-go-name": "ID"
  8351. },
  8352. "issue_id": {
  8353. "type": "integer",
  8354. "format": "int64",
  8355. "x-go-name": "IssueID"
  8356. },
  8357. "time": {
  8358. "description": "Time in seconds",
  8359. "type": "integer",
  8360. "format": "int64",
  8361. "x-go-name": "Time"
  8362. },
  8363. "user_id": {
  8364. "type": "integer",
  8365. "format": "int64",
  8366. "x-go-name": "UserID"
  8367. }
  8368. },
  8369. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8370. },
  8371. "User": {
  8372. "description": "User represents a user",
  8373. "type": "object",
  8374. "properties": {
  8375. "avatar_url": {
  8376. "description": "URL to the user's avatar",
  8377. "type": "string",
  8378. "x-go-name": "AvatarURL"
  8379. },
  8380. "email": {
  8381. "type": "string",
  8382. "format": "email",
  8383. "x-go-name": "Email"
  8384. },
  8385. "full_name": {
  8386. "description": "the user's full name",
  8387. "type": "string",
  8388. "x-go-name": "FullName"
  8389. },
  8390. "id": {
  8391. "description": "the user's id",
  8392. "type": "integer",
  8393. "format": "int64",
  8394. "x-go-name": "ID"
  8395. },
  8396. "language": {
  8397. "description": "User locale",
  8398. "type": "string",
  8399. "x-go-name": "Language"
  8400. },
  8401. "login": {
  8402. "description": "the user's username",
  8403. "type": "string",
  8404. "x-go-name": "UserName"
  8405. }
  8406. },
  8407. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8408. },
  8409. "UserHeatmapData": {
  8410. "description": "UserHeatmapData represents the data needed to create a heatmap",
  8411. "type": "object",
  8412. "properties": {
  8413. "contributions": {
  8414. "type": "integer",
  8415. "format": "int64",
  8416. "x-go-name": "Contributions"
  8417. },
  8418. "timestamp": {
  8419. "$ref": "#/definitions/TimeStamp"
  8420. }
  8421. },
  8422. "x-go-package": "code.gitea.io/gitea/models"
  8423. },
  8424. "WatchInfo": {
  8425. "description": "WatchInfo represents an API watch status of one repository",
  8426. "type": "object",
  8427. "properties": {
  8428. "created_at": {
  8429. "type": "string",
  8430. "format": "date-time",
  8431. "x-go-name": "CreatedAt"
  8432. },
  8433. "ignored": {
  8434. "type": "boolean",
  8435. "x-go-name": "Ignored"
  8436. },
  8437. "reason": {
  8438. "type": "object",
  8439. "x-go-name": "Reason"
  8440. },
  8441. "repository_url": {
  8442. "type": "string",
  8443. "x-go-name": "RepositoryURL"
  8444. },
  8445. "subscribed": {
  8446. "type": "boolean",
  8447. "x-go-name": "Subscribed"
  8448. },
  8449. "url": {
  8450. "type": "string",
  8451. "x-go-name": "URL"
  8452. }
  8453. },
  8454. "x-go-package": "code.gitea.io/gitea/vendor/code.gitea.io/sdk/gitea"
  8455. }
  8456. },
  8457. "responses": {
  8458. "AccessToken": {
  8459. "description": "AccessToken represents a API access token.",
  8460. "headers": {
  8461. "id": {
  8462. "type": "integer",
  8463. "format": "int64"
  8464. },
  8465. "name": {
  8466. "type": "string"
  8467. },
  8468. "sha1": {
  8469. "type": "string"
  8470. }
  8471. }
  8472. },
  8473. "AccessTokenList": {
  8474. "description": "AccessTokenList represents a list of API access token."
  8475. },
  8476. "Attachment": {
  8477. "description": "Attachment",
  8478. "schema": {
  8479. "$ref": "#/definitions/Attachment"
  8480. }
  8481. },
  8482. "AttachmentList": {
  8483. "description": "AttachmentList",
  8484. "schema": {
  8485. "type": "array",
  8486. "items": {
  8487. "$ref": "#/definitions/Attachment"
  8488. }
  8489. }
  8490. },
  8491. "Branch": {
  8492. "description": "Branch",
  8493. "schema": {
  8494. "$ref": "#/definitions/Branch"
  8495. }
  8496. },
  8497. "BranchList": {
  8498. "description": "BranchList",
  8499. "schema": {
  8500. "type": "array",
  8501. "items": {
  8502. "$ref": "#/definitions/Branch"
  8503. }
  8504. }
  8505. },
  8506. "Comment": {
  8507. "description": "Comment",
  8508. "schema": {
  8509. "$ref": "#/definitions/Comment"
  8510. }
  8511. },
  8512. "CommentList": {
  8513. "description": "CommentList",
  8514. "schema": {
  8515. "type": "array",
  8516. "items": {
  8517. "$ref": "#/definitions/Comment"
  8518. }
  8519. }
  8520. },
  8521. "Commit": {
  8522. "description": "Commit",
  8523. "schema": {
  8524. "$ref": "#/definitions/Commit"
  8525. }
  8526. },
  8527. "DeployKey": {
  8528. "description": "DeployKey",
  8529. "schema": {
  8530. "$ref": "#/definitions/DeployKey"
  8531. }
  8532. },
  8533. "DeployKeyList": {
  8534. "description": "DeployKeyList",
  8535. "schema": {
  8536. "type": "array",
  8537. "items": {
  8538. "$ref": "#/definitions/DeployKey"
  8539. }
  8540. }
  8541. },
  8542. "EmailList": {
  8543. "description": "EmailList",
  8544. "schema": {
  8545. "type": "array",
  8546. "items": {
  8547. "$ref": "#/definitions/Email"
  8548. }
  8549. }
  8550. },
  8551. "GPGKey": {
  8552. "description": "GPGKey",
  8553. "schema": {
  8554. "$ref": "#/definitions/GPGKey"
  8555. }
  8556. },
  8557. "GPGKeyList": {
  8558. "description": "GPGKeyList",
  8559. "schema": {
  8560. "type": "array",
  8561. "items": {
  8562. "$ref": "#/definitions/GPGKey"
  8563. }
  8564. }
  8565. },
  8566. "GitTreeResponse": {
  8567. "description": "GitTreeResponse",
  8568. "schema": {
  8569. "$ref": "#/definitions/GitTreeResponse"
  8570. }
  8571. },
  8572. "Hook": {
  8573. "description": "Hook",
  8574. "schema": {
  8575. "type": "array",
  8576. "items": {
  8577. "$ref": "#/definitions/Branch"
  8578. }
  8579. }
  8580. },
  8581. "HookList": {
  8582. "description": "HookList",
  8583. "schema": {
  8584. "type": "array",
  8585. "items": {
  8586. "$ref": "#/definitions/Branch"
  8587. }
  8588. }
  8589. },
  8590. "Issue": {
  8591. "description": "Issue",
  8592. "schema": {
  8593. "$ref": "#/definitions/Issue"
  8594. }
  8595. },
  8596. "IssueDeadline": {
  8597. "description": "IssueDeadline",
  8598. "schema": {
  8599. "$ref": "#/definitions/IssueDeadline"
  8600. }
  8601. },
  8602. "IssueList": {
  8603. "description": "IssueList",
  8604. "schema": {
  8605. "type": "array",
  8606. "items": {
  8607. "$ref": "#/definitions/Issue"
  8608. }
  8609. }
  8610. },
  8611. "Label": {
  8612. "description": "Label",
  8613. "schema": {
  8614. "$ref": "#/definitions/Label"
  8615. }
  8616. },
  8617. "LabelList": {
  8618. "description": "LabelList",
  8619. "schema": {
  8620. "type": "array",
  8621. "items": {
  8622. "$ref": "#/definitions/Label"
  8623. }
  8624. }
  8625. },
  8626. "MarkdownRender": {
  8627. "description": "MarkdownRender is a rendered markdown document"
  8628. },
  8629. "Milestone": {
  8630. "description": "Milestone",
  8631. "schema": {
  8632. "$ref": "#/definitions/Milestone"
  8633. }
  8634. },
  8635. "MilestoneList": {
  8636. "description": "MilestoneList",
  8637. "schema": {
  8638. "type": "array",
  8639. "items": {
  8640. "$ref": "#/definitions/Milestone"
  8641. }
  8642. }
  8643. },
  8644. "Organization": {
  8645. "description": "Organization",
  8646. "schema": {
  8647. "$ref": "#/definitions/Organization"
  8648. }
  8649. },
  8650. "OrganizationList": {
  8651. "description": "OrganizationList",
  8652. "schema": {
  8653. "type": "array",
  8654. "items": {
  8655. "$ref": "#/definitions/Organization"
  8656. }
  8657. }
  8658. },
  8659. "PublicKey": {
  8660. "description": "PublicKey",
  8661. "schema": {
  8662. "$ref": "#/definitions/PublicKey"
  8663. }
  8664. },
  8665. "PublicKeyList": {
  8666. "description": "PublicKeyList",
  8667. "schema": {
  8668. "type": "array",
  8669. "items": {
  8670. "$ref": "#/definitions/PublicKey"
  8671. }
  8672. }
  8673. },
  8674. "PullRequest": {
  8675. "description": "PullRequest",
  8676. "schema": {
  8677. "$ref": "#/definitions/PullRequest"
  8678. }
  8679. },
  8680. "PullRequestList": {
  8681. "description": "PullRequestList",
  8682. "schema": {
  8683. "type": "array",
  8684. "items": {
  8685. "$ref": "#/definitions/PullRequest"
  8686. }
  8687. }
  8688. },
  8689. "Reference": {
  8690. "description": "Reference",
  8691. "schema": {
  8692. "$ref": "#/definitions/Reference"
  8693. }
  8694. },
  8695. "ReferenceList": {
  8696. "description": "ReferenceList",
  8697. "schema": {
  8698. "type": "array",
  8699. "items": {
  8700. "$ref": "#/definitions/Reference"
  8701. }
  8702. }
  8703. },
  8704. "Release": {
  8705. "description": "Release",
  8706. "schema": {
  8707. "$ref": "#/definitions/Release"
  8708. }
  8709. },
  8710. "ReleaseList": {
  8711. "description": "ReleaseList",
  8712. "schema": {
  8713. "type": "array",
  8714. "items": {
  8715. "$ref": "#/definitions/Release"
  8716. }
  8717. }
  8718. },
  8719. "Repository": {
  8720. "description": "Repository",
  8721. "schema": {
  8722. "$ref": "#/definitions/Repository"
  8723. }
  8724. },
  8725. "RepositoryList": {
  8726. "description": "RepositoryList",
  8727. "schema": {
  8728. "type": "array",
  8729. "items": {
  8730. "$ref": "#/definitions/Repository"
  8731. }
  8732. }
  8733. },
  8734. "SearchResults": {
  8735. "description": "SearchResults",
  8736. "schema": {
  8737. "$ref": "#/definitions/SearchResults"
  8738. }
  8739. },
  8740. "ServerVersion": {
  8741. "description": "ServerVersion",
  8742. "schema": {
  8743. "$ref": "#/definitions/ServerVersion"
  8744. }
  8745. },
  8746. "Status": {
  8747. "description": "Status",
  8748. "schema": {
  8749. "$ref": "#/definitions/Status"
  8750. }
  8751. },
  8752. "StatusList": {
  8753. "description": "StatusList",
  8754. "schema": {
  8755. "type": "array",
  8756. "items": {
  8757. "$ref": "#/definitions/Status"
  8758. }
  8759. }
  8760. },
  8761. "Team": {
  8762. "description": "Team",
  8763. "schema": {
  8764. "$ref": "#/definitions/Team"
  8765. }
  8766. },
  8767. "TeamList": {
  8768. "description": "TeamList",
  8769. "schema": {
  8770. "type": "array",
  8771. "items": {
  8772. "$ref": "#/definitions/Team"
  8773. }
  8774. }
  8775. },
  8776. "TrackedTime": {
  8777. "description": "TrackedTime",
  8778. "schema": {
  8779. "$ref": "#/definitions/TrackedTime"
  8780. }
  8781. },
  8782. "TrackedTimeList": {
  8783. "description": "TrackedTimeList",
  8784. "schema": {
  8785. "type": "array",
  8786. "items": {
  8787. "$ref": "#/definitions/TrackedTime"
  8788. }
  8789. }
  8790. },
  8791. "User": {
  8792. "description": "User",
  8793. "schema": {
  8794. "$ref": "#/definitions/User"
  8795. }
  8796. },
  8797. "UserHeatmapData": {
  8798. "description": "UserHeatmapData",
  8799. "schema": {
  8800. "type": "array",
  8801. "items": {
  8802. "$ref": "#/definitions/UserHeatmapData"
  8803. }
  8804. }
  8805. },
  8806. "UserList": {
  8807. "description": "UserList",
  8808. "schema": {
  8809. "type": "array",
  8810. "items": {
  8811. "$ref": "#/definitions/User"
  8812. }
  8813. }
  8814. },
  8815. "WatchInfo": {
  8816. "description": "WatchInfo",
  8817. "schema": {
  8818. "$ref": "#/definitions/WatchInfo"
  8819. }
  8820. },
  8821. "empty": {
  8822. "description": "APIEmpty is an empty response"
  8823. },
  8824. "error": {
  8825. "description": "APIError is error format response",
  8826. "headers": {
  8827. "message": {
  8828. "type": "string"
  8829. },
  8830. "url": {
  8831. "type": "string"
  8832. }
  8833. }
  8834. },
  8835. "forbidden": {
  8836. "description": "APIForbiddenError is a forbidden error response",
  8837. "headers": {
  8838. "message": {
  8839. "type": "string"
  8840. },
  8841. "url": {
  8842. "type": "string"
  8843. }
  8844. }
  8845. },
  8846. "notFound": {
  8847. "description": "APINotFound is a not found empty response"
  8848. },
  8849. "parameterBodies": {
  8850. "description": "parameterBodies",
  8851. "schema": {
  8852. "$ref": "#/definitions/EditAttachmentOptions"
  8853. }
  8854. },
  8855. "redirect": {
  8856. "description": "APIRedirect is a redirect response"
  8857. },
  8858. "validationError": {
  8859. "description": "APIValidationError is error format response related to input validation",
  8860. "headers": {
  8861. "message": {
  8862. "type": "string"
  8863. },
  8864. "url": {
  8865. "type": "string"
  8866. }
  8867. }
  8868. }
  8869. },
  8870. "securityDefinitions": {
  8871. "AccessToken": {
  8872. "type": "apiKey",
  8873. "name": "access_token",
  8874. "in": "query"
  8875. },
  8876. "AuthorizationHeaderToken": {
  8877. "type": "apiKey",
  8878. "name": "Authorization",
  8879. "in": "header"
  8880. },
  8881. "BasicAuth": {
  8882. "type": "basic"
  8883. },
  8884. "SudoHeader": {
  8885. "description": "Sudo API request as the user provided as the key. Admin privileges are required.",
  8886. "type": "apiKey",
  8887. "name": "Sudo",
  8888. "in": "header"
  8889. },
  8890. "SudoParam": {
  8891. "description": "Sudo API request as the user provided as the key. Admin privileges are required.",
  8892. "type": "apiKey",
  8893. "name": "sudo",
  8894. "in": "query"
  8895. },
  8896. "Token": {
  8897. "type": "apiKey",
  8898. "name": "token",
  8899. "in": "query"
  8900. }
  8901. },
  8902. "security": [
  8903. {
  8904. "BasicAuth": []
  8905. },
  8906. {
  8907. "Token": []
  8908. },
  8909. {
  8910. "AccessToken": []
  8911. },
  8912. {
  8913. "AuthorizationHeaderToken": []
  8914. },
  8915. {
  8916. "SudoParam": []
  8917. },
  8918. {
  8919. "SudoHeader": []
  8920. }
  8921. ]
  8922. }