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 260KB

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