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

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