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

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061110621106311064110651106611067110681106911070110711107211073110741107511076110771107811079110801108111082110831108411085110861108711088110891109011091110921109311094110951109611097110981109911100111011110211103111041110511106111071110811109111101111111112111131111411115111161111711118111191112011121111221112311124111251112611127111281112911130111311113211133111341113511136111371113811139111401114111142111431114411145111461114711148111491115011151111521115311154111551115611157111581115911160111611116211163111641116511166111671116811169111701117111172111731117411175111761117711178111791118011181111821118311184111851118611187111881118911190111911119211193111941119511196111971119811199112001120111202112031120411205112061120711208112091121011211112121121311214112151121611217112181121911220112211122211223112241122511226112271122811229112301123111232112331123411235112361123711238112391124011241112421124311244112451124611247112481124911250112511125211253112541125511256112571125811259112601126111262112631126411265112661126711268112691127011271112721127311274112751127611277112781127911280112811128211283112841128511286112871128811289112901129111292112931129411295112961129711298112991130011301113021130311304113051130611307113081130911310113111131211313113141131511316113171131811319113201132111322113231132411325113261132711328113291133011331113321133311334113351133611337113381133911340113411134211343113441134511346113471134811349113501135111352113531135411355113561135711358113591136011361113621136311364113651136611367113681136911370113711137211373113741137511376113771137811379113801138111382113831138411385113861138711388113891139011391113921139311394113951139611397113981139911400114011140211403114041140511406114071140811409114101141111412114131141411415114161141711418114191142011421114221142311424114251142611427114281142911430114311143211433114341143511436114371143811439114401144111442114431144411445114461144711448114491145011451114521145311454114551145611457114581145911460114611146211463114641146511466114671146811469114701147111472114731147411475114761147711478114791148011481114821148311484114851148611487114881148911490114911149211493114941149511496114971149811499115001150111502115031150411505115061150711508115091151011511115121151311514115151151611517115181151911520115211152211523115241152511526115271152811529115301153111532115331153411535115361153711538115391154011541115421154311544115451154611547115481154911550115511155211553115541155511556115571155811559115601156111562115631156411565115661156711568115691157011571115721157311574115751157611577115781157911580115811158211583115841158511586115871158811589115901159111592115931159411595115961159711598115991160011601116021160311604116051160611607116081160911610116111161211613116141161511616116171161811619116201162111622116231162411625116261162711628116291163011631116321163311634116351163611637116381163911640116411164211643116441164511646116471164811649116501165111652116531165411655116561165711658116591166011661116621166311664116651166611667116681166911670116711167211673116741167511676116771167811679116801168111682116831168411685116861168711688116891169011691116921169311694116951169611697116981169911700117011170211703117041170511706117071170811709117101171111712117131171411715117161171711718117191172011721117221172311724117251172611727117281172911730117311173211733117341173511736117371173811739117401174111742117431174411745117461174711748117491175011751117521175311754117551175611757117581175911760117611176211763117641176511766117671176811769117701177111772117731177411775117761177711778117791178011781117821178311784117851178611787117881178911790117911179211793117941179511796117971179811799118001180111802118031180411805118061180711808118091181011811118121181311814118151181611817118181181911820118211182211823118241182511826118271182811829118301183111832118331183411835118361183711838118391184011841118421184311844118451184611847118481184911850118511185211853118541185511856118571185811859118601186111862118631186411865118661186711868118691187011871118721187311874118751187611877118781187911880118811188211883118841188511886118871188811889118901189111892118931189411895118961189711898118991190011901119021190311904119051190611907119081190911910119111191211913119141191511916119171191811919119201192111922119231192411925119261192711928119291193011931119321193311934119351193611937119381193911940119411194211943119441194511946119471194811949119501195111952119531195411955119561195711958119591196011961119621196311964119651196611967119681196911970119711197211973119741197511976119771197811979119801198111982119831198411985119861198711988119891199011991119921199311994119951199611997119981199912000120011200212003120041200512006120071200812009120101201112012120131201412015120161201712018120191202012021120221202312024120251202612027120281202912030120311203212033120341203512036120371203812039120401204112042120431204412045120461204712048120491205012051120521205312054120551205612057120581205912060120611206212063120641206512066120671206812069120701207112072120731207412075120761207712078120791208012081120821208312084120851208612087120881208912090120911209212093120941209512096120971209812099121001210112102121031210412105121061210712108121091211012111121121211312114121151211612117121181211912120121211212212123121241212512126121271212812129121301213112132121331213412135121361213712138121391214012141121421214312144121451214612147121481214912150121511215212153121541215512156121571215812159121601216112162121631216412165121661216712168121691217012171121721217312174121751217612177121781217912180121811218212183121841218512186121871218812189121901219112192121931219412195121961219712198121991220012201122021220312204122051220612207122081220912210122111221212213122141221512216122171221812219122201222112222122231222412225122261222712228122291223012231122321223312234122351223612237122381223912240122411224212243122441224512246122471224812249122501225112252122531225412255122561225712258122591226012261122621226312264122651226612267122681226912270122711227212273122741227512276122771227812279122801228112282122831228412285122861228712288122891229012291122921229312294122951229612297122981229912300123011230212303123041230512306123071230812309123101231112312123131231412315123161231712318123191232012321123221232312324123251232612327123281232912330123311233212333123341233512336123371233812339123401234112342123431234412345123461234712348123491235012351123521235312354123551235612357123581235912360123611236212363123641236512366123671236812369123701237112372123731237412375123761237712378123791238012381123821238312384123851238612387123881238912390123911239212393123941239512396123971239812399124001240112402124031240412405124061240712408124091241012411124121241312414124151241612417124181241912420124211242212423124241242512426124271242812429124301243112432124331243412435124361243712438124391244012441124421244312444124451244612447124481244912450124511245212453124541245512456124571245812459124601246112462124631246412465124661246712468124691247012471124721247312474124751247612477124781247912480124811248212483124841248512486124871248812489124901249112492124931249412495124961249712498124991250012501125021250312504125051250612507125081250912510125111251212513125141251512516125171251812519125201252112522125231252412525125261252712528125291253012531125321253312534125351253612537125381253912540125411254212543125441254512546125471254812549125501255112552125531255412555125561255712558125591256012561125621256312564125651256612567125681256912570125711257212573125741257512576125771257812579125801258112582125831258412585125861258712588125891259012591125921259312594125951259612597125981259912600126011260212603126041260512606126071260812609126101261112612126131261412615126161261712618126191262012621126221262312624126251262612627126281262912630126311263212633126341263512636126371263812639126401264112642126431264412645126461264712648126491265012651126521265312654126551265612657126581265912660126611266212663126641266512666126671266812669126701267112672126731267412675126761267712678126791268012681126821268312684126851268612687126881268912690126911269212693126941269512696126971269812699127001270112702127031270412705127061270712708127091271012711127121271312714127151271612717127181271912720127211272212723127241272512726127271272812729127301273112732127331273412735127361273712738127391274012741127421274312744127451274612747127481274912750127511275212753127541275512756127571275812759127601276112762127631276412765127661276712768127691277012771127721277312774127751277612777127781277912780127811278212783127841278512786127871278812789127901279112792127931279412795127961279712798127991280012801128021280312804128051280612807128081280912810128111281212813128141281512816128171281812819128201282112822128231282412825128261282712828128291283012831128321283312834128351283612837128381283912840128411284212843128441284512846128471284812849128501285112852128531285412855128561285712858128591286012861128621286312864128651286612867128681286912870128711287212873128741287512876128771287812879128801288112882128831288412885128861288712888128891289012891128921289312894128951289612897128981289912900129011290212903129041290512906129071290812909129101291112912129131291412915129161291712918129191292012921129221292312924129251292612927129281292912930129311293212933129341293512936129371293812939129401294112942129431294412945129461294712948129491295012951129521295312954129551295612957129581295912960129611296212963129641296512966129671296812969129701297112972129731297412975129761297712978129791298012981129821298312984129851298612987129881298912990129911299212993129941299512996129971299812999130001300113002130031300413005130061300713008130091301013011130121301313014130151301613017130181301913020130211302213023130241302513026130271302813029130301303113032130331303413035130361303713038130391304013041130421304313044130451304613047130481304913050130511305213053130541305513056130571305813059130601306113062130631306413065130661306713068130691307013071130721307313074130751307613077130781307913080130811308213083130841308513086130871308813089130901309113092130931309413095130961309713098130991310013101131021310313104131051310613107131081310913110131111311213113131141311513116131171311813119131201312113122131231312413125131261312713128131291313013131131321313313134131351313613137131381313913140131411314213143131441314513146131471314813149131501315113152131531315413155131561315713158131591316013161131621316313164131651316613167131681316913170131711317213173131741317513176131771317813179131801318113182131831318413185131861318713188131891319013191131921319313194131951319613197131981319913200132011320213203132041320513206132071320813209132101321113212132131321413215132161321713218132191322013221132221322313224132251322613227132281322913230132311323213233132341323513236132371323813239132401324113242132431324413245132461324713248132491325013251132521325313254132551325613257132581325913260132611326213263132641326513266132671326813269132701327113272132731327413275132761327713278132791328013281132821328313284132851328613287132881328913290132911329213293132941329513296132971329813299133001330113302133031330413305133061330713308133091331013311133121331313314133151331613317133181331913320133211332213323133241332513326133271332813329133301333113332133331333413335133361333713338133391334013341133421334313344133451334613347133481334913350133511335213353133541335513356133571335813359133601336113362133631336413365133661336713368133691337013371133721337313374133751337613377133781337913380133811338213383133841338513386133871338813389133901339113392133931339413395133961339713398133991340013401134021340313404134051340613407134081340913410134111341213413134141341513416134171341813419134201342113422134231342413425134261342713428134291343013431134321343313434134351343613437134381343913440134411344213443134441344513446134471344813449134501345113452134531345413455134561345713458134591346013461134621346313464134651346613467134681346913470134711347213473134741347513476134771347813479134801348113482134831348413485134861348713488134891349013491134921349313494134951349613497134981349913500135011350213503135041350513506135071350813509135101351113512135131351413515135161351713518135191352013521135221352313524135251352613527135281352913530135311353213533135341353513536135371353813539135401354113542135431354413545135461354713548135491355013551135521355313554135551355613557135581355913560135611356213563135641356513566135671356813569135701357113572135731357413575135761357713578135791358013581135821358313584135851358613587135881358913590135911359213593135941359513596135971359813599136001360113602136031360413605136061360713608136091361013611136121361313614136151361613617136181361913620136211362213623136241362513626136271362813629136301363113632136331363413635136361363713638136391364013641136421364313644136451364613647136481364913650136511365213653136541365513656136571365813659136601366113662136631366413665136661366713668136691367013671136721367313674136751367613677136781367913680136811368213683136841368513686136871368813689136901369113692136931369413695136961369713698136991370013701137021370313704137051370613707137081370913710137111371213713137141371513716137171371813719137201372113722137231372413725137261372713728137291373013731137321373313734137351373613737137381373913740137411374213743137441374513746137471374813749137501375113752137531375413755137561375713758137591376013761137621376313764137651376613767137681376913770137711377213773137741377513776137771377813779137801378113782137831378413785137861378713788137891379013791137921379313794137951379613797137981379913800138011380213803138041380513806138071380813809138101381113812138131381413815138161381713818138191382013821138221382313824138251382613827138281382913830138311383213833138341383513836138371383813839138401384113842138431384413845138461384713848138491385013851138521385313854138551385613857138581385913860138611386213863138641386513866138671386813869138701387113872138731387413875138761387713878138791388013881138821388313884138851388613887138881388913890138911389213893138941389513896138971389813899139001390113902139031390413905139061390713908139091391013911139121391313914139151391613917139181391913920139211392213923139241392513926139271392813929139301393113932139331393413935139361393713938139391394013941139421394313944139451394613947139481394913950139511395213953139541395513956139571395813959139601396113962139631396413965139661396713968139691397013971139721397313974139751397613977139781397913980139811398213983139841398513986139871398813989139901399113992139931399413995139961399713998139991400014001140021400314004140051400614007140081400914010140111401214013140141401514016140171401814019140201402114022140231402414025140261402714028140291403014031140321403314034140351403614037140381403914040140411404214043140441404514046140471404814049140501405114052140531405414055140561405714058140591406014061140621406314064140651406614067140681406914070140711407214073140741407514076140771407814079140801408114082140831408414085140861408714088140891409014091140921409314094140951409614097140981409914100141011410214103141041410514106141071410814109141101411114112141131411414115141161411714118141191412014121141221412314124141251412614127141281412914130141311413214133141341413514136141371413814139141401414114142141431414414145141461414714148141491415014151141521415314154141551415614157141581415914160141611416214163141641416514166141671416814169141701417114172141731417414175141761417714178141791418014181141821418314184141851418614187141881418914190141911419214193141941419514196141971419814199142001420114202142031420414205142061420714208142091421014211142121421314214142151421614217142181421914220142211422214223142241422514226142271422814229142301423114232142331423414235142361423714238142391424014241142421424314244142451424614247142481424914250142511425214253142541425514256142571425814259142601426114262142631426414265142661426714268142691427014271142721427314274142751427614277142781427914280142811428214283142841428514286142871428814289142901429114292142931429414295142961429714298142991430014301143021430314304143051430614307143081430914310143111431214313143141431514316143171431814319143201432114322143231432414325143261432714328143291433014331143321433314334143351433614337143381433914340143411434214343143441434514346143471434814349143501435114352143531435414355143561435714358143591436014361143621436314364143651436614367143681436914370143711437214373143741437514376143771437814379143801438114382143831438414385143861438714388143891439014391143921439314394143951439614397143981439914400144011440214403144041440514406144071440814409144101441114412144131441414415144161441714418144191442014421144221442314424144251442614427144281442914430144311443214433144341443514436144371443814439144401444114442144431444414445144461444714448144491445014451144521445314454144551445614457144581445914460144611446214463144641446514466144671446814469144701447114472144731447414475144761447714478144791448014481144821448314484144851448614487144881448914490144911449214493144941449514496144971449814499145001450114502145031450414505145061450714508145091451014511145121451314514145151451614517145181451914520145211452214523145241452514526145271452814529145301453114532145331453414535145361453714538145391454014541145421454314544145451454614547145481454914550145511455214553145541455514556145571455814559145601456114562145631456414565145661456714568145691457014571145721457314574145751457614577145781457914580145811458214583145841458514586145871458814589145901459114592145931459414595145961459714598145991460014601146021460314604146051460614607146081460914610146111461214613146141461514616146171461814619146201462114622146231462414625146261462714628146291463014631146321463314634146351463614637146381463914640146411464214643146441464514646146471464814649146501465114652146531465414655146561465714658146591466014661146621466314664146651466614667146681466914670146711467214673146741467514676146771467814679146801468114682146831468414685146861468714688146891469014691146921469314694146951469614697146981469914700147011470214703147041470514706147071470814709147101471114712147131471414715147161471714718147191472014721147221472314724147251472614727147281472914730147311473214733147341473514736147371473814739147401474114742147431474414745147461474714748147491475014751147521475314754147551475614757147581475914760147611476214763147641476514766147671476814769147701477114772147731477414775147761477714778147791478014781147821478314784147851478614787147881478914790147911479214793147941479514796147971479814799148001480114802148031480414805148061480714808148091481014811148121481314814148151481614817148181481914820148211482214823148241482514826148271482814829148301483114832148331483414835148361483714838148391484014841148421484314844148451484614847148481484914850148511485214853148541485514856148571485814859148601486114862148631486414865148661486714868148691487014871148721487314874148751487614877148781487914880148811488214883148841488514886148871488814889148901489114892148931489414895148961489714898148991490014901149021490314904149051490614907149081490914910149111491214913149141491514916149171491814919149201492114922149231492414925149261492714928149291493014931149321493314934149351493614937149381493914940149411494214943149441494514946149471494814949149501495114952149531495414955149561495714958149591496014961149621496314964149651496614967149681496914970149711497214973149741497514976149771497814979149801498114982149831498414985149861498714988149891499014991149921499314994149951499614997149981499915000150011500215003150041500515006150071500815009150101501115012150131501415015150161501715018150191502015021150221502315024150251502615027150281502915030150311503215033150341503515036150371503815039150401504115042150431504415045150461504715048150491505015051150521505315054150551505615057150581505915060150611506215063150641506515066150671506815069150701507115072150731507415075150761507715078150791508015081150821508315084150851508615087150881508915090150911509215093150941509515096150971509815099151001510115102151031510415105151061510715108151091511015111151121511315114151151511615117151181511915120151211512215123151241512515126151271512815129151301513115132151331513415135151361513715138151391514015141151421514315144151451514615147151481514915150151511515215153151541515515156151571515815159151601516115162151631516415165151661516715168151691517015171151721517315174151751517615177151781517915180151811518215183151841518515186151871518815189151901519115192151931519415195151961519715198151991520015201152021520315204152051520615207152081520915210152111521215213152141521515216152171521815219152201522115222152231522415225152261522715228152291523015231152321523315234152351523615237152381523915240152411524215243
  1. {
  2. "consumes": [
  3. "application/json",
  4. "text/plain"
  5. ],
  6. "produces": [
  7. "application/json",
  8. "text/html"
  9. ],
  10. "schemes": [
  11. "http",
  12. "https"
  13. ],
  14. "swagger": "2.0",
  15. "info": {
  16. "description": "This documentation describes the Gitea API.",
  17. "title": "Gitea API.",
  18. "license": {
  19. "name": "MIT",
  20. "url": "http://opensource.org/licenses/MIT"
  21. },
  22. "version": "1.1.1"
  23. },
  24. "basePath": "{{AppSubUrl}}/api/v1",
  25. "paths": {
  26. "/admin/orgs": {
  27. "get": {
  28. "produces": [
  29. "application/json"
  30. ],
  31. "tags": [
  32. "admin"
  33. ],
  34. "summary": "List all organizations",
  35. "operationId": "adminGetAllOrgs",
  36. "parameters": [
  37. {
  38. "type": "integer",
  39. "description": "page number of results to return (1-based)",
  40. "name": "page",
  41. "in": "query"
  42. },
  43. {
  44. "type": "integer",
  45. "description": "page size of results, maximum page size is 50",
  46. "name": "limit",
  47. "in": "query"
  48. }
  49. ],
  50. "responses": {
  51. "200": {
  52. "$ref": "#/responses/OrganizationList"
  53. },
  54. "403": {
  55. "$ref": "#/responses/forbidden"
  56. }
  57. }
  58. }
  59. },
  60. "/admin/users": {
  61. "get": {
  62. "produces": [
  63. "application/json"
  64. ],
  65. "tags": [
  66. "admin"
  67. ],
  68. "summary": "List all users",
  69. "operationId": "adminGetAllUsers",
  70. "parameters": [
  71. {
  72. "type": "integer",
  73. "description": "page number of results to return (1-based)",
  74. "name": "page",
  75. "in": "query"
  76. },
  77. {
  78. "type": "integer",
  79. "description": "page size of results, maximum page size is 50",
  80. "name": "limit",
  81. "in": "query"
  82. }
  83. ],
  84. "responses": {
  85. "200": {
  86. "$ref": "#/responses/UserList"
  87. },
  88. "403": {
  89. "$ref": "#/responses/forbidden"
  90. }
  91. }
  92. },
  93. "post": {
  94. "consumes": [
  95. "application/json"
  96. ],
  97. "produces": [
  98. "application/json"
  99. ],
  100. "tags": [
  101. "admin"
  102. ],
  103. "summary": "Create a user",
  104. "operationId": "adminCreateUser",
  105. "parameters": [
  106. {
  107. "name": "body",
  108. "in": "body",
  109. "schema": {
  110. "$ref": "#/definitions/CreateUserOption"
  111. }
  112. }
  113. ],
  114. "responses": {
  115. "201": {
  116. "$ref": "#/responses/User"
  117. },
  118. "400": {
  119. "$ref": "#/responses/error"
  120. },
  121. "403": {
  122. "$ref": "#/responses/forbidden"
  123. },
  124. "422": {
  125. "$ref": "#/responses/validationError"
  126. }
  127. }
  128. }
  129. },
  130. "/admin/users/{username}": {
  131. "delete": {
  132. "produces": [
  133. "application/json"
  134. ],
  135. "tags": [
  136. "admin"
  137. ],
  138. "summary": "Delete a user",
  139. "operationId": "adminDeleteUser",
  140. "parameters": [
  141. {
  142. "type": "string",
  143. "description": "username of user to delete",
  144. "name": "username",
  145. "in": "path",
  146. "required": true
  147. }
  148. ],
  149. "responses": {
  150. "204": {
  151. "$ref": "#/responses/empty"
  152. },
  153. "403": {
  154. "$ref": "#/responses/forbidden"
  155. },
  156. "422": {
  157. "$ref": "#/responses/validationError"
  158. }
  159. }
  160. },
  161. "patch": {
  162. "consumes": [
  163. "application/json"
  164. ],
  165. "produces": [
  166. "application/json"
  167. ],
  168. "tags": [
  169. "admin"
  170. ],
  171. "summary": "Edit an existing user",
  172. "operationId": "adminEditUser",
  173. "parameters": [
  174. {
  175. "type": "string",
  176. "description": "username of user to edit",
  177. "name": "username",
  178. "in": "path",
  179. "required": true
  180. },
  181. {
  182. "name": "body",
  183. "in": "body",
  184. "schema": {
  185. "$ref": "#/definitions/EditUserOption"
  186. }
  187. }
  188. ],
  189. "responses": {
  190. "200": {
  191. "$ref": "#/responses/User"
  192. },
  193. "403": {
  194. "$ref": "#/responses/forbidden"
  195. },
  196. "422": {
  197. "$ref": "#/responses/validationError"
  198. }
  199. }
  200. }
  201. },
  202. "/admin/users/{username}/keys": {
  203. "post": {
  204. "consumes": [
  205. "application/json"
  206. ],
  207. "produces": [
  208. "application/json"
  209. ],
  210. "tags": [
  211. "admin"
  212. ],
  213. "summary": "Add a public key on behalf of a user",
  214. "operationId": "adminCreatePublicKey",
  215. "parameters": [
  216. {
  217. "type": "string",
  218. "description": "username of the user",
  219. "name": "username",
  220. "in": "path",
  221. "required": true
  222. },
  223. {
  224. "name": "key",
  225. "in": "body",
  226. "schema": {
  227. "$ref": "#/definitions/CreateKeyOption"
  228. }
  229. }
  230. ],
  231. "responses": {
  232. "201": {
  233. "$ref": "#/responses/PublicKey"
  234. },
  235. "403": {
  236. "$ref": "#/responses/forbidden"
  237. },
  238. "422": {
  239. "$ref": "#/responses/validationError"
  240. }
  241. }
  242. }
  243. },
  244. "/admin/users/{username}/keys/{id}": {
  245. "delete": {
  246. "produces": [
  247. "application/json"
  248. ],
  249. "tags": [
  250. "admin"
  251. ],
  252. "summary": "Delete a user's public key",
  253. "operationId": "adminDeleteUserPublicKey",
  254. "parameters": [
  255. {
  256. "type": "string",
  257. "description": "username of user",
  258. "name": "username",
  259. "in": "path",
  260. "required": true
  261. },
  262. {
  263. "type": "integer",
  264. "format": "int64",
  265. "description": "id of the key to delete",
  266. "name": "id",
  267. "in": "path",
  268. "required": true
  269. }
  270. ],
  271. "responses": {
  272. "204": {
  273. "$ref": "#/responses/empty"
  274. },
  275. "403": {
  276. "$ref": "#/responses/forbidden"
  277. },
  278. "404": {
  279. "$ref": "#/responses/notFound"
  280. }
  281. }
  282. }
  283. },
  284. "/admin/users/{username}/orgs": {
  285. "post": {
  286. "consumes": [
  287. "application/json"
  288. ],
  289. "produces": [
  290. "application/json"
  291. ],
  292. "tags": [
  293. "admin"
  294. ],
  295. "summary": "Create an organization",
  296. "operationId": "adminCreateOrg",
  297. "parameters": [
  298. {
  299. "type": "string",
  300. "description": "username of the user that will own the created organization",
  301. "name": "username",
  302. "in": "path",
  303. "required": true
  304. },
  305. {
  306. "name": "organization",
  307. "in": "body",
  308. "required": true,
  309. "schema": {
  310. "$ref": "#/definitions/CreateOrgOption"
  311. }
  312. }
  313. ],
  314. "responses": {
  315. "201": {
  316. "$ref": "#/responses/Organization"
  317. },
  318. "403": {
  319. "$ref": "#/responses/forbidden"
  320. },
  321. "422": {
  322. "$ref": "#/responses/validationError"
  323. }
  324. }
  325. }
  326. },
  327. "/admin/users/{username}/repos": {
  328. "post": {
  329. "consumes": [
  330. "application/json"
  331. ],
  332. "produces": [
  333. "application/json"
  334. ],
  335. "tags": [
  336. "admin"
  337. ],
  338. "summary": "Create a repository on behalf of a user",
  339. "operationId": "adminCreateRepo",
  340. "parameters": [
  341. {
  342. "type": "string",
  343. "description": "username of the user. This user will own the created repository",
  344. "name": "username",
  345. "in": "path",
  346. "required": true
  347. },
  348. {
  349. "name": "repository",
  350. "in": "body",
  351. "required": true,
  352. "schema": {
  353. "$ref": "#/definitions/CreateRepoOption"
  354. }
  355. }
  356. ],
  357. "responses": {
  358. "201": {
  359. "$ref": "#/responses/Repository"
  360. },
  361. "403": {
  362. "$ref": "#/responses/forbidden"
  363. },
  364. "404": {
  365. "$ref": "#/responses/notFound"
  366. },
  367. "409": {
  368. "$ref": "#/responses/error"
  369. },
  370. "422": {
  371. "$ref": "#/responses/validationError"
  372. }
  373. }
  374. }
  375. },
  376. "/markdown": {
  377. "post": {
  378. "consumes": [
  379. "application/json"
  380. ],
  381. "produces": [
  382. "text/html"
  383. ],
  384. "tags": [
  385. "miscellaneous"
  386. ],
  387. "summary": "Render a markdown document as HTML",
  388. "operationId": "renderMarkdown",
  389. "parameters": [
  390. {
  391. "name": "body",
  392. "in": "body",
  393. "schema": {
  394. "$ref": "#/definitions/MarkdownOption"
  395. }
  396. }
  397. ],
  398. "responses": {
  399. "200": {
  400. "$ref": "#/responses/MarkdownRender"
  401. },
  402. "422": {
  403. "$ref": "#/responses/validationError"
  404. }
  405. }
  406. }
  407. },
  408. "/markdown/raw": {
  409. "post": {
  410. "consumes": [
  411. "text/plain"
  412. ],
  413. "produces": [
  414. "text/html"
  415. ],
  416. "tags": [
  417. "miscellaneous"
  418. ],
  419. "summary": "Render raw markdown as HTML",
  420. "operationId": "renderMarkdownRaw",
  421. "parameters": [
  422. {
  423. "description": "Request body to render",
  424. "name": "body",
  425. "in": "body",
  426. "required": true,
  427. "schema": {
  428. "type": "string"
  429. }
  430. }
  431. ],
  432. "responses": {
  433. "200": {
  434. "$ref": "#/responses/MarkdownRender"
  435. },
  436. "422": {
  437. "$ref": "#/responses/validationError"
  438. }
  439. }
  440. }
  441. },
  442. "/notifications": {
  443. "get": {
  444. "consumes": [
  445. "application/json"
  446. ],
  447. "produces": [
  448. "application/json"
  449. ],
  450. "tags": [
  451. "notification"
  452. ],
  453. "summary": "List users's notification threads",
  454. "operationId": "notifyGetList",
  455. "parameters": [
  456. {
  457. "type": "string",
  458. "description": "If true, show notifications marked as read. Default value is false",
  459. "name": "all",
  460. "in": "query"
  461. },
  462. {
  463. "type": "string",
  464. "format": "date-time",
  465. "description": "Only show notifications updated after the given time. This is a timestamp in RFC 3339 format",
  466. "name": "since",
  467. "in": "query"
  468. },
  469. {
  470. "type": "string",
  471. "format": "date-time",
  472. "description": "Only show notifications updated before the given time. This is a timestamp in RFC 3339 format",
  473. "name": "before",
  474. "in": "query"
  475. },
  476. {
  477. "type": "integer",
  478. "description": "page number of results to return (1-based)",
  479. "name": "page",
  480. "in": "query"
  481. },
  482. {
  483. "type": "integer",
  484. "description": "page size of results, maximum page size is 50",
  485. "name": "limit",
  486. "in": "query"
  487. }
  488. ],
  489. "responses": {
  490. "200": {
  491. "$ref": "#/responses/NotificationThreadList"
  492. }
  493. }
  494. },
  495. "put": {
  496. "consumes": [
  497. "application/json"
  498. ],
  499. "produces": [
  500. "application/json"
  501. ],
  502. "tags": [
  503. "notification"
  504. ],
  505. "summary": "Mark notification threads as read",
  506. "operationId": "notifyReadList",
  507. "parameters": [
  508. {
  509. "type": "string",
  510. "format": "date-time",
  511. "description": "Describes the last point that notifications were checked. Anything updated since this time will not be updated.",
  512. "name": "last_read_at",
  513. "in": "query"
  514. }
  515. ],
  516. "responses": {
  517. "205": {
  518. "$ref": "#/responses/empty"
  519. }
  520. }
  521. }
  522. },
  523. "/notifications/new": {
  524. "get": {
  525. "tags": [
  526. "notification"
  527. ],
  528. "summary": "Check if unread notifications exist",
  529. "operationId": "notifyNewAvailable",
  530. "responses": {
  531. "200": {
  532. "$ref": "#/responses/NotificationCount"
  533. }
  534. }
  535. }
  536. },
  537. "/notifications/threads/{id}": {
  538. "get": {
  539. "consumes": [
  540. "application/json"
  541. ],
  542. "produces": [
  543. "application/json"
  544. ],
  545. "tags": [
  546. "notification"
  547. ],
  548. "summary": "Get notification thread by ID",
  549. "operationId": "notifyGetThread",
  550. "parameters": [
  551. {
  552. "type": "string",
  553. "description": "id of notification thread",
  554. "name": "id",
  555. "in": "path",
  556. "required": true
  557. }
  558. ],
  559. "responses": {
  560. "200": {
  561. "$ref": "#/responses/NotificationThread"
  562. },
  563. "403": {
  564. "$ref": "#/responses/forbidden"
  565. },
  566. "404": {
  567. "$ref": "#/responses/notFound"
  568. }
  569. }
  570. },
  571. "patch": {
  572. "consumes": [
  573. "application/json"
  574. ],
  575. "produces": [
  576. "application/json"
  577. ],
  578. "tags": [
  579. "notification"
  580. ],
  581. "summary": "Mark notification thread as read by ID",
  582. "operationId": "notifyReadThread",
  583. "parameters": [
  584. {
  585. "type": "string",
  586. "description": "id of notification thread",
  587. "name": "id",
  588. "in": "path",
  589. "required": true
  590. }
  591. ],
  592. "responses": {
  593. "205": {
  594. "$ref": "#/responses/empty"
  595. },
  596. "403": {
  597. "$ref": "#/responses/forbidden"
  598. },
  599. "404": {
  600. "$ref": "#/responses/notFound"
  601. }
  602. }
  603. }
  604. },
  605. "/org/{org}/repos": {
  606. "post": {
  607. "consumes": [
  608. "application/json"
  609. ],
  610. "produces": [
  611. "application/json"
  612. ],
  613. "tags": [
  614. "organization"
  615. ],
  616. "summary": "Create a repository in an organization",
  617. "operationId": "createOrgRepoDeprecated",
  618. "deprecated": true,
  619. "parameters": [
  620. {
  621. "type": "string",
  622. "description": "name of organization",
  623. "name": "org",
  624. "in": "path",
  625. "required": true
  626. },
  627. {
  628. "name": "body",
  629. "in": "body",
  630. "schema": {
  631. "$ref": "#/definitions/CreateRepoOption"
  632. }
  633. }
  634. ],
  635. "responses": {
  636. "201": {
  637. "$ref": "#/responses/Repository"
  638. },
  639. "403": {
  640. "$ref": "#/responses/forbidden"
  641. },
  642. "422": {
  643. "$ref": "#/responses/validationError"
  644. }
  645. }
  646. }
  647. },
  648. "/orgs": {
  649. "get": {
  650. "produces": [
  651. "application/json"
  652. ],
  653. "tags": [
  654. "organization"
  655. ],
  656. "summary": "Get list of organizations",
  657. "operationId": "orgGetAll",
  658. "parameters": [
  659. {
  660. "type": "integer",
  661. "description": "page number of results to return (1-based)",
  662. "name": "page",
  663. "in": "query"
  664. },
  665. {
  666. "type": "integer",
  667. "description": "page size of results, maximum page size is 50",
  668. "name": "limit",
  669. "in": "query"
  670. }
  671. ],
  672. "responses": {
  673. "200": {
  674. "$ref": "#/responses/OrganizationList"
  675. }
  676. }
  677. },
  678. "post": {
  679. "consumes": [
  680. "application/json"
  681. ],
  682. "produces": [
  683. "application/json"
  684. ],
  685. "tags": [
  686. "organization"
  687. ],
  688. "summary": "Create an organization",
  689. "operationId": "orgCreate",
  690. "parameters": [
  691. {
  692. "name": "organization",
  693. "in": "body",
  694. "required": true,
  695. "schema": {
  696. "$ref": "#/definitions/CreateOrgOption"
  697. }
  698. }
  699. ],
  700. "responses": {
  701. "201": {
  702. "$ref": "#/responses/Organization"
  703. },
  704. "403": {
  705. "$ref": "#/responses/forbidden"
  706. },
  707. "422": {
  708. "$ref": "#/responses/validationError"
  709. }
  710. }
  711. }
  712. },
  713. "/orgs/{org}": {
  714. "get": {
  715. "produces": [
  716. "application/json"
  717. ],
  718. "tags": [
  719. "organization"
  720. ],
  721. "summary": "Get an organization",
  722. "operationId": "orgGet",
  723. "parameters": [
  724. {
  725. "type": "string",
  726. "description": "name of the organization to get",
  727. "name": "org",
  728. "in": "path",
  729. "required": true
  730. }
  731. ],
  732. "responses": {
  733. "200": {
  734. "$ref": "#/responses/Organization"
  735. }
  736. }
  737. },
  738. "delete": {
  739. "produces": [
  740. "application/json"
  741. ],
  742. "tags": [
  743. "organization"
  744. ],
  745. "summary": "Delete an organization",
  746. "operationId": "orgDelete",
  747. "parameters": [
  748. {
  749. "type": "string",
  750. "description": "organization that is to be deleted",
  751. "name": "org",
  752. "in": "path",
  753. "required": true
  754. }
  755. ],
  756. "responses": {
  757. "204": {
  758. "$ref": "#/responses/empty"
  759. }
  760. }
  761. },
  762. "patch": {
  763. "consumes": [
  764. "application/json"
  765. ],
  766. "produces": [
  767. "application/json"
  768. ],
  769. "tags": [
  770. "organization"
  771. ],
  772. "summary": "Edit an organization",
  773. "operationId": "orgEdit",
  774. "parameters": [
  775. {
  776. "type": "string",
  777. "description": "name of the organization to edit",
  778. "name": "org",
  779. "in": "path",
  780. "required": true
  781. },
  782. {
  783. "name": "body",
  784. "in": "body",
  785. "required": true,
  786. "schema": {
  787. "$ref": "#/definitions/EditOrgOption"
  788. }
  789. }
  790. ],
  791. "responses": {
  792. "200": {
  793. "$ref": "#/responses/Organization"
  794. }
  795. }
  796. }
  797. },
  798. "/orgs/{org}/hooks": {
  799. "get": {
  800. "produces": [
  801. "application/json"
  802. ],
  803. "tags": [
  804. "organization"
  805. ],
  806. "summary": "List an organization's webhooks",
  807. "operationId": "orgListHooks",
  808. "parameters": [
  809. {
  810. "type": "string",
  811. "description": "name of the organization",
  812. "name": "org",
  813. "in": "path",
  814. "required": true
  815. },
  816. {
  817. "type": "integer",
  818. "description": "page number of results to return (1-based)",
  819. "name": "page",
  820. "in": "query"
  821. },
  822. {
  823. "type": "integer",
  824. "description": "page size of results, maximum page size is 50",
  825. "name": "limit",
  826. "in": "query"
  827. }
  828. ],
  829. "responses": {
  830. "200": {
  831. "$ref": "#/responses/HookList"
  832. }
  833. }
  834. }
  835. },
  836. "/orgs/{org}/hooks/": {
  837. "post": {
  838. "consumes": [
  839. "application/json"
  840. ],
  841. "produces": [
  842. "application/json"
  843. ],
  844. "tags": [
  845. "organization"
  846. ],
  847. "summary": "Create a hook",
  848. "operationId": "orgCreateHook",
  849. "parameters": [
  850. {
  851. "type": "string",
  852. "description": "name of the organization",
  853. "name": "org",
  854. "in": "path",
  855. "required": true
  856. },
  857. {
  858. "name": "body",
  859. "in": "body",
  860. "required": true,
  861. "schema": {
  862. "$ref": "#/definitions/CreateHookOption"
  863. }
  864. }
  865. ],
  866. "responses": {
  867. "201": {
  868. "$ref": "#/responses/Hook"
  869. }
  870. }
  871. }
  872. },
  873. "/orgs/{org}/hooks/{id}": {
  874. "get": {
  875. "produces": [
  876. "application/json"
  877. ],
  878. "tags": [
  879. "organization"
  880. ],
  881. "summary": "Get a hook",
  882. "operationId": "orgGetHook",
  883. "parameters": [
  884. {
  885. "type": "string",
  886. "description": "name of the organization",
  887. "name": "org",
  888. "in": "path",
  889. "required": true
  890. },
  891. {
  892. "type": "integer",
  893. "format": "int64",
  894. "description": "id of the hook to get",
  895. "name": "id",
  896. "in": "path",
  897. "required": true
  898. }
  899. ],
  900. "responses": {
  901. "200": {
  902. "$ref": "#/responses/Hook"
  903. }
  904. }
  905. },
  906. "delete": {
  907. "produces": [
  908. "application/json"
  909. ],
  910. "tags": [
  911. "organization"
  912. ],
  913. "summary": "Delete a hook",
  914. "operationId": "orgDeleteHook",
  915. "parameters": [
  916. {
  917. "type": "string",
  918. "description": "name of the organization",
  919. "name": "org",
  920. "in": "path",
  921. "required": true
  922. },
  923. {
  924. "type": "integer",
  925. "format": "int64",
  926. "description": "id of the hook to delete",
  927. "name": "id",
  928. "in": "path",
  929. "required": true
  930. }
  931. ],
  932. "responses": {
  933. "204": {
  934. "$ref": "#/responses/empty"
  935. }
  936. }
  937. },
  938. "patch": {
  939. "consumes": [
  940. "application/json"
  941. ],
  942. "produces": [
  943. "application/json"
  944. ],
  945. "tags": [
  946. "organization"
  947. ],
  948. "summary": "Update a hook",
  949. "operationId": "orgEditHook",
  950. "parameters": [
  951. {
  952. "type": "string",
  953. "description": "name of the organization",
  954. "name": "org",
  955. "in": "path",
  956. "required": true
  957. },
  958. {
  959. "type": "integer",
  960. "format": "int64",
  961. "description": "id of the hook to update",
  962. "name": "id",
  963. "in": "path",
  964. "required": true
  965. },
  966. {
  967. "name": "body",
  968. "in": "body",
  969. "schema": {
  970. "$ref": "#/definitions/EditHookOption"
  971. }
  972. }
  973. ],
  974. "responses": {
  975. "200": {
  976. "$ref": "#/responses/Hook"
  977. }
  978. }
  979. }
  980. },
  981. "/orgs/{org}/labels": {
  982. "get": {
  983. "produces": [
  984. "application/json"
  985. ],
  986. "tags": [
  987. "organization"
  988. ],
  989. "summary": "List an organization's labels",
  990. "operationId": "orgListLabels",
  991. "parameters": [
  992. {
  993. "type": "string",
  994. "description": "name of the organization",
  995. "name": "org",
  996. "in": "path",
  997. "required": true
  998. },
  999. {
  1000. "type": "integer",
  1001. "description": "page number of results to return (1-based)",
  1002. "name": "page",
  1003. "in": "query"
  1004. },
  1005. {
  1006. "type": "integer",
  1007. "description": "page size of results, maximum page size is 50",
  1008. "name": "limit",
  1009. "in": "query"
  1010. }
  1011. ],
  1012. "responses": {
  1013. "200": {
  1014. "$ref": "#/responses/LabelList"
  1015. }
  1016. }
  1017. },
  1018. "post": {
  1019. "consumes": [
  1020. "application/json"
  1021. ],
  1022. "produces": [
  1023. "application/json"
  1024. ],
  1025. "tags": [
  1026. "organization"
  1027. ],
  1028. "summary": "Create a label for an organization",
  1029. "operationId": "orgCreateLabel",
  1030. "parameters": [
  1031. {
  1032. "type": "string",
  1033. "description": "name of the organization",
  1034. "name": "org",
  1035. "in": "path",
  1036. "required": true
  1037. },
  1038. {
  1039. "name": "body",
  1040. "in": "body",
  1041. "schema": {
  1042. "$ref": "#/definitions/CreateLabelOption"
  1043. }
  1044. }
  1045. ],
  1046. "responses": {
  1047. "201": {
  1048. "$ref": "#/responses/Label"
  1049. },
  1050. "422": {
  1051. "$ref": "#/responses/validationError"
  1052. }
  1053. }
  1054. }
  1055. },
  1056. "/orgs/{org}/labels/{id}": {
  1057. "get": {
  1058. "produces": [
  1059. "application/json"
  1060. ],
  1061. "tags": [
  1062. "organization"
  1063. ],
  1064. "summary": "Get a single label",
  1065. "operationId": "orgGetLabel",
  1066. "parameters": [
  1067. {
  1068. "type": "string",
  1069. "description": "name of the organization",
  1070. "name": "org",
  1071. "in": "path",
  1072. "required": true
  1073. },
  1074. {
  1075. "type": "integer",
  1076. "format": "int64",
  1077. "description": "id of the label to get",
  1078. "name": "id",
  1079. "in": "path",
  1080. "required": true
  1081. }
  1082. ],
  1083. "responses": {
  1084. "200": {
  1085. "$ref": "#/responses/Label"
  1086. }
  1087. }
  1088. },
  1089. "delete": {
  1090. "tags": [
  1091. "organization"
  1092. ],
  1093. "summary": "Delete a label",
  1094. "operationId": "orgDeleteLabel",
  1095. "parameters": [
  1096. {
  1097. "type": "string",
  1098. "description": "name of the organization",
  1099. "name": "org",
  1100. "in": "path",
  1101. "required": true
  1102. },
  1103. {
  1104. "type": "integer",
  1105. "format": "int64",
  1106. "description": "id of the label to delete",
  1107. "name": "id",
  1108. "in": "path",
  1109. "required": true
  1110. }
  1111. ],
  1112. "responses": {
  1113. "204": {
  1114. "$ref": "#/responses/empty"
  1115. }
  1116. }
  1117. },
  1118. "patch": {
  1119. "consumes": [
  1120. "application/json"
  1121. ],
  1122. "produces": [
  1123. "application/json"
  1124. ],
  1125. "tags": [
  1126. "organization"
  1127. ],
  1128. "summary": "Update a label",
  1129. "operationId": "orgEditLabel",
  1130. "parameters": [
  1131. {
  1132. "type": "string",
  1133. "description": "name of the organization",
  1134. "name": "org",
  1135. "in": "path",
  1136. "required": true
  1137. },
  1138. {
  1139. "type": "integer",
  1140. "format": "int64",
  1141. "description": "id of the label to edit",
  1142. "name": "id",
  1143. "in": "path",
  1144. "required": true
  1145. },
  1146. {
  1147. "name": "body",
  1148. "in": "body",
  1149. "schema": {
  1150. "$ref": "#/definitions/EditLabelOption"
  1151. }
  1152. }
  1153. ],
  1154. "responses": {
  1155. "200": {
  1156. "$ref": "#/responses/Label"
  1157. },
  1158. "422": {
  1159. "$ref": "#/responses/validationError"
  1160. }
  1161. }
  1162. }
  1163. },
  1164. "/orgs/{org}/members": {
  1165. "get": {
  1166. "produces": [
  1167. "application/json"
  1168. ],
  1169. "tags": [
  1170. "organization"
  1171. ],
  1172. "summary": "List an organization's members",
  1173. "operationId": "orgListMembers",
  1174. "parameters": [
  1175. {
  1176. "type": "string",
  1177. "description": "name of the organization",
  1178. "name": "org",
  1179. "in": "path",
  1180. "required": true
  1181. },
  1182. {
  1183. "type": "integer",
  1184. "description": "page number of results to return (1-based)",
  1185. "name": "page",
  1186. "in": "query"
  1187. },
  1188. {
  1189. "type": "integer",
  1190. "description": "page size of results, maximum page size is 50",
  1191. "name": "limit",
  1192. "in": "query"
  1193. }
  1194. ],
  1195. "responses": {
  1196. "200": {
  1197. "$ref": "#/responses/UserList"
  1198. }
  1199. }
  1200. }
  1201. },
  1202. "/orgs/{org}/members/{username}": {
  1203. "get": {
  1204. "tags": [
  1205. "organization"
  1206. ],
  1207. "summary": "Check if a user is a member of an organization",
  1208. "operationId": "orgIsMember",
  1209. "parameters": [
  1210. {
  1211. "type": "string",
  1212. "description": "name of the organization",
  1213. "name": "org",
  1214. "in": "path",
  1215. "required": true
  1216. },
  1217. {
  1218. "type": "string",
  1219. "description": "username of the user",
  1220. "name": "username",
  1221. "in": "path",
  1222. "required": true
  1223. }
  1224. ],
  1225. "responses": {
  1226. "204": {
  1227. "description": "user is a member"
  1228. },
  1229. "302": {
  1230. "description": "redirection to /orgs/{org}/public_members/{username}"
  1231. },
  1232. "404": {
  1233. "description": "user is not a member"
  1234. }
  1235. }
  1236. },
  1237. "delete": {
  1238. "produces": [
  1239. "application/json"
  1240. ],
  1241. "tags": [
  1242. "organization"
  1243. ],
  1244. "summary": "Remove a member from an organization",
  1245. "operationId": "orgDeleteMember",
  1246. "parameters": [
  1247. {
  1248. "type": "string",
  1249. "description": "name of the organization",
  1250. "name": "org",
  1251. "in": "path",
  1252. "required": true
  1253. },
  1254. {
  1255. "type": "string",
  1256. "description": "username of the user",
  1257. "name": "username",
  1258. "in": "path",
  1259. "required": true
  1260. }
  1261. ],
  1262. "responses": {
  1263. "204": {
  1264. "description": "member removed"
  1265. }
  1266. }
  1267. }
  1268. },
  1269. "/orgs/{org}/public_members": {
  1270. "get": {
  1271. "produces": [
  1272. "application/json"
  1273. ],
  1274. "tags": [
  1275. "organization"
  1276. ],
  1277. "summary": "List an organization's public members",
  1278. "operationId": "orgListPublicMembers",
  1279. "parameters": [
  1280. {
  1281. "type": "string",
  1282. "description": "name of the organization",
  1283. "name": "org",
  1284. "in": "path",
  1285. "required": true
  1286. },
  1287. {
  1288. "type": "integer",
  1289. "description": "page number of results to return (1-based)",
  1290. "name": "page",
  1291. "in": "query"
  1292. },
  1293. {
  1294. "type": "integer",
  1295. "description": "page size of results, maximum page size is 50",
  1296. "name": "limit",
  1297. "in": "query"
  1298. }
  1299. ],
  1300. "responses": {
  1301. "200": {
  1302. "$ref": "#/responses/UserList"
  1303. }
  1304. }
  1305. }
  1306. },
  1307. "/orgs/{org}/public_members/{username}": {
  1308. "get": {
  1309. "tags": [
  1310. "organization"
  1311. ],
  1312. "summary": "Check if a user is a public member of an organization",
  1313. "operationId": "orgIsPublicMember",
  1314. "parameters": [
  1315. {
  1316. "type": "string",
  1317. "description": "name of the organization",
  1318. "name": "org",
  1319. "in": "path",
  1320. "required": true
  1321. },
  1322. {
  1323. "type": "string",
  1324. "description": "username of the user",
  1325. "name": "username",
  1326. "in": "path",
  1327. "required": true
  1328. }
  1329. ],
  1330. "responses": {
  1331. "204": {
  1332. "description": "user is a public member"
  1333. },
  1334. "404": {
  1335. "description": "user is not a public member"
  1336. }
  1337. }
  1338. },
  1339. "put": {
  1340. "produces": [
  1341. "application/json"
  1342. ],
  1343. "tags": [
  1344. "organization"
  1345. ],
  1346. "summary": "Publicize a user's membership",
  1347. "operationId": "orgPublicizeMember",
  1348. "parameters": [
  1349. {
  1350. "type": "string",
  1351. "description": "name of the organization",
  1352. "name": "org",
  1353. "in": "path",
  1354. "required": true
  1355. },
  1356. {
  1357. "type": "string",
  1358. "description": "username of the user",
  1359. "name": "username",
  1360. "in": "path",
  1361. "required": true
  1362. }
  1363. ],
  1364. "responses": {
  1365. "204": {
  1366. "description": "membership publicized"
  1367. },
  1368. "403": {
  1369. "$ref": "#/responses/forbidden"
  1370. }
  1371. }
  1372. },
  1373. "delete": {
  1374. "produces": [
  1375. "application/json"
  1376. ],
  1377. "tags": [
  1378. "organization"
  1379. ],
  1380. "summary": "Conceal a user's membership",
  1381. "operationId": "orgConcealMember",
  1382. "parameters": [
  1383. {
  1384. "type": "string",
  1385. "description": "name of the organization",
  1386. "name": "org",
  1387. "in": "path",
  1388. "required": true
  1389. },
  1390. {
  1391. "type": "string",
  1392. "description": "username of the user",
  1393. "name": "username",
  1394. "in": "path",
  1395. "required": true
  1396. }
  1397. ],
  1398. "responses": {
  1399. "204": {
  1400. "$ref": "#/responses/empty"
  1401. },
  1402. "403": {
  1403. "$ref": "#/responses/forbidden"
  1404. }
  1405. }
  1406. }
  1407. },
  1408. "/orgs/{org}/repos": {
  1409. "get": {
  1410. "produces": [
  1411. "application/json"
  1412. ],
  1413. "tags": [
  1414. "organization"
  1415. ],
  1416. "summary": "List an organization's repos",
  1417. "operationId": "orgListRepos",
  1418. "parameters": [
  1419. {
  1420. "type": "string",
  1421. "description": "name of the organization",
  1422. "name": "org",
  1423. "in": "path",
  1424. "required": true
  1425. },
  1426. {
  1427. "type": "integer",
  1428. "description": "page number of results to return (1-based)",
  1429. "name": "page",
  1430. "in": "query"
  1431. },
  1432. {
  1433. "type": "integer",
  1434. "description": "page size of results, maximum page size is 50",
  1435. "name": "limit",
  1436. "in": "query"
  1437. }
  1438. ],
  1439. "responses": {
  1440. "200": {
  1441. "$ref": "#/responses/RepositoryList"
  1442. }
  1443. }
  1444. },
  1445. "post": {
  1446. "consumes": [
  1447. "application/json"
  1448. ],
  1449. "produces": [
  1450. "application/json"
  1451. ],
  1452. "tags": [
  1453. "organization"
  1454. ],
  1455. "summary": "Create a repository in an organization",
  1456. "operationId": "createOrgRepo",
  1457. "parameters": [
  1458. {
  1459. "type": "string",
  1460. "description": "name of organization",
  1461. "name": "org",
  1462. "in": "path",
  1463. "required": true
  1464. },
  1465. {
  1466. "name": "body",
  1467. "in": "body",
  1468. "schema": {
  1469. "$ref": "#/definitions/CreateRepoOption"
  1470. }
  1471. }
  1472. ],
  1473. "responses": {
  1474. "201": {
  1475. "$ref": "#/responses/Repository"
  1476. },
  1477. "403": {
  1478. "$ref": "#/responses/forbidden"
  1479. },
  1480. "404": {
  1481. "$ref": "#/responses/notFound"
  1482. }
  1483. }
  1484. }
  1485. },
  1486. "/orgs/{org}/teams": {
  1487. "get": {
  1488. "produces": [
  1489. "application/json"
  1490. ],
  1491. "tags": [
  1492. "organization"
  1493. ],
  1494. "summary": "List an organization's teams",
  1495. "operationId": "orgListTeams",
  1496. "parameters": [
  1497. {
  1498. "type": "string",
  1499. "description": "name of the organization",
  1500. "name": "org",
  1501. "in": "path",
  1502. "required": true
  1503. },
  1504. {
  1505. "type": "integer",
  1506. "description": "page number of results to return (1-based)",
  1507. "name": "page",
  1508. "in": "query"
  1509. },
  1510. {
  1511. "type": "integer",
  1512. "description": "page size of results, maximum page size is 50",
  1513. "name": "limit",
  1514. "in": "query"
  1515. }
  1516. ],
  1517. "responses": {
  1518. "200": {
  1519. "$ref": "#/responses/TeamList"
  1520. }
  1521. }
  1522. },
  1523. "post": {
  1524. "consumes": [
  1525. "application/json"
  1526. ],
  1527. "produces": [
  1528. "application/json"
  1529. ],
  1530. "tags": [
  1531. "organization"
  1532. ],
  1533. "summary": "Create a team",
  1534. "operationId": "orgCreateTeam",
  1535. "parameters": [
  1536. {
  1537. "type": "string",
  1538. "description": "name of the organization",
  1539. "name": "org",
  1540. "in": "path",
  1541. "required": true
  1542. },
  1543. {
  1544. "name": "body",
  1545. "in": "body",
  1546. "schema": {
  1547. "$ref": "#/definitions/CreateTeamOption"
  1548. }
  1549. }
  1550. ],
  1551. "responses": {
  1552. "201": {
  1553. "$ref": "#/responses/Team"
  1554. },
  1555. "422": {
  1556. "$ref": "#/responses/validationError"
  1557. }
  1558. }
  1559. }
  1560. },
  1561. "/orgs/{org}/teams/search": {
  1562. "get": {
  1563. "produces": [
  1564. "application/json"
  1565. ],
  1566. "tags": [
  1567. "organization"
  1568. ],
  1569. "summary": "Search for teams within an organization",
  1570. "operationId": "teamSearch",
  1571. "parameters": [
  1572. {
  1573. "type": "string",
  1574. "description": "name of the organization",
  1575. "name": "org",
  1576. "in": "path",
  1577. "required": true
  1578. },
  1579. {
  1580. "type": "string",
  1581. "description": "keywords to search",
  1582. "name": "q",
  1583. "in": "query"
  1584. },
  1585. {
  1586. "type": "boolean",
  1587. "description": "include search within team description (defaults to true)",
  1588. "name": "include_desc",
  1589. "in": "query"
  1590. },
  1591. {
  1592. "type": "integer",
  1593. "description": "page number of results to return (1-based)",
  1594. "name": "page",
  1595. "in": "query"
  1596. },
  1597. {
  1598. "type": "integer",
  1599. "description": "page size of results, maximum page size is 50",
  1600. "name": "limit",
  1601. "in": "query"
  1602. }
  1603. ],
  1604. "responses": {
  1605. "200": {
  1606. "description": "SearchResults of a successful search",
  1607. "schema": {
  1608. "type": "object",
  1609. "properties": {
  1610. "data": {
  1611. "type": "array",
  1612. "items": {
  1613. "$ref": "#/definitions/Team"
  1614. }
  1615. },
  1616. "ok": {
  1617. "type": "boolean"
  1618. }
  1619. }
  1620. }
  1621. }
  1622. }
  1623. }
  1624. },
  1625. "/repos/issues/search": {
  1626. "get": {
  1627. "produces": [
  1628. "application/json"
  1629. ],
  1630. "tags": [
  1631. "issue"
  1632. ],
  1633. "summary": "Search for issues across the repositories that the user has access to",
  1634. "operationId": "issueSearchIssues",
  1635. "parameters": [
  1636. {
  1637. "type": "string",
  1638. "description": "whether issue is open or closed",
  1639. "name": "state",
  1640. "in": "query"
  1641. },
  1642. {
  1643. "type": "string",
  1644. "description": "comma separated list of labels. Fetch only issues that have any of this labels. Non existent labels are discarded",
  1645. "name": "labels",
  1646. "in": "query"
  1647. },
  1648. {
  1649. "type": "string",
  1650. "description": "search string",
  1651. "name": "q",
  1652. "in": "query"
  1653. },
  1654. {
  1655. "type": "integer",
  1656. "format": "int64",
  1657. "description": "repository to prioritize in the results",
  1658. "name": "priority_repo_id",
  1659. "in": "query"
  1660. },
  1661. {
  1662. "type": "string",
  1663. "description": "filter by type (issues / pulls) if set",
  1664. "name": "type",
  1665. "in": "query"
  1666. },
  1667. {
  1668. "type": "integer",
  1669. "description": "page number of requested issues",
  1670. "name": "page",
  1671. "in": "query"
  1672. }
  1673. ],
  1674. "responses": {
  1675. "200": {
  1676. "$ref": "#/responses/IssueList"
  1677. }
  1678. }
  1679. }
  1680. },
  1681. "/repos/migrate": {
  1682. "post": {
  1683. "consumes": [
  1684. "application/json"
  1685. ],
  1686. "produces": [
  1687. "application/json"
  1688. ],
  1689. "tags": [
  1690. "repository"
  1691. ],
  1692. "summary": "Migrate a remote git repository",
  1693. "operationId": "repoMigrate",
  1694. "parameters": [
  1695. {
  1696. "name": "body",
  1697. "in": "body",
  1698. "schema": {
  1699. "$ref": "#/definitions/MigrateRepoForm"
  1700. }
  1701. }
  1702. ],
  1703. "responses": {
  1704. "201": {
  1705. "$ref": "#/responses/Repository"
  1706. },
  1707. "403": {
  1708. "$ref": "#/responses/forbidden"
  1709. },
  1710. "422": {
  1711. "$ref": "#/responses/validationError"
  1712. }
  1713. }
  1714. }
  1715. },
  1716. "/repos/search": {
  1717. "get": {
  1718. "produces": [
  1719. "application/json"
  1720. ],
  1721. "tags": [
  1722. "repository"
  1723. ],
  1724. "summary": "Search for repositories",
  1725. "operationId": "repoSearch",
  1726. "parameters": [
  1727. {
  1728. "type": "string",
  1729. "description": "keyword",
  1730. "name": "q",
  1731. "in": "query"
  1732. },
  1733. {
  1734. "type": "boolean",
  1735. "description": "Limit search to repositories with keyword as topic",
  1736. "name": "topic",
  1737. "in": "query"
  1738. },
  1739. {
  1740. "type": "boolean",
  1741. "description": "include search of keyword within repository description",
  1742. "name": "includeDesc",
  1743. "in": "query"
  1744. },
  1745. {
  1746. "type": "integer",
  1747. "format": "int64",
  1748. "description": "search only for repos that the user with the given id owns or contributes to",
  1749. "name": "uid",
  1750. "in": "query"
  1751. },
  1752. {
  1753. "type": "integer",
  1754. "format": "int64",
  1755. "description": "repo owner to prioritize in the results",
  1756. "name": "priority_owner_id",
  1757. "in": "query"
  1758. },
  1759. {
  1760. "type": "integer",
  1761. "format": "int64",
  1762. "description": "search only for repos that the user with the given id has starred",
  1763. "name": "starredBy",
  1764. "in": "query"
  1765. },
  1766. {
  1767. "type": "boolean",
  1768. "description": "include private repositories this user has access to (defaults to true)",
  1769. "name": "private",
  1770. "in": "query"
  1771. },
  1772. {
  1773. "type": "boolean",
  1774. "description": "show only pubic, private or all repositories (defaults to all)",
  1775. "name": "is_private",
  1776. "in": "query"
  1777. },
  1778. {
  1779. "type": "boolean",
  1780. "description": "include template repositories this user has access to (defaults to true)",
  1781. "name": "template",
  1782. "in": "query"
  1783. },
  1784. {
  1785. "type": "boolean",
  1786. "description": "show only archived, non-archived or all repositories (defaults to all)",
  1787. "name": "archived",
  1788. "in": "query"
  1789. },
  1790. {
  1791. "type": "string",
  1792. "description": "type of repository to search for. Supported values are \"fork\", \"source\", \"mirror\" and \"collaborative\"",
  1793. "name": "mode",
  1794. "in": "query"
  1795. },
  1796. {
  1797. "type": "boolean",
  1798. "description": "if `uid` is given, search only for repos that the user owns",
  1799. "name": "exclusive",
  1800. "in": "query"
  1801. },
  1802. {
  1803. "type": "string",
  1804. "description": "sort repos by attribute. Supported values are \"alpha\", \"created\", \"updated\", \"size\", and \"id\". Default is \"alpha\"",
  1805. "name": "sort",
  1806. "in": "query"
  1807. },
  1808. {
  1809. "type": "string",
  1810. "description": "sort order, either \"asc\" (ascending) or \"desc\" (descending). Default is \"asc\", ignored if \"sort\" is not specified.",
  1811. "name": "order",
  1812. "in": "query"
  1813. },
  1814. {
  1815. "type": "integer",
  1816. "description": "page number of results to return (1-based)",
  1817. "name": "page",
  1818. "in": "query"
  1819. },
  1820. {
  1821. "type": "integer",
  1822. "description": "page size of results, maximum page size is 50",
  1823. "name": "limit",
  1824. "in": "query"
  1825. }
  1826. ],
  1827. "responses": {
  1828. "200": {
  1829. "$ref": "#/responses/SearchResults"
  1830. },
  1831. "422": {
  1832. "$ref": "#/responses/validationError"
  1833. }
  1834. }
  1835. }
  1836. },
  1837. "/repos/{owner}/{repo}": {
  1838. "get": {
  1839. "produces": [
  1840. "application/json"
  1841. ],
  1842. "tags": [
  1843. "repository"
  1844. ],
  1845. "summary": "Get a repository",
  1846. "operationId": "repoGet",
  1847. "parameters": [
  1848. {
  1849. "type": "string",
  1850. "description": "owner of the repo",
  1851. "name": "owner",
  1852. "in": "path",
  1853. "required": true
  1854. },
  1855. {
  1856. "type": "string",
  1857. "description": "name of the repo",
  1858. "name": "repo",
  1859. "in": "path",
  1860. "required": true
  1861. }
  1862. ],
  1863. "responses": {
  1864. "200": {
  1865. "$ref": "#/responses/Repository"
  1866. }
  1867. }
  1868. },
  1869. "delete": {
  1870. "produces": [
  1871. "application/json"
  1872. ],
  1873. "tags": [
  1874. "repository"
  1875. ],
  1876. "summary": "Delete a repository",
  1877. "operationId": "repoDelete",
  1878. "parameters": [
  1879. {
  1880. "type": "string",
  1881. "description": "owner of the repo to delete",
  1882. "name": "owner",
  1883. "in": "path",
  1884. "required": true
  1885. },
  1886. {
  1887. "type": "string",
  1888. "description": "name of the repo to delete",
  1889. "name": "repo",
  1890. "in": "path",
  1891. "required": true
  1892. }
  1893. ],
  1894. "responses": {
  1895. "204": {
  1896. "$ref": "#/responses/empty"
  1897. },
  1898. "403": {
  1899. "$ref": "#/responses/forbidden"
  1900. }
  1901. }
  1902. },
  1903. "patch": {
  1904. "produces": [
  1905. "application/json"
  1906. ],
  1907. "tags": [
  1908. "repository"
  1909. ],
  1910. "summary": "Edit a repository's properties. Only fields that are set will be changed.",
  1911. "operationId": "repoEdit",
  1912. "parameters": [
  1913. {
  1914. "type": "string",
  1915. "description": "owner of the repo to edit",
  1916. "name": "owner",
  1917. "in": "path",
  1918. "required": true
  1919. },
  1920. {
  1921. "type": "string",
  1922. "description": "name of the repo to edit",
  1923. "name": "repo",
  1924. "in": "path",
  1925. "required": true
  1926. },
  1927. {
  1928. "description": "Properties of a repo that you can edit",
  1929. "name": "body",
  1930. "in": "body",
  1931. "schema": {
  1932. "$ref": "#/definitions/EditRepoOption"
  1933. }
  1934. }
  1935. ],
  1936. "responses": {
  1937. "200": {
  1938. "$ref": "#/responses/Repository"
  1939. },
  1940. "403": {
  1941. "$ref": "#/responses/forbidden"
  1942. },
  1943. "422": {
  1944. "$ref": "#/responses/validationError"
  1945. }
  1946. }
  1947. }
  1948. },
  1949. "/repos/{owner}/{repo}/archive/{archive}": {
  1950. "get": {
  1951. "produces": [
  1952. "application/json"
  1953. ],
  1954. "tags": [
  1955. "repository"
  1956. ],
  1957. "summary": "Get an archive of a repository",
  1958. "operationId": "repoGetArchive",
  1959. "parameters": [
  1960. {
  1961. "type": "string",
  1962. "description": "owner of the repo",
  1963. "name": "owner",
  1964. "in": "path",
  1965. "required": true
  1966. },
  1967. {
  1968. "type": "string",
  1969. "description": "name of the repo",
  1970. "name": "repo",
  1971. "in": "path",
  1972. "required": true
  1973. },
  1974. {
  1975. "type": "string",
  1976. "description": "archive to download, consisting of a git reference and archive",
  1977. "name": "archive",
  1978. "in": "path",
  1979. "required": true
  1980. }
  1981. ],
  1982. "responses": {
  1983. "200": {
  1984. "description": "success"
  1985. },
  1986. "404": {
  1987. "$ref": "#/responses/notFound"
  1988. }
  1989. }
  1990. }
  1991. },
  1992. "/repos/{owner}/{repo}/branch_protections": {
  1993. "get": {
  1994. "produces": [
  1995. "application/json"
  1996. ],
  1997. "tags": [
  1998. "repository"
  1999. ],
  2000. "summary": "List branch protections for a repository",
  2001. "operationId": "repoListBranchProtection",
  2002. "parameters": [
  2003. {
  2004. "type": "string",
  2005. "description": "owner of the repo",
  2006. "name": "owner",
  2007. "in": "path",
  2008. "required": true
  2009. },
  2010. {
  2011. "type": "string",
  2012. "description": "name of the repo",
  2013. "name": "repo",
  2014. "in": "path",
  2015. "required": true
  2016. }
  2017. ],
  2018. "responses": {
  2019. "200": {
  2020. "$ref": "#/responses/BranchProtectionList"
  2021. }
  2022. }
  2023. },
  2024. "post": {
  2025. "consumes": [
  2026. "application/json"
  2027. ],
  2028. "produces": [
  2029. "application/json"
  2030. ],
  2031. "tags": [
  2032. "repository"
  2033. ],
  2034. "summary": "Create a branch protections for a repository",
  2035. "operationId": "repoCreateBranchProtection",
  2036. "parameters": [
  2037. {
  2038. "type": "string",
  2039. "description": "owner of the repo",
  2040. "name": "owner",
  2041. "in": "path",
  2042. "required": true
  2043. },
  2044. {
  2045. "type": "string",
  2046. "description": "name of the repo",
  2047. "name": "repo",
  2048. "in": "path",
  2049. "required": true
  2050. },
  2051. {
  2052. "name": "body",
  2053. "in": "body",
  2054. "schema": {
  2055. "$ref": "#/definitions/CreateBranchProtectionOption"
  2056. }
  2057. }
  2058. ],
  2059. "responses": {
  2060. "201": {
  2061. "$ref": "#/responses/BranchProtection"
  2062. },
  2063. "403": {
  2064. "$ref": "#/responses/forbidden"
  2065. },
  2066. "404": {
  2067. "$ref": "#/responses/notFound"
  2068. },
  2069. "422": {
  2070. "$ref": "#/responses/validationError"
  2071. }
  2072. }
  2073. }
  2074. },
  2075. "/repos/{owner}/{repo}/branch_protections/{name}": {
  2076. "get": {
  2077. "produces": [
  2078. "application/json"
  2079. ],
  2080. "tags": [
  2081. "repository"
  2082. ],
  2083. "summary": "Get a specific branch protection for the repository",
  2084. "operationId": "repoGetBranchProtection",
  2085. "parameters": [
  2086. {
  2087. "type": "string",
  2088. "description": "owner of the repo",
  2089. "name": "owner",
  2090. "in": "path",
  2091. "required": true
  2092. },
  2093. {
  2094. "type": "string",
  2095. "description": "name of the repo",
  2096. "name": "repo",
  2097. "in": "path",
  2098. "required": true
  2099. },
  2100. {
  2101. "type": "string",
  2102. "description": "name of protected branch",
  2103. "name": "name",
  2104. "in": "path",
  2105. "required": true
  2106. }
  2107. ],
  2108. "responses": {
  2109. "200": {
  2110. "$ref": "#/responses/BranchProtection"
  2111. },
  2112. "404": {
  2113. "$ref": "#/responses/notFound"
  2114. }
  2115. }
  2116. },
  2117. "delete": {
  2118. "produces": [
  2119. "application/json"
  2120. ],
  2121. "tags": [
  2122. "repository"
  2123. ],
  2124. "summary": "Delete a specific branch protection for the repository",
  2125. "operationId": "repoDeleteBranchProtection",
  2126. "parameters": [
  2127. {
  2128. "type": "string",
  2129. "description": "owner of the repo",
  2130. "name": "owner",
  2131. "in": "path",
  2132. "required": true
  2133. },
  2134. {
  2135. "type": "string",
  2136. "description": "name of the repo",
  2137. "name": "repo",
  2138. "in": "path",
  2139. "required": true
  2140. },
  2141. {
  2142. "type": "string",
  2143. "description": "name of protected branch",
  2144. "name": "name",
  2145. "in": "path",
  2146. "required": true
  2147. }
  2148. ],
  2149. "responses": {
  2150. "204": {
  2151. "$ref": "#/responses/empty"
  2152. },
  2153. "404": {
  2154. "$ref": "#/responses/notFound"
  2155. }
  2156. }
  2157. },
  2158. "patch": {
  2159. "consumes": [
  2160. "application/json"
  2161. ],
  2162. "produces": [
  2163. "application/json"
  2164. ],
  2165. "tags": [
  2166. "repository"
  2167. ],
  2168. "summary": "Edit a branch protections for a repository. Only fields that are set will be changed",
  2169. "operationId": "repoEditBranchProtection",
  2170. "parameters": [
  2171. {
  2172. "type": "string",
  2173. "description": "owner of the repo",
  2174. "name": "owner",
  2175. "in": "path",
  2176. "required": true
  2177. },
  2178. {
  2179. "type": "string",
  2180. "description": "name of the repo",
  2181. "name": "repo",
  2182. "in": "path",
  2183. "required": true
  2184. },
  2185. {
  2186. "type": "string",
  2187. "description": "name of protected branch",
  2188. "name": "name",
  2189. "in": "path",
  2190. "required": true
  2191. },
  2192. {
  2193. "name": "body",
  2194. "in": "body",
  2195. "schema": {
  2196. "$ref": "#/definitions/EditBranchProtectionOption"
  2197. }
  2198. }
  2199. ],
  2200. "responses": {
  2201. "200": {
  2202. "$ref": "#/responses/BranchProtection"
  2203. },
  2204. "404": {
  2205. "$ref": "#/responses/notFound"
  2206. },
  2207. "422": {
  2208. "$ref": "#/responses/validationError"
  2209. }
  2210. }
  2211. }
  2212. },
  2213. "/repos/{owner}/{repo}/branches": {
  2214. "get": {
  2215. "produces": [
  2216. "application/json"
  2217. ],
  2218. "tags": [
  2219. "repository"
  2220. ],
  2221. "summary": "List a repository's branches",
  2222. "operationId": "repoListBranches",
  2223. "parameters": [
  2224. {
  2225. "type": "string",
  2226. "description": "owner of the repo",
  2227. "name": "owner",
  2228. "in": "path",
  2229. "required": true
  2230. },
  2231. {
  2232. "type": "string",
  2233. "description": "name of the repo",
  2234. "name": "repo",
  2235. "in": "path",
  2236. "required": true
  2237. }
  2238. ],
  2239. "responses": {
  2240. "200": {
  2241. "$ref": "#/responses/BranchList"
  2242. }
  2243. }
  2244. },
  2245. "post": {
  2246. "consumes": [
  2247. "application/json"
  2248. ],
  2249. "produces": [
  2250. "application/json"
  2251. ],
  2252. "tags": [
  2253. "repository"
  2254. ],
  2255. "summary": "Create a branch",
  2256. "operationId": "repoCreateBranch",
  2257. "parameters": [
  2258. {
  2259. "type": "string",
  2260. "description": "owner of the repo",
  2261. "name": "owner",
  2262. "in": "path",
  2263. "required": true
  2264. },
  2265. {
  2266. "type": "string",
  2267. "description": "name of the repo",
  2268. "name": "repo",
  2269. "in": "path",
  2270. "required": true
  2271. },
  2272. {
  2273. "name": "body",
  2274. "in": "body",
  2275. "schema": {
  2276. "$ref": "#/definitions/CreateBranchRepoOption"
  2277. }
  2278. }
  2279. ],
  2280. "responses": {
  2281. "201": {
  2282. "$ref": "#/responses/Branch"
  2283. },
  2284. "404": {
  2285. "description": "The old branch does not exist."
  2286. },
  2287. "409": {
  2288. "description": "The branch with the same name already exists."
  2289. }
  2290. }
  2291. }
  2292. },
  2293. "/repos/{owner}/{repo}/branches/{branch}": {
  2294. "get": {
  2295. "produces": [
  2296. "application/json"
  2297. ],
  2298. "tags": [
  2299. "repository"
  2300. ],
  2301. "summary": "Retrieve a specific branch from a repository, including its effective branch protection",
  2302. "operationId": "repoGetBranch",
  2303. "parameters": [
  2304. {
  2305. "type": "string",
  2306. "description": "owner of the repo",
  2307. "name": "owner",
  2308. "in": "path",
  2309. "required": true
  2310. },
  2311. {
  2312. "type": "string",
  2313. "description": "name of the repo",
  2314. "name": "repo",
  2315. "in": "path",
  2316. "required": true
  2317. },
  2318. {
  2319. "type": "string",
  2320. "description": "branch to get",
  2321. "name": "branch",
  2322. "in": "path",
  2323. "required": true
  2324. }
  2325. ],
  2326. "responses": {
  2327. "200": {
  2328. "$ref": "#/responses/Branch"
  2329. }
  2330. }
  2331. },
  2332. "delete": {
  2333. "produces": [
  2334. "application/json"
  2335. ],
  2336. "tags": [
  2337. "repository"
  2338. ],
  2339. "summary": "Delete a specific branch from a repository",
  2340. "operationId": "repoDeleteBranch",
  2341. "parameters": [
  2342. {
  2343. "type": "string",
  2344. "description": "owner of the repo",
  2345. "name": "owner",
  2346. "in": "path",
  2347. "required": true
  2348. },
  2349. {
  2350. "type": "string",
  2351. "description": "name of the repo",
  2352. "name": "repo",
  2353. "in": "path",
  2354. "required": true
  2355. },
  2356. {
  2357. "type": "string",
  2358. "description": "branch to delete",
  2359. "name": "branch",
  2360. "in": "path",
  2361. "required": true
  2362. }
  2363. ],
  2364. "responses": {
  2365. "204": {
  2366. "$ref": "#/responses/empty"
  2367. },
  2368. "403": {
  2369. "$ref": "#/responses/error"
  2370. }
  2371. }
  2372. }
  2373. },
  2374. "/repos/{owner}/{repo}/collaborators": {
  2375. "get": {
  2376. "produces": [
  2377. "application/json"
  2378. ],
  2379. "tags": [
  2380. "repository"
  2381. ],
  2382. "summary": "List a repository's collaborators",
  2383. "operationId": "repoListCollaborators",
  2384. "parameters": [
  2385. {
  2386. "type": "string",
  2387. "description": "owner of the repo",
  2388. "name": "owner",
  2389. "in": "path",
  2390. "required": true
  2391. },
  2392. {
  2393. "type": "string",
  2394. "description": "name of the repo",
  2395. "name": "repo",
  2396. "in": "path",
  2397. "required": true
  2398. },
  2399. {
  2400. "type": "integer",
  2401. "description": "page number of results to return (1-based)",
  2402. "name": "page",
  2403. "in": "query"
  2404. },
  2405. {
  2406. "type": "integer",
  2407. "description": "page size of results, maximum page size is 50",
  2408. "name": "limit",
  2409. "in": "query"
  2410. }
  2411. ],
  2412. "responses": {
  2413. "200": {
  2414. "$ref": "#/responses/UserList"
  2415. }
  2416. }
  2417. }
  2418. },
  2419. "/repos/{owner}/{repo}/collaborators/{collaborator}": {
  2420. "get": {
  2421. "produces": [
  2422. "application/json"
  2423. ],
  2424. "tags": [
  2425. "repository"
  2426. ],
  2427. "summary": "Check if a user is a collaborator of a repository",
  2428. "operationId": "repoCheckCollaborator",
  2429. "parameters": [
  2430. {
  2431. "type": "string",
  2432. "description": "owner of the repo",
  2433. "name": "owner",
  2434. "in": "path",
  2435. "required": true
  2436. },
  2437. {
  2438. "type": "string",
  2439. "description": "name of the repo",
  2440. "name": "repo",
  2441. "in": "path",
  2442. "required": true
  2443. },
  2444. {
  2445. "type": "string",
  2446. "description": "username of the collaborator",
  2447. "name": "collaborator",
  2448. "in": "path",
  2449. "required": true
  2450. }
  2451. ],
  2452. "responses": {
  2453. "204": {
  2454. "$ref": "#/responses/empty"
  2455. },
  2456. "404": {
  2457. "$ref": "#/responses/notFound"
  2458. },
  2459. "422": {
  2460. "$ref": "#/responses/validationError"
  2461. }
  2462. }
  2463. },
  2464. "put": {
  2465. "produces": [
  2466. "application/json"
  2467. ],
  2468. "tags": [
  2469. "repository"
  2470. ],
  2471. "summary": "Add a collaborator to a repository",
  2472. "operationId": "repoAddCollaborator",
  2473. "parameters": [
  2474. {
  2475. "type": "string",
  2476. "description": "owner of the repo",
  2477. "name": "owner",
  2478. "in": "path",
  2479. "required": true
  2480. },
  2481. {
  2482. "type": "string",
  2483. "description": "name of the repo",
  2484. "name": "repo",
  2485. "in": "path",
  2486. "required": true
  2487. },
  2488. {
  2489. "type": "string",
  2490. "description": "username of the collaborator to add",
  2491. "name": "collaborator",
  2492. "in": "path",
  2493. "required": true
  2494. },
  2495. {
  2496. "name": "body",
  2497. "in": "body",
  2498. "schema": {
  2499. "$ref": "#/definitions/AddCollaboratorOption"
  2500. }
  2501. }
  2502. ],
  2503. "responses": {
  2504. "204": {
  2505. "$ref": "#/responses/empty"
  2506. },
  2507. "422": {
  2508. "$ref": "#/responses/validationError"
  2509. }
  2510. }
  2511. },
  2512. "delete": {
  2513. "produces": [
  2514. "application/json"
  2515. ],
  2516. "tags": [
  2517. "repository"
  2518. ],
  2519. "summary": "Delete a collaborator from a repository",
  2520. "operationId": "repoDeleteCollaborator",
  2521. "parameters": [
  2522. {
  2523. "type": "string",
  2524. "description": "owner of the repo",
  2525. "name": "owner",
  2526. "in": "path",
  2527. "required": true
  2528. },
  2529. {
  2530. "type": "string",
  2531. "description": "name of the repo",
  2532. "name": "repo",
  2533. "in": "path",
  2534. "required": true
  2535. },
  2536. {
  2537. "type": "string",
  2538. "description": "username of the collaborator to delete",
  2539. "name": "collaborator",
  2540. "in": "path",
  2541. "required": true
  2542. }
  2543. ],
  2544. "responses": {
  2545. "204": {
  2546. "$ref": "#/responses/empty"
  2547. },
  2548. "422": {
  2549. "$ref": "#/responses/validationError"
  2550. }
  2551. }
  2552. }
  2553. },
  2554. "/repos/{owner}/{repo}/commits": {
  2555. "get": {
  2556. "produces": [
  2557. "application/json"
  2558. ],
  2559. "tags": [
  2560. "repository"
  2561. ],
  2562. "summary": "Get a list of all commits from a repository",
  2563. "operationId": "repoGetAllCommits",
  2564. "parameters": [
  2565. {
  2566. "type": "string",
  2567. "description": "owner of the repo",
  2568. "name": "owner",
  2569. "in": "path",
  2570. "required": true
  2571. },
  2572. {
  2573. "type": "string",
  2574. "description": "name of the repo",
  2575. "name": "repo",
  2576. "in": "path",
  2577. "required": true
  2578. },
  2579. {
  2580. "type": "string",
  2581. "description": "SHA or branch to start listing commits from (usually 'master')",
  2582. "name": "sha",
  2583. "in": "query"
  2584. },
  2585. {
  2586. "type": "integer",
  2587. "description": "page number of results to return (1-based)",
  2588. "name": "page",
  2589. "in": "query"
  2590. },
  2591. {
  2592. "type": "integer",
  2593. "description": "page size of results, maximum page size is 50",
  2594. "name": "limit",
  2595. "in": "query"
  2596. }
  2597. ],
  2598. "responses": {
  2599. "200": {
  2600. "$ref": "#/responses/CommitList"
  2601. },
  2602. "404": {
  2603. "$ref": "#/responses/notFound"
  2604. },
  2605. "409": {
  2606. "$ref": "#/responses/EmptyRepository"
  2607. }
  2608. }
  2609. }
  2610. },
  2611. "/repos/{owner}/{repo}/commits/{ref}/statuses": {
  2612. "get": {
  2613. "produces": [
  2614. "application/json"
  2615. ],
  2616. "tags": [
  2617. "repository"
  2618. ],
  2619. "summary": "Get a commit's combined status, by branch/tag/commit reference",
  2620. "operationId": "repoGetCombinedStatusByRef",
  2621. "parameters": [
  2622. {
  2623. "type": "string",
  2624. "description": "owner of the repo",
  2625. "name": "owner",
  2626. "in": "path",
  2627. "required": true
  2628. },
  2629. {
  2630. "type": "string",
  2631. "description": "name of the repo",
  2632. "name": "repo",
  2633. "in": "path",
  2634. "required": true
  2635. },
  2636. {
  2637. "type": "string",
  2638. "description": "name of branch/tag/commit",
  2639. "name": "ref",
  2640. "in": "path",
  2641. "required": true
  2642. },
  2643. {
  2644. "type": "integer",
  2645. "description": "page number of results",
  2646. "name": "page",
  2647. "in": "query"
  2648. }
  2649. ],
  2650. "responses": {
  2651. "200": {
  2652. "$ref": "#/responses/Status"
  2653. },
  2654. "400": {
  2655. "$ref": "#/responses/error"
  2656. }
  2657. }
  2658. }
  2659. },
  2660. "/repos/{owner}/{repo}/contents": {
  2661. "get": {
  2662. "produces": [
  2663. "application/json"
  2664. ],
  2665. "tags": [
  2666. "repository"
  2667. ],
  2668. "summary": "Gets the metadata of all the entries of the root dir",
  2669. "operationId": "repoGetContentsList",
  2670. "parameters": [
  2671. {
  2672. "type": "string",
  2673. "description": "owner of the repo",
  2674. "name": "owner",
  2675. "in": "path",
  2676. "required": true
  2677. },
  2678. {
  2679. "type": "string",
  2680. "description": "name of the repo",
  2681. "name": "repo",
  2682. "in": "path",
  2683. "required": true
  2684. },
  2685. {
  2686. "type": "string",
  2687. "description": "The name of the commit/branch/tag. Default the repository’s default branch (usually master)",
  2688. "name": "ref",
  2689. "in": "query"
  2690. }
  2691. ],
  2692. "responses": {
  2693. "200": {
  2694. "$ref": "#/responses/ContentsListResponse"
  2695. },
  2696. "404": {
  2697. "$ref": "#/responses/notFound"
  2698. }
  2699. }
  2700. }
  2701. },
  2702. "/repos/{owner}/{repo}/contents/{filepath}": {
  2703. "get": {
  2704. "produces": [
  2705. "application/json"
  2706. ],
  2707. "tags": [
  2708. "repository"
  2709. ],
  2710. "summary": "Gets the metadata and contents (if a file) of an entry in a repository, or a list of entries if a dir",
  2711. "operationId": "repoGetContents",
  2712. "parameters": [
  2713. {
  2714. "type": "string",
  2715. "description": "owner of the repo",
  2716. "name": "owner",
  2717. "in": "path",
  2718. "required": true
  2719. },
  2720. {
  2721. "type": "string",
  2722. "description": "name of the repo",
  2723. "name": "repo",
  2724. "in": "path",
  2725. "required": true
  2726. },
  2727. {
  2728. "type": "string",
  2729. "description": "path of the dir, file, symlink or submodule in the repo",
  2730. "name": "filepath",
  2731. "in": "path",
  2732. "required": true
  2733. },
  2734. {
  2735. "type": "string",
  2736. "description": "The name of the commit/branch/tag. Default the repository’s default branch (usually master)",
  2737. "name": "ref",
  2738. "in": "query"
  2739. }
  2740. ],
  2741. "responses": {
  2742. "200": {
  2743. "$ref": "#/responses/ContentsResponse"
  2744. },
  2745. "404": {
  2746. "$ref": "#/responses/notFound"
  2747. }
  2748. }
  2749. },
  2750. "put": {
  2751. "consumes": [
  2752. "application/json"
  2753. ],
  2754. "produces": [
  2755. "application/json"
  2756. ],
  2757. "tags": [
  2758. "repository"
  2759. ],
  2760. "summary": "Update a file in a repository",
  2761. "operationId": "repoUpdateFile",
  2762. "parameters": [
  2763. {
  2764. "type": "string",
  2765. "description": "owner of the repo",
  2766. "name": "owner",
  2767. "in": "path",
  2768. "required": true
  2769. },
  2770. {
  2771. "type": "string",
  2772. "description": "name of the repo",
  2773. "name": "repo",
  2774. "in": "path",
  2775. "required": true
  2776. },
  2777. {
  2778. "type": "string",
  2779. "description": "path of the file to update",
  2780. "name": "filepath",
  2781. "in": "path",
  2782. "required": true
  2783. },
  2784. {
  2785. "name": "body",
  2786. "in": "body",
  2787. "required": true,
  2788. "schema": {
  2789. "$ref": "#/definitions/UpdateFileOptions"
  2790. }
  2791. }
  2792. ],
  2793. "responses": {
  2794. "200": {
  2795. "$ref": "#/responses/FileResponse"
  2796. },
  2797. "403": {
  2798. "$ref": "#/responses/error"
  2799. },
  2800. "404": {
  2801. "$ref": "#/responses/notFound"
  2802. },
  2803. "422": {
  2804. "$ref": "#/responses/error"
  2805. }
  2806. }
  2807. },
  2808. "post": {
  2809. "consumes": [
  2810. "application/json"
  2811. ],
  2812. "produces": [
  2813. "application/json"
  2814. ],
  2815. "tags": [
  2816. "repository"
  2817. ],
  2818. "summary": "Create a file in a repository",
  2819. "operationId": "repoCreateFile",
  2820. "parameters": [
  2821. {
  2822. "type": "string",
  2823. "description": "owner of the repo",
  2824. "name": "owner",
  2825. "in": "path",
  2826. "required": true
  2827. },
  2828. {
  2829. "type": "string",
  2830. "description": "name of the repo",
  2831. "name": "repo",
  2832. "in": "path",
  2833. "required": true
  2834. },
  2835. {
  2836. "type": "string",
  2837. "description": "path of the file to create",
  2838. "name": "filepath",
  2839. "in": "path",
  2840. "required": true
  2841. },
  2842. {
  2843. "name": "body",
  2844. "in": "body",
  2845. "required": true,
  2846. "schema": {
  2847. "$ref": "#/definitions/CreateFileOptions"
  2848. }
  2849. }
  2850. ],
  2851. "responses": {
  2852. "201": {
  2853. "$ref": "#/responses/FileResponse"
  2854. },
  2855. "403": {
  2856. "$ref": "#/responses/error"
  2857. },
  2858. "404": {
  2859. "$ref": "#/responses/notFound"
  2860. },
  2861. "422": {
  2862. "$ref": "#/responses/error"
  2863. }
  2864. }
  2865. },
  2866. "delete": {
  2867. "consumes": [
  2868. "application/json"
  2869. ],
  2870. "produces": [
  2871. "application/json"
  2872. ],
  2873. "tags": [
  2874. "repository"
  2875. ],
  2876. "summary": "Delete a file in a repository",
  2877. "operationId": "repoDeleteFile",
  2878. "parameters": [
  2879. {
  2880. "type": "string",
  2881. "description": "owner of the repo",
  2882. "name": "owner",
  2883. "in": "path",
  2884. "required": true
  2885. },
  2886. {
  2887. "type": "string",
  2888. "description": "name of the repo",
  2889. "name": "repo",
  2890. "in": "path",
  2891. "required": true
  2892. },
  2893. {
  2894. "type": "string",
  2895. "description": "path of the file to delete",
  2896. "name": "filepath",
  2897. "in": "path",
  2898. "required": true
  2899. },
  2900. {
  2901. "name": "body",
  2902. "in": "body",
  2903. "required": true,
  2904. "schema": {
  2905. "$ref": "#/definitions/DeleteFileOptions"
  2906. }
  2907. }
  2908. ],
  2909. "responses": {
  2910. "200": {
  2911. "$ref": "#/responses/FileDeleteResponse"
  2912. },
  2913. "400": {
  2914. "$ref": "#/responses/error"
  2915. },
  2916. "403": {
  2917. "$ref": "#/responses/error"
  2918. },
  2919. "404": {
  2920. "$ref": "#/responses/error"
  2921. }
  2922. }
  2923. }
  2924. },
  2925. "/repos/{owner}/{repo}/editorconfig/{filepath}": {
  2926. "get": {
  2927. "produces": [
  2928. "application/json"
  2929. ],
  2930. "tags": [
  2931. "repository"
  2932. ],
  2933. "summary": "Get the EditorConfig definitions of a file in a repository",
  2934. "operationId": "repoGetEditorConfig",
  2935. "parameters": [
  2936. {
  2937. "type": "string",
  2938. "description": "owner of the repo",
  2939. "name": "owner",
  2940. "in": "path",
  2941. "required": true
  2942. },
  2943. {
  2944. "type": "string",
  2945. "description": "name of the repo",
  2946. "name": "repo",
  2947. "in": "path",
  2948. "required": true
  2949. },
  2950. {
  2951. "type": "string",
  2952. "description": "filepath of file to get",
  2953. "name": "filepath",
  2954. "in": "path",
  2955. "required": true
  2956. }
  2957. ],
  2958. "responses": {
  2959. "200": {
  2960. "description": "success"
  2961. },
  2962. "404": {
  2963. "$ref": "#/responses/notFound"
  2964. }
  2965. }
  2966. }
  2967. },
  2968. "/repos/{owner}/{repo}/forks": {
  2969. "get": {
  2970. "produces": [
  2971. "application/json"
  2972. ],
  2973. "tags": [
  2974. "repository"
  2975. ],
  2976. "summary": "List a repository's forks",
  2977. "operationId": "listForks",
  2978. "parameters": [
  2979. {
  2980. "type": "string",
  2981. "description": "owner of the repo",
  2982. "name": "owner",
  2983. "in": "path",
  2984. "required": true
  2985. },
  2986. {
  2987. "type": "string",
  2988. "description": "name of the repo",
  2989. "name": "repo",
  2990. "in": "path",
  2991. "required": true
  2992. },
  2993. {
  2994. "type": "integer",
  2995. "description": "page number of results to return (1-based)",
  2996. "name": "page",
  2997. "in": "query"
  2998. },
  2999. {
  3000. "type": "integer",
  3001. "description": "page size of results, maximum page size is 50",
  3002. "name": "limit",
  3003. "in": "query"
  3004. }
  3005. ],
  3006. "responses": {
  3007. "200": {
  3008. "$ref": "#/responses/RepositoryList"
  3009. }
  3010. }
  3011. },
  3012. "post": {
  3013. "produces": [
  3014. "application/json"
  3015. ],
  3016. "tags": [
  3017. "repository"
  3018. ],
  3019. "summary": "Fork a repository",
  3020. "operationId": "createFork",
  3021. "parameters": [
  3022. {
  3023. "type": "string",
  3024. "description": "owner of the repo to fork",
  3025. "name": "owner",
  3026. "in": "path",
  3027. "required": true
  3028. },
  3029. {
  3030. "type": "string",
  3031. "description": "name of the repo to fork",
  3032. "name": "repo",
  3033. "in": "path",
  3034. "required": true
  3035. },
  3036. {
  3037. "name": "body",
  3038. "in": "body",
  3039. "schema": {
  3040. "$ref": "#/definitions/CreateForkOption"
  3041. }
  3042. }
  3043. ],
  3044. "responses": {
  3045. "202": {
  3046. "$ref": "#/responses/Repository"
  3047. },
  3048. "403": {
  3049. "$ref": "#/responses/forbidden"
  3050. },
  3051. "422": {
  3052. "$ref": "#/responses/validationError"
  3053. }
  3054. }
  3055. }
  3056. },
  3057. "/repos/{owner}/{repo}/git/blobs/{sha}": {
  3058. "get": {
  3059. "produces": [
  3060. "application/json"
  3061. ],
  3062. "tags": [
  3063. "repository"
  3064. ],
  3065. "summary": "Gets the blob of a repository.",
  3066. "operationId": "GetBlob",
  3067. "parameters": [
  3068. {
  3069. "type": "string",
  3070. "description": "owner of the repo",
  3071. "name": "owner",
  3072. "in": "path",
  3073. "required": true
  3074. },
  3075. {
  3076. "type": "string",
  3077. "description": "name of the repo",
  3078. "name": "repo",
  3079. "in": "path",
  3080. "required": true
  3081. },
  3082. {
  3083. "type": "string",
  3084. "description": "sha of the commit",
  3085. "name": "sha",
  3086. "in": "path",
  3087. "required": true
  3088. }
  3089. ],
  3090. "responses": {
  3091. "200": {
  3092. "$ref": "#/responses/GitBlobResponse"
  3093. },
  3094. "400": {
  3095. "$ref": "#/responses/error"
  3096. }
  3097. }
  3098. }
  3099. },
  3100. "/repos/{owner}/{repo}/git/commits/{sha}": {
  3101. "get": {
  3102. "produces": [
  3103. "application/json"
  3104. ],
  3105. "tags": [
  3106. "repository"
  3107. ],
  3108. "summary": "Get a single commit from a repository",
  3109. "operationId": "repoGetSingleCommit",
  3110. "parameters": [
  3111. {
  3112. "type": "string",
  3113. "description": "owner of the repo",
  3114. "name": "owner",
  3115. "in": "path",
  3116. "required": true
  3117. },
  3118. {
  3119. "type": "string",
  3120. "description": "name of the repo",
  3121. "name": "repo",
  3122. "in": "path",
  3123. "required": true
  3124. },
  3125. {
  3126. "type": "string",
  3127. "description": "a git ref or commit sha",
  3128. "name": "sha",
  3129. "in": "path",
  3130. "required": true
  3131. }
  3132. ],
  3133. "responses": {
  3134. "200": {
  3135. "$ref": "#/responses/Commit"
  3136. },
  3137. "404": {
  3138. "$ref": "#/responses/notFound"
  3139. },
  3140. "422": {
  3141. "$ref": "#/responses/validationError"
  3142. }
  3143. }
  3144. }
  3145. },
  3146. "/repos/{owner}/{repo}/git/refs": {
  3147. "get": {
  3148. "produces": [
  3149. "application/json"
  3150. ],
  3151. "tags": [
  3152. "repository"
  3153. ],
  3154. "summary": "Get specified ref or filtered repository's refs",
  3155. "operationId": "repoListAllGitRefs",
  3156. "parameters": [
  3157. {
  3158. "type": "string",
  3159. "description": "owner of the repo",
  3160. "name": "owner",
  3161. "in": "path",
  3162. "required": true
  3163. },
  3164. {
  3165. "type": "string",
  3166. "description": "name of the repo",
  3167. "name": "repo",
  3168. "in": "path",
  3169. "required": true
  3170. }
  3171. ],
  3172. "responses": {
  3173. "200": {
  3174. "$ref": "#/responses/ReferenceList"
  3175. },
  3176. "404": {
  3177. "$ref": "#/responses/notFound"
  3178. }
  3179. }
  3180. }
  3181. },
  3182. "/repos/{owner}/{repo}/git/refs/{ref}": {
  3183. "get": {
  3184. "produces": [
  3185. "application/json"
  3186. ],
  3187. "tags": [
  3188. "repository"
  3189. ],
  3190. "summary": "Get specified ref or filtered repository's refs",
  3191. "operationId": "repoListGitRefs",
  3192. "parameters": [
  3193. {
  3194. "type": "string",
  3195. "description": "owner of the repo",
  3196. "name": "owner",
  3197. "in": "path",
  3198. "required": true
  3199. },
  3200. {
  3201. "type": "string",
  3202. "description": "name of the repo",
  3203. "name": "repo",
  3204. "in": "path",
  3205. "required": true
  3206. },
  3207. {
  3208. "type": "string",
  3209. "description": "part or full name of the ref",
  3210. "name": "ref",
  3211. "in": "path",
  3212. "required": true
  3213. }
  3214. ],
  3215. "responses": {
  3216. "200": {
  3217. "$ref": "#/responses/ReferenceList"
  3218. },
  3219. "404": {
  3220. "$ref": "#/responses/notFound"
  3221. }
  3222. }
  3223. }
  3224. },
  3225. "/repos/{owner}/{repo}/git/tags/{sha}": {
  3226. "get": {
  3227. "produces": [
  3228. "application/json"
  3229. ],
  3230. "tags": [
  3231. "repository"
  3232. ],
  3233. "summary": "Gets the tag object of an annotated tag (not lightweight tags)",
  3234. "operationId": "GetTag",
  3235. "parameters": [
  3236. {
  3237. "type": "string",
  3238. "description": "owner of the repo",
  3239. "name": "owner",
  3240. "in": "path",
  3241. "required": true
  3242. },
  3243. {
  3244. "type": "string",
  3245. "description": "name of the repo",
  3246. "name": "repo",
  3247. "in": "path",
  3248. "required": true
  3249. },
  3250. {
  3251. "type": "string",
  3252. "description": "sha of the tag. The Git tags API only supports annotated tag objects, not lightweight tags.",
  3253. "name": "sha",
  3254. "in": "path",
  3255. "required": true
  3256. }
  3257. ],
  3258. "responses": {
  3259. "200": {
  3260. "$ref": "#/responses/AnnotatedTag"
  3261. },
  3262. "400": {
  3263. "$ref": "#/responses/error"
  3264. }
  3265. }
  3266. }
  3267. },
  3268. "/repos/{owner}/{repo}/git/trees/{sha}": {
  3269. "get": {
  3270. "produces": [
  3271. "application/json"
  3272. ],
  3273. "tags": [
  3274. "repository"
  3275. ],
  3276. "summary": "Gets the tree of a repository.",
  3277. "operationId": "GetTree",
  3278. "parameters": [
  3279. {
  3280. "type": "string",
  3281. "description": "owner of the repo",
  3282. "name": "owner",
  3283. "in": "path",
  3284. "required": true
  3285. },
  3286. {
  3287. "type": "string",
  3288. "description": "name of the repo",
  3289. "name": "repo",
  3290. "in": "path",
  3291. "required": true
  3292. },
  3293. {
  3294. "type": "string",
  3295. "description": "sha of the commit",
  3296. "name": "sha",
  3297. "in": "path",
  3298. "required": true
  3299. },
  3300. {
  3301. "type": "boolean",
  3302. "description": "show all directories and files",
  3303. "name": "recursive",
  3304. "in": "query"
  3305. },
  3306. {
  3307. "type": "integer",
  3308. "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",
  3309. "name": "page",
  3310. "in": "query"
  3311. },
  3312. {
  3313. "type": "integer",
  3314. "description": "number of items per page; default is 1000 or what is set in app.ini as DEFAULT_GIT_TREES_PER_PAGE",
  3315. "name": "per_page",
  3316. "in": "query"
  3317. }
  3318. ],
  3319. "responses": {
  3320. "200": {
  3321. "$ref": "#/responses/GitTreeResponse"
  3322. },
  3323. "400": {
  3324. "$ref": "#/responses/error"
  3325. }
  3326. }
  3327. }
  3328. },
  3329. "/repos/{owner}/{repo}/hooks": {
  3330. "get": {
  3331. "produces": [
  3332. "application/json"
  3333. ],
  3334. "tags": [
  3335. "repository"
  3336. ],
  3337. "summary": "List the hooks in a repository",
  3338. "operationId": "repoListHooks",
  3339. "parameters": [
  3340. {
  3341. "type": "string",
  3342. "description": "owner of the repo",
  3343. "name": "owner",
  3344. "in": "path",
  3345. "required": true
  3346. },
  3347. {
  3348. "type": "string",
  3349. "description": "name of the repo",
  3350. "name": "repo",
  3351. "in": "path",
  3352. "required": true
  3353. },
  3354. {
  3355. "type": "integer",
  3356. "description": "page number of results to return (1-based)",
  3357. "name": "page",
  3358. "in": "query"
  3359. },
  3360. {
  3361. "type": "integer",
  3362. "description": "page size of results, maximum page size is 50",
  3363. "name": "limit",
  3364. "in": "query"
  3365. }
  3366. ],
  3367. "responses": {
  3368. "200": {
  3369. "$ref": "#/responses/HookList"
  3370. }
  3371. }
  3372. },
  3373. "post": {
  3374. "consumes": [
  3375. "application/json"
  3376. ],
  3377. "produces": [
  3378. "application/json"
  3379. ],
  3380. "tags": [
  3381. "repository"
  3382. ],
  3383. "summary": "Create a hook",
  3384. "operationId": "repoCreateHook",
  3385. "parameters": [
  3386. {
  3387. "type": "string",
  3388. "description": "owner of the repo",
  3389. "name": "owner",
  3390. "in": "path",
  3391. "required": true
  3392. },
  3393. {
  3394. "type": "string",
  3395. "description": "name of the repo",
  3396. "name": "repo",
  3397. "in": "path",
  3398. "required": true
  3399. },
  3400. {
  3401. "name": "body",
  3402. "in": "body",
  3403. "schema": {
  3404. "$ref": "#/definitions/CreateHookOption"
  3405. }
  3406. }
  3407. ],
  3408. "responses": {
  3409. "201": {
  3410. "$ref": "#/responses/Hook"
  3411. }
  3412. }
  3413. }
  3414. },
  3415. "/repos/{owner}/{repo}/hooks/git": {
  3416. "get": {
  3417. "produces": [
  3418. "application/json"
  3419. ],
  3420. "tags": [
  3421. "repository"
  3422. ],
  3423. "summary": "List the Git hooks in a repository",
  3424. "operationId": "repoListGitHooks",
  3425. "parameters": [
  3426. {
  3427. "type": "string",
  3428. "description": "owner of the repo",
  3429. "name": "owner",
  3430. "in": "path",
  3431. "required": true
  3432. },
  3433. {
  3434. "type": "string",
  3435. "description": "name of the repo",
  3436. "name": "repo",
  3437. "in": "path",
  3438. "required": true
  3439. }
  3440. ],
  3441. "responses": {
  3442. "200": {
  3443. "$ref": "#/responses/GitHookList"
  3444. }
  3445. }
  3446. }
  3447. },
  3448. "/repos/{owner}/{repo}/hooks/git/{id}": {
  3449. "get": {
  3450. "produces": [
  3451. "application/json"
  3452. ],
  3453. "tags": [
  3454. "repository"
  3455. ],
  3456. "summary": "Get a Git hook",
  3457. "operationId": "repoGetGitHook",
  3458. "parameters": [
  3459. {
  3460. "type": "string",
  3461. "description": "owner of the repo",
  3462. "name": "owner",
  3463. "in": "path",
  3464. "required": true
  3465. },
  3466. {
  3467. "type": "string",
  3468. "description": "name of the repo",
  3469. "name": "repo",
  3470. "in": "path",
  3471. "required": true
  3472. },
  3473. {
  3474. "type": "string",
  3475. "description": "id of the hook to get",
  3476. "name": "id",
  3477. "in": "path",
  3478. "required": true
  3479. }
  3480. ],
  3481. "responses": {
  3482. "200": {
  3483. "$ref": "#/responses/GitHook"
  3484. },
  3485. "404": {
  3486. "$ref": "#/responses/notFound"
  3487. }
  3488. }
  3489. },
  3490. "delete": {
  3491. "produces": [
  3492. "application/json"
  3493. ],
  3494. "tags": [
  3495. "repository"
  3496. ],
  3497. "summary": "Delete a Git hook in a repository",
  3498. "operationId": "repoDeleteGitHook",
  3499. "parameters": [
  3500. {
  3501. "type": "string",
  3502. "description": "owner of the repo",
  3503. "name": "owner",
  3504. "in": "path",
  3505. "required": true
  3506. },
  3507. {
  3508. "type": "string",
  3509. "description": "name of the repo",
  3510. "name": "repo",
  3511. "in": "path",
  3512. "required": true
  3513. },
  3514. {
  3515. "type": "string",
  3516. "description": "id of the hook to get",
  3517. "name": "id",
  3518. "in": "path",
  3519. "required": true
  3520. }
  3521. ],
  3522. "responses": {
  3523. "204": {
  3524. "$ref": "#/responses/empty"
  3525. },
  3526. "404": {
  3527. "$ref": "#/responses/notFound"
  3528. }
  3529. }
  3530. },
  3531. "patch": {
  3532. "produces": [
  3533. "application/json"
  3534. ],
  3535. "tags": [
  3536. "repository"
  3537. ],
  3538. "summary": "Edit a Git hook in a repository",
  3539. "operationId": "repoEditGitHook",
  3540. "parameters": [
  3541. {
  3542. "type": "string",
  3543. "description": "owner of the repo",
  3544. "name": "owner",
  3545. "in": "path",
  3546. "required": true
  3547. },
  3548. {
  3549. "type": "string",
  3550. "description": "name of the repo",
  3551. "name": "repo",
  3552. "in": "path",
  3553. "required": true
  3554. },
  3555. {
  3556. "type": "string",
  3557. "description": "id of the hook to get",
  3558. "name": "id",
  3559. "in": "path",
  3560. "required": true
  3561. },
  3562. {
  3563. "name": "body",
  3564. "in": "body",
  3565. "schema": {
  3566. "$ref": "#/definitions/EditGitHookOption"
  3567. }
  3568. }
  3569. ],
  3570. "responses": {
  3571. "200": {
  3572. "$ref": "#/responses/GitHook"
  3573. },
  3574. "404": {
  3575. "$ref": "#/responses/notFound"
  3576. }
  3577. }
  3578. }
  3579. },
  3580. "/repos/{owner}/{repo}/hooks/{id}": {
  3581. "get": {
  3582. "produces": [
  3583. "application/json"
  3584. ],
  3585. "tags": [
  3586. "repository"
  3587. ],
  3588. "summary": "Get a hook",
  3589. "operationId": "repoGetHook",
  3590. "parameters": [
  3591. {
  3592. "type": "string",
  3593. "description": "owner of the repo",
  3594. "name": "owner",
  3595. "in": "path",
  3596. "required": true
  3597. },
  3598. {
  3599. "type": "string",
  3600. "description": "name of the repo",
  3601. "name": "repo",
  3602. "in": "path",
  3603. "required": true
  3604. },
  3605. {
  3606. "type": "integer",
  3607. "format": "int64",
  3608. "description": "id of the hook to get",
  3609. "name": "id",
  3610. "in": "path",
  3611. "required": true
  3612. }
  3613. ],
  3614. "responses": {
  3615. "200": {
  3616. "$ref": "#/responses/Hook"
  3617. },
  3618. "404": {
  3619. "$ref": "#/responses/notFound"
  3620. }
  3621. }
  3622. },
  3623. "delete": {
  3624. "produces": [
  3625. "application/json"
  3626. ],
  3627. "tags": [
  3628. "repository"
  3629. ],
  3630. "summary": "Delete a hook in a repository",
  3631. "operationId": "repoDeleteHook",
  3632. "parameters": [
  3633. {
  3634. "type": "string",
  3635. "description": "owner of the repo",
  3636. "name": "owner",
  3637. "in": "path",
  3638. "required": true
  3639. },
  3640. {
  3641. "type": "string",
  3642. "description": "name of the repo",
  3643. "name": "repo",
  3644. "in": "path",
  3645. "required": true
  3646. },
  3647. {
  3648. "type": "integer",
  3649. "format": "int64",
  3650. "description": "id of the hook to delete",
  3651. "name": "id",
  3652. "in": "path",
  3653. "required": true
  3654. }
  3655. ],
  3656. "responses": {
  3657. "204": {
  3658. "$ref": "#/responses/empty"
  3659. },
  3660. "404": {
  3661. "$ref": "#/responses/notFound"
  3662. }
  3663. }
  3664. },
  3665. "patch": {
  3666. "produces": [
  3667. "application/json"
  3668. ],
  3669. "tags": [
  3670. "repository"
  3671. ],
  3672. "summary": "Edit a hook in a repository",
  3673. "operationId": "repoEditHook",
  3674. "parameters": [
  3675. {
  3676. "type": "string",
  3677. "description": "owner of the repo",
  3678. "name": "owner",
  3679. "in": "path",
  3680. "required": true
  3681. },
  3682. {
  3683. "type": "string",
  3684. "description": "name of the repo",
  3685. "name": "repo",
  3686. "in": "path",
  3687. "required": true
  3688. },
  3689. {
  3690. "type": "integer",
  3691. "format": "int64",
  3692. "description": "index of the hook",
  3693. "name": "id",
  3694. "in": "path",
  3695. "required": true
  3696. },
  3697. {
  3698. "name": "body",
  3699. "in": "body",
  3700. "schema": {
  3701. "$ref": "#/definitions/EditHookOption"
  3702. }
  3703. }
  3704. ],
  3705. "responses": {
  3706. "200": {
  3707. "$ref": "#/responses/Hook"
  3708. }
  3709. }
  3710. }
  3711. },
  3712. "/repos/{owner}/{repo}/hooks/{id}/tests": {
  3713. "post": {
  3714. "produces": [
  3715. "application/json"
  3716. ],
  3717. "tags": [
  3718. "repository"
  3719. ],
  3720. "summary": "Test a push webhook",
  3721. "operationId": "repoTestHook",
  3722. "parameters": [
  3723. {
  3724. "type": "string",
  3725. "description": "owner of the repo",
  3726. "name": "owner",
  3727. "in": "path",
  3728. "required": true
  3729. },
  3730. {
  3731. "type": "string",
  3732. "description": "name of the repo",
  3733. "name": "repo",
  3734. "in": "path",
  3735. "required": true
  3736. },
  3737. {
  3738. "type": "integer",
  3739. "format": "int64",
  3740. "description": "id of the hook to test",
  3741. "name": "id",
  3742. "in": "path",
  3743. "required": true
  3744. }
  3745. ],
  3746. "responses": {
  3747. "204": {
  3748. "$ref": "#/responses/empty"
  3749. }
  3750. }
  3751. }
  3752. },
  3753. "/repos/{owner}/{repo}/issues": {
  3754. "get": {
  3755. "produces": [
  3756. "application/json"
  3757. ],
  3758. "tags": [
  3759. "issue"
  3760. ],
  3761. "summary": "List a repository's issues",
  3762. "operationId": "issueListIssues",
  3763. "parameters": [
  3764. {
  3765. "type": "string",
  3766. "description": "owner of the repo",
  3767. "name": "owner",
  3768. "in": "path",
  3769. "required": true
  3770. },
  3771. {
  3772. "type": "string",
  3773. "description": "name of the repo",
  3774. "name": "repo",
  3775. "in": "path",
  3776. "required": true
  3777. },
  3778. {
  3779. "type": "string",
  3780. "description": "whether issue is open or closed",
  3781. "name": "state",
  3782. "in": "query"
  3783. },
  3784. {
  3785. "type": "string",
  3786. "description": "comma separated list of labels. Fetch only issues that have any of this labels. Non existent labels are discarded",
  3787. "name": "labels",
  3788. "in": "query"
  3789. },
  3790. {
  3791. "type": "string",
  3792. "description": "search string",
  3793. "name": "q",
  3794. "in": "query"
  3795. },
  3796. {
  3797. "type": "string",
  3798. "description": "filter by type (issues / pulls) if set",
  3799. "name": "type",
  3800. "in": "query"
  3801. },
  3802. {
  3803. "type": "string",
  3804. "description": "comma separated list of milestone names or ids. It uses names and fall back to ids. Fetch only issues that have any of this milestones. Non existent milestones are discarded",
  3805. "name": "milestones",
  3806. "in": "query"
  3807. },
  3808. {
  3809. "type": "integer",
  3810. "description": "page number of results to return (1-based)",
  3811. "name": "page",
  3812. "in": "query"
  3813. },
  3814. {
  3815. "type": "integer",
  3816. "description": "page size of results, maximum page size is 50",
  3817. "name": "limit",
  3818. "in": "query"
  3819. }
  3820. ],
  3821. "responses": {
  3822. "200": {
  3823. "$ref": "#/responses/IssueList"
  3824. }
  3825. }
  3826. },
  3827. "post": {
  3828. "consumes": [
  3829. "application/json"
  3830. ],
  3831. "produces": [
  3832. "application/json"
  3833. ],
  3834. "tags": [
  3835. "issue"
  3836. ],
  3837. "summary": "Create an issue. If using deadline only the date will be taken into account, and time of day ignored.",
  3838. "operationId": "issueCreateIssue",
  3839. "parameters": [
  3840. {
  3841. "type": "string",
  3842. "description": "owner of the repo",
  3843. "name": "owner",
  3844. "in": "path",
  3845. "required": true
  3846. },
  3847. {
  3848. "type": "string",
  3849. "description": "name of the repo",
  3850. "name": "repo",
  3851. "in": "path",
  3852. "required": true
  3853. },
  3854. {
  3855. "name": "body",
  3856. "in": "body",
  3857. "schema": {
  3858. "$ref": "#/definitions/CreateIssueOption"
  3859. }
  3860. }
  3861. ],
  3862. "responses": {
  3863. "201": {
  3864. "$ref": "#/responses/Issue"
  3865. },
  3866. "403": {
  3867. "$ref": "#/responses/forbidden"
  3868. },
  3869. "412": {
  3870. "$ref": "#/responses/error"
  3871. },
  3872. "422": {
  3873. "$ref": "#/responses/validationError"
  3874. }
  3875. }
  3876. }
  3877. },
  3878. "/repos/{owner}/{repo}/issues/comments": {
  3879. "get": {
  3880. "produces": [
  3881. "application/json"
  3882. ],
  3883. "tags": [
  3884. "issue"
  3885. ],
  3886. "summary": "List all comments in a repository",
  3887. "operationId": "issueGetRepoComments",
  3888. "parameters": [
  3889. {
  3890. "type": "string",
  3891. "description": "owner of the repo",
  3892. "name": "owner",
  3893. "in": "path",
  3894. "required": true
  3895. },
  3896. {
  3897. "type": "string",
  3898. "description": "name of the repo",
  3899. "name": "repo",
  3900. "in": "path",
  3901. "required": true
  3902. },
  3903. {
  3904. "type": "string",
  3905. "format": "date-time",
  3906. "description": "if provided, only comments updated since the provided time are returned.",
  3907. "name": "since",
  3908. "in": "query"
  3909. },
  3910. {
  3911. "type": "string",
  3912. "format": "date-time",
  3913. "description": "if provided, only comments updated before the provided time are returned.",
  3914. "name": "before",
  3915. "in": "query"
  3916. },
  3917. {
  3918. "type": "integer",
  3919. "description": "page number of results to return (1-based)",
  3920. "name": "page",
  3921. "in": "query"
  3922. },
  3923. {
  3924. "type": "integer",
  3925. "description": "page size of results, maximum page size is 50",
  3926. "name": "limit",
  3927. "in": "query"
  3928. }
  3929. ],
  3930. "responses": {
  3931. "200": {
  3932. "$ref": "#/responses/CommentList"
  3933. }
  3934. }
  3935. }
  3936. },
  3937. "/repos/{owner}/{repo}/issues/comments/{id}": {
  3938. "get": {
  3939. "consumes": [
  3940. "application/json"
  3941. ],
  3942. "produces": [
  3943. "application/json"
  3944. ],
  3945. "tags": [
  3946. "issue"
  3947. ],
  3948. "summary": "Get a comment",
  3949. "operationId": "issueGetComment",
  3950. "parameters": [
  3951. {
  3952. "type": "string",
  3953. "description": "owner of the repo",
  3954. "name": "owner",
  3955. "in": "path",
  3956. "required": true
  3957. },
  3958. {
  3959. "type": "string",
  3960. "description": "name of the repo",
  3961. "name": "repo",
  3962. "in": "path",
  3963. "required": true
  3964. },
  3965. {
  3966. "type": "integer",
  3967. "format": "int64",
  3968. "description": "id of the comment",
  3969. "name": "id",
  3970. "in": "path",
  3971. "required": true
  3972. }
  3973. ],
  3974. "responses": {
  3975. "200": {
  3976. "$ref": "#/responses/Comment"
  3977. },
  3978. "204": {
  3979. "$ref": "#/responses/empty"
  3980. },
  3981. "403": {
  3982. "$ref": "#/responses/forbidden"
  3983. },
  3984. "404": {
  3985. "$ref": "#/responses/notFound"
  3986. }
  3987. }
  3988. },
  3989. "delete": {
  3990. "tags": [
  3991. "issue"
  3992. ],
  3993. "summary": "Delete a comment",
  3994. "operationId": "issueDeleteComment",
  3995. "parameters": [
  3996. {
  3997. "type": "string",
  3998. "description": "owner of the repo",
  3999. "name": "owner",
  4000. "in": "path",
  4001. "required": true
  4002. },
  4003. {
  4004. "type": "string",
  4005. "description": "name of the repo",
  4006. "name": "repo",
  4007. "in": "path",
  4008. "required": true
  4009. },
  4010. {
  4011. "type": "integer",
  4012. "format": "int64",
  4013. "description": "id of comment to delete",
  4014. "name": "id",
  4015. "in": "path",
  4016. "required": true
  4017. }
  4018. ],
  4019. "responses": {
  4020. "204": {
  4021. "$ref": "#/responses/empty"
  4022. },
  4023. "403": {
  4024. "$ref": "#/responses/forbidden"
  4025. },
  4026. "404": {
  4027. "$ref": "#/responses/notFound"
  4028. }
  4029. }
  4030. },
  4031. "patch": {
  4032. "consumes": [
  4033. "application/json"
  4034. ],
  4035. "produces": [
  4036. "application/json"
  4037. ],
  4038. "tags": [
  4039. "issue"
  4040. ],
  4041. "summary": "Edit a comment",
  4042. "operationId": "issueEditComment",
  4043. "parameters": [
  4044. {
  4045. "type": "string",
  4046. "description": "owner of the repo",
  4047. "name": "owner",
  4048. "in": "path",
  4049. "required": true
  4050. },
  4051. {
  4052. "type": "string",
  4053. "description": "name of the repo",
  4054. "name": "repo",
  4055. "in": "path",
  4056. "required": true
  4057. },
  4058. {
  4059. "type": "integer",
  4060. "format": "int64",
  4061. "description": "id of the comment to edit",
  4062. "name": "id",
  4063. "in": "path",
  4064. "required": true
  4065. },
  4066. {
  4067. "name": "body",
  4068. "in": "body",
  4069. "schema": {
  4070. "$ref": "#/definitions/EditIssueCommentOption"
  4071. }
  4072. }
  4073. ],
  4074. "responses": {
  4075. "200": {
  4076. "$ref": "#/responses/Comment"
  4077. },
  4078. "204": {
  4079. "$ref": "#/responses/empty"
  4080. },
  4081. "403": {
  4082. "$ref": "#/responses/forbidden"
  4083. },
  4084. "404": {
  4085. "$ref": "#/responses/notFound"
  4086. }
  4087. }
  4088. }
  4089. },
  4090. "/repos/{owner}/{repo}/issues/comments/{id}/reactions": {
  4091. "get": {
  4092. "consumes": [
  4093. "application/json"
  4094. ],
  4095. "produces": [
  4096. "application/json"
  4097. ],
  4098. "tags": [
  4099. "issue"
  4100. ],
  4101. "summary": "Get a list of reactions from a comment of an issue",
  4102. "operationId": "issueGetCommentReactions",
  4103. "parameters": [
  4104. {
  4105. "type": "string",
  4106. "description": "owner of the repo",
  4107. "name": "owner",
  4108. "in": "path",
  4109. "required": true
  4110. },
  4111. {
  4112. "type": "string",
  4113. "description": "name of the repo",
  4114. "name": "repo",
  4115. "in": "path",
  4116. "required": true
  4117. },
  4118. {
  4119. "type": "integer",
  4120. "format": "int64",
  4121. "description": "id of the comment to edit",
  4122. "name": "id",
  4123. "in": "path",
  4124. "required": true
  4125. }
  4126. ],
  4127. "responses": {
  4128. "200": {
  4129. "$ref": "#/responses/ReactionList"
  4130. },
  4131. "403": {
  4132. "$ref": "#/responses/forbidden"
  4133. }
  4134. }
  4135. },
  4136. "post": {
  4137. "consumes": [
  4138. "application/json"
  4139. ],
  4140. "produces": [
  4141. "application/json"
  4142. ],
  4143. "tags": [
  4144. "issue"
  4145. ],
  4146. "summary": "Add a reaction to a comment of an issue",
  4147. "operationId": "issuePostCommentReaction",
  4148. "parameters": [
  4149. {
  4150. "type": "string",
  4151. "description": "owner of the repo",
  4152. "name": "owner",
  4153. "in": "path",
  4154. "required": true
  4155. },
  4156. {
  4157. "type": "string",
  4158. "description": "name of the repo",
  4159. "name": "repo",
  4160. "in": "path",
  4161. "required": true
  4162. },
  4163. {
  4164. "type": "integer",
  4165. "format": "int64",
  4166. "description": "id of the comment to edit",
  4167. "name": "id",
  4168. "in": "path",
  4169. "required": true
  4170. },
  4171. {
  4172. "name": "content",
  4173. "in": "body",
  4174. "schema": {
  4175. "$ref": "#/definitions/EditReactionOption"
  4176. }
  4177. }
  4178. ],
  4179. "responses": {
  4180. "200": {
  4181. "$ref": "#/responses/Reaction"
  4182. },
  4183. "201": {
  4184. "$ref": "#/responses/Reaction"
  4185. },
  4186. "403": {
  4187. "$ref": "#/responses/forbidden"
  4188. }
  4189. }
  4190. },
  4191. "delete": {
  4192. "consumes": [
  4193. "application/json"
  4194. ],
  4195. "produces": [
  4196. "application/json"
  4197. ],
  4198. "tags": [
  4199. "issue"
  4200. ],
  4201. "summary": "Remove a reaction from a comment of an issue",
  4202. "operationId": "issueDeleteCommentReaction",
  4203. "parameters": [
  4204. {
  4205. "type": "string",
  4206. "description": "owner of the repo",
  4207. "name": "owner",
  4208. "in": "path",
  4209. "required": true
  4210. },
  4211. {
  4212. "type": "string",
  4213. "description": "name of the repo",
  4214. "name": "repo",
  4215. "in": "path",
  4216. "required": true
  4217. },
  4218. {
  4219. "type": "integer",
  4220. "format": "int64",
  4221. "description": "id of the comment to edit",
  4222. "name": "id",
  4223. "in": "path",
  4224. "required": true
  4225. },
  4226. {
  4227. "name": "content",
  4228. "in": "body",
  4229. "schema": {
  4230. "$ref": "#/definitions/EditReactionOption"
  4231. }
  4232. }
  4233. ],
  4234. "responses": {
  4235. "200": {
  4236. "$ref": "#/responses/empty"
  4237. },
  4238. "403": {
  4239. "$ref": "#/responses/forbidden"
  4240. }
  4241. }
  4242. }
  4243. },
  4244. "/repos/{owner}/{repo}/issues/{index}": {
  4245. "get": {
  4246. "produces": [
  4247. "application/json"
  4248. ],
  4249. "tags": [
  4250. "issue"
  4251. ],
  4252. "summary": "Get an issue",
  4253. "operationId": "issueGetIssue",
  4254. "parameters": [
  4255. {
  4256. "type": "string",
  4257. "description": "owner of the repo",
  4258. "name": "owner",
  4259. "in": "path",
  4260. "required": true
  4261. },
  4262. {
  4263. "type": "string",
  4264. "description": "name of the repo",
  4265. "name": "repo",
  4266. "in": "path",
  4267. "required": true
  4268. },
  4269. {
  4270. "type": "integer",
  4271. "format": "int64",
  4272. "description": "index of the issue to get",
  4273. "name": "index",
  4274. "in": "path",
  4275. "required": true
  4276. }
  4277. ],
  4278. "responses": {
  4279. "200": {
  4280. "$ref": "#/responses/Issue"
  4281. },
  4282. "404": {
  4283. "$ref": "#/responses/notFound"
  4284. }
  4285. }
  4286. },
  4287. "patch": {
  4288. "consumes": [
  4289. "application/json"
  4290. ],
  4291. "produces": [
  4292. "application/json"
  4293. ],
  4294. "tags": [
  4295. "issue"
  4296. ],
  4297. "summary": "Edit an issue. If using deadline only the date will be taken into account, and time of day ignored.",
  4298. "operationId": "issueEditIssue",
  4299. "parameters": [
  4300. {
  4301. "type": "string",
  4302. "description": "owner of the repo",
  4303. "name": "owner",
  4304. "in": "path",
  4305. "required": true
  4306. },
  4307. {
  4308. "type": "string",
  4309. "description": "name of the repo",
  4310. "name": "repo",
  4311. "in": "path",
  4312. "required": true
  4313. },
  4314. {
  4315. "type": "integer",
  4316. "format": "int64",
  4317. "description": "index of the issue to edit",
  4318. "name": "index",
  4319. "in": "path",
  4320. "required": true
  4321. },
  4322. {
  4323. "name": "body",
  4324. "in": "body",
  4325. "schema": {
  4326. "$ref": "#/definitions/EditIssueOption"
  4327. }
  4328. }
  4329. ],
  4330. "responses": {
  4331. "201": {
  4332. "$ref": "#/responses/Issue"
  4333. },
  4334. "403": {
  4335. "$ref": "#/responses/forbidden"
  4336. },
  4337. "404": {
  4338. "$ref": "#/responses/notFound"
  4339. },
  4340. "412": {
  4341. "$ref": "#/responses/error"
  4342. }
  4343. }
  4344. }
  4345. },
  4346. "/repos/{owner}/{repo}/issues/{index}/comments": {
  4347. "get": {
  4348. "produces": [
  4349. "application/json"
  4350. ],
  4351. "tags": [
  4352. "issue"
  4353. ],
  4354. "summary": "List all comments on an issue",
  4355. "operationId": "issueGetComments",
  4356. "parameters": [
  4357. {
  4358. "type": "string",
  4359. "description": "owner of the repo",
  4360. "name": "owner",
  4361. "in": "path",
  4362. "required": true
  4363. },
  4364. {
  4365. "type": "string",
  4366. "description": "name of the repo",
  4367. "name": "repo",
  4368. "in": "path",
  4369. "required": true
  4370. },
  4371. {
  4372. "type": "integer",
  4373. "format": "int64",
  4374. "description": "index of the issue",
  4375. "name": "index",
  4376. "in": "path",
  4377. "required": true
  4378. },
  4379. {
  4380. "type": "string",
  4381. "format": "date-time",
  4382. "description": "if provided, only comments updated since the specified time are returned.",
  4383. "name": "since",
  4384. "in": "query"
  4385. },
  4386. {
  4387. "type": "string",
  4388. "format": "date-time",
  4389. "description": "if provided, only comments updated before the provided time are returned.",
  4390. "name": "before",
  4391. "in": "query"
  4392. }
  4393. ],
  4394. "responses": {
  4395. "200": {
  4396. "$ref": "#/responses/CommentList"
  4397. }
  4398. }
  4399. },
  4400. "post": {
  4401. "consumes": [
  4402. "application/json"
  4403. ],
  4404. "produces": [
  4405. "application/json"
  4406. ],
  4407. "tags": [
  4408. "issue"
  4409. ],
  4410. "summary": "Add a comment to an issue",
  4411. "operationId": "issueCreateComment",
  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 issue",
  4431. "name": "index",
  4432. "in": "path",
  4433. "required": true
  4434. },
  4435. {
  4436. "name": "body",
  4437. "in": "body",
  4438. "schema": {
  4439. "$ref": "#/definitions/CreateIssueCommentOption"
  4440. }
  4441. }
  4442. ],
  4443. "responses": {
  4444. "201": {
  4445. "$ref": "#/responses/Comment"
  4446. },
  4447. "403": {
  4448. "$ref": "#/responses/forbidden"
  4449. }
  4450. }
  4451. }
  4452. },
  4453. "/repos/{owner}/{repo}/issues/{index}/comments/{id}": {
  4454. "delete": {
  4455. "tags": [
  4456. "issue"
  4457. ],
  4458. "summary": "Delete a comment",
  4459. "operationId": "issueDeleteCommentDeprecated",
  4460. "deprecated": true,
  4461. "parameters": [
  4462. {
  4463. "type": "string",
  4464. "description": "owner of the repo",
  4465. "name": "owner",
  4466. "in": "path",
  4467. "required": true
  4468. },
  4469. {
  4470. "type": "string",
  4471. "description": "name of the repo",
  4472. "name": "repo",
  4473. "in": "path",
  4474. "required": true
  4475. },
  4476. {
  4477. "type": "integer",
  4478. "description": "this parameter is ignored",
  4479. "name": "index",
  4480. "in": "path",
  4481. "required": true
  4482. },
  4483. {
  4484. "type": "integer",
  4485. "format": "int64",
  4486. "description": "id of comment to delete",
  4487. "name": "id",
  4488. "in": "path",
  4489. "required": true
  4490. }
  4491. ],
  4492. "responses": {
  4493. "204": {
  4494. "$ref": "#/responses/empty"
  4495. },
  4496. "403": {
  4497. "$ref": "#/responses/forbidden"
  4498. },
  4499. "404": {
  4500. "$ref": "#/responses/notFound"
  4501. }
  4502. }
  4503. },
  4504. "patch": {
  4505. "consumes": [
  4506. "application/json"
  4507. ],
  4508. "produces": [
  4509. "application/json"
  4510. ],
  4511. "tags": [
  4512. "issue"
  4513. ],
  4514. "summary": "Edit a comment",
  4515. "operationId": "issueEditCommentDeprecated",
  4516. "deprecated": true,
  4517. "parameters": [
  4518. {
  4519. "type": "string",
  4520. "description": "owner of the repo",
  4521. "name": "owner",
  4522. "in": "path",
  4523. "required": true
  4524. },
  4525. {
  4526. "type": "string",
  4527. "description": "name of the repo",
  4528. "name": "repo",
  4529. "in": "path",
  4530. "required": true
  4531. },
  4532. {
  4533. "type": "integer",
  4534. "description": "this parameter is ignored",
  4535. "name": "index",
  4536. "in": "path",
  4537. "required": true
  4538. },
  4539. {
  4540. "type": "integer",
  4541. "format": "int64",
  4542. "description": "id of the comment to edit",
  4543. "name": "id",
  4544. "in": "path",
  4545. "required": true
  4546. },
  4547. {
  4548. "name": "body",
  4549. "in": "body",
  4550. "schema": {
  4551. "$ref": "#/definitions/EditIssueCommentOption"
  4552. }
  4553. }
  4554. ],
  4555. "responses": {
  4556. "200": {
  4557. "$ref": "#/responses/Comment"
  4558. },
  4559. "204": {
  4560. "$ref": "#/responses/empty"
  4561. },
  4562. "403": {
  4563. "$ref": "#/responses/forbidden"
  4564. },
  4565. "404": {
  4566. "$ref": "#/responses/notFound"
  4567. }
  4568. }
  4569. }
  4570. },
  4571. "/repos/{owner}/{repo}/issues/{index}/deadline": {
  4572. "post": {
  4573. "consumes": [
  4574. "application/json"
  4575. ],
  4576. "produces": [
  4577. "application/json"
  4578. ],
  4579. "tags": [
  4580. "issue"
  4581. ],
  4582. "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.",
  4583. "operationId": "issueEditIssueDeadline",
  4584. "parameters": [
  4585. {
  4586. "type": "string",
  4587. "description": "owner of the repo",
  4588. "name": "owner",
  4589. "in": "path",
  4590. "required": true
  4591. },
  4592. {
  4593. "type": "string",
  4594. "description": "name of the repo",
  4595. "name": "repo",
  4596. "in": "path",
  4597. "required": true
  4598. },
  4599. {
  4600. "type": "integer",
  4601. "format": "int64",
  4602. "description": "index of the issue to create or update a deadline on",
  4603. "name": "index",
  4604. "in": "path",
  4605. "required": true
  4606. },
  4607. {
  4608. "name": "body",
  4609. "in": "body",
  4610. "schema": {
  4611. "$ref": "#/definitions/EditDeadlineOption"
  4612. }
  4613. }
  4614. ],
  4615. "responses": {
  4616. "201": {
  4617. "$ref": "#/responses/IssueDeadline"
  4618. },
  4619. "403": {
  4620. "$ref": "#/responses/forbidden"
  4621. },
  4622. "404": {
  4623. "$ref": "#/responses/notFound"
  4624. }
  4625. }
  4626. }
  4627. },
  4628. "/repos/{owner}/{repo}/issues/{index}/labels": {
  4629. "get": {
  4630. "produces": [
  4631. "application/json"
  4632. ],
  4633. "tags": [
  4634. "issue"
  4635. ],
  4636. "summary": "Get an issue's labels",
  4637. "operationId": "issueGetLabels",
  4638. "parameters": [
  4639. {
  4640. "type": "string",
  4641. "description": "owner of the repo",
  4642. "name": "owner",
  4643. "in": "path",
  4644. "required": true
  4645. },
  4646. {
  4647. "type": "string",
  4648. "description": "name of the repo",
  4649. "name": "repo",
  4650. "in": "path",
  4651. "required": true
  4652. },
  4653. {
  4654. "type": "integer",
  4655. "format": "int64",
  4656. "description": "index of the issue",
  4657. "name": "index",
  4658. "in": "path",
  4659. "required": true
  4660. }
  4661. ],
  4662. "responses": {
  4663. "200": {
  4664. "$ref": "#/responses/LabelList"
  4665. },
  4666. "404": {
  4667. "$ref": "#/responses/notFound"
  4668. }
  4669. }
  4670. },
  4671. "put": {
  4672. "consumes": [
  4673. "application/json"
  4674. ],
  4675. "produces": [
  4676. "application/json"
  4677. ],
  4678. "tags": [
  4679. "issue"
  4680. ],
  4681. "summary": "Replace an issue's labels",
  4682. "operationId": "issueReplaceLabels",
  4683. "parameters": [
  4684. {
  4685. "type": "string",
  4686. "description": "owner of the repo",
  4687. "name": "owner",
  4688. "in": "path",
  4689. "required": true
  4690. },
  4691. {
  4692. "type": "string",
  4693. "description": "name of the repo",
  4694. "name": "repo",
  4695. "in": "path",
  4696. "required": true
  4697. },
  4698. {
  4699. "type": "integer",
  4700. "format": "int64",
  4701. "description": "index of the issue",
  4702. "name": "index",
  4703. "in": "path",
  4704. "required": true
  4705. },
  4706. {
  4707. "name": "body",
  4708. "in": "body",
  4709. "schema": {
  4710. "$ref": "#/definitions/IssueLabelsOption"
  4711. }
  4712. }
  4713. ],
  4714. "responses": {
  4715. "200": {
  4716. "$ref": "#/responses/LabelList"
  4717. },
  4718. "403": {
  4719. "$ref": "#/responses/forbidden"
  4720. }
  4721. }
  4722. },
  4723. "post": {
  4724. "consumes": [
  4725. "application/json"
  4726. ],
  4727. "produces": [
  4728. "application/json"
  4729. ],
  4730. "tags": [
  4731. "issue"
  4732. ],
  4733. "summary": "Add a label to an issue",
  4734. "operationId": "issueAddLabel",
  4735. "parameters": [
  4736. {
  4737. "type": "string",
  4738. "description": "owner of the repo",
  4739. "name": "owner",
  4740. "in": "path",
  4741. "required": true
  4742. },
  4743. {
  4744. "type": "string",
  4745. "description": "name of the repo",
  4746. "name": "repo",
  4747. "in": "path",
  4748. "required": true
  4749. },
  4750. {
  4751. "type": "integer",
  4752. "format": "int64",
  4753. "description": "index of the issue",
  4754. "name": "index",
  4755. "in": "path",
  4756. "required": true
  4757. },
  4758. {
  4759. "name": "body",
  4760. "in": "body",
  4761. "schema": {
  4762. "$ref": "#/definitions/IssueLabelsOption"
  4763. }
  4764. }
  4765. ],
  4766. "responses": {
  4767. "200": {
  4768. "$ref": "#/responses/LabelList"
  4769. },
  4770. "403": {
  4771. "$ref": "#/responses/forbidden"
  4772. }
  4773. }
  4774. },
  4775. "delete": {
  4776. "produces": [
  4777. "application/json"
  4778. ],
  4779. "tags": [
  4780. "issue"
  4781. ],
  4782. "summary": "Remove all labels from an issue",
  4783. "operationId": "issueClearLabels",
  4784. "parameters": [
  4785. {
  4786. "type": "string",
  4787. "description": "owner of the repo",
  4788. "name": "owner",
  4789. "in": "path",
  4790. "required": true
  4791. },
  4792. {
  4793. "type": "string",
  4794. "description": "name of the repo",
  4795. "name": "repo",
  4796. "in": "path",
  4797. "required": true
  4798. },
  4799. {
  4800. "type": "integer",
  4801. "format": "int64",
  4802. "description": "index of the issue",
  4803. "name": "index",
  4804. "in": "path",
  4805. "required": true
  4806. }
  4807. ],
  4808. "responses": {
  4809. "204": {
  4810. "$ref": "#/responses/empty"
  4811. },
  4812. "403": {
  4813. "$ref": "#/responses/forbidden"
  4814. }
  4815. }
  4816. }
  4817. },
  4818. "/repos/{owner}/{repo}/issues/{index}/labels/{id}": {
  4819. "delete": {
  4820. "produces": [
  4821. "application/json"
  4822. ],
  4823. "tags": [
  4824. "issue"
  4825. ],
  4826. "summary": "Remove a label from an issue",
  4827. "operationId": "issueRemoveLabel",
  4828. "parameters": [
  4829. {
  4830. "type": "string",
  4831. "description": "owner of the repo",
  4832. "name": "owner",
  4833. "in": "path",
  4834. "required": true
  4835. },
  4836. {
  4837. "type": "string",
  4838. "description": "name of the repo",
  4839. "name": "repo",
  4840. "in": "path",
  4841. "required": true
  4842. },
  4843. {
  4844. "type": "integer",
  4845. "format": "int64",
  4846. "description": "index of the issue",
  4847. "name": "index",
  4848. "in": "path",
  4849. "required": true
  4850. },
  4851. {
  4852. "type": "integer",
  4853. "format": "int64",
  4854. "description": "id of the label to remove",
  4855. "name": "id",
  4856. "in": "path",
  4857. "required": true
  4858. }
  4859. ],
  4860. "responses": {
  4861. "204": {
  4862. "$ref": "#/responses/empty"
  4863. },
  4864. "403": {
  4865. "$ref": "#/responses/forbidden"
  4866. },
  4867. "422": {
  4868. "$ref": "#/responses/validationError"
  4869. }
  4870. }
  4871. }
  4872. },
  4873. "/repos/{owner}/{repo}/issues/{index}/reactions": {
  4874. "get": {
  4875. "consumes": [
  4876. "application/json"
  4877. ],
  4878. "produces": [
  4879. "application/json"
  4880. ],
  4881. "tags": [
  4882. "issue"
  4883. ],
  4884. "summary": "Get a list reactions of an issue",
  4885. "operationId": "issueGetIssueReactions",
  4886. "parameters": [
  4887. {
  4888. "type": "string",
  4889. "description": "owner of the repo",
  4890. "name": "owner",
  4891. "in": "path",
  4892. "required": true
  4893. },
  4894. {
  4895. "type": "string",
  4896. "description": "name of the repo",
  4897. "name": "repo",
  4898. "in": "path",
  4899. "required": true
  4900. },
  4901. {
  4902. "type": "integer",
  4903. "format": "int64",
  4904. "description": "index of the issue",
  4905. "name": "index",
  4906. "in": "path",
  4907. "required": true
  4908. },
  4909. {
  4910. "type": "integer",
  4911. "description": "page number of results to return (1-based)",
  4912. "name": "page",
  4913. "in": "query"
  4914. },
  4915. {
  4916. "type": "integer",
  4917. "description": "page size of results, maximum page size is 50",
  4918. "name": "limit",
  4919. "in": "query"
  4920. }
  4921. ],
  4922. "responses": {
  4923. "200": {
  4924. "$ref": "#/responses/ReactionList"
  4925. },
  4926. "403": {
  4927. "$ref": "#/responses/forbidden"
  4928. }
  4929. }
  4930. },
  4931. "post": {
  4932. "consumes": [
  4933. "application/json"
  4934. ],
  4935. "produces": [
  4936. "application/json"
  4937. ],
  4938. "tags": [
  4939. "issue"
  4940. ],
  4941. "summary": "Add a reaction to an issue",
  4942. "operationId": "issuePostIssueReaction",
  4943. "parameters": [
  4944. {
  4945. "type": "string",
  4946. "description": "owner of the repo",
  4947. "name": "owner",
  4948. "in": "path",
  4949. "required": true
  4950. },
  4951. {
  4952. "type": "string",
  4953. "description": "name of the repo",
  4954. "name": "repo",
  4955. "in": "path",
  4956. "required": true
  4957. },
  4958. {
  4959. "type": "integer",
  4960. "format": "int64",
  4961. "description": "index of the issue",
  4962. "name": "index",
  4963. "in": "path",
  4964. "required": true
  4965. },
  4966. {
  4967. "name": "content",
  4968. "in": "body",
  4969. "schema": {
  4970. "$ref": "#/definitions/EditReactionOption"
  4971. }
  4972. }
  4973. ],
  4974. "responses": {
  4975. "200": {
  4976. "$ref": "#/responses/Reaction"
  4977. },
  4978. "201": {
  4979. "$ref": "#/responses/Reaction"
  4980. },
  4981. "403": {
  4982. "$ref": "#/responses/forbidden"
  4983. }
  4984. }
  4985. },
  4986. "delete": {
  4987. "consumes": [
  4988. "application/json"
  4989. ],
  4990. "produces": [
  4991. "application/json"
  4992. ],
  4993. "tags": [
  4994. "issue"
  4995. ],
  4996. "summary": "Remove a reaction from an issue",
  4997. "operationId": "issueDeleteIssueReaction",
  4998. "parameters": [
  4999. {
  5000. "type": "string",
  5001. "description": "owner of the repo",
  5002. "name": "owner",
  5003. "in": "path",
  5004. "required": true
  5005. },
  5006. {
  5007. "type": "string",
  5008. "description": "name of the repo",
  5009. "name": "repo",
  5010. "in": "path",
  5011. "required": true
  5012. },
  5013. {
  5014. "type": "integer",
  5015. "format": "int64",
  5016. "description": "index of the issue",
  5017. "name": "index",
  5018. "in": "path",
  5019. "required": true
  5020. },
  5021. {
  5022. "name": "content",
  5023. "in": "body",
  5024. "schema": {
  5025. "$ref": "#/definitions/EditReactionOption"
  5026. }
  5027. }
  5028. ],
  5029. "responses": {
  5030. "200": {
  5031. "$ref": "#/responses/empty"
  5032. },
  5033. "403": {
  5034. "$ref": "#/responses/forbidden"
  5035. }
  5036. }
  5037. }
  5038. },
  5039. "/repos/{owner}/{repo}/issues/{index}/stopwatch/delete": {
  5040. "delete": {
  5041. "consumes": [
  5042. "application/json"
  5043. ],
  5044. "produces": [
  5045. "application/json"
  5046. ],
  5047. "tags": [
  5048. "issue"
  5049. ],
  5050. "summary": "Delete an issue's existing stopwatch.",
  5051. "operationId": "issueDeleteStopWatch",
  5052. "parameters": [
  5053. {
  5054. "type": "string",
  5055. "description": "owner of the repo",
  5056. "name": "owner",
  5057. "in": "path",
  5058. "required": true
  5059. },
  5060. {
  5061. "type": "string",
  5062. "description": "name of the repo",
  5063. "name": "repo",
  5064. "in": "path",
  5065. "required": true
  5066. },
  5067. {
  5068. "type": "integer",
  5069. "format": "int64",
  5070. "description": "index of the issue to stop the stopwatch on",
  5071. "name": "index",
  5072. "in": "path",
  5073. "required": true
  5074. }
  5075. ],
  5076. "responses": {
  5077. "204": {
  5078. "$ref": "#/responses/empty"
  5079. },
  5080. "403": {
  5081. "description": "Not repo writer, user does not have rights to toggle stopwatch"
  5082. },
  5083. "404": {
  5084. "$ref": "#/responses/notFound"
  5085. },
  5086. "409": {
  5087. "description": "Cannot cancel a non existent stopwatch"
  5088. }
  5089. }
  5090. }
  5091. },
  5092. "/repos/{owner}/{repo}/issues/{index}/stopwatch/start": {
  5093. "post": {
  5094. "consumes": [
  5095. "application/json"
  5096. ],
  5097. "produces": [
  5098. "application/json"
  5099. ],
  5100. "tags": [
  5101. "issue"
  5102. ],
  5103. "summary": "Start stopwatch on an issue.",
  5104. "operationId": "issueStartStopWatch",
  5105. "parameters": [
  5106. {
  5107. "type": "string",
  5108. "description": "owner of the repo",
  5109. "name": "owner",
  5110. "in": "path",
  5111. "required": true
  5112. },
  5113. {
  5114. "type": "string",
  5115. "description": "name of the repo",
  5116. "name": "repo",
  5117. "in": "path",
  5118. "required": true
  5119. },
  5120. {
  5121. "type": "integer",
  5122. "format": "int64",
  5123. "description": "index of the issue to create the stopwatch on",
  5124. "name": "index",
  5125. "in": "path",
  5126. "required": true
  5127. }
  5128. ],
  5129. "responses": {
  5130. "201": {
  5131. "$ref": "#/responses/empty"
  5132. },
  5133. "403": {
  5134. "description": "Not repo writer, user does not have rights to toggle stopwatch"
  5135. },
  5136. "404": {
  5137. "$ref": "#/responses/notFound"
  5138. },
  5139. "409": {
  5140. "description": "Cannot start a stopwatch again if it already exists"
  5141. }
  5142. }
  5143. }
  5144. },
  5145. "/repos/{owner}/{repo}/issues/{index}/stopwatch/stop": {
  5146. "post": {
  5147. "consumes": [
  5148. "application/json"
  5149. ],
  5150. "produces": [
  5151. "application/json"
  5152. ],
  5153. "tags": [
  5154. "issue"
  5155. ],
  5156. "summary": "Stop an issue's existing stopwatch.",
  5157. "operationId": "issueStopStopWatch",
  5158. "parameters": [
  5159. {
  5160. "type": "string",
  5161. "description": "owner of the repo",
  5162. "name": "owner",
  5163. "in": "path",
  5164. "required": true
  5165. },
  5166. {
  5167. "type": "string",
  5168. "description": "name of the repo",
  5169. "name": "repo",
  5170. "in": "path",
  5171. "required": true
  5172. },
  5173. {
  5174. "type": "integer",
  5175. "format": "int64",
  5176. "description": "index of the issue to stop the stopwatch on",
  5177. "name": "index",
  5178. "in": "path",
  5179. "required": true
  5180. }
  5181. ],
  5182. "responses": {
  5183. "201": {
  5184. "$ref": "#/responses/empty"
  5185. },
  5186. "403": {
  5187. "description": "Not repo writer, user does not have rights to toggle stopwatch"
  5188. },
  5189. "404": {
  5190. "$ref": "#/responses/notFound"
  5191. },
  5192. "409": {
  5193. "description": "Cannot stop a non existent stopwatch"
  5194. }
  5195. }
  5196. }
  5197. },
  5198. "/repos/{owner}/{repo}/issues/{index}/subscriptions": {
  5199. "get": {
  5200. "consumes": [
  5201. "application/json"
  5202. ],
  5203. "produces": [
  5204. "application/json"
  5205. ],
  5206. "tags": [
  5207. "issue"
  5208. ],
  5209. "summary": "Get users who subscribed on an issue.",
  5210. "operationId": "issueSubscriptions",
  5211. "parameters": [
  5212. {
  5213. "type": "string",
  5214. "description": "owner of the repo",
  5215. "name": "owner",
  5216. "in": "path",
  5217. "required": true
  5218. },
  5219. {
  5220. "type": "string",
  5221. "description": "name of the repo",
  5222. "name": "repo",
  5223. "in": "path",
  5224. "required": true
  5225. },
  5226. {
  5227. "type": "integer",
  5228. "format": "int64",
  5229. "description": "index of the issue",
  5230. "name": "index",
  5231. "in": "path",
  5232. "required": true
  5233. },
  5234. {
  5235. "type": "integer",
  5236. "description": "page number of results to return (1-based)",
  5237. "name": "page",
  5238. "in": "query"
  5239. },
  5240. {
  5241. "type": "integer",
  5242. "description": "page size of results, maximum page size is 50",
  5243. "name": "limit",
  5244. "in": "query"
  5245. }
  5246. ],
  5247. "responses": {
  5248. "200": {
  5249. "$ref": "#/responses/UserList"
  5250. },
  5251. "404": {
  5252. "$ref": "#/responses/notFound"
  5253. }
  5254. }
  5255. }
  5256. },
  5257. "/repos/{owner}/{repo}/issues/{index}/subscriptions/check": {
  5258. "get": {
  5259. "consumes": [
  5260. "application/json"
  5261. ],
  5262. "produces": [
  5263. "application/json"
  5264. ],
  5265. "tags": [
  5266. "issue"
  5267. ],
  5268. "summary": "Check if user is subscribed to an issue",
  5269. "operationId": "issueCheckSubscription",
  5270. "parameters": [
  5271. {
  5272. "type": "string",
  5273. "description": "owner of the repo",
  5274. "name": "owner",
  5275. "in": "path",
  5276. "required": true
  5277. },
  5278. {
  5279. "type": "string",
  5280. "description": "name of the repo",
  5281. "name": "repo",
  5282. "in": "path",
  5283. "required": true
  5284. },
  5285. {
  5286. "type": "integer",
  5287. "format": "int64",
  5288. "description": "index of the issue",
  5289. "name": "index",
  5290. "in": "path",
  5291. "required": true
  5292. }
  5293. ],
  5294. "responses": {
  5295. "200": {
  5296. "$ref": "#/responses/WatchInfo"
  5297. },
  5298. "404": {
  5299. "$ref": "#/responses/notFound"
  5300. }
  5301. }
  5302. }
  5303. },
  5304. "/repos/{owner}/{repo}/issues/{index}/subscriptions/{user}": {
  5305. "put": {
  5306. "consumes": [
  5307. "application/json"
  5308. ],
  5309. "produces": [
  5310. "application/json"
  5311. ],
  5312. "tags": [
  5313. "issue"
  5314. ],
  5315. "summary": "Subscribe user to issue",
  5316. "operationId": "issueAddSubscription",
  5317. "parameters": [
  5318. {
  5319. "type": "string",
  5320. "description": "owner of the repo",
  5321. "name": "owner",
  5322. "in": "path",
  5323. "required": true
  5324. },
  5325. {
  5326. "type": "string",
  5327. "description": "name of the repo",
  5328. "name": "repo",
  5329. "in": "path",
  5330. "required": true
  5331. },
  5332. {
  5333. "type": "integer",
  5334. "format": "int64",
  5335. "description": "index of the issue",
  5336. "name": "index",
  5337. "in": "path",
  5338. "required": true
  5339. },
  5340. {
  5341. "type": "string",
  5342. "description": "user to subscribe",
  5343. "name": "user",
  5344. "in": "path",
  5345. "required": true
  5346. }
  5347. ],
  5348. "responses": {
  5349. "200": {
  5350. "description": "Already subscribed"
  5351. },
  5352. "201": {
  5353. "description": "Successfully Subscribed"
  5354. },
  5355. "304": {
  5356. "description": "User can only subscribe itself if he is no admin"
  5357. },
  5358. "404": {
  5359. "$ref": "#/responses/notFound"
  5360. }
  5361. }
  5362. },
  5363. "delete": {
  5364. "consumes": [
  5365. "application/json"
  5366. ],
  5367. "produces": [
  5368. "application/json"
  5369. ],
  5370. "tags": [
  5371. "issue"
  5372. ],
  5373. "summary": "Unsubscribe user from issue",
  5374. "operationId": "issueDeleteSubscription",
  5375. "parameters": [
  5376. {
  5377. "type": "string",
  5378. "description": "owner of the repo",
  5379. "name": "owner",
  5380. "in": "path",
  5381. "required": true
  5382. },
  5383. {
  5384. "type": "string",
  5385. "description": "name of the repo",
  5386. "name": "repo",
  5387. "in": "path",
  5388. "required": true
  5389. },
  5390. {
  5391. "type": "integer",
  5392. "format": "int64",
  5393. "description": "index of the issue",
  5394. "name": "index",
  5395. "in": "path",
  5396. "required": true
  5397. },
  5398. {
  5399. "type": "string",
  5400. "description": "user witch unsubscribe",
  5401. "name": "user",
  5402. "in": "path",
  5403. "required": true
  5404. }
  5405. ],
  5406. "responses": {
  5407. "200": {
  5408. "description": "Already unsubscribed"
  5409. },
  5410. "201": {
  5411. "description": "Successfully Unsubscribed"
  5412. },
  5413. "304": {
  5414. "description": "User can only subscribe itself if he is no admin"
  5415. },
  5416. "404": {
  5417. "$ref": "#/responses/notFound"
  5418. }
  5419. }
  5420. }
  5421. },
  5422. "/repos/{owner}/{repo}/issues/{index}/times": {
  5423. "get": {
  5424. "produces": [
  5425. "application/json"
  5426. ],
  5427. "tags": [
  5428. "issue"
  5429. ],
  5430. "summary": "List an issue's tracked times",
  5431. "operationId": "issueTrackedTimes",
  5432. "parameters": [
  5433. {
  5434. "type": "string",
  5435. "description": "owner of the repo",
  5436. "name": "owner",
  5437. "in": "path",
  5438. "required": true
  5439. },
  5440. {
  5441. "type": "string",
  5442. "description": "name of the repo",
  5443. "name": "repo",
  5444. "in": "path",
  5445. "required": true
  5446. },
  5447. {
  5448. "type": "integer",
  5449. "format": "int64",
  5450. "description": "index of the issue",
  5451. "name": "index",
  5452. "in": "path",
  5453. "required": true
  5454. },
  5455. {
  5456. "type": "string",
  5457. "format": "date-time",
  5458. "description": "Only show times updated after the given time. This is a timestamp in RFC 3339 format",
  5459. "name": "since",
  5460. "in": "query"
  5461. },
  5462. {
  5463. "type": "string",
  5464. "format": "date-time",
  5465. "description": "Only show times updated before the given time. This is a timestamp in RFC 3339 format",
  5466. "name": "before",
  5467. "in": "query"
  5468. },
  5469. {
  5470. "type": "integer",
  5471. "description": "page number of results to return (1-based)",
  5472. "name": "page",
  5473. "in": "query"
  5474. },
  5475. {
  5476. "type": "integer",
  5477. "description": "page size of results, maximum page size is 50",
  5478. "name": "limit",
  5479. "in": "query"
  5480. }
  5481. ],
  5482. "responses": {
  5483. "200": {
  5484. "$ref": "#/responses/TrackedTimeList"
  5485. },
  5486. "404": {
  5487. "$ref": "#/responses/notFound"
  5488. }
  5489. }
  5490. },
  5491. "post": {
  5492. "consumes": [
  5493. "application/json"
  5494. ],
  5495. "produces": [
  5496. "application/json"
  5497. ],
  5498. "tags": [
  5499. "issue"
  5500. ],
  5501. "summary": "Add tracked time to a issue",
  5502. "operationId": "issueAddTime",
  5503. "parameters": [
  5504. {
  5505. "type": "string",
  5506. "description": "owner of the repo",
  5507. "name": "owner",
  5508. "in": "path",
  5509. "required": true
  5510. },
  5511. {
  5512. "type": "string",
  5513. "description": "name of the repo",
  5514. "name": "repo",
  5515. "in": "path",
  5516. "required": true
  5517. },
  5518. {
  5519. "type": "integer",
  5520. "format": "int64",
  5521. "description": "index of the issue",
  5522. "name": "index",
  5523. "in": "path",
  5524. "required": true
  5525. },
  5526. {
  5527. "name": "body",
  5528. "in": "body",
  5529. "schema": {
  5530. "$ref": "#/definitions/AddTimeOption"
  5531. }
  5532. }
  5533. ],
  5534. "responses": {
  5535. "200": {
  5536. "$ref": "#/responses/TrackedTime"
  5537. },
  5538. "400": {
  5539. "$ref": "#/responses/error"
  5540. },
  5541. "403": {
  5542. "$ref": "#/responses/forbidden"
  5543. }
  5544. }
  5545. },
  5546. "delete": {
  5547. "consumes": [
  5548. "application/json"
  5549. ],
  5550. "produces": [
  5551. "application/json"
  5552. ],
  5553. "tags": [
  5554. "issue"
  5555. ],
  5556. "summary": "Reset a tracked time of an issue",
  5557. "operationId": "issueResetTime",
  5558. "parameters": [
  5559. {
  5560. "type": "string",
  5561. "description": "owner of the repo",
  5562. "name": "owner",
  5563. "in": "path",
  5564. "required": true
  5565. },
  5566. {
  5567. "type": "string",
  5568. "description": "name of the repo",
  5569. "name": "repo",
  5570. "in": "path",
  5571. "required": true
  5572. },
  5573. {
  5574. "type": "integer",
  5575. "format": "int64",
  5576. "description": "index of the issue to add tracked time to",
  5577. "name": "index",
  5578. "in": "path",
  5579. "required": true
  5580. }
  5581. ],
  5582. "responses": {
  5583. "204": {
  5584. "$ref": "#/responses/empty"
  5585. },
  5586. "400": {
  5587. "$ref": "#/responses/error"
  5588. },
  5589. "403": {
  5590. "$ref": "#/responses/forbidden"
  5591. }
  5592. }
  5593. }
  5594. },
  5595. "/repos/{owner}/{repo}/issues/{index}/times/{id}": {
  5596. "delete": {
  5597. "consumes": [
  5598. "application/json"
  5599. ],
  5600. "produces": [
  5601. "application/json"
  5602. ],
  5603. "tags": [
  5604. "issue"
  5605. ],
  5606. "summary": "Delete specific tracked time",
  5607. "operationId": "issueDeleteTime",
  5608. "parameters": [
  5609. {
  5610. "type": "string",
  5611. "description": "owner of the repo",
  5612. "name": "owner",
  5613. "in": "path",
  5614. "required": true
  5615. },
  5616. {
  5617. "type": "string",
  5618. "description": "name of the repo",
  5619. "name": "repo",
  5620. "in": "path",
  5621. "required": true
  5622. },
  5623. {
  5624. "type": "integer",
  5625. "format": "int64",
  5626. "description": "index of the issue",
  5627. "name": "index",
  5628. "in": "path",
  5629. "required": true
  5630. },
  5631. {
  5632. "type": "integer",
  5633. "format": "int64",
  5634. "description": "id of time to delete",
  5635. "name": "id",
  5636. "in": "path",
  5637. "required": true
  5638. }
  5639. ],
  5640. "responses": {
  5641. "204": {
  5642. "$ref": "#/responses/empty"
  5643. },
  5644. "400": {
  5645. "$ref": "#/responses/error"
  5646. },
  5647. "403": {
  5648. "$ref": "#/responses/forbidden"
  5649. }
  5650. }
  5651. }
  5652. },
  5653. "/repos/{owner}/{repo}/keys": {
  5654. "get": {
  5655. "produces": [
  5656. "application/json"
  5657. ],
  5658. "tags": [
  5659. "repository"
  5660. ],
  5661. "summary": "List a repository's keys",
  5662. "operationId": "repoListKeys",
  5663. "parameters": [
  5664. {
  5665. "type": "string",
  5666. "description": "owner of the repo",
  5667. "name": "owner",
  5668. "in": "path",
  5669. "required": true
  5670. },
  5671. {
  5672. "type": "string",
  5673. "description": "name of the repo",
  5674. "name": "repo",
  5675. "in": "path",
  5676. "required": true
  5677. },
  5678. {
  5679. "type": "integer",
  5680. "description": "the key_id to search for",
  5681. "name": "key_id",
  5682. "in": "query"
  5683. },
  5684. {
  5685. "type": "string",
  5686. "description": "fingerprint of the key",
  5687. "name": "fingerprint",
  5688. "in": "query"
  5689. },
  5690. {
  5691. "type": "integer",
  5692. "description": "page number of results to return (1-based)",
  5693. "name": "page",
  5694. "in": "query"
  5695. },
  5696. {
  5697. "type": "integer",
  5698. "description": "page size of results, maximum page size is 50",
  5699. "name": "limit",
  5700. "in": "query"
  5701. }
  5702. ],
  5703. "responses": {
  5704. "200": {
  5705. "$ref": "#/responses/DeployKeyList"
  5706. }
  5707. }
  5708. },
  5709. "post": {
  5710. "consumes": [
  5711. "application/json"
  5712. ],
  5713. "produces": [
  5714. "application/json"
  5715. ],
  5716. "tags": [
  5717. "repository"
  5718. ],
  5719. "summary": "Add a key to a repository",
  5720. "operationId": "repoCreateKey",
  5721. "parameters": [
  5722. {
  5723. "type": "string",
  5724. "description": "owner of the repo",
  5725. "name": "owner",
  5726. "in": "path",
  5727. "required": true
  5728. },
  5729. {
  5730. "type": "string",
  5731. "description": "name of the repo",
  5732. "name": "repo",
  5733. "in": "path",
  5734. "required": true
  5735. },
  5736. {
  5737. "name": "body",
  5738. "in": "body",
  5739. "schema": {
  5740. "$ref": "#/definitions/CreateKeyOption"
  5741. }
  5742. }
  5743. ],
  5744. "responses": {
  5745. "201": {
  5746. "$ref": "#/responses/DeployKey"
  5747. },
  5748. "422": {
  5749. "$ref": "#/responses/validationError"
  5750. }
  5751. }
  5752. }
  5753. },
  5754. "/repos/{owner}/{repo}/keys/{id}": {
  5755. "get": {
  5756. "produces": [
  5757. "application/json"
  5758. ],
  5759. "tags": [
  5760. "repository"
  5761. ],
  5762. "summary": "Get a repository's key by id",
  5763. "operationId": "repoGetKey",
  5764. "parameters": [
  5765. {
  5766. "type": "string",
  5767. "description": "owner of the repo",
  5768. "name": "owner",
  5769. "in": "path",
  5770. "required": true
  5771. },
  5772. {
  5773. "type": "string",
  5774. "description": "name of the repo",
  5775. "name": "repo",
  5776. "in": "path",
  5777. "required": true
  5778. },
  5779. {
  5780. "type": "integer",
  5781. "format": "int64",
  5782. "description": "id of the key to get",
  5783. "name": "id",
  5784. "in": "path",
  5785. "required": true
  5786. }
  5787. ],
  5788. "responses": {
  5789. "200": {
  5790. "$ref": "#/responses/DeployKey"
  5791. }
  5792. }
  5793. },
  5794. "delete": {
  5795. "tags": [
  5796. "repository"
  5797. ],
  5798. "summary": "Delete a key from a repository",
  5799. "operationId": "repoDeleteKey",
  5800. "parameters": [
  5801. {
  5802. "type": "string",
  5803. "description": "owner of the repo",
  5804. "name": "owner",
  5805. "in": "path",
  5806. "required": true
  5807. },
  5808. {
  5809. "type": "string",
  5810. "description": "name of the repo",
  5811. "name": "repo",
  5812. "in": "path",
  5813. "required": true
  5814. },
  5815. {
  5816. "type": "integer",
  5817. "format": "int64",
  5818. "description": "id of the key to delete",
  5819. "name": "id",
  5820. "in": "path",
  5821. "required": true
  5822. }
  5823. ],
  5824. "responses": {
  5825. "204": {
  5826. "$ref": "#/responses/empty"
  5827. },
  5828. "403": {
  5829. "$ref": "#/responses/forbidden"
  5830. }
  5831. }
  5832. }
  5833. },
  5834. "/repos/{owner}/{repo}/labels": {
  5835. "get": {
  5836. "produces": [
  5837. "application/json"
  5838. ],
  5839. "tags": [
  5840. "issue"
  5841. ],
  5842. "summary": "Get all of a repository's labels",
  5843. "operationId": "issueListLabels",
  5844. "parameters": [
  5845. {
  5846. "type": "string",
  5847. "description": "owner of the repo",
  5848. "name": "owner",
  5849. "in": "path",
  5850. "required": true
  5851. },
  5852. {
  5853. "type": "string",
  5854. "description": "name of the repo",
  5855. "name": "repo",
  5856. "in": "path",
  5857. "required": true
  5858. },
  5859. {
  5860. "type": "integer",
  5861. "description": "page number of results to return (1-based)",
  5862. "name": "page",
  5863. "in": "query"
  5864. },
  5865. {
  5866. "type": "integer",
  5867. "description": "page size of results, maximum page size is 50",
  5868. "name": "limit",
  5869. "in": "query"
  5870. }
  5871. ],
  5872. "responses": {
  5873. "200": {
  5874. "$ref": "#/responses/LabelList"
  5875. }
  5876. }
  5877. },
  5878. "post": {
  5879. "consumes": [
  5880. "application/json"
  5881. ],
  5882. "produces": [
  5883. "application/json"
  5884. ],
  5885. "tags": [
  5886. "issue"
  5887. ],
  5888. "summary": "Create a label",
  5889. "operationId": "issueCreateLabel",
  5890. "parameters": [
  5891. {
  5892. "type": "string",
  5893. "description": "owner of the repo",
  5894. "name": "owner",
  5895. "in": "path",
  5896. "required": true
  5897. },
  5898. {
  5899. "type": "string",
  5900. "description": "name of the repo",
  5901. "name": "repo",
  5902. "in": "path",
  5903. "required": true
  5904. },
  5905. {
  5906. "name": "body",
  5907. "in": "body",
  5908. "schema": {
  5909. "$ref": "#/definitions/CreateLabelOption"
  5910. }
  5911. }
  5912. ],
  5913. "responses": {
  5914. "201": {
  5915. "$ref": "#/responses/Label"
  5916. },
  5917. "422": {
  5918. "$ref": "#/responses/validationError"
  5919. }
  5920. }
  5921. }
  5922. },
  5923. "/repos/{owner}/{repo}/labels/{id}": {
  5924. "get": {
  5925. "produces": [
  5926. "application/json"
  5927. ],
  5928. "tags": [
  5929. "issue"
  5930. ],
  5931. "summary": "Get a single label",
  5932. "operationId": "issueGetLabel",
  5933. "parameters": [
  5934. {
  5935. "type": "string",
  5936. "description": "owner of the repo",
  5937. "name": "owner",
  5938. "in": "path",
  5939. "required": true
  5940. },
  5941. {
  5942. "type": "string",
  5943. "description": "name of the repo",
  5944. "name": "repo",
  5945. "in": "path",
  5946. "required": true
  5947. },
  5948. {
  5949. "type": "integer",
  5950. "format": "int64",
  5951. "description": "id of the label to get",
  5952. "name": "id",
  5953. "in": "path",
  5954. "required": true
  5955. }
  5956. ],
  5957. "responses": {
  5958. "200": {
  5959. "$ref": "#/responses/Label"
  5960. }
  5961. }
  5962. },
  5963. "delete": {
  5964. "tags": [
  5965. "issue"
  5966. ],
  5967. "summary": "Delete a label",
  5968. "operationId": "issueDeleteLabel",
  5969. "parameters": [
  5970. {
  5971. "type": "string",
  5972. "description": "owner of the repo",
  5973. "name": "owner",
  5974. "in": "path",
  5975. "required": true
  5976. },
  5977. {
  5978. "type": "string",
  5979. "description": "name of the repo",
  5980. "name": "repo",
  5981. "in": "path",
  5982. "required": true
  5983. },
  5984. {
  5985. "type": "integer",
  5986. "format": "int64",
  5987. "description": "id of the label to delete",
  5988. "name": "id",
  5989. "in": "path",
  5990. "required": true
  5991. }
  5992. ],
  5993. "responses": {
  5994. "204": {
  5995. "$ref": "#/responses/empty"
  5996. }
  5997. }
  5998. },
  5999. "patch": {
  6000. "consumes": [
  6001. "application/json"
  6002. ],
  6003. "produces": [
  6004. "application/json"
  6005. ],
  6006. "tags": [
  6007. "issue"
  6008. ],
  6009. "summary": "Update a label",
  6010. "operationId": "issueEditLabel",
  6011. "parameters": [
  6012. {
  6013. "type": "string",
  6014. "description": "owner of the repo",
  6015. "name": "owner",
  6016. "in": "path",
  6017. "required": true
  6018. },
  6019. {
  6020. "type": "string",
  6021. "description": "name of the repo",
  6022. "name": "repo",
  6023. "in": "path",
  6024. "required": true
  6025. },
  6026. {
  6027. "type": "integer",
  6028. "format": "int64",
  6029. "description": "id of the label to edit",
  6030. "name": "id",
  6031. "in": "path",
  6032. "required": true
  6033. },
  6034. {
  6035. "name": "body",
  6036. "in": "body",
  6037. "schema": {
  6038. "$ref": "#/definitions/EditLabelOption"
  6039. }
  6040. }
  6041. ],
  6042. "responses": {
  6043. "200": {
  6044. "$ref": "#/responses/Label"
  6045. },
  6046. "422": {
  6047. "$ref": "#/responses/validationError"
  6048. }
  6049. }
  6050. }
  6051. },
  6052. "/repos/{owner}/{repo}/milestones": {
  6053. "get": {
  6054. "produces": [
  6055. "application/json"
  6056. ],
  6057. "tags": [
  6058. "issue"
  6059. ],
  6060. "summary": "Get all of a repository's opened milestones",
  6061. "operationId": "issueGetMilestonesList",
  6062. "parameters": [
  6063. {
  6064. "type": "string",
  6065. "description": "owner of the repo",
  6066. "name": "owner",
  6067. "in": "path",
  6068. "required": true
  6069. },
  6070. {
  6071. "type": "string",
  6072. "description": "name of the repo",
  6073. "name": "repo",
  6074. "in": "path",
  6075. "required": true
  6076. },
  6077. {
  6078. "type": "string",
  6079. "description": "Milestone state, Recognised values are open, closed and all. Defaults to \"open\"",
  6080. "name": "state",
  6081. "in": "query"
  6082. },
  6083. {
  6084. "type": "integer",
  6085. "description": "page number of results to return (1-based)",
  6086. "name": "page",
  6087. "in": "query"
  6088. },
  6089. {
  6090. "type": "integer",
  6091. "description": "page size of results, maximum page size is 50",
  6092. "name": "limit",
  6093. "in": "query"
  6094. }
  6095. ],
  6096. "responses": {
  6097. "200": {
  6098. "$ref": "#/responses/MilestoneList"
  6099. }
  6100. }
  6101. },
  6102. "post": {
  6103. "consumes": [
  6104. "application/json"
  6105. ],
  6106. "produces": [
  6107. "application/json"
  6108. ],
  6109. "tags": [
  6110. "issue"
  6111. ],
  6112. "summary": "Create a milestone",
  6113. "operationId": "issueCreateMilestone",
  6114. "parameters": [
  6115. {
  6116. "type": "string",
  6117. "description": "owner of the repo",
  6118. "name": "owner",
  6119. "in": "path",
  6120. "required": true
  6121. },
  6122. {
  6123. "type": "string",
  6124. "description": "name of the repo",
  6125. "name": "repo",
  6126. "in": "path",
  6127. "required": true
  6128. },
  6129. {
  6130. "name": "body",
  6131. "in": "body",
  6132. "schema": {
  6133. "$ref": "#/definitions/CreateMilestoneOption"
  6134. }
  6135. }
  6136. ],
  6137. "responses": {
  6138. "201": {
  6139. "$ref": "#/responses/Milestone"
  6140. }
  6141. }
  6142. }
  6143. },
  6144. "/repos/{owner}/{repo}/milestones/{id}": {
  6145. "get": {
  6146. "produces": [
  6147. "application/json"
  6148. ],
  6149. "tags": [
  6150. "issue"
  6151. ],
  6152. "summary": "Get a milestone",
  6153. "operationId": "issueGetMilestone",
  6154. "parameters": [
  6155. {
  6156. "type": "string",
  6157. "description": "owner of the repo",
  6158. "name": "owner",
  6159. "in": "path",
  6160. "required": true
  6161. },
  6162. {
  6163. "type": "string",
  6164. "description": "name of the repo",
  6165. "name": "repo",
  6166. "in": "path",
  6167. "required": true
  6168. },
  6169. {
  6170. "type": "integer",
  6171. "format": "int64",
  6172. "description": "id of the milestone",
  6173. "name": "id",
  6174. "in": "path",
  6175. "required": true
  6176. }
  6177. ],
  6178. "responses": {
  6179. "200": {
  6180. "$ref": "#/responses/Milestone"
  6181. }
  6182. }
  6183. },
  6184. "delete": {
  6185. "tags": [
  6186. "issue"
  6187. ],
  6188. "summary": "Delete a milestone",
  6189. "operationId": "issueDeleteMilestone",
  6190. "parameters": [
  6191. {
  6192. "type": "string",
  6193. "description": "owner of the repo",
  6194. "name": "owner",
  6195. "in": "path",
  6196. "required": true
  6197. },
  6198. {
  6199. "type": "string",
  6200. "description": "name of the repo",
  6201. "name": "repo",
  6202. "in": "path",
  6203. "required": true
  6204. },
  6205. {
  6206. "type": "integer",
  6207. "format": "int64",
  6208. "description": "id of the milestone to delete",
  6209. "name": "id",
  6210. "in": "path",
  6211. "required": true
  6212. }
  6213. ],
  6214. "responses": {
  6215. "204": {
  6216. "$ref": "#/responses/empty"
  6217. }
  6218. }
  6219. },
  6220. "patch": {
  6221. "consumes": [
  6222. "application/json"
  6223. ],
  6224. "produces": [
  6225. "application/json"
  6226. ],
  6227. "tags": [
  6228. "issue"
  6229. ],
  6230. "summary": "Update a milestone",
  6231. "operationId": "issueEditMilestone",
  6232. "parameters": [
  6233. {
  6234. "type": "string",
  6235. "description": "owner of the repo",
  6236. "name": "owner",
  6237. "in": "path",
  6238. "required": true
  6239. },
  6240. {
  6241. "type": "string",
  6242. "description": "name of the repo",
  6243. "name": "repo",
  6244. "in": "path",
  6245. "required": true
  6246. },
  6247. {
  6248. "type": "integer",
  6249. "format": "int64",
  6250. "description": "id of the milestone",
  6251. "name": "id",
  6252. "in": "path",
  6253. "required": true
  6254. },
  6255. {
  6256. "name": "body",
  6257. "in": "body",
  6258. "schema": {
  6259. "$ref": "#/definitions/EditMilestoneOption"
  6260. }
  6261. }
  6262. ],
  6263. "responses": {
  6264. "200": {
  6265. "$ref": "#/responses/Milestone"
  6266. }
  6267. }
  6268. }
  6269. },
  6270. "/repos/{owner}/{repo}/mirror-sync": {
  6271. "post": {
  6272. "produces": [
  6273. "application/json"
  6274. ],
  6275. "tags": [
  6276. "repository"
  6277. ],
  6278. "summary": "Sync a mirrored repository",
  6279. "operationId": "repoMirrorSync",
  6280. "parameters": [
  6281. {
  6282. "type": "string",
  6283. "description": "owner of the repo to sync",
  6284. "name": "owner",
  6285. "in": "path",
  6286. "required": true
  6287. },
  6288. {
  6289. "type": "string",
  6290. "description": "name of the repo to sync",
  6291. "name": "repo",
  6292. "in": "path",
  6293. "required": true
  6294. }
  6295. ],
  6296. "responses": {
  6297. "200": {
  6298. "$ref": "#/responses/empty"
  6299. },
  6300. "403": {
  6301. "$ref": "#/responses/forbidden"
  6302. }
  6303. }
  6304. }
  6305. },
  6306. "/repos/{owner}/{repo}/notifications": {
  6307. "get": {
  6308. "consumes": [
  6309. "application/json"
  6310. ],
  6311. "produces": [
  6312. "application/json"
  6313. ],
  6314. "tags": [
  6315. "notification"
  6316. ],
  6317. "summary": "List users's notification threads on a specific repo",
  6318. "operationId": "notifyGetRepoList",
  6319. "parameters": [
  6320. {
  6321. "type": "string",
  6322. "description": "owner of the repo",
  6323. "name": "owner",
  6324. "in": "path",
  6325. "required": true
  6326. },
  6327. {
  6328. "type": "string",
  6329. "description": "name of the repo",
  6330. "name": "repo",
  6331. "in": "path",
  6332. "required": true
  6333. },
  6334. {
  6335. "type": "string",
  6336. "description": "If true, show notifications marked as read. Default value is false",
  6337. "name": "all",
  6338. "in": "query"
  6339. },
  6340. {
  6341. "type": "string",
  6342. "format": "date-time",
  6343. "description": "Only show notifications updated after the given time. This is a timestamp in RFC 3339 format",
  6344. "name": "since",
  6345. "in": "query"
  6346. },
  6347. {
  6348. "type": "string",
  6349. "format": "date-time",
  6350. "description": "Only show notifications updated before the given time. This is a timestamp in RFC 3339 format",
  6351. "name": "before",
  6352. "in": "query"
  6353. },
  6354. {
  6355. "type": "integer",
  6356. "description": "page number of results to return (1-based)",
  6357. "name": "page",
  6358. "in": "query"
  6359. },
  6360. {
  6361. "type": "integer",
  6362. "description": "page size of results, maximum page size is 50",
  6363. "name": "limit",
  6364. "in": "query"
  6365. }
  6366. ],
  6367. "responses": {
  6368. "200": {
  6369. "$ref": "#/responses/NotificationThreadList"
  6370. }
  6371. }
  6372. },
  6373. "put": {
  6374. "consumes": [
  6375. "application/json"
  6376. ],
  6377. "produces": [
  6378. "application/json"
  6379. ],
  6380. "tags": [
  6381. "notification"
  6382. ],
  6383. "summary": "Mark notification threads as read on a specific repo",
  6384. "operationId": "notifyReadRepoList",
  6385. "parameters": [
  6386. {
  6387. "type": "string",
  6388. "description": "owner of the repo",
  6389. "name": "owner",
  6390. "in": "path",
  6391. "required": true
  6392. },
  6393. {
  6394. "type": "string",
  6395. "description": "name of the repo",
  6396. "name": "repo",
  6397. "in": "path",
  6398. "required": true
  6399. },
  6400. {
  6401. "type": "string",
  6402. "format": "date-time",
  6403. "description": "Describes the last point that notifications were checked. Anything updated since this time will not be updated.",
  6404. "name": "last_read_at",
  6405. "in": "query"
  6406. }
  6407. ],
  6408. "responses": {
  6409. "205": {
  6410. "$ref": "#/responses/empty"
  6411. }
  6412. }
  6413. }
  6414. },
  6415. "/repos/{owner}/{repo}/pulls": {
  6416. "get": {
  6417. "produces": [
  6418. "application/json"
  6419. ],
  6420. "tags": [
  6421. "repository"
  6422. ],
  6423. "summary": "List a repo's pull requests",
  6424. "operationId": "repoListPullRequests",
  6425. "parameters": [
  6426. {
  6427. "type": "string",
  6428. "description": "owner of the repo",
  6429. "name": "owner",
  6430. "in": "path",
  6431. "required": true
  6432. },
  6433. {
  6434. "type": "string",
  6435. "description": "name of the repo",
  6436. "name": "repo",
  6437. "in": "path",
  6438. "required": true
  6439. },
  6440. {
  6441. "enum": [
  6442. "closed",
  6443. "open",
  6444. "all"
  6445. ],
  6446. "type": "string",
  6447. "description": "State of pull request: open or closed (optional)",
  6448. "name": "state",
  6449. "in": "query"
  6450. },
  6451. {
  6452. "enum": [
  6453. "oldest",
  6454. "recentupdate",
  6455. "leastupdate",
  6456. "mostcomment",
  6457. "leastcomment",
  6458. "priority"
  6459. ],
  6460. "type": "string",
  6461. "description": "Type of sort",
  6462. "name": "sort",
  6463. "in": "query"
  6464. },
  6465. {
  6466. "type": "integer",
  6467. "format": "int64",
  6468. "description": "ID of the milestone",
  6469. "name": "milestone",
  6470. "in": "query"
  6471. },
  6472. {
  6473. "type": "array",
  6474. "items": {
  6475. "type": "integer",
  6476. "format": "int64"
  6477. },
  6478. "collectionFormat": "multi",
  6479. "description": "Label IDs",
  6480. "name": "labels",
  6481. "in": "query"
  6482. },
  6483. {
  6484. "type": "integer",
  6485. "description": "page number of results to return (1-based)",
  6486. "name": "page",
  6487. "in": "query"
  6488. },
  6489. {
  6490. "type": "integer",
  6491. "description": "page size of results, maximum page size is 50",
  6492. "name": "limit",
  6493. "in": "query"
  6494. }
  6495. ],
  6496. "responses": {
  6497. "200": {
  6498. "$ref": "#/responses/PullRequestList"
  6499. }
  6500. }
  6501. },
  6502. "post": {
  6503. "consumes": [
  6504. "application/json"
  6505. ],
  6506. "produces": [
  6507. "application/json"
  6508. ],
  6509. "tags": [
  6510. "repository"
  6511. ],
  6512. "summary": "Create a pull request",
  6513. "operationId": "repoCreatePullRequest",
  6514. "parameters": [
  6515. {
  6516. "type": "string",
  6517. "description": "owner of the repo",
  6518. "name": "owner",
  6519. "in": "path",
  6520. "required": true
  6521. },
  6522. {
  6523. "type": "string",
  6524. "description": "name of the repo",
  6525. "name": "repo",
  6526. "in": "path",
  6527. "required": true
  6528. },
  6529. {
  6530. "name": "body",
  6531. "in": "body",
  6532. "schema": {
  6533. "$ref": "#/definitions/CreatePullRequestOption"
  6534. }
  6535. }
  6536. ],
  6537. "responses": {
  6538. "201": {
  6539. "$ref": "#/responses/PullRequest"
  6540. },
  6541. "409": {
  6542. "$ref": "#/responses/error"
  6543. },
  6544. "422": {
  6545. "$ref": "#/responses/validationError"
  6546. }
  6547. }
  6548. }
  6549. },
  6550. "/repos/{owner}/{repo}/pulls/{index}": {
  6551. "get": {
  6552. "produces": [
  6553. "application/json"
  6554. ],
  6555. "tags": [
  6556. "repository"
  6557. ],
  6558. "summary": "Get a pull request",
  6559. "operationId": "repoGetPullRequest",
  6560. "parameters": [
  6561. {
  6562. "type": "string",
  6563. "description": "owner of the repo",
  6564. "name": "owner",
  6565. "in": "path",
  6566. "required": true
  6567. },
  6568. {
  6569. "type": "string",
  6570. "description": "name of the repo",
  6571. "name": "repo",
  6572. "in": "path",
  6573. "required": true
  6574. },
  6575. {
  6576. "type": "integer",
  6577. "format": "int64",
  6578. "description": "index of the pull request to get",
  6579. "name": "index",
  6580. "in": "path",
  6581. "required": true
  6582. }
  6583. ],
  6584. "responses": {
  6585. "200": {
  6586. "$ref": "#/responses/PullRequest"
  6587. },
  6588. "404": {
  6589. "$ref": "#/responses/notFound"
  6590. }
  6591. }
  6592. },
  6593. "patch": {
  6594. "consumes": [
  6595. "application/json"
  6596. ],
  6597. "produces": [
  6598. "application/json"
  6599. ],
  6600. "tags": [
  6601. "repository"
  6602. ],
  6603. "summary": "Update a pull request. If using deadline only the date will be taken into account, and time of day ignored.",
  6604. "operationId": "repoEditPullRequest",
  6605. "parameters": [
  6606. {
  6607. "type": "string",
  6608. "description": "owner of the repo",
  6609. "name": "owner",
  6610. "in": "path",
  6611. "required": true
  6612. },
  6613. {
  6614. "type": "string",
  6615. "description": "name of the repo",
  6616. "name": "repo",
  6617. "in": "path",
  6618. "required": true
  6619. },
  6620. {
  6621. "type": "integer",
  6622. "format": "int64",
  6623. "description": "index of the pull request to edit",
  6624. "name": "index",
  6625. "in": "path",
  6626. "required": true
  6627. },
  6628. {
  6629. "name": "body",
  6630. "in": "body",
  6631. "schema": {
  6632. "$ref": "#/definitions/EditPullRequestOption"
  6633. }
  6634. }
  6635. ],
  6636. "responses": {
  6637. "201": {
  6638. "$ref": "#/responses/PullRequest"
  6639. },
  6640. "403": {
  6641. "$ref": "#/responses/forbidden"
  6642. },
  6643. "412": {
  6644. "$ref": "#/responses/error"
  6645. },
  6646. "422": {
  6647. "$ref": "#/responses/validationError"
  6648. }
  6649. }
  6650. }
  6651. },
  6652. "/repos/{owner}/{repo}/pulls/{index}/merge": {
  6653. "get": {
  6654. "produces": [
  6655. "application/json"
  6656. ],
  6657. "tags": [
  6658. "repository"
  6659. ],
  6660. "summary": "Check if a pull request has been merged",
  6661. "operationId": "repoPullRequestIsMerged",
  6662. "parameters": [
  6663. {
  6664. "type": "string",
  6665. "description": "owner of the repo",
  6666. "name": "owner",
  6667. "in": "path",
  6668. "required": true
  6669. },
  6670. {
  6671. "type": "string",
  6672. "description": "name of the repo",
  6673. "name": "repo",
  6674. "in": "path",
  6675. "required": true
  6676. },
  6677. {
  6678. "type": "integer",
  6679. "format": "int64",
  6680. "description": "index of the pull request",
  6681. "name": "index",
  6682. "in": "path",
  6683. "required": true
  6684. }
  6685. ],
  6686. "responses": {
  6687. "204": {
  6688. "description": "pull request has been merged"
  6689. },
  6690. "404": {
  6691. "description": "pull request has not been merged"
  6692. }
  6693. }
  6694. },
  6695. "post": {
  6696. "produces": [
  6697. "application/json"
  6698. ],
  6699. "tags": [
  6700. "repository"
  6701. ],
  6702. "summary": "Merge a pull request",
  6703. "operationId": "repoMergePullRequest",
  6704. "parameters": [
  6705. {
  6706. "type": "string",
  6707. "description": "owner of the repo",
  6708. "name": "owner",
  6709. "in": "path",
  6710. "required": true
  6711. },
  6712. {
  6713. "type": "string",
  6714. "description": "name of the repo",
  6715. "name": "repo",
  6716. "in": "path",
  6717. "required": true
  6718. },
  6719. {
  6720. "type": "integer",
  6721. "format": "int64",
  6722. "description": "index of the pull request to merge",
  6723. "name": "index",
  6724. "in": "path",
  6725. "required": true
  6726. },
  6727. {
  6728. "name": "body",
  6729. "in": "body",
  6730. "schema": {
  6731. "$ref": "#/definitions/MergePullRequestOption"
  6732. }
  6733. }
  6734. ],
  6735. "responses": {
  6736. "200": {
  6737. "$ref": "#/responses/empty"
  6738. },
  6739. "405": {
  6740. "$ref": "#/responses/empty"
  6741. },
  6742. "409": {
  6743. "$ref": "#/responses/error"
  6744. }
  6745. }
  6746. }
  6747. },
  6748. "/repos/{owner}/{repo}/pulls/{index}/reviews": {
  6749. "get": {
  6750. "produces": [
  6751. "application/json"
  6752. ],
  6753. "tags": [
  6754. "repository"
  6755. ],
  6756. "summary": "List all reviews for a pull request",
  6757. "operationId": "repoListPullReviews",
  6758. "parameters": [
  6759. {
  6760. "type": "string",
  6761. "description": "owner of the repo",
  6762. "name": "owner",
  6763. "in": "path",
  6764. "required": true
  6765. },
  6766. {
  6767. "type": "string",
  6768. "description": "name of the repo",
  6769. "name": "repo",
  6770. "in": "path",
  6771. "required": true
  6772. },
  6773. {
  6774. "type": "integer",
  6775. "format": "int64",
  6776. "description": "index of the pull request",
  6777. "name": "index",
  6778. "in": "path",
  6779. "required": true
  6780. },
  6781. {
  6782. "type": "integer",
  6783. "description": "page number of results to return (1-based)",
  6784. "name": "page",
  6785. "in": "query"
  6786. },
  6787. {
  6788. "type": "integer",
  6789. "description": "page size of results, maximum page size is 50",
  6790. "name": "limit",
  6791. "in": "query"
  6792. }
  6793. ],
  6794. "responses": {
  6795. "200": {
  6796. "$ref": "#/responses/PullReviewList"
  6797. },
  6798. "404": {
  6799. "$ref": "#/responses/notFound"
  6800. }
  6801. }
  6802. },
  6803. "post": {
  6804. "produces": [
  6805. "application/json"
  6806. ],
  6807. "tags": [
  6808. "repository"
  6809. ],
  6810. "summary": "Create a review to an pull request",
  6811. "operationId": "repoCreatePullReview",
  6812. "parameters": [
  6813. {
  6814. "type": "string",
  6815. "description": "owner of the repo",
  6816. "name": "owner",
  6817. "in": "path",
  6818. "required": true
  6819. },
  6820. {
  6821. "type": "string",
  6822. "description": "name of the repo",
  6823. "name": "repo",
  6824. "in": "path",
  6825. "required": true
  6826. },
  6827. {
  6828. "type": "integer",
  6829. "format": "int64",
  6830. "description": "index of the pull request",
  6831. "name": "index",
  6832. "in": "path",
  6833. "required": true
  6834. },
  6835. {
  6836. "name": "body",
  6837. "in": "body",
  6838. "required": true,
  6839. "schema": {
  6840. "$ref": "#/definitions/CreatePullReviewOptions"
  6841. }
  6842. }
  6843. ],
  6844. "responses": {
  6845. "200": {
  6846. "$ref": "#/responses/PullReview"
  6847. },
  6848. "404": {
  6849. "$ref": "#/responses/notFound"
  6850. },
  6851. "422": {
  6852. "$ref": "#/responses/validationError"
  6853. }
  6854. }
  6855. }
  6856. },
  6857. "/repos/{owner}/{repo}/pulls/{index}/reviews/{id}": {
  6858. "get": {
  6859. "produces": [
  6860. "application/json"
  6861. ],
  6862. "tags": [
  6863. "repository"
  6864. ],
  6865. "summary": "Get a specific review for a pull request",
  6866. "operationId": "repoGetPullReview",
  6867. "parameters": [
  6868. {
  6869. "type": "string",
  6870. "description": "owner of the repo",
  6871. "name": "owner",
  6872. "in": "path",
  6873. "required": true
  6874. },
  6875. {
  6876. "type": "string",
  6877. "description": "name of the repo",
  6878. "name": "repo",
  6879. "in": "path",
  6880. "required": true
  6881. },
  6882. {
  6883. "type": "integer",
  6884. "format": "int64",
  6885. "description": "index of the pull request",
  6886. "name": "index",
  6887. "in": "path",
  6888. "required": true
  6889. },
  6890. {
  6891. "type": "integer",
  6892. "format": "int64",
  6893. "description": "id of the review",
  6894. "name": "id",
  6895. "in": "path",
  6896. "required": true
  6897. }
  6898. ],
  6899. "responses": {
  6900. "200": {
  6901. "$ref": "#/responses/PullReview"
  6902. },
  6903. "404": {
  6904. "$ref": "#/responses/notFound"
  6905. }
  6906. }
  6907. },
  6908. "post": {
  6909. "produces": [
  6910. "application/json"
  6911. ],
  6912. "tags": [
  6913. "repository"
  6914. ],
  6915. "summary": "Submit a pending review to an pull request",
  6916. "operationId": "repoSubmitPullReview",
  6917. "parameters": [
  6918. {
  6919. "type": "string",
  6920. "description": "owner of the repo",
  6921. "name": "owner",
  6922. "in": "path",
  6923. "required": true
  6924. },
  6925. {
  6926. "type": "string",
  6927. "description": "name of the repo",
  6928. "name": "repo",
  6929. "in": "path",
  6930. "required": true
  6931. },
  6932. {
  6933. "type": "integer",
  6934. "format": "int64",
  6935. "description": "index of the pull request",
  6936. "name": "index",
  6937. "in": "path",
  6938. "required": true
  6939. },
  6940. {
  6941. "type": "integer",
  6942. "format": "int64",
  6943. "description": "id of the review",
  6944. "name": "id",
  6945. "in": "path",
  6946. "required": true
  6947. },
  6948. {
  6949. "name": "body",
  6950. "in": "body",
  6951. "required": true,
  6952. "schema": {
  6953. "$ref": "#/definitions/SubmitPullReviewOptions"
  6954. }
  6955. }
  6956. ],
  6957. "responses": {
  6958. "200": {
  6959. "$ref": "#/responses/PullReview"
  6960. },
  6961. "404": {
  6962. "$ref": "#/responses/notFound"
  6963. },
  6964. "422": {
  6965. "$ref": "#/responses/validationError"
  6966. }
  6967. }
  6968. },
  6969. "delete": {
  6970. "produces": [
  6971. "application/json"
  6972. ],
  6973. "tags": [
  6974. "repository"
  6975. ],
  6976. "summary": "Delete a specific review from a pull request",
  6977. "operationId": "repoDeletePullReview",
  6978. "parameters": [
  6979. {
  6980. "type": "string",
  6981. "description": "owner of the repo",
  6982. "name": "owner",
  6983. "in": "path",
  6984. "required": true
  6985. },
  6986. {
  6987. "type": "string",
  6988. "description": "name of the repo",
  6989. "name": "repo",
  6990. "in": "path",
  6991. "required": true
  6992. },
  6993. {
  6994. "type": "integer",
  6995. "format": "int64",
  6996. "description": "index of the pull request",
  6997. "name": "index",
  6998. "in": "path",
  6999. "required": true
  7000. },
  7001. {
  7002. "type": "integer",
  7003. "format": "int64",
  7004. "description": "id of the review",
  7005. "name": "id",
  7006. "in": "path",
  7007. "required": true
  7008. }
  7009. ],
  7010. "responses": {
  7011. "204": {
  7012. "$ref": "#/responses/empty"
  7013. },
  7014. "403": {
  7015. "$ref": "#/responses/forbidden"
  7016. },
  7017. "404": {
  7018. "$ref": "#/responses/notFound"
  7019. }
  7020. }
  7021. }
  7022. },
  7023. "/repos/{owner}/{repo}/pulls/{index}/reviews/{id}/comments": {
  7024. "get": {
  7025. "produces": [
  7026. "application/json"
  7027. ],
  7028. "tags": [
  7029. "repository"
  7030. ],
  7031. "summary": "Get a specific review for a pull request",
  7032. "operationId": "repoGetPullReviewComments",
  7033. "parameters": [
  7034. {
  7035. "type": "string",
  7036. "description": "owner of the repo",
  7037. "name": "owner",
  7038. "in": "path",
  7039. "required": true
  7040. },
  7041. {
  7042. "type": "string",
  7043. "description": "name of the repo",
  7044. "name": "repo",
  7045. "in": "path",
  7046. "required": true
  7047. },
  7048. {
  7049. "type": "integer",
  7050. "format": "int64",
  7051. "description": "index of the pull request",
  7052. "name": "index",
  7053. "in": "path",
  7054. "required": true
  7055. },
  7056. {
  7057. "type": "integer",
  7058. "format": "int64",
  7059. "description": "id of the review",
  7060. "name": "id",
  7061. "in": "path",
  7062. "required": true
  7063. }
  7064. ],
  7065. "responses": {
  7066. "200": {
  7067. "$ref": "#/responses/PullReviewCommentList"
  7068. },
  7069. "404": {
  7070. "$ref": "#/responses/notFound"
  7071. }
  7072. }
  7073. }
  7074. },
  7075. "/repos/{owner}/{repo}/raw/{filepath}": {
  7076. "get": {
  7077. "produces": [
  7078. "application/json"
  7079. ],
  7080. "tags": [
  7081. "repository"
  7082. ],
  7083. "summary": "Get a file from a repository",
  7084. "operationId": "repoGetRawFile",
  7085. "parameters": [
  7086. {
  7087. "type": "string",
  7088. "description": "owner of the repo",
  7089. "name": "owner",
  7090. "in": "path",
  7091. "required": true
  7092. },
  7093. {
  7094. "type": "string",
  7095. "description": "name of the repo",
  7096. "name": "repo",
  7097. "in": "path",
  7098. "required": true
  7099. },
  7100. {
  7101. "type": "string",
  7102. "description": "filepath of the file to get",
  7103. "name": "filepath",
  7104. "in": "path",
  7105. "required": true
  7106. }
  7107. ],
  7108. "responses": {
  7109. "200": {
  7110. "description": "success"
  7111. },
  7112. "404": {
  7113. "$ref": "#/responses/notFound"
  7114. }
  7115. }
  7116. }
  7117. },
  7118. "/repos/{owner}/{repo}/releases": {
  7119. "get": {
  7120. "produces": [
  7121. "application/json"
  7122. ],
  7123. "tags": [
  7124. "repository"
  7125. ],
  7126. "summary": "List a repo's releases",
  7127. "operationId": "repoListReleases",
  7128. "parameters": [
  7129. {
  7130. "type": "string",
  7131. "description": "owner of the repo",
  7132. "name": "owner",
  7133. "in": "path",
  7134. "required": true
  7135. },
  7136. {
  7137. "type": "string",
  7138. "description": "name of the repo",
  7139. "name": "repo",
  7140. "in": "path",
  7141. "required": true
  7142. },
  7143. {
  7144. "type": "integer",
  7145. "description": "items count every page wants to load",
  7146. "name": "per_page",
  7147. "in": "query"
  7148. },
  7149. {
  7150. "type": "integer",
  7151. "description": "page number of results to return (1-based)",
  7152. "name": "page",
  7153. "in": "query"
  7154. },
  7155. {
  7156. "type": "integer",
  7157. "description": "page size of results, maximum page size is 50",
  7158. "name": "limit",
  7159. "in": "query"
  7160. }
  7161. ],
  7162. "responses": {
  7163. "200": {
  7164. "$ref": "#/responses/ReleaseList"
  7165. }
  7166. }
  7167. },
  7168. "post": {
  7169. "consumes": [
  7170. "application/json"
  7171. ],
  7172. "produces": [
  7173. "application/json"
  7174. ],
  7175. "tags": [
  7176. "repository"
  7177. ],
  7178. "summary": "Create a release",
  7179. "operationId": "repoCreateRelease",
  7180. "parameters": [
  7181. {
  7182. "type": "string",
  7183. "description": "owner of the repo",
  7184. "name": "owner",
  7185. "in": "path",
  7186. "required": true
  7187. },
  7188. {
  7189. "type": "string",
  7190. "description": "name of the repo",
  7191. "name": "repo",
  7192. "in": "path",
  7193. "required": true
  7194. },
  7195. {
  7196. "name": "body",
  7197. "in": "body",
  7198. "schema": {
  7199. "$ref": "#/definitions/CreateReleaseOption"
  7200. }
  7201. }
  7202. ],
  7203. "responses": {
  7204. "201": {
  7205. "$ref": "#/responses/Release"
  7206. },
  7207. "409": {
  7208. "$ref": "#/responses/error"
  7209. }
  7210. }
  7211. }
  7212. },
  7213. "/repos/{owner}/{repo}/releases/{id}": {
  7214. "get": {
  7215. "produces": [
  7216. "application/json"
  7217. ],
  7218. "tags": [
  7219. "repository"
  7220. ],
  7221. "summary": "Get a release",
  7222. "operationId": "repoGetRelease",
  7223. "parameters": [
  7224. {
  7225. "type": "string",
  7226. "description": "owner of the repo",
  7227. "name": "owner",
  7228. "in": "path",
  7229. "required": true
  7230. },
  7231. {
  7232. "type": "string",
  7233. "description": "name of the repo",
  7234. "name": "repo",
  7235. "in": "path",
  7236. "required": true
  7237. },
  7238. {
  7239. "type": "integer",
  7240. "format": "int64",
  7241. "description": "id of the release to get",
  7242. "name": "id",
  7243. "in": "path",
  7244. "required": true
  7245. }
  7246. ],
  7247. "responses": {
  7248. "200": {
  7249. "$ref": "#/responses/Release"
  7250. }
  7251. }
  7252. },
  7253. "delete": {
  7254. "tags": [
  7255. "repository"
  7256. ],
  7257. "summary": "Delete a release",
  7258. "operationId": "repoDeleteRelease",
  7259. "parameters": [
  7260. {
  7261. "type": "string",
  7262. "description": "owner of the repo",
  7263. "name": "owner",
  7264. "in": "path",
  7265. "required": true
  7266. },
  7267. {
  7268. "type": "string",
  7269. "description": "name of the repo",
  7270. "name": "repo",
  7271. "in": "path",
  7272. "required": true
  7273. },
  7274. {
  7275. "type": "integer",
  7276. "format": "int64",
  7277. "description": "id of the release to delete",
  7278. "name": "id",
  7279. "in": "path",
  7280. "required": true
  7281. }
  7282. ],
  7283. "responses": {
  7284. "204": {
  7285. "$ref": "#/responses/empty"
  7286. }
  7287. }
  7288. },
  7289. "patch": {
  7290. "consumes": [
  7291. "application/json"
  7292. ],
  7293. "produces": [
  7294. "application/json"
  7295. ],
  7296. "tags": [
  7297. "repository"
  7298. ],
  7299. "summary": "Update a release",
  7300. "operationId": "repoEditRelease",
  7301. "parameters": [
  7302. {
  7303. "type": "string",
  7304. "description": "owner of the repo",
  7305. "name": "owner",
  7306. "in": "path",
  7307. "required": true
  7308. },
  7309. {
  7310. "type": "string",
  7311. "description": "name of the repo",
  7312. "name": "repo",
  7313. "in": "path",
  7314. "required": true
  7315. },
  7316. {
  7317. "type": "integer",
  7318. "format": "int64",
  7319. "description": "id of the release to edit",
  7320. "name": "id",
  7321. "in": "path",
  7322. "required": true
  7323. },
  7324. {
  7325. "name": "body",
  7326. "in": "body",
  7327. "schema": {
  7328. "$ref": "#/definitions/EditReleaseOption"
  7329. }
  7330. }
  7331. ],
  7332. "responses": {
  7333. "200": {
  7334. "$ref": "#/responses/Release"
  7335. }
  7336. }
  7337. }
  7338. },
  7339. "/repos/{owner}/{repo}/releases/{id}/assets": {
  7340. "get": {
  7341. "produces": [
  7342. "application/json"
  7343. ],
  7344. "tags": [
  7345. "repository"
  7346. ],
  7347. "summary": "List release's attachments",
  7348. "operationId": "repoListReleaseAttachments",
  7349. "parameters": [
  7350. {
  7351. "type": "string",
  7352. "description": "owner of the repo",
  7353. "name": "owner",
  7354. "in": "path",
  7355. "required": true
  7356. },
  7357. {
  7358. "type": "string",
  7359. "description": "name of the repo",
  7360. "name": "repo",
  7361. "in": "path",
  7362. "required": true
  7363. },
  7364. {
  7365. "type": "integer",
  7366. "format": "int64",
  7367. "description": "id of the release",
  7368. "name": "id",
  7369. "in": "path",
  7370. "required": true
  7371. }
  7372. ],
  7373. "responses": {
  7374. "200": {
  7375. "$ref": "#/responses/AttachmentList"
  7376. }
  7377. }
  7378. },
  7379. "post": {
  7380. "consumes": [
  7381. "multipart/form-data"
  7382. ],
  7383. "produces": [
  7384. "application/json"
  7385. ],
  7386. "tags": [
  7387. "repository"
  7388. ],
  7389. "summary": "Create a release attachment",
  7390. "operationId": "repoCreateReleaseAttachment",
  7391. "parameters": [
  7392. {
  7393. "type": "string",
  7394. "description": "owner of the repo",
  7395. "name": "owner",
  7396. "in": "path",
  7397. "required": true
  7398. },
  7399. {
  7400. "type": "string",
  7401. "description": "name of the repo",
  7402. "name": "repo",
  7403. "in": "path",
  7404. "required": true
  7405. },
  7406. {
  7407. "type": "integer",
  7408. "format": "int64",
  7409. "description": "id of the release",
  7410. "name": "id",
  7411. "in": "path",
  7412. "required": true
  7413. },
  7414. {
  7415. "type": "string",
  7416. "description": "name of the attachment",
  7417. "name": "name",
  7418. "in": "query"
  7419. },
  7420. {
  7421. "type": "file",
  7422. "description": "attachment to upload",
  7423. "name": "attachment",
  7424. "in": "formData",
  7425. "required": true
  7426. }
  7427. ],
  7428. "responses": {
  7429. "201": {
  7430. "$ref": "#/responses/Attachment"
  7431. },
  7432. "400": {
  7433. "$ref": "#/responses/error"
  7434. }
  7435. }
  7436. }
  7437. },
  7438. "/repos/{owner}/{repo}/releases/{id}/assets/{attachment_id}": {
  7439. "get": {
  7440. "produces": [
  7441. "application/json"
  7442. ],
  7443. "tags": [
  7444. "repository"
  7445. ],
  7446. "summary": "Get a release attachment",
  7447. "operationId": "repoGetReleaseAttachment",
  7448. "parameters": [
  7449. {
  7450. "type": "string",
  7451. "description": "owner of the repo",
  7452. "name": "owner",
  7453. "in": "path",
  7454. "required": true
  7455. },
  7456. {
  7457. "type": "string",
  7458. "description": "name of the repo",
  7459. "name": "repo",
  7460. "in": "path",
  7461. "required": true
  7462. },
  7463. {
  7464. "type": "integer",
  7465. "format": "int64",
  7466. "description": "id of the release",
  7467. "name": "id",
  7468. "in": "path",
  7469. "required": true
  7470. },
  7471. {
  7472. "type": "integer",
  7473. "format": "int64",
  7474. "description": "id of the attachment to get",
  7475. "name": "attachment_id",
  7476. "in": "path",
  7477. "required": true
  7478. }
  7479. ],
  7480. "responses": {
  7481. "200": {
  7482. "$ref": "#/responses/Attachment"
  7483. }
  7484. }
  7485. },
  7486. "delete": {
  7487. "produces": [
  7488. "application/json"
  7489. ],
  7490. "tags": [
  7491. "repository"
  7492. ],
  7493. "summary": "Delete a release attachment",
  7494. "operationId": "repoDeleteReleaseAttachment",
  7495. "parameters": [
  7496. {
  7497. "type": "string",
  7498. "description": "owner of the repo",
  7499. "name": "owner",
  7500. "in": "path",
  7501. "required": true
  7502. },
  7503. {
  7504. "type": "string",
  7505. "description": "name of the repo",
  7506. "name": "repo",
  7507. "in": "path",
  7508. "required": true
  7509. },
  7510. {
  7511. "type": "integer",
  7512. "format": "int64",
  7513. "description": "id of the release",
  7514. "name": "id",
  7515. "in": "path",
  7516. "required": true
  7517. },
  7518. {
  7519. "type": "integer",
  7520. "format": "int64",
  7521. "description": "id of the attachment to delete",
  7522. "name": "attachment_id",
  7523. "in": "path",
  7524. "required": true
  7525. }
  7526. ],
  7527. "responses": {
  7528. "204": {
  7529. "$ref": "#/responses/empty"
  7530. }
  7531. }
  7532. },
  7533. "patch": {
  7534. "consumes": [
  7535. "application/json"
  7536. ],
  7537. "produces": [
  7538. "application/json"
  7539. ],
  7540. "tags": [
  7541. "repository"
  7542. ],
  7543. "summary": "Edit a release attachment",
  7544. "operationId": "repoEditReleaseAttachment",
  7545. "parameters": [
  7546. {
  7547. "type": "string",
  7548. "description": "owner of the repo",
  7549. "name": "owner",
  7550. "in": "path",
  7551. "required": true
  7552. },
  7553. {
  7554. "type": "string",
  7555. "description": "name of the repo",
  7556. "name": "repo",
  7557. "in": "path",
  7558. "required": true
  7559. },
  7560. {
  7561. "type": "integer",
  7562. "format": "int64",
  7563. "description": "id of the release",
  7564. "name": "id",
  7565. "in": "path",
  7566. "required": true
  7567. },
  7568. {
  7569. "type": "integer",
  7570. "format": "int64",
  7571. "description": "id of the attachment to edit",
  7572. "name": "attachment_id",
  7573. "in": "path",
  7574. "required": true
  7575. },
  7576. {
  7577. "name": "body",
  7578. "in": "body",
  7579. "schema": {
  7580. "$ref": "#/definitions/EditAttachmentOptions"
  7581. }
  7582. }
  7583. ],
  7584. "responses": {
  7585. "201": {
  7586. "$ref": "#/responses/Attachment"
  7587. }
  7588. }
  7589. }
  7590. },
  7591. "/repos/{owner}/{repo}/signing-key.gpg": {
  7592. "get": {
  7593. "produces": [
  7594. "text/plain"
  7595. ],
  7596. "tags": [
  7597. "repository"
  7598. ],
  7599. "summary": "Get signing-key.gpg for given repository",
  7600. "operationId": "repoSigningKey",
  7601. "parameters": [
  7602. {
  7603. "type": "string",
  7604. "description": "owner of the repo",
  7605. "name": "owner",
  7606. "in": "path",
  7607. "required": true
  7608. },
  7609. {
  7610. "type": "string",
  7611. "description": "name of the repo",
  7612. "name": "repo",
  7613. "in": "path",
  7614. "required": true
  7615. }
  7616. ],
  7617. "responses": {
  7618. "200": {
  7619. "description": "GPG armored public key",
  7620. "schema": {
  7621. "type": "string"
  7622. }
  7623. }
  7624. }
  7625. }
  7626. },
  7627. "/repos/{owner}/{repo}/stargazers": {
  7628. "get": {
  7629. "produces": [
  7630. "application/json"
  7631. ],
  7632. "tags": [
  7633. "repository"
  7634. ],
  7635. "summary": "List a repo's stargazers",
  7636. "operationId": "repoListStargazers",
  7637. "parameters": [
  7638. {
  7639. "type": "string",
  7640. "description": "owner of the repo",
  7641. "name": "owner",
  7642. "in": "path",
  7643. "required": true
  7644. },
  7645. {
  7646. "type": "string",
  7647. "description": "name of the repo",
  7648. "name": "repo",
  7649. "in": "path",
  7650. "required": true
  7651. },
  7652. {
  7653. "type": "integer",
  7654. "description": "page number of results to return (1-based)",
  7655. "name": "page",
  7656. "in": "query"
  7657. },
  7658. {
  7659. "type": "integer",
  7660. "description": "page size of results, maximum page size is 50",
  7661. "name": "limit",
  7662. "in": "query"
  7663. }
  7664. ],
  7665. "responses": {
  7666. "200": {
  7667. "$ref": "#/responses/UserList"
  7668. }
  7669. }
  7670. }
  7671. },
  7672. "/repos/{owner}/{repo}/statuses/{sha}": {
  7673. "get": {
  7674. "produces": [
  7675. "application/json"
  7676. ],
  7677. "tags": [
  7678. "repository"
  7679. ],
  7680. "summary": "Get a commit's statuses",
  7681. "operationId": "repoListStatuses",
  7682. "parameters": [
  7683. {
  7684. "type": "string",
  7685. "description": "owner of the repo",
  7686. "name": "owner",
  7687. "in": "path",
  7688. "required": true
  7689. },
  7690. {
  7691. "type": "string",
  7692. "description": "name of the repo",
  7693. "name": "repo",
  7694. "in": "path",
  7695. "required": true
  7696. },
  7697. {
  7698. "type": "string",
  7699. "description": "sha of the commit",
  7700. "name": "sha",
  7701. "in": "path",
  7702. "required": true
  7703. },
  7704. {
  7705. "enum": [
  7706. "oldest",
  7707. "recentupdate",
  7708. "leastupdate",
  7709. "leastindex",
  7710. "highestindex"
  7711. ],
  7712. "type": "string",
  7713. "description": "type of sort",
  7714. "name": "sort",
  7715. "in": "query"
  7716. },
  7717. {
  7718. "enum": [
  7719. "pending",
  7720. "success",
  7721. "error",
  7722. "failure",
  7723. "warning"
  7724. ],
  7725. "type": "string",
  7726. "description": "type of state",
  7727. "name": "state",
  7728. "in": "query"
  7729. },
  7730. {
  7731. "type": "integer",
  7732. "description": "page number of results to return (1-based)",
  7733. "name": "page",
  7734. "in": "query"
  7735. },
  7736. {
  7737. "type": "integer",
  7738. "description": "page size of results, maximum page size is 50",
  7739. "name": "limit",
  7740. "in": "query"
  7741. }
  7742. ],
  7743. "responses": {
  7744. "200": {
  7745. "$ref": "#/responses/StatusList"
  7746. },
  7747. "400": {
  7748. "$ref": "#/responses/error"
  7749. }
  7750. }
  7751. },
  7752. "post": {
  7753. "produces": [
  7754. "application/json"
  7755. ],
  7756. "tags": [
  7757. "repository"
  7758. ],
  7759. "summary": "Create a commit status",
  7760. "operationId": "repoCreateStatus",
  7761. "parameters": [
  7762. {
  7763. "type": "string",
  7764. "description": "owner of the repo",
  7765. "name": "owner",
  7766. "in": "path",
  7767. "required": true
  7768. },
  7769. {
  7770. "type": "string",
  7771. "description": "name of the repo",
  7772. "name": "repo",
  7773. "in": "path",
  7774. "required": true
  7775. },
  7776. {
  7777. "type": "string",
  7778. "description": "sha of the commit",
  7779. "name": "sha",
  7780. "in": "path",
  7781. "required": true
  7782. },
  7783. {
  7784. "name": "body",
  7785. "in": "body",
  7786. "schema": {
  7787. "$ref": "#/definitions/CreateStatusOption"
  7788. }
  7789. }
  7790. ],
  7791. "responses": {
  7792. "201": {
  7793. "$ref": "#/responses/Status"
  7794. },
  7795. "400": {
  7796. "$ref": "#/responses/error"
  7797. }
  7798. }
  7799. }
  7800. },
  7801. "/repos/{owner}/{repo}/subscribers": {
  7802. "get": {
  7803. "produces": [
  7804. "application/json"
  7805. ],
  7806. "tags": [
  7807. "repository"
  7808. ],
  7809. "summary": "List a repo's watchers",
  7810. "operationId": "repoListSubscribers",
  7811. "parameters": [
  7812. {
  7813. "type": "string",
  7814. "description": "owner of the repo",
  7815. "name": "owner",
  7816. "in": "path",
  7817. "required": true
  7818. },
  7819. {
  7820. "type": "string",
  7821. "description": "name of the repo",
  7822. "name": "repo",
  7823. "in": "path",
  7824. "required": true
  7825. },
  7826. {
  7827. "type": "integer",
  7828. "description": "page number of results to return (1-based)",
  7829. "name": "page",
  7830. "in": "query"
  7831. },
  7832. {
  7833. "type": "integer",
  7834. "description": "page size of results, maximum page size is 50",
  7835. "name": "limit",
  7836. "in": "query"
  7837. }
  7838. ],
  7839. "responses": {
  7840. "200": {
  7841. "$ref": "#/responses/UserList"
  7842. }
  7843. }
  7844. }
  7845. },
  7846. "/repos/{owner}/{repo}/subscription": {
  7847. "get": {
  7848. "tags": [
  7849. "repository"
  7850. ],
  7851. "summary": "Check if the current user is watching a repo",
  7852. "operationId": "userCurrentCheckSubscription",
  7853. "parameters": [
  7854. {
  7855. "type": "string",
  7856. "description": "owner of the repo",
  7857. "name": "owner",
  7858. "in": "path",
  7859. "required": true
  7860. },
  7861. {
  7862. "type": "string",
  7863. "description": "name of the repo",
  7864. "name": "repo",
  7865. "in": "path",
  7866. "required": true
  7867. }
  7868. ],
  7869. "responses": {
  7870. "200": {
  7871. "$ref": "#/responses/WatchInfo"
  7872. },
  7873. "404": {
  7874. "description": "User is not watching this repo or repo do not exist"
  7875. }
  7876. }
  7877. },
  7878. "put": {
  7879. "tags": [
  7880. "repository"
  7881. ],
  7882. "summary": "Watch a repo",
  7883. "operationId": "userCurrentPutSubscription",
  7884. "parameters": [
  7885. {
  7886. "type": "string",
  7887. "description": "owner of the repo",
  7888. "name": "owner",
  7889. "in": "path",
  7890. "required": true
  7891. },
  7892. {
  7893. "type": "string",
  7894. "description": "name of the repo",
  7895. "name": "repo",
  7896. "in": "path",
  7897. "required": true
  7898. }
  7899. ],
  7900. "responses": {
  7901. "200": {
  7902. "$ref": "#/responses/WatchInfo"
  7903. }
  7904. }
  7905. },
  7906. "delete": {
  7907. "tags": [
  7908. "repository"
  7909. ],
  7910. "summary": "Unwatch a repo",
  7911. "operationId": "userCurrentDeleteSubscription",
  7912. "parameters": [
  7913. {
  7914. "type": "string",
  7915. "description": "owner of the repo",
  7916. "name": "owner",
  7917. "in": "path",
  7918. "required": true
  7919. },
  7920. {
  7921. "type": "string",
  7922. "description": "name of the repo",
  7923. "name": "repo",
  7924. "in": "path",
  7925. "required": true
  7926. }
  7927. ],
  7928. "responses": {
  7929. "204": {
  7930. "$ref": "#/responses/empty"
  7931. }
  7932. }
  7933. }
  7934. },
  7935. "/repos/{owner}/{repo}/tags": {
  7936. "get": {
  7937. "produces": [
  7938. "application/json"
  7939. ],
  7940. "tags": [
  7941. "repository"
  7942. ],
  7943. "summary": "List a repository's tags",
  7944. "operationId": "repoListTags",
  7945. "parameters": [
  7946. {
  7947. "type": "string",
  7948. "description": "owner of the repo",
  7949. "name": "owner",
  7950. "in": "path",
  7951. "required": true
  7952. },
  7953. {
  7954. "type": "string",
  7955. "description": "name of the repo",
  7956. "name": "repo",
  7957. "in": "path",
  7958. "required": true
  7959. },
  7960. {
  7961. "type": "integer",
  7962. "description": "page number of results to return (1-based)",
  7963. "name": "page",
  7964. "in": "query"
  7965. },
  7966. {
  7967. "type": "integer",
  7968. "description": "page size of results, default maximum page size is 50",
  7969. "name": "limit",
  7970. "in": "query"
  7971. }
  7972. ],
  7973. "responses": {
  7974. "200": {
  7975. "$ref": "#/responses/TagList"
  7976. }
  7977. }
  7978. }
  7979. },
  7980. "/repos/{owner}/{repo}/times": {
  7981. "get": {
  7982. "produces": [
  7983. "application/json"
  7984. ],
  7985. "tags": [
  7986. "repository"
  7987. ],
  7988. "summary": "List a repo's tracked times",
  7989. "operationId": "repoTrackedTimes",
  7990. "parameters": [
  7991. {
  7992. "type": "string",
  7993. "description": "owner of the repo",
  7994. "name": "owner",
  7995. "in": "path",
  7996. "required": true
  7997. },
  7998. {
  7999. "type": "string",
  8000. "description": "name of the repo",
  8001. "name": "repo",
  8002. "in": "path",
  8003. "required": true
  8004. },
  8005. {
  8006. "type": "string",
  8007. "description": "optional filter by user",
  8008. "name": "user",
  8009. "in": "query"
  8010. },
  8011. {
  8012. "type": "string",
  8013. "format": "date-time",
  8014. "description": "Only show times updated after the given time. This is a timestamp in RFC 3339 format",
  8015. "name": "since",
  8016. "in": "query"
  8017. },
  8018. {
  8019. "type": "string",
  8020. "format": "date-time",
  8021. "description": "Only show times updated before the given time. This is a timestamp in RFC 3339 format",
  8022. "name": "before",
  8023. "in": "query"
  8024. },
  8025. {
  8026. "type": "integer",
  8027. "description": "page number of results to return (1-based)",
  8028. "name": "page",
  8029. "in": "query"
  8030. },
  8031. {
  8032. "type": "integer",
  8033. "description": "page size of results, maximum page size is 50",
  8034. "name": "limit",
  8035. "in": "query"
  8036. }
  8037. ],
  8038. "responses": {
  8039. "200": {
  8040. "$ref": "#/responses/TrackedTimeList"
  8041. },
  8042. "400": {
  8043. "$ref": "#/responses/error"
  8044. },
  8045. "403": {
  8046. "$ref": "#/responses/forbidden"
  8047. }
  8048. }
  8049. }
  8050. },
  8051. "/repos/{owner}/{repo}/times/{user}": {
  8052. "get": {
  8053. "produces": [
  8054. "application/json"
  8055. ],
  8056. "tags": [
  8057. "repository"
  8058. ],
  8059. "summary": "List a user's tracked times in a repo",
  8060. "operationId": "userTrackedTimes",
  8061. "deprecated": true,
  8062. "parameters": [
  8063. {
  8064. "type": "string",
  8065. "description": "owner of the repo",
  8066. "name": "owner",
  8067. "in": "path",
  8068. "required": true
  8069. },
  8070. {
  8071. "type": "string",
  8072. "description": "name of the repo",
  8073. "name": "repo",
  8074. "in": "path",
  8075. "required": true
  8076. },
  8077. {
  8078. "type": "string",
  8079. "description": "username of user",
  8080. "name": "user",
  8081. "in": "path",
  8082. "required": true
  8083. }
  8084. ],
  8085. "responses": {
  8086. "200": {
  8087. "$ref": "#/responses/TrackedTimeList"
  8088. },
  8089. "400": {
  8090. "$ref": "#/responses/error"
  8091. },
  8092. "403": {
  8093. "$ref": "#/responses/forbidden"
  8094. }
  8095. }
  8096. }
  8097. },
  8098. "/repos/{owner}/{repo}/topics": {
  8099. "get": {
  8100. "produces": [
  8101. "application/json"
  8102. ],
  8103. "tags": [
  8104. "repository"
  8105. ],
  8106. "summary": "Get list of topics that a repository has",
  8107. "operationId": "repoListTopics",
  8108. "parameters": [
  8109. {
  8110. "type": "string",
  8111. "description": "owner of the repo",
  8112. "name": "owner",
  8113. "in": "path",
  8114. "required": true
  8115. },
  8116. {
  8117. "type": "string",
  8118. "description": "name of the repo",
  8119. "name": "repo",
  8120. "in": "path",
  8121. "required": true
  8122. },
  8123. {
  8124. "type": "integer",
  8125. "description": "page number of results to return (1-based)",
  8126. "name": "page",
  8127. "in": "query"
  8128. },
  8129. {
  8130. "type": "integer",
  8131. "description": "page size of results, maximum page size is 50",
  8132. "name": "limit",
  8133. "in": "query"
  8134. }
  8135. ],
  8136. "responses": {
  8137. "200": {
  8138. "$ref": "#/responses/TopicNames"
  8139. }
  8140. }
  8141. },
  8142. "put": {
  8143. "produces": [
  8144. "application/json"
  8145. ],
  8146. "tags": [
  8147. "repository"
  8148. ],
  8149. "summary": "Replace list of topics for a repository",
  8150. "operationId": "repoUpdateTopics",
  8151. "parameters": [
  8152. {
  8153. "type": "string",
  8154. "description": "owner of the repo",
  8155. "name": "owner",
  8156. "in": "path",
  8157. "required": true
  8158. },
  8159. {
  8160. "type": "string",
  8161. "description": "name of the repo",
  8162. "name": "repo",
  8163. "in": "path",
  8164. "required": true
  8165. },
  8166. {
  8167. "name": "body",
  8168. "in": "body",
  8169. "schema": {
  8170. "$ref": "#/definitions/RepoTopicOptions"
  8171. }
  8172. }
  8173. ],
  8174. "responses": {
  8175. "204": {
  8176. "$ref": "#/responses/empty"
  8177. },
  8178. "422": {
  8179. "$ref": "#/responses/invalidTopicsError"
  8180. }
  8181. }
  8182. }
  8183. },
  8184. "/repos/{owner}/{repo}/topics/{topic}": {
  8185. "put": {
  8186. "produces": [
  8187. "application/json"
  8188. ],
  8189. "tags": [
  8190. "repository"
  8191. ],
  8192. "summary": "Add a topic to a repository",
  8193. "operationId": "repoAddTopíc",
  8194. "parameters": [
  8195. {
  8196. "type": "string",
  8197. "description": "owner of the repo",
  8198. "name": "owner",
  8199. "in": "path",
  8200. "required": true
  8201. },
  8202. {
  8203. "type": "string",
  8204. "description": "name of the repo",
  8205. "name": "repo",
  8206. "in": "path",
  8207. "required": true
  8208. },
  8209. {
  8210. "type": "string",
  8211. "description": "name of the topic to add",
  8212. "name": "topic",
  8213. "in": "path",
  8214. "required": true
  8215. }
  8216. ],
  8217. "responses": {
  8218. "204": {
  8219. "$ref": "#/responses/empty"
  8220. },
  8221. "422": {
  8222. "$ref": "#/responses/invalidTopicsError"
  8223. }
  8224. }
  8225. },
  8226. "delete": {
  8227. "produces": [
  8228. "application/json"
  8229. ],
  8230. "tags": [
  8231. "repository"
  8232. ],
  8233. "summary": "Delete a topic from a repository",
  8234. "operationId": "repoDeleteTopic",
  8235. "parameters": [
  8236. {
  8237. "type": "string",
  8238. "description": "owner of the repo",
  8239. "name": "owner",
  8240. "in": "path",
  8241. "required": true
  8242. },
  8243. {
  8244. "type": "string",
  8245. "description": "name of the repo",
  8246. "name": "repo",
  8247. "in": "path",
  8248. "required": true
  8249. },
  8250. {
  8251. "type": "string",
  8252. "description": "name of the topic to delete",
  8253. "name": "topic",
  8254. "in": "path",
  8255. "required": true
  8256. }
  8257. ],
  8258. "responses": {
  8259. "204": {
  8260. "$ref": "#/responses/empty"
  8261. },
  8262. "422": {
  8263. "$ref": "#/responses/invalidTopicsError"
  8264. }
  8265. }
  8266. }
  8267. },
  8268. "/repos/{owner}/{repo}/transfer": {
  8269. "post": {
  8270. "produces": [
  8271. "application/json"
  8272. ],
  8273. "tags": [
  8274. "repository"
  8275. ],
  8276. "summary": "Transfer a repo ownership",
  8277. "operationId": "repoTransfer",
  8278. "parameters": [
  8279. {
  8280. "type": "string",
  8281. "description": "owner of the repo to transfer",
  8282. "name": "owner",
  8283. "in": "path",
  8284. "required": true
  8285. },
  8286. {
  8287. "type": "string",
  8288. "description": "name of the repo to transfer",
  8289. "name": "repo",
  8290. "in": "path",
  8291. "required": true
  8292. },
  8293. {
  8294. "description": "Transfer Options",
  8295. "name": "body",
  8296. "in": "body",
  8297. "required": true,
  8298. "schema": {
  8299. "$ref": "#/definitions/TransferRepoOption"
  8300. }
  8301. }
  8302. ],
  8303. "responses": {
  8304. "202": {
  8305. "$ref": "#/responses/Repository"
  8306. },
  8307. "403": {
  8308. "$ref": "#/responses/forbidden"
  8309. },
  8310. "404": {
  8311. "$ref": "#/responses/notFound"
  8312. },
  8313. "422": {
  8314. "$ref": "#/responses/validationError"
  8315. }
  8316. }
  8317. }
  8318. },
  8319. "/repositories/{id}": {
  8320. "get": {
  8321. "produces": [
  8322. "application/json"
  8323. ],
  8324. "tags": [
  8325. "repository"
  8326. ],
  8327. "summary": "Get a repository by id",
  8328. "operationId": "repoGetByID",
  8329. "parameters": [
  8330. {
  8331. "type": "integer",
  8332. "format": "int64",
  8333. "description": "id of the repo to get",
  8334. "name": "id",
  8335. "in": "path",
  8336. "required": true
  8337. }
  8338. ],
  8339. "responses": {
  8340. "200": {
  8341. "$ref": "#/responses/Repository"
  8342. }
  8343. }
  8344. }
  8345. },
  8346. "/signing-key.gpg": {
  8347. "get": {
  8348. "produces": [
  8349. "text/plain"
  8350. ],
  8351. "tags": [
  8352. "miscellaneous"
  8353. ],
  8354. "summary": "Get default signing-key.gpg",
  8355. "operationId": "getSigningKey",
  8356. "responses": {
  8357. "200": {
  8358. "description": "GPG armored public key",
  8359. "schema": {
  8360. "type": "string"
  8361. }
  8362. }
  8363. }
  8364. }
  8365. },
  8366. "/teams/{id}": {
  8367. "get": {
  8368. "produces": [
  8369. "application/json"
  8370. ],
  8371. "tags": [
  8372. "organization"
  8373. ],
  8374. "summary": "Get a team",
  8375. "operationId": "orgGetTeam",
  8376. "parameters": [
  8377. {
  8378. "type": "integer",
  8379. "format": "int64",
  8380. "description": "id of the team to get",
  8381. "name": "id",
  8382. "in": "path",
  8383. "required": true
  8384. }
  8385. ],
  8386. "responses": {
  8387. "200": {
  8388. "$ref": "#/responses/Team"
  8389. }
  8390. }
  8391. },
  8392. "delete": {
  8393. "tags": [
  8394. "organization"
  8395. ],
  8396. "summary": "Delete a team",
  8397. "operationId": "orgDeleteTeam",
  8398. "parameters": [
  8399. {
  8400. "type": "integer",
  8401. "format": "int64",
  8402. "description": "id of the team to delete",
  8403. "name": "id",
  8404. "in": "path",
  8405. "required": true
  8406. }
  8407. ],
  8408. "responses": {
  8409. "204": {
  8410. "description": "team deleted"
  8411. }
  8412. }
  8413. },
  8414. "patch": {
  8415. "consumes": [
  8416. "application/json"
  8417. ],
  8418. "produces": [
  8419. "application/json"
  8420. ],
  8421. "tags": [
  8422. "organization"
  8423. ],
  8424. "summary": "Edit a team",
  8425. "operationId": "orgEditTeam",
  8426. "parameters": [
  8427. {
  8428. "type": "integer",
  8429. "description": "id of the team to edit",
  8430. "name": "id",
  8431. "in": "path",
  8432. "required": true
  8433. },
  8434. {
  8435. "name": "body",
  8436. "in": "body",
  8437. "schema": {
  8438. "$ref": "#/definitions/EditTeamOption"
  8439. }
  8440. }
  8441. ],
  8442. "responses": {
  8443. "200": {
  8444. "$ref": "#/responses/Team"
  8445. }
  8446. }
  8447. }
  8448. },
  8449. "/teams/{id}/members": {
  8450. "get": {
  8451. "produces": [
  8452. "application/json"
  8453. ],
  8454. "tags": [
  8455. "organization"
  8456. ],
  8457. "summary": "List a team's members",
  8458. "operationId": "orgListTeamMembers",
  8459. "parameters": [
  8460. {
  8461. "type": "integer",
  8462. "format": "int64",
  8463. "description": "id of the team",
  8464. "name": "id",
  8465. "in": "path",
  8466. "required": true
  8467. },
  8468. {
  8469. "type": "integer",
  8470. "description": "page number of results to return (1-based)",
  8471. "name": "page",
  8472. "in": "query"
  8473. },
  8474. {
  8475. "type": "integer",
  8476. "description": "page size of results, maximum page size is 50",
  8477. "name": "limit",
  8478. "in": "query"
  8479. }
  8480. ],
  8481. "responses": {
  8482. "200": {
  8483. "$ref": "#/responses/UserList"
  8484. }
  8485. }
  8486. }
  8487. },
  8488. "/teams/{id}/members/{username}": {
  8489. "get": {
  8490. "produces": [
  8491. "application/json"
  8492. ],
  8493. "tags": [
  8494. "organization"
  8495. ],
  8496. "summary": "List a particular member of team",
  8497. "operationId": "orgListTeamMember",
  8498. "parameters": [
  8499. {
  8500. "type": "integer",
  8501. "format": "int64",
  8502. "description": "id of the team",
  8503. "name": "id",
  8504. "in": "path",
  8505. "required": true
  8506. },
  8507. {
  8508. "type": "string",
  8509. "description": "username of the member to list",
  8510. "name": "username",
  8511. "in": "path",
  8512. "required": true
  8513. }
  8514. ],
  8515. "responses": {
  8516. "200": {
  8517. "$ref": "#/responses/User"
  8518. },
  8519. "404": {
  8520. "$ref": "#/responses/notFound"
  8521. }
  8522. }
  8523. },
  8524. "put": {
  8525. "produces": [
  8526. "application/json"
  8527. ],
  8528. "tags": [
  8529. "organization"
  8530. ],
  8531. "summary": "Add a team member",
  8532. "operationId": "orgAddTeamMember",
  8533. "parameters": [
  8534. {
  8535. "type": "integer",
  8536. "format": "int64",
  8537. "description": "id of the team",
  8538. "name": "id",
  8539. "in": "path",
  8540. "required": true
  8541. },
  8542. {
  8543. "type": "string",
  8544. "description": "username of the user to add",
  8545. "name": "username",
  8546. "in": "path",
  8547. "required": true
  8548. }
  8549. ],
  8550. "responses": {
  8551. "204": {
  8552. "$ref": "#/responses/empty"
  8553. },
  8554. "404": {
  8555. "$ref": "#/responses/notFound"
  8556. }
  8557. }
  8558. },
  8559. "delete": {
  8560. "produces": [
  8561. "application/json"
  8562. ],
  8563. "tags": [
  8564. "organization"
  8565. ],
  8566. "summary": "Remove a team member",
  8567. "operationId": "orgRemoveTeamMember",
  8568. "parameters": [
  8569. {
  8570. "type": "integer",
  8571. "format": "int64",
  8572. "description": "id of the team",
  8573. "name": "id",
  8574. "in": "path",
  8575. "required": true
  8576. },
  8577. {
  8578. "type": "string",
  8579. "description": "username of the user to remove",
  8580. "name": "username",
  8581. "in": "path",
  8582. "required": true
  8583. }
  8584. ],
  8585. "responses": {
  8586. "204": {
  8587. "$ref": "#/responses/empty"
  8588. },
  8589. "404": {
  8590. "$ref": "#/responses/notFound"
  8591. }
  8592. }
  8593. }
  8594. },
  8595. "/teams/{id}/repos": {
  8596. "get": {
  8597. "produces": [
  8598. "application/json"
  8599. ],
  8600. "tags": [
  8601. "organization"
  8602. ],
  8603. "summary": "List a team's repos",
  8604. "operationId": "orgListTeamRepos",
  8605. "parameters": [
  8606. {
  8607. "type": "integer",
  8608. "format": "int64",
  8609. "description": "id of the team",
  8610. "name": "id",
  8611. "in": "path",
  8612. "required": true
  8613. },
  8614. {
  8615. "type": "integer",
  8616. "description": "page number of results to return (1-based)",
  8617. "name": "page",
  8618. "in": "query"
  8619. },
  8620. {
  8621. "type": "integer",
  8622. "description": "page size of results, maximum page size is 50",
  8623. "name": "limit",
  8624. "in": "query"
  8625. }
  8626. ],
  8627. "responses": {
  8628. "200": {
  8629. "$ref": "#/responses/RepositoryList"
  8630. }
  8631. }
  8632. }
  8633. },
  8634. "/teams/{id}/repos/{org}/{repo}": {
  8635. "put": {
  8636. "produces": [
  8637. "application/json"
  8638. ],
  8639. "tags": [
  8640. "organization"
  8641. ],
  8642. "summary": "Add a repository to a team",
  8643. "operationId": "orgAddTeamRepository",
  8644. "parameters": [
  8645. {
  8646. "type": "integer",
  8647. "format": "int64",
  8648. "description": "id of the team",
  8649. "name": "id",
  8650. "in": "path",
  8651. "required": true
  8652. },
  8653. {
  8654. "type": "string",
  8655. "description": "organization that owns the repo to add",
  8656. "name": "org",
  8657. "in": "path",
  8658. "required": true
  8659. },
  8660. {
  8661. "type": "string",
  8662. "description": "name of the repo to add",
  8663. "name": "repo",
  8664. "in": "path",
  8665. "required": true
  8666. }
  8667. ],
  8668. "responses": {
  8669. "204": {
  8670. "$ref": "#/responses/empty"
  8671. },
  8672. "403": {
  8673. "$ref": "#/responses/forbidden"
  8674. }
  8675. }
  8676. },
  8677. "delete": {
  8678. "description": "This does not delete the repository, it only removes the repository from the team.",
  8679. "produces": [
  8680. "application/json"
  8681. ],
  8682. "tags": [
  8683. "organization"
  8684. ],
  8685. "summary": "Remove a repository from a team",
  8686. "operationId": "orgRemoveTeamRepository",
  8687. "parameters": [
  8688. {
  8689. "type": "integer",
  8690. "format": "int64",
  8691. "description": "id of the team",
  8692. "name": "id",
  8693. "in": "path",
  8694. "required": true
  8695. },
  8696. {
  8697. "type": "string",
  8698. "description": "organization that owns the repo to remove",
  8699. "name": "org",
  8700. "in": "path",
  8701. "required": true
  8702. },
  8703. {
  8704. "type": "string",
  8705. "description": "name of the repo to remove",
  8706. "name": "repo",
  8707. "in": "path",
  8708. "required": true
  8709. }
  8710. ],
  8711. "responses": {
  8712. "204": {
  8713. "$ref": "#/responses/empty"
  8714. },
  8715. "403": {
  8716. "$ref": "#/responses/forbidden"
  8717. }
  8718. }
  8719. }
  8720. },
  8721. "/topics/search": {
  8722. "get": {
  8723. "produces": [
  8724. "application/json"
  8725. ],
  8726. "tags": [
  8727. "repository"
  8728. ],
  8729. "summary": "search topics via keyword",
  8730. "operationId": "topicSearch",
  8731. "parameters": [
  8732. {
  8733. "type": "string",
  8734. "description": "keywords to search",
  8735. "name": "q",
  8736. "in": "query",
  8737. "required": true
  8738. },
  8739. {
  8740. "type": "integer",
  8741. "description": "page number of results to return (1-based)",
  8742. "name": "page",
  8743. "in": "query"
  8744. },
  8745. {
  8746. "type": "integer",
  8747. "description": "page size of results, maximum page size is 50",
  8748. "name": "limit",
  8749. "in": "query"
  8750. }
  8751. ],
  8752. "responses": {
  8753. "200": {
  8754. "$ref": "#/responses/TopicListResponse"
  8755. },
  8756. "403": {
  8757. "$ref": "#/responses/forbidden"
  8758. }
  8759. }
  8760. }
  8761. },
  8762. "/user": {
  8763. "get": {
  8764. "produces": [
  8765. "application/json"
  8766. ],
  8767. "tags": [
  8768. "user"
  8769. ],
  8770. "summary": "Get the authenticated user",
  8771. "operationId": "userGetCurrent",
  8772. "responses": {
  8773. "200": {
  8774. "$ref": "#/responses/User"
  8775. }
  8776. }
  8777. }
  8778. },
  8779. "/user/applications/oauth2": {
  8780. "get": {
  8781. "produces": [
  8782. "application/json"
  8783. ],
  8784. "tags": [
  8785. "user"
  8786. ],
  8787. "summary": "List the authenticated user's oauth2 applications",
  8788. "operationId": "userGetOauth2Application",
  8789. "parameters": [
  8790. {
  8791. "type": "integer",
  8792. "description": "page number of results to return (1-based)",
  8793. "name": "page",
  8794. "in": "query"
  8795. },
  8796. {
  8797. "type": "integer",
  8798. "description": "page size of results, maximum page size is 50",
  8799. "name": "limit",
  8800. "in": "query"
  8801. }
  8802. ],
  8803. "responses": {
  8804. "200": {
  8805. "$ref": "#/responses/OAuth2ApplicationList"
  8806. }
  8807. }
  8808. },
  8809. "post": {
  8810. "produces": [
  8811. "application/json"
  8812. ],
  8813. "tags": [
  8814. "user"
  8815. ],
  8816. "summary": "creates a new OAuth2 application",
  8817. "operationId": "userCreateOAuth2Application",
  8818. "parameters": [
  8819. {
  8820. "name": "body",
  8821. "in": "body",
  8822. "required": true,
  8823. "schema": {
  8824. "$ref": "#/definitions/CreateOAuth2ApplicationOptions"
  8825. }
  8826. }
  8827. ],
  8828. "responses": {
  8829. "201": {
  8830. "$ref": "#/responses/OAuth2Application"
  8831. }
  8832. }
  8833. }
  8834. },
  8835. "/user/applications/oauth2/{id}": {
  8836. "get": {
  8837. "produces": [
  8838. "application/json"
  8839. ],
  8840. "tags": [
  8841. "user"
  8842. ],
  8843. "summary": "get an OAuth2 Application",
  8844. "operationId": "userGetOAuth2Application",
  8845. "parameters": [
  8846. {
  8847. "type": "integer",
  8848. "format": "int64",
  8849. "description": "Application ID to be found",
  8850. "name": "id",
  8851. "in": "path",
  8852. "required": true
  8853. }
  8854. ],
  8855. "responses": {
  8856. "200": {
  8857. "$ref": "#/responses/OAuth2Application"
  8858. }
  8859. }
  8860. },
  8861. "delete": {
  8862. "produces": [
  8863. "application/json"
  8864. ],
  8865. "tags": [
  8866. "user"
  8867. ],
  8868. "summary": "delete an OAuth2 Application",
  8869. "operationId": "userDeleteOAuth2Application",
  8870. "parameters": [
  8871. {
  8872. "type": "integer",
  8873. "format": "int64",
  8874. "description": "token to be deleted",
  8875. "name": "id",
  8876. "in": "path",
  8877. "required": true
  8878. }
  8879. ],
  8880. "responses": {
  8881. "204": {
  8882. "$ref": "#/responses/empty"
  8883. }
  8884. }
  8885. },
  8886. "patch": {
  8887. "produces": [
  8888. "application/json"
  8889. ],
  8890. "tags": [
  8891. "user"
  8892. ],
  8893. "summary": "update an OAuth2 Application, this includes regenerating the client secret",
  8894. "operationId": "userUpdateOAuth2Application",
  8895. "parameters": [
  8896. {
  8897. "type": "integer",
  8898. "format": "int64",
  8899. "description": "application to be updated",
  8900. "name": "id",
  8901. "in": "path",
  8902. "required": true
  8903. },
  8904. {
  8905. "name": "body",
  8906. "in": "body",
  8907. "required": true,
  8908. "schema": {
  8909. "$ref": "#/definitions/CreateOAuth2ApplicationOptions"
  8910. }
  8911. }
  8912. ],
  8913. "responses": {
  8914. "200": {
  8915. "$ref": "#/responses/OAuth2Application"
  8916. }
  8917. }
  8918. }
  8919. },
  8920. "/user/emails": {
  8921. "get": {
  8922. "produces": [
  8923. "application/json"
  8924. ],
  8925. "tags": [
  8926. "user"
  8927. ],
  8928. "summary": "List the authenticated user's email addresses",
  8929. "operationId": "userListEmails",
  8930. "responses": {
  8931. "200": {
  8932. "$ref": "#/responses/EmailList"
  8933. }
  8934. }
  8935. },
  8936. "post": {
  8937. "produces": [
  8938. "application/json"
  8939. ],
  8940. "tags": [
  8941. "user"
  8942. ],
  8943. "summary": "Add email addresses",
  8944. "operationId": "userAddEmail",
  8945. "parameters": [
  8946. {
  8947. "name": "body",
  8948. "in": "body",
  8949. "schema": {
  8950. "$ref": "#/definitions/CreateEmailOption"
  8951. }
  8952. }
  8953. ],
  8954. "responses": {
  8955. "201": {
  8956. "$ref": "#/responses/EmailList"
  8957. },
  8958. "422": {
  8959. "$ref": "#/responses/validationError"
  8960. }
  8961. }
  8962. },
  8963. "delete": {
  8964. "produces": [
  8965. "application/json"
  8966. ],
  8967. "tags": [
  8968. "user"
  8969. ],
  8970. "summary": "Delete email addresses",
  8971. "operationId": "userDeleteEmail",
  8972. "parameters": [
  8973. {
  8974. "name": "body",
  8975. "in": "body",
  8976. "schema": {
  8977. "$ref": "#/definitions/DeleteEmailOption"
  8978. }
  8979. }
  8980. ],
  8981. "responses": {
  8982. "204": {
  8983. "$ref": "#/responses/empty"
  8984. }
  8985. }
  8986. }
  8987. },
  8988. "/user/followers": {
  8989. "get": {
  8990. "produces": [
  8991. "application/json"
  8992. ],
  8993. "tags": [
  8994. "user"
  8995. ],
  8996. "summary": "List the authenticated user's followers",
  8997. "operationId": "userCurrentListFollowers",
  8998. "parameters": [
  8999. {
  9000. "type": "integer",
  9001. "description": "page number of results to return (1-based)",
  9002. "name": "page",
  9003. "in": "query"
  9004. },
  9005. {
  9006. "type": "integer",
  9007. "description": "page size of results, maximum page size is 50",
  9008. "name": "limit",
  9009. "in": "query"
  9010. }
  9011. ],
  9012. "responses": {
  9013. "200": {
  9014. "$ref": "#/responses/UserList"
  9015. }
  9016. }
  9017. }
  9018. },
  9019. "/user/following": {
  9020. "get": {
  9021. "produces": [
  9022. "application/json"
  9023. ],
  9024. "tags": [
  9025. "user"
  9026. ],
  9027. "summary": "List the users that the authenticated user is following",
  9028. "operationId": "userCurrentListFollowing",
  9029. "parameters": [
  9030. {
  9031. "type": "integer",
  9032. "description": "page number of results to return (1-based)",
  9033. "name": "page",
  9034. "in": "query"
  9035. },
  9036. {
  9037. "type": "integer",
  9038. "description": "page size of results, maximum page size is 50",
  9039. "name": "limit",
  9040. "in": "query"
  9041. }
  9042. ],
  9043. "responses": {
  9044. "200": {
  9045. "$ref": "#/responses/UserList"
  9046. }
  9047. }
  9048. }
  9049. },
  9050. "/user/following/{username}": {
  9051. "get": {
  9052. "tags": [
  9053. "user"
  9054. ],
  9055. "summary": "Check whether a user is followed by the authenticated user",
  9056. "operationId": "userCurrentCheckFollowing",
  9057. "parameters": [
  9058. {
  9059. "type": "string",
  9060. "description": "username of followed user",
  9061. "name": "username",
  9062. "in": "path",
  9063. "required": true
  9064. }
  9065. ],
  9066. "responses": {
  9067. "204": {
  9068. "$ref": "#/responses/empty"
  9069. },
  9070. "404": {
  9071. "$ref": "#/responses/notFound"
  9072. }
  9073. }
  9074. },
  9075. "put": {
  9076. "tags": [
  9077. "user"
  9078. ],
  9079. "summary": "Follow a user",
  9080. "operationId": "userCurrentPutFollow",
  9081. "parameters": [
  9082. {
  9083. "type": "string",
  9084. "description": "username of user to follow",
  9085. "name": "username",
  9086. "in": "path",
  9087. "required": true
  9088. }
  9089. ],
  9090. "responses": {
  9091. "204": {
  9092. "$ref": "#/responses/empty"
  9093. }
  9094. }
  9095. },
  9096. "delete": {
  9097. "tags": [
  9098. "user"
  9099. ],
  9100. "summary": "Unfollow a user",
  9101. "operationId": "userCurrentDeleteFollow",
  9102. "parameters": [
  9103. {
  9104. "type": "string",
  9105. "description": "username of user to unfollow",
  9106. "name": "username",
  9107. "in": "path",
  9108. "required": true
  9109. }
  9110. ],
  9111. "responses": {
  9112. "204": {
  9113. "$ref": "#/responses/empty"
  9114. }
  9115. }
  9116. }
  9117. },
  9118. "/user/gpg_keys": {
  9119. "get": {
  9120. "produces": [
  9121. "application/json"
  9122. ],
  9123. "tags": [
  9124. "user"
  9125. ],
  9126. "summary": "List the authenticated user's GPG keys",
  9127. "operationId": "userCurrentListGPGKeys",
  9128. "parameters": [
  9129. {
  9130. "type": "integer",
  9131. "description": "page number of results to return (1-based)",
  9132. "name": "page",
  9133. "in": "query"
  9134. },
  9135. {
  9136. "type": "integer",
  9137. "description": "page size of results, maximum page size is 50",
  9138. "name": "limit",
  9139. "in": "query"
  9140. }
  9141. ],
  9142. "responses": {
  9143. "200": {
  9144. "$ref": "#/responses/GPGKeyList"
  9145. }
  9146. }
  9147. },
  9148. "post": {
  9149. "consumes": [
  9150. "application/json"
  9151. ],
  9152. "produces": [
  9153. "application/json"
  9154. ],
  9155. "tags": [
  9156. "user"
  9157. ],
  9158. "summary": "Create a GPG key",
  9159. "operationId": "userCurrentPostGPGKey",
  9160. "parameters": [
  9161. {
  9162. "name": "Form",
  9163. "in": "body",
  9164. "schema": {
  9165. "$ref": "#/definitions/CreateGPGKeyOption"
  9166. }
  9167. }
  9168. ],
  9169. "responses": {
  9170. "201": {
  9171. "$ref": "#/responses/GPGKey"
  9172. },
  9173. "404": {
  9174. "$ref": "#/responses/notFound"
  9175. },
  9176. "422": {
  9177. "$ref": "#/responses/validationError"
  9178. }
  9179. }
  9180. }
  9181. },
  9182. "/user/gpg_keys/{id}": {
  9183. "get": {
  9184. "produces": [
  9185. "application/json"
  9186. ],
  9187. "tags": [
  9188. "user"
  9189. ],
  9190. "summary": "Get a GPG key",
  9191. "operationId": "userCurrentGetGPGKey",
  9192. "parameters": [
  9193. {
  9194. "type": "integer",
  9195. "format": "int64",
  9196. "description": "id of key to get",
  9197. "name": "id",
  9198. "in": "path",
  9199. "required": true
  9200. }
  9201. ],
  9202. "responses": {
  9203. "200": {
  9204. "$ref": "#/responses/GPGKey"
  9205. },
  9206. "404": {
  9207. "$ref": "#/responses/notFound"
  9208. }
  9209. }
  9210. },
  9211. "delete": {
  9212. "produces": [
  9213. "application/json"
  9214. ],
  9215. "tags": [
  9216. "user"
  9217. ],
  9218. "summary": "Remove a GPG key",
  9219. "operationId": "userCurrentDeleteGPGKey",
  9220. "parameters": [
  9221. {
  9222. "type": "integer",
  9223. "format": "int64",
  9224. "description": "id of key to delete",
  9225. "name": "id",
  9226. "in": "path",
  9227. "required": true
  9228. }
  9229. ],
  9230. "responses": {
  9231. "204": {
  9232. "$ref": "#/responses/empty"
  9233. },
  9234. "403": {
  9235. "$ref": "#/responses/forbidden"
  9236. },
  9237. "404": {
  9238. "$ref": "#/responses/notFound"
  9239. }
  9240. }
  9241. }
  9242. },
  9243. "/user/keys": {
  9244. "get": {
  9245. "produces": [
  9246. "application/json"
  9247. ],
  9248. "tags": [
  9249. "user"
  9250. ],
  9251. "summary": "List the authenticated user's public keys",
  9252. "operationId": "userCurrentListKeys",
  9253. "parameters": [
  9254. {
  9255. "type": "string",
  9256. "description": "fingerprint of the key",
  9257. "name": "fingerprint",
  9258. "in": "query"
  9259. },
  9260. {
  9261. "type": "integer",
  9262. "description": "page number of results to return (1-based)",
  9263. "name": "page",
  9264. "in": "query"
  9265. },
  9266. {
  9267. "type": "integer",
  9268. "description": "page size of results, maximum page size is 50",
  9269. "name": "limit",
  9270. "in": "query"
  9271. }
  9272. ],
  9273. "responses": {
  9274. "200": {
  9275. "$ref": "#/responses/PublicKeyList"
  9276. }
  9277. }
  9278. },
  9279. "post": {
  9280. "consumes": [
  9281. "application/json"
  9282. ],
  9283. "produces": [
  9284. "application/json"
  9285. ],
  9286. "tags": [
  9287. "user"
  9288. ],
  9289. "summary": "Create a public key",
  9290. "operationId": "userCurrentPostKey",
  9291. "parameters": [
  9292. {
  9293. "name": "body",
  9294. "in": "body",
  9295. "schema": {
  9296. "$ref": "#/definitions/CreateKeyOption"
  9297. }
  9298. }
  9299. ],
  9300. "responses": {
  9301. "201": {
  9302. "$ref": "#/responses/PublicKey"
  9303. },
  9304. "422": {
  9305. "$ref": "#/responses/validationError"
  9306. }
  9307. }
  9308. }
  9309. },
  9310. "/user/keys/{id}": {
  9311. "get": {
  9312. "produces": [
  9313. "application/json"
  9314. ],
  9315. "tags": [
  9316. "user"
  9317. ],
  9318. "summary": "Get a public key",
  9319. "operationId": "userCurrentGetKey",
  9320. "parameters": [
  9321. {
  9322. "type": "integer",
  9323. "format": "int64",
  9324. "description": "id of key to get",
  9325. "name": "id",
  9326. "in": "path",
  9327. "required": true
  9328. }
  9329. ],
  9330. "responses": {
  9331. "200": {
  9332. "$ref": "#/responses/PublicKey"
  9333. },
  9334. "404": {
  9335. "$ref": "#/responses/notFound"
  9336. }
  9337. }
  9338. },
  9339. "delete": {
  9340. "produces": [
  9341. "application/json"
  9342. ],
  9343. "tags": [
  9344. "user"
  9345. ],
  9346. "summary": "Delete a public key",
  9347. "operationId": "userCurrentDeleteKey",
  9348. "parameters": [
  9349. {
  9350. "type": "integer",
  9351. "format": "int64",
  9352. "description": "id of key to delete",
  9353. "name": "id",
  9354. "in": "path",
  9355. "required": true
  9356. }
  9357. ],
  9358. "responses": {
  9359. "204": {
  9360. "$ref": "#/responses/empty"
  9361. },
  9362. "403": {
  9363. "$ref": "#/responses/forbidden"
  9364. },
  9365. "404": {
  9366. "$ref": "#/responses/notFound"
  9367. }
  9368. }
  9369. }
  9370. },
  9371. "/user/orgs": {
  9372. "get": {
  9373. "produces": [
  9374. "application/json"
  9375. ],
  9376. "tags": [
  9377. "organization"
  9378. ],
  9379. "summary": "List the current user's organizations",
  9380. "operationId": "orgListCurrentUserOrgs",
  9381. "parameters": [
  9382. {
  9383. "type": "integer",
  9384. "description": "page number of results to return (1-based)",
  9385. "name": "page",
  9386. "in": "query"
  9387. },
  9388. {
  9389. "type": "integer",
  9390. "description": "page size of results, maximum page size is 50",
  9391. "name": "limit",
  9392. "in": "query"
  9393. }
  9394. ],
  9395. "responses": {
  9396. "200": {
  9397. "$ref": "#/responses/OrganizationList"
  9398. }
  9399. }
  9400. }
  9401. },
  9402. "/user/repos": {
  9403. "get": {
  9404. "produces": [
  9405. "application/json"
  9406. ],
  9407. "tags": [
  9408. "user"
  9409. ],
  9410. "summary": "List the repos that the authenticated user owns or has access to",
  9411. "operationId": "userCurrentListRepos",
  9412. "parameters": [
  9413. {
  9414. "type": "integer",
  9415. "description": "page number of results to return (1-based)",
  9416. "name": "page",
  9417. "in": "query"
  9418. },
  9419. {
  9420. "type": "integer",
  9421. "description": "page size of results, maximum page size is 50",
  9422. "name": "limit",
  9423. "in": "query"
  9424. }
  9425. ],
  9426. "responses": {
  9427. "200": {
  9428. "$ref": "#/responses/RepositoryList"
  9429. }
  9430. }
  9431. },
  9432. "post": {
  9433. "consumes": [
  9434. "application/json"
  9435. ],
  9436. "produces": [
  9437. "application/json"
  9438. ],
  9439. "tags": [
  9440. "repository",
  9441. "user"
  9442. ],
  9443. "summary": "Create a repository",
  9444. "operationId": "createCurrentUserRepo",
  9445. "parameters": [
  9446. {
  9447. "name": "body",
  9448. "in": "body",
  9449. "schema": {
  9450. "$ref": "#/definitions/CreateRepoOption"
  9451. }
  9452. }
  9453. ],
  9454. "responses": {
  9455. "201": {
  9456. "$ref": "#/responses/Repository"
  9457. },
  9458. "409": {
  9459. "description": "The repository with the same name already exists."
  9460. },
  9461. "422": {
  9462. "$ref": "#/responses/validationError"
  9463. }
  9464. }
  9465. }
  9466. },
  9467. "/user/starred": {
  9468. "get": {
  9469. "produces": [
  9470. "application/json"
  9471. ],
  9472. "tags": [
  9473. "user"
  9474. ],
  9475. "summary": "The repos that the authenticated user has starred",
  9476. "operationId": "userCurrentListStarred",
  9477. "parameters": [
  9478. {
  9479. "type": "integer",
  9480. "description": "page number of results to return (1-based)",
  9481. "name": "page",
  9482. "in": "query"
  9483. },
  9484. {
  9485. "type": "integer",
  9486. "description": "page size of results, maximum page size is 50",
  9487. "name": "limit",
  9488. "in": "query"
  9489. }
  9490. ],
  9491. "responses": {
  9492. "200": {
  9493. "$ref": "#/responses/RepositoryList"
  9494. }
  9495. }
  9496. }
  9497. },
  9498. "/user/starred/{owner}/{repo}": {
  9499. "get": {
  9500. "tags": [
  9501. "user"
  9502. ],
  9503. "summary": "Whether the authenticated is starring the repo",
  9504. "operationId": "userCurrentCheckStarring",
  9505. "parameters": [
  9506. {
  9507. "type": "string",
  9508. "description": "owner of the repo",
  9509. "name": "owner",
  9510. "in": "path",
  9511. "required": true
  9512. },
  9513. {
  9514. "type": "string",
  9515. "description": "name of the repo",
  9516. "name": "repo",
  9517. "in": "path",
  9518. "required": true
  9519. }
  9520. ],
  9521. "responses": {
  9522. "204": {
  9523. "$ref": "#/responses/empty"
  9524. },
  9525. "404": {
  9526. "$ref": "#/responses/notFound"
  9527. }
  9528. }
  9529. },
  9530. "put": {
  9531. "tags": [
  9532. "user"
  9533. ],
  9534. "summary": "Star the given repo",
  9535. "operationId": "userCurrentPutStar",
  9536. "parameters": [
  9537. {
  9538. "type": "string",
  9539. "description": "owner of the repo to star",
  9540. "name": "owner",
  9541. "in": "path",
  9542. "required": true
  9543. },
  9544. {
  9545. "type": "string",
  9546. "description": "name of the repo to star",
  9547. "name": "repo",
  9548. "in": "path",
  9549. "required": true
  9550. }
  9551. ],
  9552. "responses": {
  9553. "204": {
  9554. "$ref": "#/responses/empty"
  9555. }
  9556. }
  9557. },
  9558. "delete": {
  9559. "tags": [
  9560. "user"
  9561. ],
  9562. "summary": "Unstar the given repo",
  9563. "operationId": "userCurrentDeleteStar",
  9564. "parameters": [
  9565. {
  9566. "type": "string",
  9567. "description": "owner of the repo to unstar",
  9568. "name": "owner",
  9569. "in": "path",
  9570. "required": true
  9571. },
  9572. {
  9573. "type": "string",
  9574. "description": "name of the repo to unstar",
  9575. "name": "repo",
  9576. "in": "path",
  9577. "required": true
  9578. }
  9579. ],
  9580. "responses": {
  9581. "204": {
  9582. "$ref": "#/responses/empty"
  9583. }
  9584. }
  9585. }
  9586. },
  9587. "/user/stopwatches": {
  9588. "get": {
  9589. "consumes": [
  9590. "application/json"
  9591. ],
  9592. "produces": [
  9593. "application/json"
  9594. ],
  9595. "tags": [
  9596. "user"
  9597. ],
  9598. "summary": "Get list of all existing stopwatches",
  9599. "operationId": "userGetStopWatches",
  9600. "parameters": [
  9601. {
  9602. "type": "integer",
  9603. "description": "page number of results to return (1-based)",
  9604. "name": "page",
  9605. "in": "query"
  9606. },
  9607. {
  9608. "type": "integer",
  9609. "description": "page size of results, maximum page size is 50",
  9610. "name": "limit",
  9611. "in": "query"
  9612. }
  9613. ],
  9614. "responses": {
  9615. "200": {
  9616. "$ref": "#/responses/StopWatchList"
  9617. }
  9618. }
  9619. }
  9620. },
  9621. "/user/subscriptions": {
  9622. "get": {
  9623. "produces": [
  9624. "application/json"
  9625. ],
  9626. "tags": [
  9627. "user"
  9628. ],
  9629. "summary": "List repositories watched by the authenticated user",
  9630. "operationId": "userCurrentListSubscriptions",
  9631. "parameters": [
  9632. {
  9633. "type": "integer",
  9634. "description": "page number of results to return (1-based)",
  9635. "name": "page",
  9636. "in": "query"
  9637. },
  9638. {
  9639. "type": "integer",
  9640. "description": "page size of results, maximum page size is 50",
  9641. "name": "limit",
  9642. "in": "query"
  9643. }
  9644. ],
  9645. "responses": {
  9646. "200": {
  9647. "$ref": "#/responses/RepositoryList"
  9648. }
  9649. }
  9650. }
  9651. },
  9652. "/user/teams": {
  9653. "get": {
  9654. "produces": [
  9655. "application/json"
  9656. ],
  9657. "tags": [
  9658. "user"
  9659. ],
  9660. "summary": "List all the teams a user belongs to",
  9661. "operationId": "userListTeams",
  9662. "parameters": [
  9663. {
  9664. "type": "integer",
  9665. "description": "page number of results to return (1-based)",
  9666. "name": "page",
  9667. "in": "query"
  9668. },
  9669. {
  9670. "type": "integer",
  9671. "description": "page size of results, maximum page size is 50",
  9672. "name": "limit",
  9673. "in": "query"
  9674. }
  9675. ],
  9676. "responses": {
  9677. "200": {
  9678. "$ref": "#/responses/TeamList"
  9679. }
  9680. }
  9681. }
  9682. },
  9683. "/user/times": {
  9684. "get": {
  9685. "produces": [
  9686. "application/json"
  9687. ],
  9688. "tags": [
  9689. "user"
  9690. ],
  9691. "summary": "List the current user's tracked times",
  9692. "operationId": "userCurrentTrackedTimes",
  9693. "parameters": [
  9694. {
  9695. "type": "string",
  9696. "format": "date-time",
  9697. "description": "Only show times updated after the given time. This is a timestamp in RFC 3339 format",
  9698. "name": "since",
  9699. "in": "query"
  9700. },
  9701. {
  9702. "type": "string",
  9703. "format": "date-time",
  9704. "description": "Only show times updated before the given time. This is a timestamp in RFC 3339 format",
  9705. "name": "before",
  9706. "in": "query"
  9707. }
  9708. ],
  9709. "responses": {
  9710. "200": {
  9711. "$ref": "#/responses/TrackedTimeList"
  9712. }
  9713. }
  9714. }
  9715. },
  9716. "/users/search": {
  9717. "get": {
  9718. "produces": [
  9719. "application/json"
  9720. ],
  9721. "tags": [
  9722. "user"
  9723. ],
  9724. "summary": "Search for users",
  9725. "operationId": "userSearch",
  9726. "parameters": [
  9727. {
  9728. "type": "string",
  9729. "description": "keyword",
  9730. "name": "q",
  9731. "in": "query"
  9732. },
  9733. {
  9734. "type": "integer",
  9735. "format": "int64",
  9736. "description": "ID of the user to search for",
  9737. "name": "uid",
  9738. "in": "query"
  9739. },
  9740. {
  9741. "type": "integer",
  9742. "description": "page number of results to return (1-based)",
  9743. "name": "page",
  9744. "in": "query"
  9745. },
  9746. {
  9747. "type": "integer",
  9748. "description": "page size of results, maximum page size is 50",
  9749. "name": "limit",
  9750. "in": "query"
  9751. }
  9752. ],
  9753. "responses": {
  9754. "200": {
  9755. "description": "SearchResults of a successful search",
  9756. "schema": {
  9757. "type": "object",
  9758. "properties": {
  9759. "data": {
  9760. "type": "array",
  9761. "items": {
  9762. "$ref": "#/definitions/User"
  9763. }
  9764. },
  9765. "ok": {
  9766. "type": "boolean"
  9767. }
  9768. }
  9769. }
  9770. }
  9771. }
  9772. }
  9773. },
  9774. "/users/{follower}/following/{followee}": {
  9775. "get": {
  9776. "tags": [
  9777. "user"
  9778. ],
  9779. "summary": "Check if one user is following another user",
  9780. "operationId": "userCheckFollowing",
  9781. "parameters": [
  9782. {
  9783. "type": "string",
  9784. "description": "username of following user",
  9785. "name": "follower",
  9786. "in": "path",
  9787. "required": true
  9788. },
  9789. {
  9790. "type": "string",
  9791. "description": "username of followed user",
  9792. "name": "followee",
  9793. "in": "path",
  9794. "required": true
  9795. }
  9796. ],
  9797. "responses": {
  9798. "204": {
  9799. "$ref": "#/responses/empty"
  9800. },
  9801. "404": {
  9802. "$ref": "#/responses/notFound"
  9803. }
  9804. }
  9805. }
  9806. },
  9807. "/users/{username}": {
  9808. "get": {
  9809. "produces": [
  9810. "application/json"
  9811. ],
  9812. "tags": [
  9813. "user"
  9814. ],
  9815. "summary": "Get a user",
  9816. "operationId": "userGet",
  9817. "parameters": [
  9818. {
  9819. "type": "string",
  9820. "description": "username of user to get",
  9821. "name": "username",
  9822. "in": "path",
  9823. "required": true
  9824. }
  9825. ],
  9826. "responses": {
  9827. "200": {
  9828. "$ref": "#/responses/User"
  9829. },
  9830. "404": {
  9831. "$ref": "#/responses/notFound"
  9832. }
  9833. }
  9834. }
  9835. },
  9836. "/users/{username}/followers": {
  9837. "get": {
  9838. "produces": [
  9839. "application/json"
  9840. ],
  9841. "tags": [
  9842. "user"
  9843. ],
  9844. "summary": "List the given user's followers",
  9845. "operationId": "userListFollowers",
  9846. "parameters": [
  9847. {
  9848. "type": "string",
  9849. "description": "username of user",
  9850. "name": "username",
  9851. "in": "path",
  9852. "required": true
  9853. },
  9854. {
  9855. "type": "integer",
  9856. "description": "page number of results to return (1-based)",
  9857. "name": "page",
  9858. "in": "query"
  9859. },
  9860. {
  9861. "type": "integer",
  9862. "description": "page size of results, maximum page size is 50",
  9863. "name": "limit",
  9864. "in": "query"
  9865. }
  9866. ],
  9867. "responses": {
  9868. "200": {
  9869. "$ref": "#/responses/UserList"
  9870. }
  9871. }
  9872. }
  9873. },
  9874. "/users/{username}/following": {
  9875. "get": {
  9876. "produces": [
  9877. "application/json"
  9878. ],
  9879. "tags": [
  9880. "user"
  9881. ],
  9882. "summary": "List the users that the given user is following",
  9883. "operationId": "userListFollowing",
  9884. "parameters": [
  9885. {
  9886. "type": "string",
  9887. "description": "username of user",
  9888. "name": "username",
  9889. "in": "path",
  9890. "required": true
  9891. },
  9892. {
  9893. "type": "integer",
  9894. "description": "page number of results to return (1-based)",
  9895. "name": "page",
  9896. "in": "query"
  9897. },
  9898. {
  9899. "type": "integer",
  9900. "description": "page size of results, maximum page size is 50",
  9901. "name": "limit",
  9902. "in": "query"
  9903. }
  9904. ],
  9905. "responses": {
  9906. "200": {
  9907. "$ref": "#/responses/UserList"
  9908. }
  9909. }
  9910. }
  9911. },
  9912. "/users/{username}/gpg_keys": {
  9913. "get": {
  9914. "produces": [
  9915. "application/json"
  9916. ],
  9917. "tags": [
  9918. "user"
  9919. ],
  9920. "summary": "List the given user's GPG keys",
  9921. "operationId": "userListGPGKeys",
  9922. "parameters": [
  9923. {
  9924. "type": "string",
  9925. "description": "username of user",
  9926. "name": "username",
  9927. "in": "path",
  9928. "required": true
  9929. },
  9930. {
  9931. "type": "integer",
  9932. "description": "page number of results to return (1-based)",
  9933. "name": "page",
  9934. "in": "query"
  9935. },
  9936. {
  9937. "type": "integer",
  9938. "description": "page size of results, maximum page size is 50",
  9939. "name": "limit",
  9940. "in": "query"
  9941. }
  9942. ],
  9943. "responses": {
  9944. "200": {
  9945. "$ref": "#/responses/GPGKeyList"
  9946. }
  9947. }
  9948. }
  9949. },
  9950. "/users/{username}/heatmap": {
  9951. "get": {
  9952. "produces": [
  9953. "application/json"
  9954. ],
  9955. "tags": [
  9956. "user"
  9957. ],
  9958. "summary": "Get a user's heatmap",
  9959. "operationId": "userGetHeatmapData",
  9960. "parameters": [
  9961. {
  9962. "type": "string",
  9963. "description": "username of user to get",
  9964. "name": "username",
  9965. "in": "path",
  9966. "required": true
  9967. }
  9968. ],
  9969. "responses": {
  9970. "200": {
  9971. "$ref": "#/responses/UserHeatmapData"
  9972. },
  9973. "404": {
  9974. "$ref": "#/responses/notFound"
  9975. }
  9976. }
  9977. }
  9978. },
  9979. "/users/{username}/keys": {
  9980. "get": {
  9981. "produces": [
  9982. "application/json"
  9983. ],
  9984. "tags": [
  9985. "user"
  9986. ],
  9987. "summary": "List the given user's public keys",
  9988. "operationId": "userListKeys",
  9989. "parameters": [
  9990. {
  9991. "type": "string",
  9992. "description": "username of user",
  9993. "name": "username",
  9994. "in": "path",
  9995. "required": true
  9996. },
  9997. {
  9998. "type": "string",
  9999. "description": "fingerprint of the key",
  10000. "name": "fingerprint",
  10001. "in": "query"
  10002. },
  10003. {
  10004. "type": "integer",
  10005. "description": "page number of results to return (1-based)",
  10006. "name": "page",
  10007. "in": "query"
  10008. },
  10009. {
  10010. "type": "integer",
  10011. "description": "page size of results, maximum page size is 50",
  10012. "name": "limit",
  10013. "in": "query"
  10014. }
  10015. ],
  10016. "responses": {
  10017. "200": {
  10018. "$ref": "#/responses/PublicKeyList"
  10019. }
  10020. }
  10021. }
  10022. },
  10023. "/users/{username}/orgs": {
  10024. "get": {
  10025. "produces": [
  10026. "application/json"
  10027. ],
  10028. "tags": [
  10029. "organization"
  10030. ],
  10031. "summary": "List a user's organizations",
  10032. "operationId": "orgListUserOrgs",
  10033. "parameters": [
  10034. {
  10035. "type": "string",
  10036. "description": "username of user",
  10037. "name": "username",
  10038. "in": "path",
  10039. "required": true
  10040. },
  10041. {
  10042. "type": "integer",
  10043. "description": "page number of results to return (1-based)",
  10044. "name": "page",
  10045. "in": "query"
  10046. },
  10047. {
  10048. "type": "integer",
  10049. "description": "page size of results, maximum page size is 50",
  10050. "name": "limit",
  10051. "in": "query"
  10052. }
  10053. ],
  10054. "responses": {
  10055. "200": {
  10056. "$ref": "#/responses/OrganizationList"
  10057. }
  10058. }
  10059. }
  10060. },
  10061. "/users/{username}/repos": {
  10062. "get": {
  10063. "produces": [
  10064. "application/json"
  10065. ],
  10066. "tags": [
  10067. "user"
  10068. ],
  10069. "summary": "List the repos owned by the given user",
  10070. "operationId": "userListRepos",
  10071. "parameters": [
  10072. {
  10073. "type": "string",
  10074. "description": "username of user",
  10075. "name": "username",
  10076. "in": "path",
  10077. "required": true
  10078. },
  10079. {
  10080. "type": "integer",
  10081. "description": "page number of results to return (1-based)",
  10082. "name": "page",
  10083. "in": "query"
  10084. },
  10085. {
  10086. "type": "integer",
  10087. "description": "page size of results, maximum page size is 50",
  10088. "name": "limit",
  10089. "in": "query"
  10090. }
  10091. ],
  10092. "responses": {
  10093. "200": {
  10094. "$ref": "#/responses/RepositoryList"
  10095. }
  10096. }
  10097. }
  10098. },
  10099. "/users/{username}/starred": {
  10100. "get": {
  10101. "produces": [
  10102. "application/json"
  10103. ],
  10104. "tags": [
  10105. "user"
  10106. ],
  10107. "summary": "The repos that the given user has starred",
  10108. "operationId": "userListStarred",
  10109. "parameters": [
  10110. {
  10111. "type": "string",
  10112. "description": "username of user",
  10113. "name": "username",
  10114. "in": "path",
  10115. "required": true
  10116. },
  10117. {
  10118. "type": "integer",
  10119. "description": "page number of results to return (1-based)",
  10120. "name": "page",
  10121. "in": "query"
  10122. },
  10123. {
  10124. "type": "integer",
  10125. "description": "page size of results, maximum page size is 50",
  10126. "name": "limit",
  10127. "in": "query"
  10128. }
  10129. ],
  10130. "responses": {
  10131. "200": {
  10132. "$ref": "#/responses/RepositoryList"
  10133. }
  10134. }
  10135. }
  10136. },
  10137. "/users/{username}/subscriptions": {
  10138. "get": {
  10139. "produces": [
  10140. "application/json"
  10141. ],
  10142. "tags": [
  10143. "user"
  10144. ],
  10145. "summary": "List the repositories watched by a user",
  10146. "operationId": "userListSubscriptions",
  10147. "parameters": [
  10148. {
  10149. "type": "string",
  10150. "description": "username of the user",
  10151. "name": "username",
  10152. "in": "path",
  10153. "required": true
  10154. },
  10155. {
  10156. "type": "integer",
  10157. "description": "page number of results to return (1-based)",
  10158. "name": "page",
  10159. "in": "query"
  10160. },
  10161. {
  10162. "type": "integer",
  10163. "description": "page size of results, maximum page size is 50",
  10164. "name": "limit",
  10165. "in": "query"
  10166. }
  10167. ],
  10168. "responses": {
  10169. "200": {
  10170. "$ref": "#/responses/RepositoryList"
  10171. }
  10172. }
  10173. }
  10174. },
  10175. "/users/{username}/tokens": {
  10176. "get": {
  10177. "produces": [
  10178. "application/json"
  10179. ],
  10180. "tags": [
  10181. "user"
  10182. ],
  10183. "summary": "List the authenticated user's access tokens",
  10184. "operationId": "userGetTokens",
  10185. "parameters": [
  10186. {
  10187. "type": "string",
  10188. "description": "username of user",
  10189. "name": "username",
  10190. "in": "path",
  10191. "required": true
  10192. },
  10193. {
  10194. "type": "integer",
  10195. "description": "page number of results to return (1-based)",
  10196. "name": "page",
  10197. "in": "query"
  10198. },
  10199. {
  10200. "type": "integer",
  10201. "description": "page size of results, maximum page size is 50",
  10202. "name": "limit",
  10203. "in": "query"
  10204. }
  10205. ],
  10206. "responses": {
  10207. "200": {
  10208. "$ref": "#/responses/AccessTokenList"
  10209. }
  10210. }
  10211. },
  10212. "post": {
  10213. "consumes": [
  10214. "application/json"
  10215. ],
  10216. "produces": [
  10217. "application/json"
  10218. ],
  10219. "tags": [
  10220. "user"
  10221. ],
  10222. "summary": "Create an access token",
  10223. "operationId": "userCreateToken",
  10224. "parameters": [
  10225. {
  10226. "type": "string",
  10227. "x-go-name": "Name",
  10228. "description": "username of user",
  10229. "name": "username",
  10230. "in": "path",
  10231. "required": true
  10232. },
  10233. {
  10234. "name": "accessToken",
  10235. "in": "body",
  10236. "schema": {
  10237. "type": "object",
  10238. "required": [
  10239. "name"
  10240. ],
  10241. "properties": {
  10242. "name": {
  10243. "type": "string"
  10244. }
  10245. }
  10246. }
  10247. }
  10248. ],
  10249. "responses": {
  10250. "200": {
  10251. "$ref": "#/responses/AccessToken"
  10252. }
  10253. }
  10254. }
  10255. },
  10256. "/users/{username}/tokens/{token}": {
  10257. "delete": {
  10258. "produces": [
  10259. "application/json"
  10260. ],
  10261. "tags": [
  10262. "user"
  10263. ],
  10264. "summary": "delete an access token",
  10265. "operationId": "userDeleteAccessToken",
  10266. "parameters": [
  10267. {
  10268. "type": "string",
  10269. "description": "username of user",
  10270. "name": "username",
  10271. "in": "path",
  10272. "required": true
  10273. },
  10274. {
  10275. "type": "integer",
  10276. "format": "int64",
  10277. "description": "token to be deleted",
  10278. "name": "token",
  10279. "in": "path",
  10280. "required": true
  10281. }
  10282. ],
  10283. "responses": {
  10284. "204": {
  10285. "$ref": "#/responses/empty"
  10286. }
  10287. }
  10288. }
  10289. },
  10290. "/version": {
  10291. "get": {
  10292. "produces": [
  10293. "application/json"
  10294. ],
  10295. "tags": [
  10296. "miscellaneous"
  10297. ],
  10298. "summary": "Returns the version of the Gitea application",
  10299. "operationId": "getVersion",
  10300. "responses": {
  10301. "200": {
  10302. "$ref": "#/responses/ServerVersion"
  10303. }
  10304. }
  10305. }
  10306. }
  10307. },
  10308. "definitions": {
  10309. "APIError": {
  10310. "description": "APIError is an api error with a message",
  10311. "type": "object",
  10312. "properties": {
  10313. "message": {
  10314. "type": "string",
  10315. "x-go-name": "Message"
  10316. },
  10317. "url": {
  10318. "type": "string",
  10319. "x-go-name": "URL"
  10320. }
  10321. },
  10322. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10323. },
  10324. "AccessToken": {
  10325. "type": "object",
  10326. "title": "AccessToken represents an API access token.",
  10327. "properties": {
  10328. "id": {
  10329. "type": "integer",
  10330. "format": "int64",
  10331. "x-go-name": "ID"
  10332. },
  10333. "name": {
  10334. "type": "string",
  10335. "x-go-name": "Name"
  10336. },
  10337. "sha1": {
  10338. "type": "string",
  10339. "x-go-name": "Token"
  10340. },
  10341. "token_last_eight": {
  10342. "type": "string",
  10343. "x-go-name": "TokenLastEight"
  10344. }
  10345. },
  10346. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10347. },
  10348. "AddCollaboratorOption": {
  10349. "description": "AddCollaboratorOption options when adding a user as a collaborator of a repository",
  10350. "type": "object",
  10351. "properties": {
  10352. "permission": {
  10353. "type": "string",
  10354. "x-go-name": "Permission"
  10355. }
  10356. },
  10357. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10358. },
  10359. "AddTimeOption": {
  10360. "description": "AddTimeOption options for adding time to an issue",
  10361. "type": "object",
  10362. "required": [
  10363. "time"
  10364. ],
  10365. "properties": {
  10366. "created": {
  10367. "type": "string",
  10368. "format": "date-time",
  10369. "x-go-name": "Created"
  10370. },
  10371. "time": {
  10372. "description": "time in seconds",
  10373. "type": "integer",
  10374. "format": "int64",
  10375. "x-go-name": "Time"
  10376. },
  10377. "user_name": {
  10378. "description": "User who spent the time (optional)",
  10379. "type": "string",
  10380. "x-go-name": "User"
  10381. }
  10382. },
  10383. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10384. },
  10385. "AnnotatedTag": {
  10386. "description": "AnnotatedTag represents an annotated tag",
  10387. "type": "object",
  10388. "properties": {
  10389. "message": {
  10390. "type": "string",
  10391. "x-go-name": "Message"
  10392. },
  10393. "object": {
  10394. "$ref": "#/definitions/AnnotatedTagObject"
  10395. },
  10396. "sha": {
  10397. "type": "string",
  10398. "x-go-name": "SHA"
  10399. },
  10400. "tag": {
  10401. "type": "string",
  10402. "x-go-name": "Tag"
  10403. },
  10404. "tagger": {
  10405. "$ref": "#/definitions/CommitUser"
  10406. },
  10407. "url": {
  10408. "type": "string",
  10409. "x-go-name": "URL"
  10410. },
  10411. "verification": {
  10412. "$ref": "#/definitions/PayloadCommitVerification"
  10413. }
  10414. },
  10415. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10416. },
  10417. "AnnotatedTagObject": {
  10418. "description": "AnnotatedTagObject contains meta information of the tag object",
  10419. "type": "object",
  10420. "properties": {
  10421. "sha": {
  10422. "type": "string",
  10423. "x-go-name": "SHA"
  10424. },
  10425. "type": {
  10426. "type": "string",
  10427. "x-go-name": "Type"
  10428. },
  10429. "url": {
  10430. "type": "string",
  10431. "x-go-name": "URL"
  10432. }
  10433. },
  10434. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10435. },
  10436. "Attachment": {
  10437. "description": "Attachment a generic attachment",
  10438. "type": "object",
  10439. "properties": {
  10440. "browser_download_url": {
  10441. "type": "string",
  10442. "x-go-name": "DownloadURL"
  10443. },
  10444. "created_at": {
  10445. "type": "string",
  10446. "format": "date-time",
  10447. "x-go-name": "Created"
  10448. },
  10449. "download_count": {
  10450. "type": "integer",
  10451. "format": "int64",
  10452. "x-go-name": "DownloadCount"
  10453. },
  10454. "id": {
  10455. "type": "integer",
  10456. "format": "int64",
  10457. "x-go-name": "ID"
  10458. },
  10459. "name": {
  10460. "type": "string",
  10461. "x-go-name": "Name"
  10462. },
  10463. "size": {
  10464. "type": "integer",
  10465. "format": "int64",
  10466. "x-go-name": "Size"
  10467. },
  10468. "uuid": {
  10469. "type": "string",
  10470. "x-go-name": "UUID"
  10471. }
  10472. },
  10473. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10474. },
  10475. "Branch": {
  10476. "description": "Branch represents a repository branch",
  10477. "type": "object",
  10478. "properties": {
  10479. "commit": {
  10480. "$ref": "#/definitions/PayloadCommit"
  10481. },
  10482. "effective_branch_protection_name": {
  10483. "type": "string",
  10484. "x-go-name": "EffectiveBranchProtectionName"
  10485. },
  10486. "enable_status_check": {
  10487. "type": "boolean",
  10488. "x-go-name": "EnableStatusCheck"
  10489. },
  10490. "name": {
  10491. "type": "string",
  10492. "x-go-name": "Name"
  10493. },
  10494. "protected": {
  10495. "type": "boolean",
  10496. "x-go-name": "Protected"
  10497. },
  10498. "required_approvals": {
  10499. "type": "integer",
  10500. "format": "int64",
  10501. "x-go-name": "RequiredApprovals"
  10502. },
  10503. "status_check_contexts": {
  10504. "type": "array",
  10505. "items": {
  10506. "type": "string"
  10507. },
  10508. "x-go-name": "StatusCheckContexts"
  10509. },
  10510. "user_can_merge": {
  10511. "type": "boolean",
  10512. "x-go-name": "UserCanMerge"
  10513. },
  10514. "user_can_push": {
  10515. "type": "boolean",
  10516. "x-go-name": "UserCanPush"
  10517. }
  10518. },
  10519. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10520. },
  10521. "BranchProtection": {
  10522. "description": "BranchProtection represents a branch protection for a repository",
  10523. "type": "object",
  10524. "properties": {
  10525. "approvals_whitelist_teams": {
  10526. "type": "array",
  10527. "items": {
  10528. "type": "string"
  10529. },
  10530. "x-go-name": "ApprovalsWhitelistTeams"
  10531. },
  10532. "approvals_whitelist_username": {
  10533. "type": "array",
  10534. "items": {
  10535. "type": "string"
  10536. },
  10537. "x-go-name": "ApprovalsWhitelistUsernames"
  10538. },
  10539. "block_on_outdated_branch": {
  10540. "type": "boolean",
  10541. "x-go-name": "BlockOnOutdatedBranch"
  10542. },
  10543. "block_on_rejected_reviews": {
  10544. "type": "boolean",
  10545. "x-go-name": "BlockOnRejectedReviews"
  10546. },
  10547. "branch_name": {
  10548. "type": "string",
  10549. "x-go-name": "BranchName"
  10550. },
  10551. "created_at": {
  10552. "type": "string",
  10553. "format": "date-time",
  10554. "x-go-name": "Created"
  10555. },
  10556. "dismiss_stale_approvals": {
  10557. "type": "boolean",
  10558. "x-go-name": "DismissStaleApprovals"
  10559. },
  10560. "enable_approvals_whitelist": {
  10561. "type": "boolean",
  10562. "x-go-name": "EnableApprovalsWhitelist"
  10563. },
  10564. "enable_merge_whitelist": {
  10565. "type": "boolean",
  10566. "x-go-name": "EnableMergeWhitelist"
  10567. },
  10568. "enable_push": {
  10569. "type": "boolean",
  10570. "x-go-name": "EnablePush"
  10571. },
  10572. "enable_push_whitelist": {
  10573. "type": "boolean",
  10574. "x-go-name": "EnablePushWhitelist"
  10575. },
  10576. "enable_status_check": {
  10577. "type": "boolean",
  10578. "x-go-name": "EnableStatusCheck"
  10579. },
  10580. "merge_whitelist_teams": {
  10581. "type": "array",
  10582. "items": {
  10583. "type": "string"
  10584. },
  10585. "x-go-name": "MergeWhitelistTeams"
  10586. },
  10587. "merge_whitelist_usernames": {
  10588. "type": "array",
  10589. "items": {
  10590. "type": "string"
  10591. },
  10592. "x-go-name": "MergeWhitelistUsernames"
  10593. },
  10594. "protected_file_patterns": {
  10595. "type": "string",
  10596. "x-go-name": "ProtectedFilePatterns"
  10597. },
  10598. "push_whitelist_deploy_keys": {
  10599. "type": "boolean",
  10600. "x-go-name": "PushWhitelistDeployKeys"
  10601. },
  10602. "push_whitelist_teams": {
  10603. "type": "array",
  10604. "items": {
  10605. "type": "string"
  10606. },
  10607. "x-go-name": "PushWhitelistTeams"
  10608. },
  10609. "push_whitelist_usernames": {
  10610. "type": "array",
  10611. "items": {
  10612. "type": "string"
  10613. },
  10614. "x-go-name": "PushWhitelistUsernames"
  10615. },
  10616. "require_signed_commits": {
  10617. "type": "boolean",
  10618. "x-go-name": "RequireSignedCommits"
  10619. },
  10620. "required_approvals": {
  10621. "type": "integer",
  10622. "format": "int64",
  10623. "x-go-name": "RequiredApprovals"
  10624. },
  10625. "status_check_contexts": {
  10626. "type": "array",
  10627. "items": {
  10628. "type": "string"
  10629. },
  10630. "x-go-name": "StatusCheckContexts"
  10631. },
  10632. "updated_at": {
  10633. "type": "string",
  10634. "format": "date-time",
  10635. "x-go-name": "Updated"
  10636. }
  10637. },
  10638. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10639. },
  10640. "Comment": {
  10641. "description": "Comment represents a comment on a commit or issue",
  10642. "type": "object",
  10643. "properties": {
  10644. "body": {
  10645. "type": "string",
  10646. "x-go-name": "Body"
  10647. },
  10648. "created_at": {
  10649. "type": "string",
  10650. "format": "date-time",
  10651. "x-go-name": "Created"
  10652. },
  10653. "html_url": {
  10654. "type": "string",
  10655. "x-go-name": "HTMLURL"
  10656. },
  10657. "id": {
  10658. "type": "integer",
  10659. "format": "int64",
  10660. "x-go-name": "ID"
  10661. },
  10662. "issue_url": {
  10663. "type": "string",
  10664. "x-go-name": "IssueURL"
  10665. },
  10666. "original_author": {
  10667. "type": "string",
  10668. "x-go-name": "OriginalAuthor"
  10669. },
  10670. "original_author_id": {
  10671. "type": "integer",
  10672. "format": "int64",
  10673. "x-go-name": "OriginalAuthorID"
  10674. },
  10675. "pull_request_url": {
  10676. "type": "string",
  10677. "x-go-name": "PRURL"
  10678. },
  10679. "updated_at": {
  10680. "type": "string",
  10681. "format": "date-time",
  10682. "x-go-name": "Updated"
  10683. },
  10684. "user": {
  10685. "$ref": "#/definitions/User"
  10686. }
  10687. },
  10688. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10689. },
  10690. "Commit": {
  10691. "type": "object",
  10692. "title": "Commit contains information generated from a Git commit.",
  10693. "properties": {
  10694. "author": {
  10695. "$ref": "#/definitions/User"
  10696. },
  10697. "commit": {
  10698. "$ref": "#/definitions/RepoCommit"
  10699. },
  10700. "committer": {
  10701. "$ref": "#/definitions/User"
  10702. },
  10703. "html_url": {
  10704. "type": "string",
  10705. "x-go-name": "HTMLURL"
  10706. },
  10707. "parents": {
  10708. "type": "array",
  10709. "items": {
  10710. "$ref": "#/definitions/CommitMeta"
  10711. },
  10712. "x-go-name": "Parents"
  10713. },
  10714. "sha": {
  10715. "type": "string",
  10716. "x-go-name": "SHA"
  10717. },
  10718. "url": {
  10719. "type": "string",
  10720. "x-go-name": "URL"
  10721. }
  10722. },
  10723. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10724. },
  10725. "CommitDateOptions": {
  10726. "description": "CommitDateOptions store dates for GIT_AUTHOR_DATE and GIT_COMMITTER_DATE",
  10727. "type": "object",
  10728. "properties": {
  10729. "author": {
  10730. "type": "string",
  10731. "format": "date-time",
  10732. "x-go-name": "Author"
  10733. },
  10734. "committer": {
  10735. "type": "string",
  10736. "format": "date-time",
  10737. "x-go-name": "Committer"
  10738. }
  10739. },
  10740. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10741. },
  10742. "CommitMeta": {
  10743. "type": "object",
  10744. "title": "CommitMeta contains meta information of a commit in terms of API.",
  10745. "properties": {
  10746. "sha": {
  10747. "type": "string",
  10748. "x-go-name": "SHA"
  10749. },
  10750. "url": {
  10751. "type": "string",
  10752. "x-go-name": "URL"
  10753. }
  10754. },
  10755. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10756. },
  10757. "CommitUser": {
  10758. "type": "object",
  10759. "title": "CommitUser contains information of a user in the context of a commit.",
  10760. "properties": {
  10761. "date": {
  10762. "type": "string",
  10763. "x-go-name": "Date"
  10764. },
  10765. "email": {
  10766. "type": "string",
  10767. "format": "email",
  10768. "x-go-name": "Email"
  10769. },
  10770. "name": {
  10771. "type": "string",
  10772. "x-go-name": "Name"
  10773. }
  10774. },
  10775. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10776. },
  10777. "ContentsResponse": {
  10778. "description": "ContentsResponse contains information about a repo's entry's (dir, file, symlink, submodule) metadata and content",
  10779. "type": "object",
  10780. "properties": {
  10781. "_links": {
  10782. "$ref": "#/definitions/FileLinksResponse"
  10783. },
  10784. "content": {
  10785. "description": "`content` is populated when `type` is `file`, otherwise null",
  10786. "type": "string",
  10787. "x-go-name": "Content"
  10788. },
  10789. "download_url": {
  10790. "type": "string",
  10791. "x-go-name": "DownloadURL"
  10792. },
  10793. "encoding": {
  10794. "description": "`encoding` is populated when `type` is `file`, otherwise null",
  10795. "type": "string",
  10796. "x-go-name": "Encoding"
  10797. },
  10798. "git_url": {
  10799. "type": "string",
  10800. "x-go-name": "GitURL"
  10801. },
  10802. "html_url": {
  10803. "type": "string",
  10804. "x-go-name": "HTMLURL"
  10805. },
  10806. "name": {
  10807. "type": "string",
  10808. "x-go-name": "Name"
  10809. },
  10810. "path": {
  10811. "type": "string",
  10812. "x-go-name": "Path"
  10813. },
  10814. "sha": {
  10815. "type": "string",
  10816. "x-go-name": "SHA"
  10817. },
  10818. "size": {
  10819. "type": "integer",
  10820. "format": "int64",
  10821. "x-go-name": "Size"
  10822. },
  10823. "submodule_git_url": {
  10824. "description": "`submodule_git_url` is populated when `type` is `submodule`, otherwise null",
  10825. "type": "string",
  10826. "x-go-name": "SubmoduleGitURL"
  10827. },
  10828. "target": {
  10829. "description": "`target` is populated when `type` is `symlink`, otherwise null",
  10830. "type": "string",
  10831. "x-go-name": "Target"
  10832. },
  10833. "type": {
  10834. "description": "`type` will be `file`, `dir`, `symlink`, or `submodule`",
  10835. "type": "string",
  10836. "x-go-name": "Type"
  10837. },
  10838. "url": {
  10839. "type": "string",
  10840. "x-go-name": "URL"
  10841. }
  10842. },
  10843. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10844. },
  10845. "CreateBranchProtectionOption": {
  10846. "description": "CreateBranchProtectionOption options for creating a branch protection",
  10847. "type": "object",
  10848. "properties": {
  10849. "approvals_whitelist_teams": {
  10850. "type": "array",
  10851. "items": {
  10852. "type": "string"
  10853. },
  10854. "x-go-name": "ApprovalsWhitelistTeams"
  10855. },
  10856. "approvals_whitelist_username": {
  10857. "type": "array",
  10858. "items": {
  10859. "type": "string"
  10860. },
  10861. "x-go-name": "ApprovalsWhitelistUsernames"
  10862. },
  10863. "block_on_outdated_branch": {
  10864. "type": "boolean",
  10865. "x-go-name": "BlockOnOutdatedBranch"
  10866. },
  10867. "block_on_rejected_reviews": {
  10868. "type": "boolean",
  10869. "x-go-name": "BlockOnRejectedReviews"
  10870. },
  10871. "branch_name": {
  10872. "type": "string",
  10873. "x-go-name": "BranchName"
  10874. },
  10875. "dismiss_stale_approvals": {
  10876. "type": "boolean",
  10877. "x-go-name": "DismissStaleApprovals"
  10878. },
  10879. "enable_approvals_whitelist": {
  10880. "type": "boolean",
  10881. "x-go-name": "EnableApprovalsWhitelist"
  10882. },
  10883. "enable_merge_whitelist": {
  10884. "type": "boolean",
  10885. "x-go-name": "EnableMergeWhitelist"
  10886. },
  10887. "enable_push": {
  10888. "type": "boolean",
  10889. "x-go-name": "EnablePush"
  10890. },
  10891. "enable_push_whitelist": {
  10892. "type": "boolean",
  10893. "x-go-name": "EnablePushWhitelist"
  10894. },
  10895. "enable_status_check": {
  10896. "type": "boolean",
  10897. "x-go-name": "EnableStatusCheck"
  10898. },
  10899. "merge_whitelist_teams": {
  10900. "type": "array",
  10901. "items": {
  10902. "type": "string"
  10903. },
  10904. "x-go-name": "MergeWhitelistTeams"
  10905. },
  10906. "merge_whitelist_usernames": {
  10907. "type": "array",
  10908. "items": {
  10909. "type": "string"
  10910. },
  10911. "x-go-name": "MergeWhitelistUsernames"
  10912. },
  10913. "protected_file_patterns": {
  10914. "type": "string",
  10915. "x-go-name": "ProtectedFilePatterns"
  10916. },
  10917. "push_whitelist_deploy_keys": {
  10918. "type": "boolean",
  10919. "x-go-name": "PushWhitelistDeployKeys"
  10920. },
  10921. "push_whitelist_teams": {
  10922. "type": "array",
  10923. "items": {
  10924. "type": "string"
  10925. },
  10926. "x-go-name": "PushWhitelistTeams"
  10927. },
  10928. "push_whitelist_usernames": {
  10929. "type": "array",
  10930. "items": {
  10931. "type": "string"
  10932. },
  10933. "x-go-name": "PushWhitelistUsernames"
  10934. },
  10935. "require_signed_commits": {
  10936. "type": "boolean",
  10937. "x-go-name": "RequireSignedCommits"
  10938. },
  10939. "required_approvals": {
  10940. "type": "integer",
  10941. "format": "int64",
  10942. "x-go-name": "RequiredApprovals"
  10943. },
  10944. "status_check_contexts": {
  10945. "type": "array",
  10946. "items": {
  10947. "type": "string"
  10948. },
  10949. "x-go-name": "StatusCheckContexts"
  10950. }
  10951. },
  10952. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10953. },
  10954. "CreateBranchRepoOption": {
  10955. "description": "CreateBranchRepoOption options when creating a branch in a repository",
  10956. "type": "object",
  10957. "required": [
  10958. "new_branch_name"
  10959. ],
  10960. "properties": {
  10961. "new_branch_name": {
  10962. "description": "Name of the branch to create",
  10963. "type": "string",
  10964. "uniqueItems": true,
  10965. "x-go-name": "BranchName"
  10966. },
  10967. "old_branch_name": {
  10968. "description": "Name of the old branch to create from",
  10969. "type": "string",
  10970. "uniqueItems": true,
  10971. "x-go-name": "OldBranchName"
  10972. }
  10973. },
  10974. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10975. },
  10976. "CreateEmailOption": {
  10977. "description": "CreateEmailOption options when creating email addresses",
  10978. "type": "object",
  10979. "properties": {
  10980. "emails": {
  10981. "description": "email addresses to add",
  10982. "type": "array",
  10983. "items": {
  10984. "type": "string"
  10985. },
  10986. "x-go-name": "Emails"
  10987. }
  10988. },
  10989. "x-go-package": "code.gitea.io/gitea/modules/structs"
  10990. },
  10991. "CreateFileOptions": {
  10992. "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)",
  10993. "type": "object",
  10994. "required": [
  10995. "content"
  10996. ],
  10997. "properties": {
  10998. "author": {
  10999. "$ref": "#/definitions/Identity"
  11000. },
  11001. "branch": {
  11002. "description": "branch (optional) to base this file from. if not given, the default branch is used",
  11003. "type": "string",
  11004. "x-go-name": "BranchName"
  11005. },
  11006. "committer": {
  11007. "$ref": "#/definitions/Identity"
  11008. },
  11009. "content": {
  11010. "description": "content must be base64 encoded",
  11011. "type": "string",
  11012. "x-go-name": "Content"
  11013. },
  11014. "dates": {
  11015. "$ref": "#/definitions/CommitDateOptions"
  11016. },
  11017. "message": {
  11018. "description": "message (optional) for the commit of this file. if not supplied, a default message will be used",
  11019. "type": "string",
  11020. "x-go-name": "Message"
  11021. },
  11022. "new_branch": {
  11023. "description": "new_branch (optional) will make a new branch from `branch` before creating the file",
  11024. "type": "string",
  11025. "x-go-name": "NewBranchName"
  11026. }
  11027. },
  11028. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11029. },
  11030. "CreateForkOption": {
  11031. "description": "CreateForkOption options for creating a fork",
  11032. "type": "object",
  11033. "properties": {
  11034. "organization": {
  11035. "description": "organization name, if forking into an organization",
  11036. "type": "string",
  11037. "x-go-name": "Organization"
  11038. }
  11039. },
  11040. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11041. },
  11042. "CreateGPGKeyOption": {
  11043. "description": "CreateGPGKeyOption options create user GPG key",
  11044. "type": "object",
  11045. "required": [
  11046. "armored_public_key"
  11047. ],
  11048. "properties": {
  11049. "armored_public_key": {
  11050. "description": "An armored GPG key to add",
  11051. "type": "string",
  11052. "uniqueItems": true,
  11053. "x-go-name": "ArmoredKey"
  11054. }
  11055. },
  11056. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11057. },
  11058. "CreateHookOption": {
  11059. "description": "CreateHookOption options when create a hook",
  11060. "type": "object",
  11061. "required": [
  11062. "type",
  11063. "config"
  11064. ],
  11065. "properties": {
  11066. "active": {
  11067. "type": "boolean",
  11068. "default": false,
  11069. "x-go-name": "Active"
  11070. },
  11071. "branch_filter": {
  11072. "type": "string",
  11073. "x-go-name": "BranchFilter"
  11074. },
  11075. "config": {
  11076. "$ref": "#/definitions/CreateHookOptionConfig"
  11077. },
  11078. "events": {
  11079. "type": "array",
  11080. "items": {
  11081. "type": "string"
  11082. },
  11083. "x-go-name": "Events"
  11084. },
  11085. "type": {
  11086. "type": "string",
  11087. "enum": [
  11088. "dingtalk",
  11089. "discord",
  11090. "gitea",
  11091. "gogs",
  11092. "msteams",
  11093. "slack",
  11094. "telegram",
  11095. "feishu"
  11096. ],
  11097. "x-go-name": "Type"
  11098. }
  11099. },
  11100. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11101. },
  11102. "CreateHookOptionConfig": {
  11103. "description": "CreateHookOptionConfig has all config options in it\nrequired are \"content_type\" and \"url\" Required",
  11104. "type": "object",
  11105. "additionalProperties": {
  11106. "type": "string"
  11107. },
  11108. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11109. },
  11110. "CreateIssueCommentOption": {
  11111. "description": "CreateIssueCommentOption options for creating a comment on an issue",
  11112. "type": "object",
  11113. "required": [
  11114. "body"
  11115. ],
  11116. "properties": {
  11117. "body": {
  11118. "type": "string",
  11119. "x-go-name": "Body"
  11120. }
  11121. },
  11122. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11123. },
  11124. "CreateIssueOption": {
  11125. "description": "CreateIssueOption options to create one issue",
  11126. "type": "object",
  11127. "required": [
  11128. "title"
  11129. ],
  11130. "properties": {
  11131. "assignee": {
  11132. "description": "username of assignee",
  11133. "type": "string",
  11134. "x-go-name": "Assignee"
  11135. },
  11136. "assignees": {
  11137. "type": "array",
  11138. "items": {
  11139. "type": "string"
  11140. },
  11141. "x-go-name": "Assignees"
  11142. },
  11143. "body": {
  11144. "type": "string",
  11145. "x-go-name": "Body"
  11146. },
  11147. "closed": {
  11148. "type": "boolean",
  11149. "x-go-name": "Closed"
  11150. },
  11151. "due_date": {
  11152. "type": "string",
  11153. "format": "date-time",
  11154. "x-go-name": "Deadline"
  11155. },
  11156. "labels": {
  11157. "description": "list of label ids",
  11158. "type": "array",
  11159. "items": {
  11160. "type": "integer",
  11161. "format": "int64"
  11162. },
  11163. "x-go-name": "Labels"
  11164. },
  11165. "milestone": {
  11166. "description": "milestone id",
  11167. "type": "integer",
  11168. "format": "int64",
  11169. "x-go-name": "Milestone"
  11170. },
  11171. "title": {
  11172. "type": "string",
  11173. "x-go-name": "Title"
  11174. }
  11175. },
  11176. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11177. },
  11178. "CreateKeyOption": {
  11179. "description": "CreateKeyOption options when creating a key",
  11180. "type": "object",
  11181. "required": [
  11182. "title",
  11183. "key"
  11184. ],
  11185. "properties": {
  11186. "key": {
  11187. "description": "An armored SSH key to add",
  11188. "type": "string",
  11189. "uniqueItems": true,
  11190. "x-go-name": "Key"
  11191. },
  11192. "read_only": {
  11193. "description": "Describe if the key has only read access or read/write",
  11194. "type": "boolean",
  11195. "x-go-name": "ReadOnly"
  11196. },
  11197. "title": {
  11198. "description": "Title of the key to add",
  11199. "type": "string",
  11200. "uniqueItems": true,
  11201. "x-go-name": "Title"
  11202. }
  11203. },
  11204. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11205. },
  11206. "CreateLabelOption": {
  11207. "description": "CreateLabelOption options for creating a label",
  11208. "type": "object",
  11209. "required": [
  11210. "name",
  11211. "color"
  11212. ],
  11213. "properties": {
  11214. "color": {
  11215. "type": "string",
  11216. "x-go-name": "Color",
  11217. "example": "#00aabb"
  11218. },
  11219. "description": {
  11220. "type": "string",
  11221. "x-go-name": "Description"
  11222. },
  11223. "name": {
  11224. "type": "string",
  11225. "x-go-name": "Name"
  11226. }
  11227. },
  11228. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11229. },
  11230. "CreateMilestoneOption": {
  11231. "description": "CreateMilestoneOption options for creating a milestone",
  11232. "type": "object",
  11233. "properties": {
  11234. "description": {
  11235. "type": "string",
  11236. "x-go-name": "Description"
  11237. },
  11238. "due_on": {
  11239. "type": "string",
  11240. "format": "date-time",
  11241. "x-go-name": "Deadline"
  11242. },
  11243. "title": {
  11244. "type": "string",
  11245. "x-go-name": "Title"
  11246. }
  11247. },
  11248. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11249. },
  11250. "CreateOAuth2ApplicationOptions": {
  11251. "description": "CreateOAuth2ApplicationOptions holds options to create an oauth2 application",
  11252. "type": "object",
  11253. "properties": {
  11254. "name": {
  11255. "type": "string",
  11256. "x-go-name": "Name"
  11257. },
  11258. "redirect_uris": {
  11259. "type": "array",
  11260. "items": {
  11261. "type": "string"
  11262. },
  11263. "x-go-name": "RedirectURIs"
  11264. }
  11265. },
  11266. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11267. },
  11268. "CreateOrgOption": {
  11269. "description": "CreateOrgOption options for creating an organization",
  11270. "type": "object",
  11271. "required": [
  11272. "username"
  11273. ],
  11274. "properties": {
  11275. "description": {
  11276. "type": "string",
  11277. "x-go-name": "Description"
  11278. },
  11279. "full_name": {
  11280. "type": "string",
  11281. "x-go-name": "FullName"
  11282. },
  11283. "location": {
  11284. "type": "string",
  11285. "x-go-name": "Location"
  11286. },
  11287. "repo_admin_change_team_access": {
  11288. "type": "boolean",
  11289. "x-go-name": "RepoAdminChangeTeamAccess"
  11290. },
  11291. "username": {
  11292. "type": "string",
  11293. "x-go-name": "UserName"
  11294. },
  11295. "visibility": {
  11296. "description": "possible values are `public` (default), `limited` or `private`",
  11297. "type": "string",
  11298. "enum": [
  11299. "public",
  11300. "limited",
  11301. "private"
  11302. ],
  11303. "x-go-name": "Visibility"
  11304. },
  11305. "website": {
  11306. "type": "string",
  11307. "x-go-name": "Website"
  11308. }
  11309. },
  11310. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11311. },
  11312. "CreatePullRequestOption": {
  11313. "description": "CreatePullRequestOption options when creating a pull request",
  11314. "type": "object",
  11315. "properties": {
  11316. "assignee": {
  11317. "type": "string",
  11318. "x-go-name": "Assignee"
  11319. },
  11320. "assignees": {
  11321. "type": "array",
  11322. "items": {
  11323. "type": "string"
  11324. },
  11325. "x-go-name": "Assignees"
  11326. },
  11327. "base": {
  11328. "type": "string",
  11329. "x-go-name": "Base"
  11330. },
  11331. "body": {
  11332. "type": "string",
  11333. "x-go-name": "Body"
  11334. },
  11335. "due_date": {
  11336. "type": "string",
  11337. "format": "date-time",
  11338. "x-go-name": "Deadline"
  11339. },
  11340. "head": {
  11341. "type": "string",
  11342. "x-go-name": "Head"
  11343. },
  11344. "labels": {
  11345. "type": "array",
  11346. "items": {
  11347. "type": "integer",
  11348. "format": "int64"
  11349. },
  11350. "x-go-name": "Labels"
  11351. },
  11352. "milestone": {
  11353. "type": "integer",
  11354. "format": "int64",
  11355. "x-go-name": "Milestone"
  11356. },
  11357. "title": {
  11358. "type": "string",
  11359. "x-go-name": "Title"
  11360. }
  11361. },
  11362. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11363. },
  11364. "CreatePullReviewComment": {
  11365. "description": "CreatePullReviewComment represent a review comment for creation api",
  11366. "type": "object",
  11367. "properties": {
  11368. "body": {
  11369. "type": "string",
  11370. "x-go-name": "Body"
  11371. },
  11372. "new_position": {
  11373. "description": "if comment to new file line or 0",
  11374. "type": "integer",
  11375. "format": "int64",
  11376. "x-go-name": "NewLineNum"
  11377. },
  11378. "old_position": {
  11379. "description": "if comment to old file line or 0",
  11380. "type": "integer",
  11381. "format": "int64",
  11382. "x-go-name": "OldLineNum"
  11383. },
  11384. "path": {
  11385. "description": "the tree path",
  11386. "type": "string",
  11387. "x-go-name": "Path"
  11388. }
  11389. },
  11390. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11391. },
  11392. "CreatePullReviewOptions": {
  11393. "description": "CreatePullReviewOptions are options to create a pull review",
  11394. "type": "object",
  11395. "properties": {
  11396. "body": {
  11397. "type": "string",
  11398. "x-go-name": "Body"
  11399. },
  11400. "comments": {
  11401. "type": "array",
  11402. "items": {
  11403. "$ref": "#/definitions/CreatePullReviewComment"
  11404. },
  11405. "x-go-name": "Comments"
  11406. },
  11407. "commit_id": {
  11408. "type": "string",
  11409. "x-go-name": "CommitID"
  11410. },
  11411. "event": {
  11412. "$ref": "#/definitions/ReviewStateType"
  11413. }
  11414. },
  11415. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11416. },
  11417. "CreateReleaseOption": {
  11418. "description": "CreateReleaseOption options when creating a release",
  11419. "type": "object",
  11420. "required": [
  11421. "tag_name"
  11422. ],
  11423. "properties": {
  11424. "body": {
  11425. "type": "string",
  11426. "x-go-name": "Note"
  11427. },
  11428. "draft": {
  11429. "type": "boolean",
  11430. "x-go-name": "IsDraft"
  11431. },
  11432. "name": {
  11433. "type": "string",
  11434. "x-go-name": "Title"
  11435. },
  11436. "prerelease": {
  11437. "type": "boolean",
  11438. "x-go-name": "IsPrerelease"
  11439. },
  11440. "tag_name": {
  11441. "type": "string",
  11442. "x-go-name": "TagName"
  11443. },
  11444. "target_commitish": {
  11445. "type": "string",
  11446. "x-go-name": "Target"
  11447. }
  11448. },
  11449. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11450. },
  11451. "CreateRepoOption": {
  11452. "description": "CreateRepoOption options when creating repository",
  11453. "type": "object",
  11454. "required": [
  11455. "name"
  11456. ],
  11457. "properties": {
  11458. "auto_init": {
  11459. "description": "Whether the repository should be auto-intialized?",
  11460. "type": "boolean",
  11461. "x-go-name": "AutoInit"
  11462. },
  11463. "default_branch": {
  11464. "description": "DefaultBranch of the repository (used when initializes and in template)",
  11465. "type": "string",
  11466. "x-go-name": "DefaultBranch"
  11467. },
  11468. "description": {
  11469. "description": "Description of the repository to create",
  11470. "type": "string",
  11471. "x-go-name": "Description"
  11472. },
  11473. "gitignores": {
  11474. "description": "Gitignores to use",
  11475. "type": "string",
  11476. "x-go-name": "Gitignores"
  11477. },
  11478. "issue_labels": {
  11479. "description": "Issue Label set to use",
  11480. "type": "string",
  11481. "x-go-name": "IssueLabels"
  11482. },
  11483. "license": {
  11484. "description": "License to use",
  11485. "type": "string",
  11486. "x-go-name": "License"
  11487. },
  11488. "name": {
  11489. "description": "Name of the repository to create",
  11490. "type": "string",
  11491. "uniqueItems": true,
  11492. "x-go-name": "Name"
  11493. },
  11494. "private": {
  11495. "description": "Whether the repository is private",
  11496. "type": "boolean",
  11497. "x-go-name": "Private"
  11498. },
  11499. "readme": {
  11500. "description": "Readme of the repository to create",
  11501. "type": "string",
  11502. "x-go-name": "Readme"
  11503. }
  11504. },
  11505. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11506. },
  11507. "CreateStatusOption": {
  11508. "description": "CreateStatusOption holds the information needed to create a new Status for a Commit",
  11509. "type": "object",
  11510. "properties": {
  11511. "context": {
  11512. "type": "string",
  11513. "x-go-name": "Context"
  11514. },
  11515. "description": {
  11516. "type": "string",
  11517. "x-go-name": "Description"
  11518. },
  11519. "state": {
  11520. "$ref": "#/definitions/StatusState"
  11521. },
  11522. "target_url": {
  11523. "type": "string",
  11524. "x-go-name": "TargetURL"
  11525. }
  11526. },
  11527. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11528. },
  11529. "CreateTeamOption": {
  11530. "description": "CreateTeamOption options for creating a team",
  11531. "type": "object",
  11532. "required": [
  11533. "name"
  11534. ],
  11535. "properties": {
  11536. "can_create_org_repo": {
  11537. "type": "boolean",
  11538. "x-go-name": "CanCreateOrgRepo"
  11539. },
  11540. "description": {
  11541. "type": "string",
  11542. "x-go-name": "Description"
  11543. },
  11544. "includes_all_repositories": {
  11545. "type": "boolean",
  11546. "x-go-name": "IncludesAllRepositories"
  11547. },
  11548. "name": {
  11549. "type": "string",
  11550. "x-go-name": "Name"
  11551. },
  11552. "permission": {
  11553. "type": "string",
  11554. "enum": [
  11555. "read",
  11556. "write",
  11557. "admin"
  11558. ],
  11559. "x-go-name": "Permission"
  11560. },
  11561. "units": {
  11562. "type": "array",
  11563. "items": {
  11564. "type": "string"
  11565. },
  11566. "x-go-name": "Units",
  11567. "example": [
  11568. "repo.code",
  11569. "repo.issues",
  11570. "repo.ext_issues",
  11571. "repo.wiki",
  11572. "repo.pulls",
  11573. "repo.releases",
  11574. "repo.ext_wiki"
  11575. ]
  11576. }
  11577. },
  11578. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11579. },
  11580. "CreateUserOption": {
  11581. "description": "CreateUserOption create user options",
  11582. "type": "object",
  11583. "required": [
  11584. "username",
  11585. "email",
  11586. "password"
  11587. ],
  11588. "properties": {
  11589. "email": {
  11590. "type": "string",
  11591. "format": "email",
  11592. "x-go-name": "Email"
  11593. },
  11594. "full_name": {
  11595. "type": "string",
  11596. "x-go-name": "FullName"
  11597. },
  11598. "login_name": {
  11599. "type": "string",
  11600. "x-go-name": "LoginName"
  11601. },
  11602. "must_change_password": {
  11603. "type": "boolean",
  11604. "x-go-name": "MustChangePassword"
  11605. },
  11606. "password": {
  11607. "type": "string",
  11608. "x-go-name": "Password"
  11609. },
  11610. "send_notify": {
  11611. "type": "boolean",
  11612. "x-go-name": "SendNotify"
  11613. },
  11614. "source_id": {
  11615. "type": "integer",
  11616. "format": "int64",
  11617. "x-go-name": "SourceID"
  11618. },
  11619. "username": {
  11620. "type": "string",
  11621. "x-go-name": "Username"
  11622. }
  11623. },
  11624. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11625. },
  11626. "DeleteEmailOption": {
  11627. "description": "DeleteEmailOption options when deleting email addresses",
  11628. "type": "object",
  11629. "properties": {
  11630. "emails": {
  11631. "description": "email addresses to delete",
  11632. "type": "array",
  11633. "items": {
  11634. "type": "string"
  11635. },
  11636. "x-go-name": "Emails"
  11637. }
  11638. },
  11639. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11640. },
  11641. "DeleteFileOptions": {
  11642. "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)",
  11643. "type": "object",
  11644. "required": [
  11645. "sha"
  11646. ],
  11647. "properties": {
  11648. "author": {
  11649. "$ref": "#/definitions/Identity"
  11650. },
  11651. "branch": {
  11652. "description": "branch (optional) to base this file from. if not given, the default branch is used",
  11653. "type": "string",
  11654. "x-go-name": "BranchName"
  11655. },
  11656. "committer": {
  11657. "$ref": "#/definitions/Identity"
  11658. },
  11659. "dates": {
  11660. "$ref": "#/definitions/CommitDateOptions"
  11661. },
  11662. "message": {
  11663. "description": "message (optional) for the commit of this file. if not supplied, a default message will be used",
  11664. "type": "string",
  11665. "x-go-name": "Message"
  11666. },
  11667. "new_branch": {
  11668. "description": "new_branch (optional) will make a new branch from `branch` before creating the file",
  11669. "type": "string",
  11670. "x-go-name": "NewBranchName"
  11671. },
  11672. "sha": {
  11673. "description": "sha is the SHA for the file that already exists",
  11674. "type": "string",
  11675. "x-go-name": "SHA"
  11676. }
  11677. },
  11678. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11679. },
  11680. "DeployKey": {
  11681. "description": "DeployKey a deploy key",
  11682. "type": "object",
  11683. "properties": {
  11684. "created_at": {
  11685. "type": "string",
  11686. "format": "date-time",
  11687. "x-go-name": "Created"
  11688. },
  11689. "fingerprint": {
  11690. "type": "string",
  11691. "x-go-name": "Fingerprint"
  11692. },
  11693. "id": {
  11694. "type": "integer",
  11695. "format": "int64",
  11696. "x-go-name": "ID"
  11697. },
  11698. "key": {
  11699. "type": "string",
  11700. "x-go-name": "Key"
  11701. },
  11702. "key_id": {
  11703. "type": "integer",
  11704. "format": "int64",
  11705. "x-go-name": "KeyID"
  11706. },
  11707. "read_only": {
  11708. "type": "boolean",
  11709. "x-go-name": "ReadOnly"
  11710. },
  11711. "repository": {
  11712. "$ref": "#/definitions/Repository"
  11713. },
  11714. "title": {
  11715. "type": "string",
  11716. "x-go-name": "Title"
  11717. },
  11718. "url": {
  11719. "type": "string",
  11720. "x-go-name": "URL"
  11721. }
  11722. },
  11723. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11724. },
  11725. "EditAttachmentOptions": {
  11726. "description": "EditAttachmentOptions options for editing attachments",
  11727. "type": "object",
  11728. "properties": {
  11729. "name": {
  11730. "type": "string",
  11731. "x-go-name": "Name"
  11732. }
  11733. },
  11734. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11735. },
  11736. "EditBranchProtectionOption": {
  11737. "description": "EditBranchProtectionOption options for editing a branch protection",
  11738. "type": "object",
  11739. "properties": {
  11740. "approvals_whitelist_teams": {
  11741. "type": "array",
  11742. "items": {
  11743. "type": "string"
  11744. },
  11745. "x-go-name": "ApprovalsWhitelistTeams"
  11746. },
  11747. "approvals_whitelist_username": {
  11748. "type": "array",
  11749. "items": {
  11750. "type": "string"
  11751. },
  11752. "x-go-name": "ApprovalsWhitelistUsernames"
  11753. },
  11754. "block_on_outdated_branch": {
  11755. "type": "boolean",
  11756. "x-go-name": "BlockOnOutdatedBranch"
  11757. },
  11758. "block_on_rejected_reviews": {
  11759. "type": "boolean",
  11760. "x-go-name": "BlockOnRejectedReviews"
  11761. },
  11762. "dismiss_stale_approvals": {
  11763. "type": "boolean",
  11764. "x-go-name": "DismissStaleApprovals"
  11765. },
  11766. "enable_approvals_whitelist": {
  11767. "type": "boolean",
  11768. "x-go-name": "EnableApprovalsWhitelist"
  11769. },
  11770. "enable_merge_whitelist": {
  11771. "type": "boolean",
  11772. "x-go-name": "EnableMergeWhitelist"
  11773. },
  11774. "enable_push": {
  11775. "type": "boolean",
  11776. "x-go-name": "EnablePush"
  11777. },
  11778. "enable_push_whitelist": {
  11779. "type": "boolean",
  11780. "x-go-name": "EnablePushWhitelist"
  11781. },
  11782. "enable_status_check": {
  11783. "type": "boolean",
  11784. "x-go-name": "EnableStatusCheck"
  11785. },
  11786. "merge_whitelist_teams": {
  11787. "type": "array",
  11788. "items": {
  11789. "type": "string"
  11790. },
  11791. "x-go-name": "MergeWhitelistTeams"
  11792. },
  11793. "merge_whitelist_usernames": {
  11794. "type": "array",
  11795. "items": {
  11796. "type": "string"
  11797. },
  11798. "x-go-name": "MergeWhitelistUsernames"
  11799. },
  11800. "protected_file_patterns": {
  11801. "type": "string",
  11802. "x-go-name": "ProtectedFilePatterns"
  11803. },
  11804. "push_whitelist_deploy_keys": {
  11805. "type": "boolean",
  11806. "x-go-name": "PushWhitelistDeployKeys"
  11807. },
  11808. "push_whitelist_teams": {
  11809. "type": "array",
  11810. "items": {
  11811. "type": "string"
  11812. },
  11813. "x-go-name": "PushWhitelistTeams"
  11814. },
  11815. "push_whitelist_usernames": {
  11816. "type": "array",
  11817. "items": {
  11818. "type": "string"
  11819. },
  11820. "x-go-name": "PushWhitelistUsernames"
  11821. },
  11822. "require_signed_commits": {
  11823. "type": "boolean",
  11824. "x-go-name": "RequireSignedCommits"
  11825. },
  11826. "required_approvals": {
  11827. "type": "integer",
  11828. "format": "int64",
  11829. "x-go-name": "RequiredApprovals"
  11830. },
  11831. "status_check_contexts": {
  11832. "type": "array",
  11833. "items": {
  11834. "type": "string"
  11835. },
  11836. "x-go-name": "StatusCheckContexts"
  11837. }
  11838. },
  11839. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11840. },
  11841. "EditDeadlineOption": {
  11842. "description": "EditDeadlineOption options for creating a deadline",
  11843. "type": "object",
  11844. "required": [
  11845. "due_date"
  11846. ],
  11847. "properties": {
  11848. "due_date": {
  11849. "type": "string",
  11850. "format": "date-time",
  11851. "x-go-name": "Deadline"
  11852. }
  11853. },
  11854. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11855. },
  11856. "EditGitHookOption": {
  11857. "description": "EditGitHookOption options when modifying one Git hook",
  11858. "type": "object",
  11859. "properties": {
  11860. "content": {
  11861. "type": "string",
  11862. "x-go-name": "Content"
  11863. }
  11864. },
  11865. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11866. },
  11867. "EditHookOption": {
  11868. "description": "EditHookOption options when modify one hook",
  11869. "type": "object",
  11870. "properties": {
  11871. "active": {
  11872. "type": "boolean",
  11873. "x-go-name": "Active"
  11874. },
  11875. "branch_filter": {
  11876. "type": "string",
  11877. "x-go-name": "BranchFilter"
  11878. },
  11879. "config": {
  11880. "type": "object",
  11881. "additionalProperties": {
  11882. "type": "string"
  11883. },
  11884. "x-go-name": "Config"
  11885. },
  11886. "events": {
  11887. "type": "array",
  11888. "items": {
  11889. "type": "string"
  11890. },
  11891. "x-go-name": "Events"
  11892. }
  11893. },
  11894. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11895. },
  11896. "EditIssueCommentOption": {
  11897. "description": "EditIssueCommentOption options for editing a comment",
  11898. "type": "object",
  11899. "required": [
  11900. "body"
  11901. ],
  11902. "properties": {
  11903. "body": {
  11904. "type": "string",
  11905. "x-go-name": "Body"
  11906. }
  11907. },
  11908. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11909. },
  11910. "EditIssueOption": {
  11911. "description": "EditIssueOption options for editing an issue",
  11912. "type": "object",
  11913. "properties": {
  11914. "assignee": {
  11915. "type": "string",
  11916. "x-go-name": "Assignee"
  11917. },
  11918. "assignees": {
  11919. "type": "array",
  11920. "items": {
  11921. "type": "string"
  11922. },
  11923. "x-go-name": "Assignees"
  11924. },
  11925. "body": {
  11926. "type": "string",
  11927. "x-go-name": "Body"
  11928. },
  11929. "due_date": {
  11930. "type": "string",
  11931. "format": "date-time",
  11932. "x-go-name": "Deadline"
  11933. },
  11934. "milestone": {
  11935. "type": "integer",
  11936. "format": "int64",
  11937. "x-go-name": "Milestone"
  11938. },
  11939. "state": {
  11940. "type": "string",
  11941. "x-go-name": "State"
  11942. },
  11943. "title": {
  11944. "type": "string",
  11945. "x-go-name": "Title"
  11946. },
  11947. "unset_due_date": {
  11948. "type": "boolean",
  11949. "x-go-name": "RemoveDeadline"
  11950. }
  11951. },
  11952. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11953. },
  11954. "EditLabelOption": {
  11955. "description": "EditLabelOption options for editing a label",
  11956. "type": "object",
  11957. "properties": {
  11958. "color": {
  11959. "type": "string",
  11960. "x-go-name": "Color"
  11961. },
  11962. "description": {
  11963. "type": "string",
  11964. "x-go-name": "Description"
  11965. },
  11966. "name": {
  11967. "type": "string",
  11968. "x-go-name": "Name"
  11969. }
  11970. },
  11971. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11972. },
  11973. "EditMilestoneOption": {
  11974. "description": "EditMilestoneOption options for editing a milestone",
  11975. "type": "object",
  11976. "properties": {
  11977. "description": {
  11978. "type": "string",
  11979. "x-go-name": "Description"
  11980. },
  11981. "due_on": {
  11982. "type": "string",
  11983. "format": "date-time",
  11984. "x-go-name": "Deadline"
  11985. },
  11986. "state": {
  11987. "type": "string",
  11988. "x-go-name": "State"
  11989. },
  11990. "title": {
  11991. "type": "string",
  11992. "x-go-name": "Title"
  11993. }
  11994. },
  11995. "x-go-package": "code.gitea.io/gitea/modules/structs"
  11996. },
  11997. "EditOrgOption": {
  11998. "description": "EditOrgOption options for editing an organization",
  11999. "type": "object",
  12000. "properties": {
  12001. "description": {
  12002. "type": "string",
  12003. "x-go-name": "Description"
  12004. },
  12005. "full_name": {
  12006. "type": "string",
  12007. "x-go-name": "FullName"
  12008. },
  12009. "location": {
  12010. "type": "string",
  12011. "x-go-name": "Location"
  12012. },
  12013. "repo_admin_change_team_access": {
  12014. "type": "boolean",
  12015. "x-go-name": "RepoAdminChangeTeamAccess"
  12016. },
  12017. "visibility": {
  12018. "description": "possible values are `public`, `limited` or `private`",
  12019. "type": "string",
  12020. "enum": [
  12021. "public",
  12022. "limited",
  12023. "private"
  12024. ],
  12025. "x-go-name": "Visibility"
  12026. },
  12027. "website": {
  12028. "type": "string",
  12029. "x-go-name": "Website"
  12030. }
  12031. },
  12032. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12033. },
  12034. "EditPullRequestOption": {
  12035. "description": "EditPullRequestOption options when modify pull request",
  12036. "type": "object",
  12037. "properties": {
  12038. "assignee": {
  12039. "type": "string",
  12040. "x-go-name": "Assignee"
  12041. },
  12042. "assignees": {
  12043. "type": "array",
  12044. "items": {
  12045. "type": "string"
  12046. },
  12047. "x-go-name": "Assignees"
  12048. },
  12049. "body": {
  12050. "type": "string",
  12051. "x-go-name": "Body"
  12052. },
  12053. "due_date": {
  12054. "type": "string",
  12055. "format": "date-time",
  12056. "x-go-name": "Deadline"
  12057. },
  12058. "labels": {
  12059. "type": "array",
  12060. "items": {
  12061. "type": "integer",
  12062. "format": "int64"
  12063. },
  12064. "x-go-name": "Labels"
  12065. },
  12066. "milestone": {
  12067. "type": "integer",
  12068. "format": "int64",
  12069. "x-go-name": "Milestone"
  12070. },
  12071. "state": {
  12072. "type": "string",
  12073. "x-go-name": "State"
  12074. },
  12075. "title": {
  12076. "type": "string",
  12077. "x-go-name": "Title"
  12078. },
  12079. "unset_due_date": {
  12080. "type": "boolean",
  12081. "x-go-name": "RemoveDeadline"
  12082. }
  12083. },
  12084. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12085. },
  12086. "EditReactionOption": {
  12087. "description": "EditReactionOption contain the reaction type",
  12088. "type": "object",
  12089. "properties": {
  12090. "content": {
  12091. "type": "string",
  12092. "x-go-name": "Reaction"
  12093. }
  12094. },
  12095. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12096. },
  12097. "EditReleaseOption": {
  12098. "description": "EditReleaseOption options when editing a release",
  12099. "type": "object",
  12100. "properties": {
  12101. "body": {
  12102. "type": "string",
  12103. "x-go-name": "Note"
  12104. },
  12105. "draft": {
  12106. "type": "boolean",
  12107. "x-go-name": "IsDraft"
  12108. },
  12109. "name": {
  12110. "type": "string",
  12111. "x-go-name": "Title"
  12112. },
  12113. "prerelease": {
  12114. "type": "boolean",
  12115. "x-go-name": "IsPrerelease"
  12116. },
  12117. "tag_name": {
  12118. "type": "string",
  12119. "x-go-name": "TagName"
  12120. },
  12121. "target_commitish": {
  12122. "type": "string",
  12123. "x-go-name": "Target"
  12124. }
  12125. },
  12126. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12127. },
  12128. "EditRepoOption": {
  12129. "description": "EditRepoOption options when editing a repository's properties",
  12130. "type": "object",
  12131. "properties": {
  12132. "allow_merge_commits": {
  12133. "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`.",
  12134. "type": "boolean",
  12135. "x-go-name": "AllowMerge"
  12136. },
  12137. "allow_rebase": {
  12138. "description": "either `true` to allow rebase-merging pull requests, or `false` to prevent rebase-merging. `has_pull_requests` must be `true`.",
  12139. "type": "boolean",
  12140. "x-go-name": "AllowRebase"
  12141. },
  12142. "allow_rebase_explicit": {
  12143. "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`.",
  12144. "type": "boolean",
  12145. "x-go-name": "AllowRebaseMerge"
  12146. },
  12147. "allow_squash_merge": {
  12148. "description": "either `true` to allow squash-merging pull requests, or `false` to prevent squash-merging. `has_pull_requests` must be `true`.",
  12149. "type": "boolean",
  12150. "x-go-name": "AllowSquash"
  12151. },
  12152. "archived": {
  12153. "description": "set to `true` to archive this repository.",
  12154. "type": "boolean",
  12155. "x-go-name": "Archived"
  12156. },
  12157. "default_branch": {
  12158. "description": "sets the default branch for this repository.",
  12159. "type": "string",
  12160. "x-go-name": "DefaultBranch"
  12161. },
  12162. "description": {
  12163. "description": "a short description of the repository.",
  12164. "type": "string",
  12165. "x-go-name": "Description"
  12166. },
  12167. "external_tracker": {
  12168. "$ref": "#/definitions/ExternalTracker"
  12169. },
  12170. "external_wiki": {
  12171. "$ref": "#/definitions/ExternalWiki"
  12172. },
  12173. "has_issues": {
  12174. "description": "either `true` to enable issues for this repository or `false` to disable them.",
  12175. "type": "boolean",
  12176. "x-go-name": "HasIssues"
  12177. },
  12178. "has_pull_requests": {
  12179. "description": "either `true` to allow pull requests, or `false` to prevent pull request.",
  12180. "type": "boolean",
  12181. "x-go-name": "HasPullRequests"
  12182. },
  12183. "has_wiki": {
  12184. "description": "either `true` to enable the wiki for this repository or `false` to disable it.",
  12185. "type": "boolean",
  12186. "x-go-name": "HasWiki"
  12187. },
  12188. "ignore_whitespace_conflicts": {
  12189. "description": "either `true` to ignore whitespace for conflicts, or `false` to not ignore whitespace. `has_pull_requests` must be `true`.",
  12190. "type": "boolean",
  12191. "x-go-name": "IgnoreWhitespaceConflicts"
  12192. },
  12193. "internal_tracker": {
  12194. "$ref": "#/definitions/InternalTracker"
  12195. },
  12196. "name": {
  12197. "description": "name of the repository",
  12198. "type": "string",
  12199. "uniqueItems": true,
  12200. "x-go-name": "Name"
  12201. },
  12202. "private": {
  12203. "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.",
  12204. "type": "boolean",
  12205. "x-go-name": "Private"
  12206. },
  12207. "template": {
  12208. "description": "either `true` to make this repository a template or `false` to make it a normal repository",
  12209. "type": "boolean",
  12210. "x-go-name": "Template"
  12211. },
  12212. "website": {
  12213. "description": "a URL with more information about the repository.",
  12214. "type": "string",
  12215. "x-go-name": "Website"
  12216. }
  12217. },
  12218. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12219. },
  12220. "EditTeamOption": {
  12221. "description": "EditTeamOption options for editing a team",
  12222. "type": "object",
  12223. "required": [
  12224. "name"
  12225. ],
  12226. "properties": {
  12227. "can_create_org_repo": {
  12228. "type": "boolean",
  12229. "x-go-name": "CanCreateOrgRepo"
  12230. },
  12231. "description": {
  12232. "type": "string",
  12233. "x-go-name": "Description"
  12234. },
  12235. "includes_all_repositories": {
  12236. "type": "boolean",
  12237. "x-go-name": "IncludesAllRepositories"
  12238. },
  12239. "name": {
  12240. "type": "string",
  12241. "x-go-name": "Name"
  12242. },
  12243. "permission": {
  12244. "type": "string",
  12245. "enum": [
  12246. "read",
  12247. "write",
  12248. "admin"
  12249. ],
  12250. "x-go-name": "Permission"
  12251. },
  12252. "units": {
  12253. "type": "array",
  12254. "items": {
  12255. "type": "string"
  12256. },
  12257. "x-go-name": "Units",
  12258. "example": [
  12259. "repo.code",
  12260. "repo.issues",
  12261. "repo.ext_issues",
  12262. "repo.wiki",
  12263. "repo.pulls",
  12264. "repo.releases",
  12265. "repo.ext_wiki"
  12266. ]
  12267. }
  12268. },
  12269. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12270. },
  12271. "EditUserOption": {
  12272. "description": "EditUserOption edit user options",
  12273. "type": "object",
  12274. "required": [
  12275. "email"
  12276. ],
  12277. "properties": {
  12278. "active": {
  12279. "type": "boolean",
  12280. "x-go-name": "Active"
  12281. },
  12282. "admin": {
  12283. "type": "boolean",
  12284. "x-go-name": "Admin"
  12285. },
  12286. "allow_create_organization": {
  12287. "type": "boolean",
  12288. "x-go-name": "AllowCreateOrganization"
  12289. },
  12290. "allow_git_hook": {
  12291. "type": "boolean",
  12292. "x-go-name": "AllowGitHook"
  12293. },
  12294. "allow_import_local": {
  12295. "type": "boolean",
  12296. "x-go-name": "AllowImportLocal"
  12297. },
  12298. "email": {
  12299. "type": "string",
  12300. "format": "email",
  12301. "x-go-name": "Email"
  12302. },
  12303. "full_name": {
  12304. "type": "string",
  12305. "x-go-name": "FullName"
  12306. },
  12307. "location": {
  12308. "type": "string",
  12309. "x-go-name": "Location"
  12310. },
  12311. "login_name": {
  12312. "type": "string",
  12313. "x-go-name": "LoginName"
  12314. },
  12315. "max_repo_creation": {
  12316. "type": "integer",
  12317. "format": "int64",
  12318. "x-go-name": "MaxRepoCreation"
  12319. },
  12320. "must_change_password": {
  12321. "type": "boolean",
  12322. "x-go-name": "MustChangePassword"
  12323. },
  12324. "password": {
  12325. "type": "string",
  12326. "x-go-name": "Password"
  12327. },
  12328. "prohibit_login": {
  12329. "type": "boolean",
  12330. "x-go-name": "ProhibitLogin"
  12331. },
  12332. "source_id": {
  12333. "type": "integer",
  12334. "format": "int64",
  12335. "x-go-name": "SourceID"
  12336. },
  12337. "website": {
  12338. "type": "string",
  12339. "x-go-name": "Website"
  12340. }
  12341. },
  12342. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12343. },
  12344. "Email": {
  12345. "description": "Email an email address belonging to a user",
  12346. "type": "object",
  12347. "properties": {
  12348. "email": {
  12349. "type": "string",
  12350. "format": "email",
  12351. "x-go-name": "Email"
  12352. },
  12353. "primary": {
  12354. "type": "boolean",
  12355. "x-go-name": "Primary"
  12356. },
  12357. "verified": {
  12358. "type": "boolean",
  12359. "x-go-name": "Verified"
  12360. }
  12361. },
  12362. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12363. },
  12364. "ExternalTracker": {
  12365. "description": "ExternalTracker represents settings for external tracker",
  12366. "type": "object",
  12367. "properties": {
  12368. "external_tracker_format": {
  12369. "description": "External Issue Tracker URL Format. Use the placeholders {user}, {repo} and {index} for the username, repository name and issue index.",
  12370. "type": "string",
  12371. "x-go-name": "ExternalTrackerFormat"
  12372. },
  12373. "external_tracker_style": {
  12374. "description": "External Issue Tracker Number Format, either `numeric` or `alphanumeric`",
  12375. "type": "string",
  12376. "x-go-name": "ExternalTrackerStyle"
  12377. },
  12378. "external_tracker_url": {
  12379. "description": "URL of external issue tracker.",
  12380. "type": "string",
  12381. "x-go-name": "ExternalTrackerURL"
  12382. }
  12383. },
  12384. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12385. },
  12386. "ExternalWiki": {
  12387. "description": "ExternalWiki represents setting for external wiki",
  12388. "type": "object",
  12389. "properties": {
  12390. "external_wiki_url": {
  12391. "description": "URL of external wiki.",
  12392. "type": "string",
  12393. "x-go-name": "ExternalWikiURL"
  12394. }
  12395. },
  12396. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12397. },
  12398. "FileCommitResponse": {
  12399. "type": "object",
  12400. "title": "FileCommitResponse contains information generated from a Git commit for a repo's file.",
  12401. "properties": {
  12402. "author": {
  12403. "$ref": "#/definitions/CommitUser"
  12404. },
  12405. "committer": {
  12406. "$ref": "#/definitions/CommitUser"
  12407. },
  12408. "html_url": {
  12409. "type": "string",
  12410. "x-go-name": "HTMLURL"
  12411. },
  12412. "message": {
  12413. "type": "string",
  12414. "x-go-name": "Message"
  12415. },
  12416. "parents": {
  12417. "type": "array",
  12418. "items": {
  12419. "$ref": "#/definitions/CommitMeta"
  12420. },
  12421. "x-go-name": "Parents"
  12422. },
  12423. "sha": {
  12424. "type": "string",
  12425. "x-go-name": "SHA"
  12426. },
  12427. "tree": {
  12428. "$ref": "#/definitions/CommitMeta"
  12429. },
  12430. "url": {
  12431. "type": "string",
  12432. "x-go-name": "URL"
  12433. }
  12434. },
  12435. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12436. },
  12437. "FileDeleteResponse": {
  12438. "description": "FileDeleteResponse contains information about a repo's file that was deleted",
  12439. "type": "object",
  12440. "properties": {
  12441. "commit": {
  12442. "$ref": "#/definitions/FileCommitResponse"
  12443. },
  12444. "content": {
  12445. "type": "object",
  12446. "x-go-name": "Content"
  12447. },
  12448. "verification": {
  12449. "$ref": "#/definitions/PayloadCommitVerification"
  12450. }
  12451. },
  12452. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12453. },
  12454. "FileLinksResponse": {
  12455. "description": "FileLinksResponse contains the links for a repo's file",
  12456. "type": "object",
  12457. "properties": {
  12458. "git": {
  12459. "type": "string",
  12460. "x-go-name": "GitURL"
  12461. },
  12462. "html": {
  12463. "type": "string",
  12464. "x-go-name": "HTMLURL"
  12465. },
  12466. "self": {
  12467. "type": "string",
  12468. "x-go-name": "Self"
  12469. }
  12470. },
  12471. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12472. },
  12473. "FileResponse": {
  12474. "description": "FileResponse contains information about a repo's file",
  12475. "type": "object",
  12476. "properties": {
  12477. "commit": {
  12478. "$ref": "#/definitions/FileCommitResponse"
  12479. },
  12480. "content": {
  12481. "$ref": "#/definitions/ContentsResponse"
  12482. },
  12483. "verification": {
  12484. "$ref": "#/definitions/PayloadCommitVerification"
  12485. }
  12486. },
  12487. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12488. },
  12489. "GPGKey": {
  12490. "description": "GPGKey a user GPG key to sign commit and tag in repository",
  12491. "type": "object",
  12492. "properties": {
  12493. "can_certify": {
  12494. "type": "boolean",
  12495. "x-go-name": "CanCertify"
  12496. },
  12497. "can_encrypt_comms": {
  12498. "type": "boolean",
  12499. "x-go-name": "CanEncryptComms"
  12500. },
  12501. "can_encrypt_storage": {
  12502. "type": "boolean",
  12503. "x-go-name": "CanEncryptStorage"
  12504. },
  12505. "can_sign": {
  12506. "type": "boolean",
  12507. "x-go-name": "CanSign"
  12508. },
  12509. "created_at": {
  12510. "type": "string",
  12511. "format": "date-time",
  12512. "x-go-name": "Created"
  12513. },
  12514. "emails": {
  12515. "type": "array",
  12516. "items": {
  12517. "$ref": "#/definitions/GPGKeyEmail"
  12518. },
  12519. "x-go-name": "Emails"
  12520. },
  12521. "expires_at": {
  12522. "type": "string",
  12523. "format": "date-time",
  12524. "x-go-name": "Expires"
  12525. },
  12526. "id": {
  12527. "type": "integer",
  12528. "format": "int64",
  12529. "x-go-name": "ID"
  12530. },
  12531. "key_id": {
  12532. "type": "string",
  12533. "x-go-name": "KeyID"
  12534. },
  12535. "primary_key_id": {
  12536. "type": "string",
  12537. "x-go-name": "PrimaryKeyID"
  12538. },
  12539. "public_key": {
  12540. "type": "string",
  12541. "x-go-name": "PublicKey"
  12542. },
  12543. "subkeys": {
  12544. "type": "array",
  12545. "items": {
  12546. "$ref": "#/definitions/GPGKey"
  12547. },
  12548. "x-go-name": "SubsKey"
  12549. }
  12550. },
  12551. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12552. },
  12553. "GPGKeyEmail": {
  12554. "description": "GPGKeyEmail an email attached to a GPGKey",
  12555. "type": "object",
  12556. "properties": {
  12557. "email": {
  12558. "type": "string",
  12559. "x-go-name": "Email"
  12560. },
  12561. "verified": {
  12562. "type": "boolean",
  12563. "x-go-name": "Verified"
  12564. }
  12565. },
  12566. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12567. },
  12568. "GitBlobResponse": {
  12569. "description": "GitBlobResponse represents a git blob",
  12570. "type": "object",
  12571. "properties": {
  12572. "content": {
  12573. "type": "string",
  12574. "x-go-name": "Content"
  12575. },
  12576. "encoding": {
  12577. "type": "string",
  12578. "x-go-name": "Encoding"
  12579. },
  12580. "sha": {
  12581. "type": "string",
  12582. "x-go-name": "SHA"
  12583. },
  12584. "size": {
  12585. "type": "integer",
  12586. "format": "int64",
  12587. "x-go-name": "Size"
  12588. },
  12589. "url": {
  12590. "type": "string",
  12591. "x-go-name": "URL"
  12592. }
  12593. },
  12594. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12595. },
  12596. "GitEntry": {
  12597. "description": "GitEntry represents a git tree",
  12598. "type": "object",
  12599. "properties": {
  12600. "mode": {
  12601. "type": "string",
  12602. "x-go-name": "Mode"
  12603. },
  12604. "path": {
  12605. "type": "string",
  12606. "x-go-name": "Path"
  12607. },
  12608. "sha": {
  12609. "type": "string",
  12610. "x-go-name": "SHA"
  12611. },
  12612. "size": {
  12613. "type": "integer",
  12614. "format": "int64",
  12615. "x-go-name": "Size"
  12616. },
  12617. "type": {
  12618. "type": "string",
  12619. "x-go-name": "Type"
  12620. },
  12621. "url": {
  12622. "type": "string",
  12623. "x-go-name": "URL"
  12624. }
  12625. },
  12626. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12627. },
  12628. "GitHook": {
  12629. "description": "GitHook represents a Git repository hook",
  12630. "type": "object",
  12631. "properties": {
  12632. "content": {
  12633. "type": "string",
  12634. "x-go-name": "Content"
  12635. },
  12636. "is_active": {
  12637. "type": "boolean",
  12638. "x-go-name": "IsActive"
  12639. },
  12640. "name": {
  12641. "type": "string",
  12642. "x-go-name": "Name"
  12643. }
  12644. },
  12645. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12646. },
  12647. "GitObject": {
  12648. "type": "object",
  12649. "title": "GitObject represents a Git object.",
  12650. "properties": {
  12651. "sha": {
  12652. "type": "string",
  12653. "x-go-name": "SHA"
  12654. },
  12655. "type": {
  12656. "type": "string",
  12657. "x-go-name": "Type"
  12658. },
  12659. "url": {
  12660. "type": "string",
  12661. "x-go-name": "URL"
  12662. }
  12663. },
  12664. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12665. },
  12666. "GitTreeResponse": {
  12667. "description": "GitTreeResponse returns a git tree",
  12668. "type": "object",
  12669. "properties": {
  12670. "page": {
  12671. "type": "integer",
  12672. "format": "int64",
  12673. "x-go-name": "Page"
  12674. },
  12675. "sha": {
  12676. "type": "string",
  12677. "x-go-name": "SHA"
  12678. },
  12679. "total_count": {
  12680. "type": "integer",
  12681. "format": "int64",
  12682. "x-go-name": "TotalCount"
  12683. },
  12684. "tree": {
  12685. "type": "array",
  12686. "items": {
  12687. "$ref": "#/definitions/GitEntry"
  12688. },
  12689. "x-go-name": "Entries"
  12690. },
  12691. "truncated": {
  12692. "type": "boolean",
  12693. "x-go-name": "Truncated"
  12694. },
  12695. "url": {
  12696. "type": "string",
  12697. "x-go-name": "URL"
  12698. }
  12699. },
  12700. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12701. },
  12702. "Hook": {
  12703. "description": "Hook a hook is a web hook when one repository changed",
  12704. "type": "object",
  12705. "properties": {
  12706. "active": {
  12707. "type": "boolean",
  12708. "x-go-name": "Active"
  12709. },
  12710. "config": {
  12711. "type": "object",
  12712. "additionalProperties": {
  12713. "type": "string"
  12714. },
  12715. "x-go-name": "Config"
  12716. },
  12717. "created_at": {
  12718. "type": "string",
  12719. "format": "date-time",
  12720. "x-go-name": "Created"
  12721. },
  12722. "events": {
  12723. "type": "array",
  12724. "items": {
  12725. "type": "string"
  12726. },
  12727. "x-go-name": "Events"
  12728. },
  12729. "id": {
  12730. "type": "integer",
  12731. "format": "int64",
  12732. "x-go-name": "ID"
  12733. },
  12734. "type": {
  12735. "type": "string",
  12736. "x-go-name": "Type"
  12737. },
  12738. "updated_at": {
  12739. "type": "string",
  12740. "format": "date-time",
  12741. "x-go-name": "Updated"
  12742. }
  12743. },
  12744. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12745. },
  12746. "Identity": {
  12747. "description": "Identity for a person's identity like an author or committer",
  12748. "type": "object",
  12749. "properties": {
  12750. "email": {
  12751. "type": "string",
  12752. "format": "email",
  12753. "x-go-name": "Email"
  12754. },
  12755. "name": {
  12756. "type": "string",
  12757. "x-go-name": "Name"
  12758. }
  12759. },
  12760. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12761. },
  12762. "InternalTracker": {
  12763. "description": "InternalTracker represents settings for internal tracker",
  12764. "type": "object",
  12765. "properties": {
  12766. "allow_only_contributors_to_track_time": {
  12767. "description": "Let only contributors track time (Built-in issue tracker)",
  12768. "type": "boolean",
  12769. "x-go-name": "AllowOnlyContributorsToTrackTime"
  12770. },
  12771. "enable_issue_dependencies": {
  12772. "description": "Enable dependencies for issues and pull requests (Built-in issue tracker)",
  12773. "type": "boolean",
  12774. "x-go-name": "EnableIssueDependencies"
  12775. },
  12776. "enable_time_tracker": {
  12777. "description": "Enable time tracking (Built-in issue tracker)",
  12778. "type": "boolean",
  12779. "x-go-name": "EnableTimeTracker"
  12780. }
  12781. },
  12782. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12783. },
  12784. "Issue": {
  12785. "description": "Issue represents an issue in a repository",
  12786. "type": "object",
  12787. "properties": {
  12788. "assignee": {
  12789. "$ref": "#/definitions/User"
  12790. },
  12791. "assignees": {
  12792. "type": "array",
  12793. "items": {
  12794. "$ref": "#/definitions/User"
  12795. },
  12796. "x-go-name": "Assignees"
  12797. },
  12798. "body": {
  12799. "type": "string",
  12800. "x-go-name": "Body"
  12801. },
  12802. "closed_at": {
  12803. "type": "string",
  12804. "format": "date-time",
  12805. "x-go-name": "Closed"
  12806. },
  12807. "comments": {
  12808. "type": "integer",
  12809. "format": "int64",
  12810. "x-go-name": "Comments"
  12811. },
  12812. "created_at": {
  12813. "type": "string",
  12814. "format": "date-time",
  12815. "x-go-name": "Created"
  12816. },
  12817. "due_date": {
  12818. "type": "string",
  12819. "format": "date-time",
  12820. "x-go-name": "Deadline"
  12821. },
  12822. "html_url": {
  12823. "type": "string",
  12824. "x-go-name": "HTMLURL"
  12825. },
  12826. "id": {
  12827. "type": "integer",
  12828. "format": "int64",
  12829. "x-go-name": "ID"
  12830. },
  12831. "labels": {
  12832. "type": "array",
  12833. "items": {
  12834. "$ref": "#/definitions/Label"
  12835. },
  12836. "x-go-name": "Labels"
  12837. },
  12838. "milestone": {
  12839. "$ref": "#/definitions/Milestone"
  12840. },
  12841. "number": {
  12842. "type": "integer",
  12843. "format": "int64",
  12844. "x-go-name": "Index"
  12845. },
  12846. "original_author": {
  12847. "type": "string",
  12848. "x-go-name": "OriginalAuthor"
  12849. },
  12850. "original_author_id": {
  12851. "type": "integer",
  12852. "format": "int64",
  12853. "x-go-name": "OriginalAuthorID"
  12854. },
  12855. "pull_request": {
  12856. "$ref": "#/definitions/PullRequestMeta"
  12857. },
  12858. "repository": {
  12859. "$ref": "#/definitions/RepositoryMeta"
  12860. },
  12861. "state": {
  12862. "$ref": "#/definitions/StateType"
  12863. },
  12864. "title": {
  12865. "type": "string",
  12866. "x-go-name": "Title"
  12867. },
  12868. "updated_at": {
  12869. "type": "string",
  12870. "format": "date-time",
  12871. "x-go-name": "Updated"
  12872. },
  12873. "url": {
  12874. "type": "string",
  12875. "x-go-name": "URL"
  12876. },
  12877. "user": {
  12878. "$ref": "#/definitions/User"
  12879. }
  12880. },
  12881. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12882. },
  12883. "IssueDeadline": {
  12884. "description": "IssueDeadline represents an issue deadline",
  12885. "type": "object",
  12886. "properties": {
  12887. "due_date": {
  12888. "type": "string",
  12889. "format": "date-time",
  12890. "x-go-name": "Deadline"
  12891. }
  12892. },
  12893. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12894. },
  12895. "IssueLabelsOption": {
  12896. "description": "IssueLabelsOption a collection of labels",
  12897. "type": "object",
  12898. "properties": {
  12899. "labels": {
  12900. "description": "list of label IDs",
  12901. "type": "array",
  12902. "items": {
  12903. "type": "integer",
  12904. "format": "int64"
  12905. },
  12906. "x-go-name": "Labels"
  12907. }
  12908. },
  12909. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12910. },
  12911. "Label": {
  12912. "description": "Label a label to an issue or a pr",
  12913. "type": "object",
  12914. "properties": {
  12915. "color": {
  12916. "type": "string",
  12917. "x-go-name": "Color",
  12918. "example": "00aabb"
  12919. },
  12920. "description": {
  12921. "type": "string",
  12922. "x-go-name": "Description"
  12923. },
  12924. "id": {
  12925. "type": "integer",
  12926. "format": "int64",
  12927. "x-go-name": "ID"
  12928. },
  12929. "name": {
  12930. "type": "string",
  12931. "x-go-name": "Name"
  12932. },
  12933. "url": {
  12934. "type": "string",
  12935. "x-go-name": "URL"
  12936. }
  12937. },
  12938. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12939. },
  12940. "MarkdownOption": {
  12941. "description": "MarkdownOption markdown options",
  12942. "type": "object",
  12943. "properties": {
  12944. "Context": {
  12945. "description": "Context to render\n\nin: body",
  12946. "type": "string"
  12947. },
  12948. "Mode": {
  12949. "description": "Mode to render\n\nin: body",
  12950. "type": "string"
  12951. },
  12952. "Text": {
  12953. "description": "Text markdown to render\n\nin: body",
  12954. "type": "string"
  12955. },
  12956. "Wiki": {
  12957. "description": "Is it a wiki page ?\n\nin: body",
  12958. "type": "boolean"
  12959. }
  12960. },
  12961. "x-go-package": "code.gitea.io/gitea/modules/structs"
  12962. },
  12963. "MergePullRequestOption": {
  12964. "description": "MergePullRequestForm form for merging Pull Request",
  12965. "type": "object",
  12966. "required": [
  12967. "Do"
  12968. ],
  12969. "properties": {
  12970. "Do": {
  12971. "type": "string",
  12972. "enum": [
  12973. "merge",
  12974. "rebase",
  12975. "rebase-merge",
  12976. "squash"
  12977. ]
  12978. },
  12979. "MergeMessageField": {
  12980. "type": "string"
  12981. },
  12982. "MergeTitleField": {
  12983. "type": "string"
  12984. },
  12985. "force_merge": {
  12986. "type": "boolean",
  12987. "x-go-name": "ForceMerge"
  12988. }
  12989. },
  12990. "x-go-name": "MergePullRequestForm",
  12991. "x-go-package": "code.gitea.io/gitea/modules/auth"
  12992. },
  12993. "MigrateRepoForm": {
  12994. "description": "MigrateRepoForm form for migrating repository",
  12995. "type": "object",
  12996. "required": [
  12997. "clone_addr",
  12998. "uid",
  12999. "repo_name"
  13000. ],
  13001. "properties": {
  13002. "auth_password": {
  13003. "type": "string",
  13004. "x-go-name": "AuthPassword"
  13005. },
  13006. "auth_username": {
  13007. "type": "string",
  13008. "x-go-name": "AuthUsername"
  13009. },
  13010. "clone_addr": {
  13011. "type": "string",
  13012. "x-go-name": "CloneAddr"
  13013. },
  13014. "description": {
  13015. "type": "string",
  13016. "x-go-name": "Description"
  13017. },
  13018. "issues": {
  13019. "type": "boolean",
  13020. "x-go-name": "Issues"
  13021. },
  13022. "labels": {
  13023. "type": "boolean",
  13024. "x-go-name": "Labels"
  13025. },
  13026. "milestones": {
  13027. "type": "boolean",
  13028. "x-go-name": "Milestones"
  13029. },
  13030. "mirror": {
  13031. "type": "boolean",
  13032. "x-go-name": "Mirror"
  13033. },
  13034. "private": {
  13035. "type": "boolean",
  13036. "x-go-name": "Private"
  13037. },
  13038. "pull_requests": {
  13039. "type": "boolean",
  13040. "x-go-name": "PullRequests"
  13041. },
  13042. "releases": {
  13043. "type": "boolean",
  13044. "x-go-name": "Releases"
  13045. },
  13046. "repo_name": {
  13047. "type": "string",
  13048. "x-go-name": "RepoName"
  13049. },
  13050. "uid": {
  13051. "type": "integer",
  13052. "format": "int64",
  13053. "x-go-name": "UID"
  13054. },
  13055. "wiki": {
  13056. "type": "boolean",
  13057. "x-go-name": "Wiki"
  13058. }
  13059. },
  13060. "x-go-package": "code.gitea.io/gitea/modules/auth"
  13061. },
  13062. "Milestone": {
  13063. "description": "Milestone milestone is a collection of issues on one repository",
  13064. "type": "object",
  13065. "properties": {
  13066. "closed_at": {
  13067. "type": "string",
  13068. "format": "date-time",
  13069. "x-go-name": "Closed"
  13070. },
  13071. "closed_issues": {
  13072. "type": "integer",
  13073. "format": "int64",
  13074. "x-go-name": "ClosedIssues"
  13075. },
  13076. "description": {
  13077. "type": "string",
  13078. "x-go-name": "Description"
  13079. },
  13080. "due_on": {
  13081. "type": "string",
  13082. "format": "date-time",
  13083. "x-go-name": "Deadline"
  13084. },
  13085. "id": {
  13086. "type": "integer",
  13087. "format": "int64",
  13088. "x-go-name": "ID"
  13089. },
  13090. "open_issues": {
  13091. "type": "integer",
  13092. "format": "int64",
  13093. "x-go-name": "OpenIssues"
  13094. },
  13095. "state": {
  13096. "$ref": "#/definitions/StateType"
  13097. },
  13098. "title": {
  13099. "type": "string",
  13100. "x-go-name": "Title"
  13101. }
  13102. },
  13103. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13104. },
  13105. "NotificationCount": {
  13106. "description": "NotificationCount number of unread notifications",
  13107. "type": "object",
  13108. "properties": {
  13109. "new": {
  13110. "type": "integer",
  13111. "format": "int64",
  13112. "x-go-name": "New"
  13113. }
  13114. },
  13115. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13116. },
  13117. "NotificationSubject": {
  13118. "description": "NotificationSubject contains the notification subject (Issue/Pull/Commit)",
  13119. "type": "object",
  13120. "properties": {
  13121. "latest_comment_url": {
  13122. "type": "string",
  13123. "x-go-name": "LatestCommentURL"
  13124. },
  13125. "title": {
  13126. "type": "string",
  13127. "x-go-name": "Title"
  13128. },
  13129. "type": {
  13130. "type": "string",
  13131. "x-go-name": "Type"
  13132. },
  13133. "url": {
  13134. "type": "string",
  13135. "x-go-name": "URL"
  13136. }
  13137. },
  13138. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13139. },
  13140. "NotificationThread": {
  13141. "description": "NotificationThread expose Notification on API",
  13142. "type": "object",
  13143. "properties": {
  13144. "id": {
  13145. "type": "integer",
  13146. "format": "int64",
  13147. "x-go-name": "ID"
  13148. },
  13149. "pinned": {
  13150. "type": "boolean",
  13151. "x-go-name": "Pinned"
  13152. },
  13153. "repository": {
  13154. "$ref": "#/definitions/Repository"
  13155. },
  13156. "subject": {
  13157. "$ref": "#/definitions/NotificationSubject"
  13158. },
  13159. "unread": {
  13160. "type": "boolean",
  13161. "x-go-name": "Unread"
  13162. },
  13163. "updated_at": {
  13164. "type": "string",
  13165. "format": "date-time",
  13166. "x-go-name": "UpdatedAt"
  13167. },
  13168. "url": {
  13169. "type": "string",
  13170. "x-go-name": "URL"
  13171. }
  13172. },
  13173. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13174. },
  13175. "OAuth2Application": {
  13176. "type": "object",
  13177. "title": "OAuth2Application represents an OAuth2 application.",
  13178. "properties": {
  13179. "client_id": {
  13180. "type": "string",
  13181. "x-go-name": "ClientID"
  13182. },
  13183. "client_secret": {
  13184. "type": "string",
  13185. "x-go-name": "ClientSecret"
  13186. },
  13187. "created": {
  13188. "type": "string",
  13189. "format": "date-time",
  13190. "x-go-name": "Created"
  13191. },
  13192. "id": {
  13193. "type": "integer",
  13194. "format": "int64",
  13195. "x-go-name": "ID"
  13196. },
  13197. "name": {
  13198. "type": "string",
  13199. "x-go-name": "Name"
  13200. },
  13201. "redirect_uris": {
  13202. "type": "array",
  13203. "items": {
  13204. "type": "string"
  13205. },
  13206. "x-go-name": "RedirectURIs"
  13207. }
  13208. },
  13209. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13210. },
  13211. "Organization": {
  13212. "description": "Organization represents an organization",
  13213. "type": "object",
  13214. "properties": {
  13215. "avatar_url": {
  13216. "type": "string",
  13217. "x-go-name": "AvatarURL"
  13218. },
  13219. "description": {
  13220. "type": "string",
  13221. "x-go-name": "Description"
  13222. },
  13223. "full_name": {
  13224. "type": "string",
  13225. "x-go-name": "FullName"
  13226. },
  13227. "id": {
  13228. "type": "integer",
  13229. "format": "int64",
  13230. "x-go-name": "ID"
  13231. },
  13232. "location": {
  13233. "type": "string",
  13234. "x-go-name": "Location"
  13235. },
  13236. "repo_admin_change_team_access": {
  13237. "type": "boolean",
  13238. "x-go-name": "RepoAdminChangeTeamAccess"
  13239. },
  13240. "username": {
  13241. "type": "string",
  13242. "x-go-name": "UserName"
  13243. },
  13244. "visibility": {
  13245. "type": "string",
  13246. "x-go-name": "Visibility"
  13247. },
  13248. "website": {
  13249. "type": "string",
  13250. "x-go-name": "Website"
  13251. }
  13252. },
  13253. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13254. },
  13255. "PRBranchInfo": {
  13256. "description": "PRBranchInfo information about a branch",
  13257. "type": "object",
  13258. "properties": {
  13259. "label": {
  13260. "type": "string",
  13261. "x-go-name": "Name"
  13262. },
  13263. "ref": {
  13264. "type": "string",
  13265. "x-go-name": "Ref"
  13266. },
  13267. "repo": {
  13268. "$ref": "#/definitions/Repository"
  13269. },
  13270. "repo_id": {
  13271. "type": "integer",
  13272. "format": "int64",
  13273. "x-go-name": "RepoID"
  13274. },
  13275. "sha": {
  13276. "type": "string",
  13277. "x-go-name": "Sha"
  13278. }
  13279. },
  13280. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13281. },
  13282. "PayloadCommit": {
  13283. "description": "PayloadCommit represents a commit",
  13284. "type": "object",
  13285. "properties": {
  13286. "added": {
  13287. "type": "array",
  13288. "items": {
  13289. "type": "string"
  13290. },
  13291. "x-go-name": "Added"
  13292. },
  13293. "author": {
  13294. "$ref": "#/definitions/PayloadUser"
  13295. },
  13296. "committer": {
  13297. "$ref": "#/definitions/PayloadUser"
  13298. },
  13299. "id": {
  13300. "description": "sha1 hash of the commit",
  13301. "type": "string",
  13302. "x-go-name": "ID"
  13303. },
  13304. "message": {
  13305. "type": "string",
  13306. "x-go-name": "Message"
  13307. },
  13308. "modified": {
  13309. "type": "array",
  13310. "items": {
  13311. "type": "string"
  13312. },
  13313. "x-go-name": "Modified"
  13314. },
  13315. "removed": {
  13316. "type": "array",
  13317. "items": {
  13318. "type": "string"
  13319. },
  13320. "x-go-name": "Removed"
  13321. },
  13322. "timestamp": {
  13323. "type": "string",
  13324. "format": "date-time",
  13325. "x-go-name": "Timestamp"
  13326. },
  13327. "url": {
  13328. "type": "string",
  13329. "x-go-name": "URL"
  13330. },
  13331. "verification": {
  13332. "$ref": "#/definitions/PayloadCommitVerification"
  13333. }
  13334. },
  13335. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13336. },
  13337. "PayloadCommitVerification": {
  13338. "description": "PayloadCommitVerification represents the GPG verification of a commit",
  13339. "type": "object",
  13340. "properties": {
  13341. "payload": {
  13342. "type": "string",
  13343. "x-go-name": "Payload"
  13344. },
  13345. "reason": {
  13346. "type": "string",
  13347. "x-go-name": "Reason"
  13348. },
  13349. "signature": {
  13350. "type": "string",
  13351. "x-go-name": "Signature"
  13352. },
  13353. "signer": {
  13354. "$ref": "#/definitions/PayloadUser"
  13355. },
  13356. "verified": {
  13357. "type": "boolean",
  13358. "x-go-name": "Verified"
  13359. }
  13360. },
  13361. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13362. },
  13363. "PayloadUser": {
  13364. "description": "PayloadUser represents the author or committer of a commit",
  13365. "type": "object",
  13366. "properties": {
  13367. "email": {
  13368. "type": "string",
  13369. "format": "email",
  13370. "x-go-name": "Email"
  13371. },
  13372. "name": {
  13373. "description": "Full name of the commit author",
  13374. "type": "string",
  13375. "x-go-name": "Name"
  13376. },
  13377. "username": {
  13378. "type": "string",
  13379. "x-go-name": "UserName"
  13380. }
  13381. },
  13382. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13383. },
  13384. "Permission": {
  13385. "description": "Permission represents a set of permissions",
  13386. "type": "object",
  13387. "properties": {
  13388. "admin": {
  13389. "type": "boolean",
  13390. "x-go-name": "Admin"
  13391. },
  13392. "pull": {
  13393. "type": "boolean",
  13394. "x-go-name": "Pull"
  13395. },
  13396. "push": {
  13397. "type": "boolean",
  13398. "x-go-name": "Push"
  13399. }
  13400. },
  13401. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13402. },
  13403. "PublicKey": {
  13404. "description": "PublicKey publickey is a user key to push code to repository",
  13405. "type": "object",
  13406. "properties": {
  13407. "created_at": {
  13408. "type": "string",
  13409. "format": "date-time",
  13410. "x-go-name": "Created"
  13411. },
  13412. "fingerprint": {
  13413. "type": "string",
  13414. "x-go-name": "Fingerprint"
  13415. },
  13416. "id": {
  13417. "type": "integer",
  13418. "format": "int64",
  13419. "x-go-name": "ID"
  13420. },
  13421. "key": {
  13422. "type": "string",
  13423. "x-go-name": "Key"
  13424. },
  13425. "key_type": {
  13426. "type": "string",
  13427. "x-go-name": "KeyType"
  13428. },
  13429. "read_only": {
  13430. "type": "boolean",
  13431. "x-go-name": "ReadOnly"
  13432. },
  13433. "title": {
  13434. "type": "string",
  13435. "x-go-name": "Title"
  13436. },
  13437. "url": {
  13438. "type": "string",
  13439. "x-go-name": "URL"
  13440. },
  13441. "user": {
  13442. "$ref": "#/definitions/User"
  13443. }
  13444. },
  13445. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13446. },
  13447. "PullRequest": {
  13448. "description": "PullRequest represents a pull request",
  13449. "type": "object",
  13450. "properties": {
  13451. "assignee": {
  13452. "$ref": "#/definitions/User"
  13453. },
  13454. "assignees": {
  13455. "type": "array",
  13456. "items": {
  13457. "$ref": "#/definitions/User"
  13458. },
  13459. "x-go-name": "Assignees"
  13460. },
  13461. "base": {
  13462. "$ref": "#/definitions/PRBranchInfo"
  13463. },
  13464. "body": {
  13465. "type": "string",
  13466. "x-go-name": "Body"
  13467. },
  13468. "closed_at": {
  13469. "type": "string",
  13470. "format": "date-time",
  13471. "x-go-name": "Closed"
  13472. },
  13473. "comments": {
  13474. "type": "integer",
  13475. "format": "int64",
  13476. "x-go-name": "Comments"
  13477. },
  13478. "created_at": {
  13479. "type": "string",
  13480. "format": "date-time",
  13481. "x-go-name": "Created"
  13482. },
  13483. "diff_url": {
  13484. "type": "string",
  13485. "x-go-name": "DiffURL"
  13486. },
  13487. "due_date": {
  13488. "type": "string",
  13489. "format": "date-time",
  13490. "x-go-name": "Deadline"
  13491. },
  13492. "head": {
  13493. "$ref": "#/definitions/PRBranchInfo"
  13494. },
  13495. "html_url": {
  13496. "type": "string",
  13497. "x-go-name": "HTMLURL"
  13498. },
  13499. "id": {
  13500. "type": "integer",
  13501. "format": "int64",
  13502. "x-go-name": "ID"
  13503. },
  13504. "labels": {
  13505. "type": "array",
  13506. "items": {
  13507. "$ref": "#/definitions/Label"
  13508. },
  13509. "x-go-name": "Labels"
  13510. },
  13511. "merge_base": {
  13512. "type": "string",
  13513. "x-go-name": "MergeBase"
  13514. },
  13515. "merge_commit_sha": {
  13516. "type": "string",
  13517. "x-go-name": "MergedCommitID"
  13518. },
  13519. "mergeable": {
  13520. "type": "boolean",
  13521. "x-go-name": "Mergeable"
  13522. },
  13523. "merged": {
  13524. "type": "boolean",
  13525. "x-go-name": "HasMerged"
  13526. },
  13527. "merged_at": {
  13528. "type": "string",
  13529. "format": "date-time",
  13530. "x-go-name": "Merged"
  13531. },
  13532. "merged_by": {
  13533. "$ref": "#/definitions/User"
  13534. },
  13535. "milestone": {
  13536. "$ref": "#/definitions/Milestone"
  13537. },
  13538. "number": {
  13539. "type": "integer",
  13540. "format": "int64",
  13541. "x-go-name": "Index"
  13542. },
  13543. "patch_url": {
  13544. "type": "string",
  13545. "x-go-name": "PatchURL"
  13546. },
  13547. "state": {
  13548. "$ref": "#/definitions/StateType"
  13549. },
  13550. "title": {
  13551. "type": "string",
  13552. "x-go-name": "Title"
  13553. },
  13554. "updated_at": {
  13555. "type": "string",
  13556. "format": "date-time",
  13557. "x-go-name": "Updated"
  13558. },
  13559. "url": {
  13560. "type": "string",
  13561. "x-go-name": "URL"
  13562. },
  13563. "user": {
  13564. "$ref": "#/definitions/User"
  13565. }
  13566. },
  13567. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13568. },
  13569. "PullRequestMeta": {
  13570. "description": "PullRequestMeta PR info if an issue is a PR",
  13571. "type": "object",
  13572. "properties": {
  13573. "merged": {
  13574. "type": "boolean",
  13575. "x-go-name": "HasMerged"
  13576. },
  13577. "merged_at": {
  13578. "type": "string",
  13579. "format": "date-time",
  13580. "x-go-name": "Merged"
  13581. }
  13582. },
  13583. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13584. },
  13585. "PullReview": {
  13586. "description": "PullReview represents a pull request review",
  13587. "type": "object",
  13588. "properties": {
  13589. "body": {
  13590. "type": "string",
  13591. "x-go-name": "Body"
  13592. },
  13593. "comments_count": {
  13594. "type": "integer",
  13595. "format": "int64",
  13596. "x-go-name": "CodeCommentsCount"
  13597. },
  13598. "commit_id": {
  13599. "type": "string",
  13600. "x-go-name": "CommitID"
  13601. },
  13602. "html_url": {
  13603. "type": "string",
  13604. "x-go-name": "HTMLURL"
  13605. },
  13606. "id": {
  13607. "type": "integer",
  13608. "format": "int64",
  13609. "x-go-name": "ID"
  13610. },
  13611. "official": {
  13612. "type": "boolean",
  13613. "x-go-name": "Official"
  13614. },
  13615. "pull_request_url": {
  13616. "type": "string",
  13617. "x-go-name": "HTMLPullURL"
  13618. },
  13619. "stale": {
  13620. "type": "boolean",
  13621. "x-go-name": "Stale"
  13622. },
  13623. "state": {
  13624. "$ref": "#/definitions/ReviewStateType"
  13625. },
  13626. "submitted_at": {
  13627. "type": "string",
  13628. "format": "date-time",
  13629. "x-go-name": "Submitted"
  13630. },
  13631. "user": {
  13632. "$ref": "#/definitions/User"
  13633. }
  13634. },
  13635. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13636. },
  13637. "PullReviewComment": {
  13638. "description": "PullReviewComment represents a comment on a pull request review",
  13639. "type": "object",
  13640. "properties": {
  13641. "body": {
  13642. "type": "string",
  13643. "x-go-name": "Body"
  13644. },
  13645. "commit_id": {
  13646. "type": "string",
  13647. "x-go-name": "CommitID"
  13648. },
  13649. "created_at": {
  13650. "type": "string",
  13651. "format": "date-time",
  13652. "x-go-name": "Created"
  13653. },
  13654. "diff_hunk": {
  13655. "type": "string",
  13656. "x-go-name": "DiffHunk"
  13657. },
  13658. "html_url": {
  13659. "type": "string",
  13660. "x-go-name": "HTMLURL"
  13661. },
  13662. "id": {
  13663. "type": "integer",
  13664. "format": "int64",
  13665. "x-go-name": "ID"
  13666. },
  13667. "original_commit_id": {
  13668. "type": "string",
  13669. "x-go-name": "OrigCommitID"
  13670. },
  13671. "original_position": {
  13672. "type": "integer",
  13673. "format": "uint64",
  13674. "x-go-name": "OldLineNum"
  13675. },
  13676. "path": {
  13677. "type": "string",
  13678. "x-go-name": "Path"
  13679. },
  13680. "position": {
  13681. "type": "integer",
  13682. "format": "uint64",
  13683. "x-go-name": "LineNum"
  13684. },
  13685. "pull_request_review_id": {
  13686. "type": "integer",
  13687. "format": "int64",
  13688. "x-go-name": "ReviewID"
  13689. },
  13690. "pull_request_url": {
  13691. "type": "string",
  13692. "x-go-name": "HTMLPullURL"
  13693. },
  13694. "updated_at": {
  13695. "type": "string",
  13696. "format": "date-time",
  13697. "x-go-name": "Updated"
  13698. },
  13699. "user": {
  13700. "$ref": "#/definitions/User"
  13701. }
  13702. },
  13703. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13704. },
  13705. "Reaction": {
  13706. "description": "Reaction contain one reaction",
  13707. "type": "object",
  13708. "properties": {
  13709. "content": {
  13710. "type": "string",
  13711. "x-go-name": "Reaction"
  13712. },
  13713. "created_at": {
  13714. "type": "string",
  13715. "format": "date-time",
  13716. "x-go-name": "Created"
  13717. },
  13718. "user": {
  13719. "$ref": "#/definitions/User"
  13720. }
  13721. },
  13722. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13723. },
  13724. "Reference": {
  13725. "type": "object",
  13726. "title": "Reference represents a Git reference.",
  13727. "properties": {
  13728. "object": {
  13729. "$ref": "#/definitions/GitObject"
  13730. },
  13731. "ref": {
  13732. "type": "string",
  13733. "x-go-name": "Ref"
  13734. },
  13735. "url": {
  13736. "type": "string",
  13737. "x-go-name": "URL"
  13738. }
  13739. },
  13740. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13741. },
  13742. "Release": {
  13743. "description": "Release represents a repository release",
  13744. "type": "object",
  13745. "properties": {
  13746. "assets": {
  13747. "type": "array",
  13748. "items": {
  13749. "$ref": "#/definitions/Attachment"
  13750. },
  13751. "x-go-name": "Attachments"
  13752. },
  13753. "author": {
  13754. "$ref": "#/definitions/User"
  13755. },
  13756. "body": {
  13757. "type": "string",
  13758. "x-go-name": "Note"
  13759. },
  13760. "created_at": {
  13761. "type": "string",
  13762. "format": "date-time",
  13763. "x-go-name": "CreatedAt"
  13764. },
  13765. "draft": {
  13766. "type": "boolean",
  13767. "x-go-name": "IsDraft"
  13768. },
  13769. "html_url": {
  13770. "type": "string",
  13771. "x-go-name": "HTMLURL"
  13772. },
  13773. "id": {
  13774. "type": "integer",
  13775. "format": "int64",
  13776. "x-go-name": "ID"
  13777. },
  13778. "name": {
  13779. "type": "string",
  13780. "x-go-name": "Title"
  13781. },
  13782. "prerelease": {
  13783. "type": "boolean",
  13784. "x-go-name": "IsPrerelease"
  13785. },
  13786. "published_at": {
  13787. "type": "string",
  13788. "format": "date-time",
  13789. "x-go-name": "PublishedAt"
  13790. },
  13791. "tag_name": {
  13792. "type": "string",
  13793. "x-go-name": "TagName"
  13794. },
  13795. "tarball_url": {
  13796. "type": "string",
  13797. "x-go-name": "TarURL"
  13798. },
  13799. "target_commitish": {
  13800. "type": "string",
  13801. "x-go-name": "Target"
  13802. },
  13803. "url": {
  13804. "type": "string",
  13805. "x-go-name": "URL"
  13806. },
  13807. "zipball_url": {
  13808. "type": "string",
  13809. "x-go-name": "ZipURL"
  13810. }
  13811. },
  13812. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13813. },
  13814. "RepoCommit": {
  13815. "type": "object",
  13816. "title": "RepoCommit contains information of a commit in the context of a repository.",
  13817. "properties": {
  13818. "author": {
  13819. "$ref": "#/definitions/CommitUser"
  13820. },
  13821. "committer": {
  13822. "$ref": "#/definitions/CommitUser"
  13823. },
  13824. "message": {
  13825. "type": "string",
  13826. "x-go-name": "Message"
  13827. },
  13828. "tree": {
  13829. "$ref": "#/definitions/CommitMeta"
  13830. },
  13831. "url": {
  13832. "type": "string",
  13833. "x-go-name": "URL"
  13834. }
  13835. },
  13836. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13837. },
  13838. "RepoTopicOptions": {
  13839. "description": "RepoTopicOptions a collection of repo topic names",
  13840. "type": "object",
  13841. "properties": {
  13842. "topics": {
  13843. "description": "list of topic names",
  13844. "type": "array",
  13845. "items": {
  13846. "type": "string"
  13847. },
  13848. "x-go-name": "Topics"
  13849. }
  13850. },
  13851. "x-go-package": "code.gitea.io/gitea/modules/structs"
  13852. },
  13853. "Repository": {
  13854. "description": "Repository represents a repository",
  13855. "type": "object",
  13856. "properties": {
  13857. "allow_merge_commits": {
  13858. "type": "boolean",
  13859. "x-go-name": "AllowMerge"
  13860. },
  13861. "allow_rebase": {
  13862. "type": "boolean",
  13863. "x-go-name": "AllowRebase"
  13864. },
  13865. "allow_rebase_explicit": {
  13866. "type": "boolean",
  13867. "x-go-name": "AllowRebaseMerge"
  13868. },
  13869. "allow_squash_merge": {
  13870. "type": "boolean",
  13871. "x-go-name": "AllowSquash"
  13872. },
  13873. "archived": {
  13874. "type": "boolean",
  13875. "x-go-name": "Archived"
  13876. },
  13877. "avatar_url": {
  13878. "type": "string",
  13879. "x-go-name": "AvatarURL"
  13880. },
  13881. "clone_url": {
  13882. "type": "string",
  13883. "x-go-name": "CloneURL"
  13884. },
  13885. "created_at": {
  13886. "type": "string",
  13887. "format": "date-time",
  13888. "x-go-name": "Created"
  13889. },
  13890. "default_branch": {
  13891. "type": "string",
  13892. "x-go-name": "DefaultBranch"
  13893. },
  13894. "description": {
  13895. "type": "string",
  13896. "x-go-name": "Description"
  13897. },
  13898. "empty": {
  13899. "type": "boolean",
  13900. "x-go-name": "Empty"
  13901. },
  13902. "external_tracker": {
  13903. "$ref": "#/definitions/ExternalTracker"
  13904. },
  13905. "external_wiki": {
  13906. "$ref": "#/definitions/ExternalWiki"
  13907. },
  13908. "fork": {
  13909. "type": "boolean",
  13910. "x-go-name": "Fork"
  13911. },
  13912. "forks_count": {
  13913. "type": "integer",
  13914. "format": "int64",
  13915. "x-go-name": "Forks"
  13916. },
  13917. "full_name": {
  13918. "type": "string",
  13919. "x-go-name": "FullName"
  13920. },
  13921. "has_issues": {
  13922. "type": "boolean",
  13923. "x-go-name": "HasIssues"
  13924. },
  13925. "has_pull_requests": {
  13926. "type": "boolean",
  13927. "x-go-name": "HasPullRequests"
  13928. },
  13929. "has_wiki": {
  13930. "type": "boolean",
  13931. "x-go-name": "HasWiki"
  13932. },
  13933. "html_url": {
  13934. "type": "string",
  13935. "x-go-name": "HTMLURL"
  13936. },
  13937. "id": {
  13938. "type": "integer",
  13939. "format": "int64",
  13940. "x-go-name": "ID"
  13941. },
  13942. "ignore_whitespace_conflicts": {
  13943. "type": "boolean",
  13944. "x-go-name": "IgnoreWhitespaceConflicts"
  13945. },
  13946. "internal_tracker": {
  13947. "$ref": "#/definitions/InternalTracker"
  13948. },
  13949. "mirror": {
  13950. "type": "boolean",
  13951. "x-go-name": "Mirror"
  13952. },
  13953. "name": {
  13954. "type": "string",
  13955. "x-go-name": "Name"
  13956. },
  13957. "open_issues_count": {
  13958. "type": "integer",
  13959. "format": "int64",
  13960. "x-go-name": "OpenIssues"
  13961. },
  13962. "open_pr_counter": {
  13963. "type": "integer",
  13964. "format": "int64",
  13965. "x-go-name": "OpenPulls"
  13966. },
  13967. "original_url": {
  13968. "type": "string",
  13969. "x-go-name": "OriginalURL"
  13970. },
  13971. "owner": {
  13972. "$ref": "#/definitions/User"
  13973. },
  13974. "parent": {
  13975. "$ref": "#/definitions/Repository"
  13976. },
  13977. "permissions": {
  13978. "$ref": "#/definitions/Permission"
  13979. },
  13980. "private": {
  13981. "type": "boolean",
  13982. "x-go-name": "Private"
  13983. },
  13984. "release_counter": {
  13985. "type": "integer",
  13986. "format": "int64",
  13987. "x-go-name": "Releases"
  13988. },
  13989. "size": {
  13990. "type": "integer",
  13991. "format": "int64",
  13992. "x-go-name": "Size"
  13993. },
  13994. "ssh_url": {
  13995. "type": "string",
  13996. "x-go-name": "SSHURL"
  13997. },
  13998. "stars_count": {
  13999. "type": "integer",
  14000. "format": "int64",
  14001. "x-go-name": "Stars"
  14002. },
  14003. "template": {
  14004. "type": "boolean",
  14005. "x-go-name": "Template"
  14006. },
  14007. "updated_at": {
  14008. "type": "string",
  14009. "format": "date-time",
  14010. "x-go-name": "Updated"
  14011. },
  14012. "watchers_count": {
  14013. "type": "integer",
  14014. "format": "int64",
  14015. "x-go-name": "Watchers"
  14016. },
  14017. "website": {
  14018. "type": "string",
  14019. "x-go-name": "Website"
  14020. }
  14021. },
  14022. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14023. },
  14024. "RepositoryMeta": {
  14025. "description": "RepositoryMeta basic repository information",
  14026. "type": "object",
  14027. "properties": {
  14028. "full_name": {
  14029. "type": "string",
  14030. "x-go-name": "FullName"
  14031. },
  14032. "id": {
  14033. "type": "integer",
  14034. "format": "int64",
  14035. "x-go-name": "ID"
  14036. },
  14037. "name": {
  14038. "type": "string",
  14039. "x-go-name": "Name"
  14040. },
  14041. "owner": {
  14042. "type": "string",
  14043. "x-go-name": "Owner"
  14044. }
  14045. },
  14046. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14047. },
  14048. "ReviewStateType": {
  14049. "description": "ReviewStateType review state type",
  14050. "type": "string",
  14051. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14052. },
  14053. "SearchResults": {
  14054. "description": "SearchResults results of a successful search",
  14055. "type": "object",
  14056. "properties": {
  14057. "data": {
  14058. "type": "array",
  14059. "items": {
  14060. "$ref": "#/definitions/Repository"
  14061. },
  14062. "x-go-name": "Data"
  14063. },
  14064. "ok": {
  14065. "type": "boolean",
  14066. "x-go-name": "OK"
  14067. }
  14068. },
  14069. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14070. },
  14071. "ServerVersion": {
  14072. "description": "ServerVersion wraps the version of the server",
  14073. "type": "object",
  14074. "properties": {
  14075. "version": {
  14076. "type": "string",
  14077. "x-go-name": "Version"
  14078. }
  14079. },
  14080. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14081. },
  14082. "StateType": {
  14083. "description": "StateType issue state type",
  14084. "type": "string",
  14085. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14086. },
  14087. "Status": {
  14088. "description": "Status holds a single Status of a single Commit",
  14089. "type": "object",
  14090. "properties": {
  14091. "context": {
  14092. "type": "string",
  14093. "x-go-name": "Context"
  14094. },
  14095. "created_at": {
  14096. "type": "string",
  14097. "format": "date-time",
  14098. "x-go-name": "Created"
  14099. },
  14100. "creator": {
  14101. "$ref": "#/definitions/User"
  14102. },
  14103. "description": {
  14104. "type": "string",
  14105. "x-go-name": "Description"
  14106. },
  14107. "id": {
  14108. "type": "integer",
  14109. "format": "int64",
  14110. "x-go-name": "ID"
  14111. },
  14112. "status": {
  14113. "$ref": "#/definitions/StatusState"
  14114. },
  14115. "target_url": {
  14116. "type": "string",
  14117. "x-go-name": "TargetURL"
  14118. },
  14119. "updated_at": {
  14120. "type": "string",
  14121. "format": "date-time",
  14122. "x-go-name": "Updated"
  14123. },
  14124. "url": {
  14125. "type": "string",
  14126. "x-go-name": "URL"
  14127. }
  14128. },
  14129. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14130. },
  14131. "StatusState": {
  14132. "description": "StatusState holds the state of a Status\nIt can be \"pending\", \"success\", \"error\", \"failure\", and \"warning\"",
  14133. "type": "string",
  14134. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14135. },
  14136. "StopWatch": {
  14137. "description": "StopWatch represent a running stopwatch",
  14138. "type": "object",
  14139. "properties": {
  14140. "created": {
  14141. "type": "string",
  14142. "format": "date-time",
  14143. "x-go-name": "Created"
  14144. },
  14145. "issue_index": {
  14146. "type": "integer",
  14147. "format": "int64",
  14148. "x-go-name": "IssueIndex"
  14149. }
  14150. },
  14151. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14152. },
  14153. "SubmitPullReviewOptions": {
  14154. "description": "SubmitPullReviewOptions are options to submit a pending pull review",
  14155. "type": "object",
  14156. "properties": {
  14157. "body": {
  14158. "type": "string",
  14159. "x-go-name": "Body"
  14160. },
  14161. "event": {
  14162. "$ref": "#/definitions/ReviewStateType"
  14163. }
  14164. },
  14165. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14166. },
  14167. "Tag": {
  14168. "description": "Tag represents a repository tag",
  14169. "type": "object",
  14170. "properties": {
  14171. "commit": {
  14172. "$ref": "#/definitions/CommitMeta"
  14173. },
  14174. "id": {
  14175. "type": "string",
  14176. "x-go-name": "ID"
  14177. },
  14178. "name": {
  14179. "type": "string",
  14180. "x-go-name": "Name"
  14181. },
  14182. "tarball_url": {
  14183. "type": "string",
  14184. "x-go-name": "TarballURL"
  14185. },
  14186. "zipball_url": {
  14187. "type": "string",
  14188. "x-go-name": "ZipballURL"
  14189. }
  14190. },
  14191. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14192. },
  14193. "Team": {
  14194. "description": "Team represents a team in an organization",
  14195. "type": "object",
  14196. "properties": {
  14197. "can_create_org_repo": {
  14198. "type": "boolean",
  14199. "x-go-name": "CanCreateOrgRepo"
  14200. },
  14201. "description": {
  14202. "type": "string",
  14203. "x-go-name": "Description"
  14204. },
  14205. "id": {
  14206. "type": "integer",
  14207. "format": "int64",
  14208. "x-go-name": "ID"
  14209. },
  14210. "includes_all_repositories": {
  14211. "type": "boolean",
  14212. "x-go-name": "IncludesAllRepositories"
  14213. },
  14214. "name": {
  14215. "type": "string",
  14216. "x-go-name": "Name"
  14217. },
  14218. "organization": {
  14219. "$ref": "#/definitions/Organization"
  14220. },
  14221. "permission": {
  14222. "type": "string",
  14223. "enum": [
  14224. "none",
  14225. "read",
  14226. "write",
  14227. "admin",
  14228. "owner"
  14229. ],
  14230. "x-go-name": "Permission"
  14231. },
  14232. "units": {
  14233. "type": "array",
  14234. "items": {
  14235. "type": "string"
  14236. },
  14237. "x-go-name": "Units",
  14238. "example": [
  14239. "repo.code",
  14240. "repo.issues",
  14241. "repo.ext_issues",
  14242. "repo.wiki",
  14243. "repo.pulls",
  14244. "repo.releases",
  14245. "repo.ext_wiki"
  14246. ]
  14247. }
  14248. },
  14249. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14250. },
  14251. "TimeStamp": {
  14252. "description": "TimeStamp defines a timestamp",
  14253. "type": "integer",
  14254. "format": "int64",
  14255. "x-go-package": "code.gitea.io/gitea/modules/timeutil"
  14256. },
  14257. "TopicName": {
  14258. "description": "TopicName a list of repo topic names",
  14259. "type": "object",
  14260. "properties": {
  14261. "topics": {
  14262. "type": "array",
  14263. "items": {
  14264. "type": "string"
  14265. },
  14266. "x-go-name": "TopicNames"
  14267. }
  14268. },
  14269. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14270. },
  14271. "TopicResponse": {
  14272. "description": "TopicResponse for returning topics",
  14273. "type": "object",
  14274. "properties": {
  14275. "created": {
  14276. "type": "string",
  14277. "format": "date-time",
  14278. "x-go-name": "Created"
  14279. },
  14280. "id": {
  14281. "type": "integer",
  14282. "format": "int64",
  14283. "x-go-name": "ID"
  14284. },
  14285. "repo_count": {
  14286. "type": "integer",
  14287. "format": "int64",
  14288. "x-go-name": "RepoCount"
  14289. },
  14290. "topic_name": {
  14291. "type": "string",
  14292. "x-go-name": "Name"
  14293. },
  14294. "updated": {
  14295. "type": "string",
  14296. "format": "date-time",
  14297. "x-go-name": "Updated"
  14298. }
  14299. },
  14300. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14301. },
  14302. "TrackedTime": {
  14303. "description": "TrackedTime worked time for an issue / pr",
  14304. "type": "object",
  14305. "properties": {
  14306. "created": {
  14307. "type": "string",
  14308. "format": "date-time",
  14309. "x-go-name": "Created"
  14310. },
  14311. "id": {
  14312. "type": "integer",
  14313. "format": "int64",
  14314. "x-go-name": "ID"
  14315. },
  14316. "issue": {
  14317. "$ref": "#/definitions/Issue"
  14318. },
  14319. "issue_id": {
  14320. "description": "deprecated (only for backwards compatibility)",
  14321. "type": "integer",
  14322. "format": "int64",
  14323. "x-go-name": "IssueID"
  14324. },
  14325. "time": {
  14326. "description": "Time in seconds",
  14327. "type": "integer",
  14328. "format": "int64",
  14329. "x-go-name": "Time"
  14330. },
  14331. "user_id": {
  14332. "description": "deprecated (only for backwards compatibility)",
  14333. "type": "integer",
  14334. "format": "int64",
  14335. "x-go-name": "UserID"
  14336. },
  14337. "user_name": {
  14338. "type": "string",
  14339. "x-go-name": "UserName"
  14340. }
  14341. },
  14342. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14343. },
  14344. "TransferRepoOption": {
  14345. "description": "TransferRepoOption options when transfer a repository's ownership",
  14346. "type": "object",
  14347. "required": [
  14348. "new_owner"
  14349. ],
  14350. "properties": {
  14351. "new_owner": {
  14352. "type": "string",
  14353. "x-go-name": "NewOwner"
  14354. },
  14355. "team_ids": {
  14356. "description": "ID of the team or teams to add to the repository. Teams can only be added to organization-owned repositories.",
  14357. "type": "array",
  14358. "items": {
  14359. "type": "integer",
  14360. "format": "int64"
  14361. },
  14362. "x-go-name": "TeamIDs"
  14363. }
  14364. },
  14365. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14366. },
  14367. "UpdateFileOptions": {
  14368. "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)",
  14369. "type": "object",
  14370. "required": [
  14371. "sha",
  14372. "content"
  14373. ],
  14374. "properties": {
  14375. "author": {
  14376. "$ref": "#/definitions/Identity"
  14377. },
  14378. "branch": {
  14379. "description": "branch (optional) to base this file from. if not given, the default branch is used",
  14380. "type": "string",
  14381. "x-go-name": "BranchName"
  14382. },
  14383. "committer": {
  14384. "$ref": "#/definitions/Identity"
  14385. },
  14386. "content": {
  14387. "description": "content must be base64 encoded",
  14388. "type": "string",
  14389. "x-go-name": "Content"
  14390. },
  14391. "dates": {
  14392. "$ref": "#/definitions/CommitDateOptions"
  14393. },
  14394. "from_path": {
  14395. "description": "from_path (optional) is the path of the original file which will be moved/renamed to the path in the URL",
  14396. "type": "string",
  14397. "x-go-name": "FromPath"
  14398. },
  14399. "message": {
  14400. "description": "message (optional) for the commit of this file. if not supplied, a default message will be used",
  14401. "type": "string",
  14402. "x-go-name": "Message"
  14403. },
  14404. "new_branch": {
  14405. "description": "new_branch (optional) will make a new branch from `branch` before creating the file",
  14406. "type": "string",
  14407. "x-go-name": "NewBranchName"
  14408. },
  14409. "sha": {
  14410. "description": "sha is the SHA for the file that already exists",
  14411. "type": "string",
  14412. "x-go-name": "SHA"
  14413. }
  14414. },
  14415. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14416. },
  14417. "User": {
  14418. "description": "User represents a user",
  14419. "type": "object",
  14420. "properties": {
  14421. "avatar_url": {
  14422. "description": "URL to the user's avatar",
  14423. "type": "string",
  14424. "x-go-name": "AvatarURL"
  14425. },
  14426. "created": {
  14427. "type": "string",
  14428. "format": "date-time",
  14429. "x-go-name": "Created"
  14430. },
  14431. "email": {
  14432. "type": "string",
  14433. "format": "email",
  14434. "x-go-name": "Email"
  14435. },
  14436. "full_name": {
  14437. "description": "the user's full name",
  14438. "type": "string",
  14439. "x-go-name": "FullName"
  14440. },
  14441. "id": {
  14442. "description": "the user's id",
  14443. "type": "integer",
  14444. "format": "int64",
  14445. "x-go-name": "ID"
  14446. },
  14447. "is_admin": {
  14448. "description": "Is the user an administrator",
  14449. "type": "boolean",
  14450. "x-go-name": "IsAdmin"
  14451. },
  14452. "language": {
  14453. "description": "User locale",
  14454. "type": "string",
  14455. "x-go-name": "Language"
  14456. },
  14457. "last_login": {
  14458. "type": "string",
  14459. "format": "date-time",
  14460. "x-go-name": "LastLogin"
  14461. },
  14462. "login": {
  14463. "description": "the user's username",
  14464. "type": "string",
  14465. "x-go-name": "UserName"
  14466. }
  14467. },
  14468. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14469. },
  14470. "UserHeatmapData": {
  14471. "description": "UserHeatmapData represents the data needed to create a heatmap",
  14472. "type": "object",
  14473. "properties": {
  14474. "contributions": {
  14475. "type": "integer",
  14476. "format": "int64",
  14477. "x-go-name": "Contributions"
  14478. },
  14479. "timestamp": {
  14480. "$ref": "#/definitions/TimeStamp"
  14481. }
  14482. },
  14483. "x-go-package": "code.gitea.io/gitea/models"
  14484. },
  14485. "WatchInfo": {
  14486. "description": "WatchInfo represents an API watch status of one repository",
  14487. "type": "object",
  14488. "properties": {
  14489. "created_at": {
  14490. "type": "string",
  14491. "format": "date-time",
  14492. "x-go-name": "CreatedAt"
  14493. },
  14494. "ignored": {
  14495. "type": "boolean",
  14496. "x-go-name": "Ignored"
  14497. },
  14498. "reason": {
  14499. "type": "object",
  14500. "x-go-name": "Reason"
  14501. },
  14502. "repository_url": {
  14503. "type": "string",
  14504. "x-go-name": "RepositoryURL"
  14505. },
  14506. "subscribed": {
  14507. "type": "boolean",
  14508. "x-go-name": "Subscribed"
  14509. },
  14510. "url": {
  14511. "type": "string",
  14512. "x-go-name": "URL"
  14513. }
  14514. },
  14515. "x-go-package": "code.gitea.io/gitea/modules/structs"
  14516. }
  14517. },
  14518. "responses": {
  14519. "AccessToken": {
  14520. "description": "AccessToken represents an API access token.",
  14521. "headers": {
  14522. "id": {
  14523. "type": "integer",
  14524. "format": "int64"
  14525. },
  14526. "name": {
  14527. "type": "string"
  14528. },
  14529. "sha1": {
  14530. "type": "string"
  14531. },
  14532. "token_last_eight": {
  14533. "type": "string"
  14534. }
  14535. }
  14536. },
  14537. "AccessTokenList": {
  14538. "description": "AccessTokenList represents a list of API access token.",
  14539. "schema": {
  14540. "type": "array",
  14541. "items": {
  14542. "$ref": "#/definitions/AccessToken"
  14543. }
  14544. }
  14545. },
  14546. "AnnotatedTag": {
  14547. "description": "AnnotatedTag",
  14548. "schema": {
  14549. "$ref": "#/definitions/AnnotatedTag"
  14550. }
  14551. },
  14552. "Attachment": {
  14553. "description": "Attachment",
  14554. "schema": {
  14555. "$ref": "#/definitions/Attachment"
  14556. }
  14557. },
  14558. "AttachmentList": {
  14559. "description": "AttachmentList",
  14560. "schema": {
  14561. "type": "array",
  14562. "items": {
  14563. "$ref": "#/definitions/Attachment"
  14564. }
  14565. }
  14566. },
  14567. "Branch": {
  14568. "description": "Branch",
  14569. "schema": {
  14570. "$ref": "#/definitions/Branch"
  14571. }
  14572. },
  14573. "BranchList": {
  14574. "description": "BranchList",
  14575. "schema": {
  14576. "type": "array",
  14577. "items": {
  14578. "$ref": "#/definitions/Branch"
  14579. }
  14580. }
  14581. },
  14582. "BranchProtection": {
  14583. "description": "BranchProtection",
  14584. "schema": {
  14585. "$ref": "#/definitions/BranchProtection"
  14586. }
  14587. },
  14588. "BranchProtectionList": {
  14589. "description": "BranchProtectionList",
  14590. "schema": {
  14591. "type": "array",
  14592. "items": {
  14593. "$ref": "#/definitions/BranchProtection"
  14594. }
  14595. }
  14596. },
  14597. "Comment": {
  14598. "description": "Comment",
  14599. "schema": {
  14600. "$ref": "#/definitions/Comment"
  14601. }
  14602. },
  14603. "CommentList": {
  14604. "description": "CommentList",
  14605. "schema": {
  14606. "type": "array",
  14607. "items": {
  14608. "$ref": "#/definitions/Comment"
  14609. }
  14610. }
  14611. },
  14612. "Commit": {
  14613. "description": "Commit",
  14614. "schema": {
  14615. "$ref": "#/definitions/Commit"
  14616. }
  14617. },
  14618. "CommitList": {
  14619. "description": "CommitList",
  14620. "schema": {
  14621. "type": "array",
  14622. "items": {
  14623. "$ref": "#/definitions/Commit"
  14624. }
  14625. },
  14626. "headers": {
  14627. "X-HasMore": {
  14628. "type": "boolean",
  14629. "description": "True if there is another page"
  14630. },
  14631. "X-Page": {
  14632. "type": "integer",
  14633. "format": "int64",
  14634. "description": "The current page"
  14635. },
  14636. "X-PageCount": {
  14637. "type": "integer",
  14638. "format": "int64",
  14639. "description": "Total number of pages"
  14640. },
  14641. "X-PerPage": {
  14642. "type": "integer",
  14643. "format": "int64",
  14644. "description": "Commits per page"
  14645. },
  14646. "X-Total": {
  14647. "type": "integer",
  14648. "format": "int64",
  14649. "description": "Total commit count"
  14650. }
  14651. }
  14652. },
  14653. "ContentsListResponse": {
  14654. "description": "ContentsListResponse",
  14655. "schema": {
  14656. "type": "array",
  14657. "items": {
  14658. "$ref": "#/definitions/ContentsResponse"
  14659. }
  14660. }
  14661. },
  14662. "ContentsResponse": {
  14663. "description": "ContentsResponse",
  14664. "schema": {
  14665. "$ref": "#/definitions/ContentsResponse"
  14666. }
  14667. },
  14668. "DeployKey": {
  14669. "description": "DeployKey",
  14670. "schema": {
  14671. "$ref": "#/definitions/DeployKey"
  14672. }
  14673. },
  14674. "DeployKeyList": {
  14675. "description": "DeployKeyList",
  14676. "schema": {
  14677. "type": "array",
  14678. "items": {
  14679. "$ref": "#/definitions/DeployKey"
  14680. }
  14681. }
  14682. },
  14683. "EmailList": {
  14684. "description": "EmailList",
  14685. "schema": {
  14686. "type": "array",
  14687. "items": {
  14688. "$ref": "#/definitions/Email"
  14689. }
  14690. }
  14691. },
  14692. "EmptyRepository": {
  14693. "description": "EmptyRepository",
  14694. "schema": {
  14695. "$ref": "#/definitions/APIError"
  14696. }
  14697. },
  14698. "FileDeleteResponse": {
  14699. "description": "FileDeleteResponse",
  14700. "schema": {
  14701. "$ref": "#/definitions/FileDeleteResponse"
  14702. }
  14703. },
  14704. "FileResponse": {
  14705. "description": "FileResponse",
  14706. "schema": {
  14707. "$ref": "#/definitions/FileResponse"
  14708. }
  14709. },
  14710. "GPGKey": {
  14711. "description": "GPGKey",
  14712. "schema": {
  14713. "$ref": "#/definitions/GPGKey"
  14714. }
  14715. },
  14716. "GPGKeyList": {
  14717. "description": "GPGKeyList",
  14718. "schema": {
  14719. "type": "array",
  14720. "items": {
  14721. "$ref": "#/definitions/GPGKey"
  14722. }
  14723. }
  14724. },
  14725. "GitBlobResponse": {
  14726. "description": "GitBlobResponse",
  14727. "schema": {
  14728. "$ref": "#/definitions/GitBlobResponse"
  14729. }
  14730. },
  14731. "GitHook": {
  14732. "description": "GitHook",
  14733. "schema": {
  14734. "$ref": "#/definitions/GitHook"
  14735. }
  14736. },
  14737. "GitHookList": {
  14738. "description": "GitHookList",
  14739. "schema": {
  14740. "type": "array",
  14741. "items": {
  14742. "$ref": "#/definitions/GitHook"
  14743. }
  14744. }
  14745. },
  14746. "GitTreeResponse": {
  14747. "description": "GitTreeResponse",
  14748. "schema": {
  14749. "$ref": "#/definitions/GitTreeResponse"
  14750. }
  14751. },
  14752. "Hook": {
  14753. "description": "Hook",
  14754. "schema": {
  14755. "$ref": "#/definitions/Hook"
  14756. }
  14757. },
  14758. "HookList": {
  14759. "description": "HookList",
  14760. "schema": {
  14761. "type": "array",
  14762. "items": {
  14763. "$ref": "#/definitions/Hook"
  14764. }
  14765. }
  14766. },
  14767. "Issue": {
  14768. "description": "Issue",
  14769. "schema": {
  14770. "$ref": "#/definitions/Issue"
  14771. }
  14772. },
  14773. "IssueDeadline": {
  14774. "description": "IssueDeadline",
  14775. "schema": {
  14776. "$ref": "#/definitions/IssueDeadline"
  14777. }
  14778. },
  14779. "IssueList": {
  14780. "description": "IssueList",
  14781. "schema": {
  14782. "type": "array",
  14783. "items": {
  14784. "$ref": "#/definitions/Issue"
  14785. }
  14786. }
  14787. },
  14788. "Label": {
  14789. "description": "Label",
  14790. "schema": {
  14791. "$ref": "#/definitions/Label"
  14792. }
  14793. },
  14794. "LabelList": {
  14795. "description": "LabelList",
  14796. "schema": {
  14797. "type": "array",
  14798. "items": {
  14799. "$ref": "#/definitions/Label"
  14800. }
  14801. }
  14802. },
  14803. "MarkdownRender": {
  14804. "description": "MarkdownRender is a rendered markdown document",
  14805. "schema": {
  14806. "type": "string"
  14807. }
  14808. },
  14809. "Milestone": {
  14810. "description": "Milestone",
  14811. "schema": {
  14812. "$ref": "#/definitions/Milestone"
  14813. }
  14814. },
  14815. "MilestoneList": {
  14816. "description": "MilestoneList",
  14817. "schema": {
  14818. "type": "array",
  14819. "items": {
  14820. "$ref": "#/definitions/Milestone"
  14821. }
  14822. }
  14823. },
  14824. "NotificationCount": {
  14825. "description": "Number of unread notifications",
  14826. "schema": {
  14827. "$ref": "#/definitions/NotificationCount"
  14828. }
  14829. },
  14830. "NotificationThread": {
  14831. "description": "NotificationThread",
  14832. "schema": {
  14833. "$ref": "#/definitions/NotificationThread"
  14834. }
  14835. },
  14836. "NotificationThreadList": {
  14837. "description": "NotificationThreadList",
  14838. "schema": {
  14839. "type": "array",
  14840. "items": {
  14841. "$ref": "#/definitions/NotificationThread"
  14842. }
  14843. }
  14844. },
  14845. "OAuth2Application": {
  14846. "description": "OAuth2Application",
  14847. "schema": {
  14848. "$ref": "#/definitions/OAuth2Application"
  14849. }
  14850. },
  14851. "OAuth2ApplicationList": {
  14852. "description": "OAuth2ApplicationList represents a list of OAuth2 applications.",
  14853. "schema": {
  14854. "type": "array",
  14855. "items": {
  14856. "$ref": "#/definitions/OAuth2Application"
  14857. }
  14858. }
  14859. },
  14860. "Organization": {
  14861. "description": "Organization",
  14862. "schema": {
  14863. "$ref": "#/definitions/Organization"
  14864. }
  14865. },
  14866. "OrganizationList": {
  14867. "description": "OrganizationList",
  14868. "schema": {
  14869. "type": "array",
  14870. "items": {
  14871. "$ref": "#/definitions/Organization"
  14872. }
  14873. }
  14874. },
  14875. "PublicKey": {
  14876. "description": "PublicKey",
  14877. "schema": {
  14878. "$ref": "#/definitions/PublicKey"
  14879. }
  14880. },
  14881. "PublicKeyList": {
  14882. "description": "PublicKeyList",
  14883. "schema": {
  14884. "type": "array",
  14885. "items": {
  14886. "$ref": "#/definitions/PublicKey"
  14887. }
  14888. }
  14889. },
  14890. "PullRequest": {
  14891. "description": "PullRequest",
  14892. "schema": {
  14893. "$ref": "#/definitions/PullRequest"
  14894. }
  14895. },
  14896. "PullRequestList": {
  14897. "description": "PullRequestList",
  14898. "schema": {
  14899. "type": "array",
  14900. "items": {
  14901. "$ref": "#/definitions/PullRequest"
  14902. }
  14903. }
  14904. },
  14905. "PullReview": {
  14906. "description": "PullReview",
  14907. "schema": {
  14908. "$ref": "#/definitions/PullReview"
  14909. }
  14910. },
  14911. "PullReviewComment": {
  14912. "description": "PullComment",
  14913. "schema": {
  14914. "$ref": "#/definitions/PullReviewComment"
  14915. }
  14916. },
  14917. "PullReviewCommentList": {
  14918. "description": "PullCommentList",
  14919. "schema": {
  14920. "type": "array",
  14921. "items": {
  14922. "$ref": "#/definitions/PullReviewComment"
  14923. }
  14924. }
  14925. },
  14926. "PullReviewList": {
  14927. "description": "PullReviewList",
  14928. "schema": {
  14929. "type": "array",
  14930. "items": {
  14931. "$ref": "#/definitions/PullReview"
  14932. }
  14933. }
  14934. },
  14935. "Reaction": {
  14936. "description": "Reaction",
  14937. "schema": {
  14938. "$ref": "#/definitions/Reaction"
  14939. }
  14940. },
  14941. "ReactionList": {
  14942. "description": "ReactionList",
  14943. "schema": {
  14944. "type": "array",
  14945. "items": {
  14946. "$ref": "#/definitions/Reaction"
  14947. }
  14948. }
  14949. },
  14950. "Reference": {
  14951. "description": "Reference",
  14952. "schema": {
  14953. "$ref": "#/definitions/Reference"
  14954. }
  14955. },
  14956. "ReferenceList": {
  14957. "description": "ReferenceList",
  14958. "schema": {
  14959. "type": "array",
  14960. "items": {
  14961. "$ref": "#/definitions/Reference"
  14962. }
  14963. }
  14964. },
  14965. "Release": {
  14966. "description": "Release",
  14967. "schema": {
  14968. "$ref": "#/definitions/Release"
  14969. }
  14970. },
  14971. "ReleaseList": {
  14972. "description": "ReleaseList",
  14973. "schema": {
  14974. "type": "array",
  14975. "items": {
  14976. "$ref": "#/definitions/Release"
  14977. }
  14978. }
  14979. },
  14980. "Repository": {
  14981. "description": "Repository",
  14982. "schema": {
  14983. "$ref": "#/definitions/Repository"
  14984. }
  14985. },
  14986. "RepositoryList": {
  14987. "description": "RepositoryList",
  14988. "schema": {
  14989. "type": "array",
  14990. "items": {
  14991. "$ref": "#/definitions/Repository"
  14992. }
  14993. }
  14994. },
  14995. "SearchResults": {
  14996. "description": "SearchResults",
  14997. "schema": {
  14998. "$ref": "#/definitions/SearchResults"
  14999. }
  15000. },
  15001. "ServerVersion": {
  15002. "description": "ServerVersion",
  15003. "schema": {
  15004. "$ref": "#/definitions/ServerVersion"
  15005. }
  15006. },
  15007. "Status": {
  15008. "description": "Status",
  15009. "schema": {
  15010. "$ref": "#/definitions/Status"
  15011. }
  15012. },
  15013. "StatusList": {
  15014. "description": "StatusList",
  15015. "schema": {
  15016. "type": "array",
  15017. "items": {
  15018. "$ref": "#/definitions/Status"
  15019. }
  15020. }
  15021. },
  15022. "StopWatch": {
  15023. "description": "StopWatch",
  15024. "schema": {
  15025. "$ref": "#/definitions/StopWatch"
  15026. }
  15027. },
  15028. "StopWatchList": {
  15029. "description": "StopWatchList",
  15030. "schema": {
  15031. "type": "array",
  15032. "items": {
  15033. "$ref": "#/definitions/StopWatch"
  15034. }
  15035. }
  15036. },
  15037. "Tag": {
  15038. "description": "Tag",
  15039. "schema": {
  15040. "$ref": "#/definitions/Tag"
  15041. }
  15042. },
  15043. "TagList": {
  15044. "description": "TagList",
  15045. "schema": {
  15046. "type": "array",
  15047. "items": {
  15048. "$ref": "#/definitions/Tag"
  15049. }
  15050. }
  15051. },
  15052. "Team": {
  15053. "description": "Team",
  15054. "schema": {
  15055. "$ref": "#/definitions/Team"
  15056. }
  15057. },
  15058. "TeamList": {
  15059. "description": "TeamList",
  15060. "schema": {
  15061. "type": "array",
  15062. "items": {
  15063. "$ref": "#/definitions/Team"
  15064. }
  15065. }
  15066. },
  15067. "TopicListResponse": {
  15068. "description": "TopicListResponse",
  15069. "schema": {
  15070. "type": "array",
  15071. "items": {
  15072. "$ref": "#/definitions/TopicResponse"
  15073. }
  15074. }
  15075. },
  15076. "TopicNames": {
  15077. "description": "TopicNames",
  15078. "schema": {
  15079. "$ref": "#/definitions/TopicName"
  15080. }
  15081. },
  15082. "TrackedTime": {
  15083. "description": "TrackedTime",
  15084. "schema": {
  15085. "$ref": "#/definitions/TrackedTime"
  15086. }
  15087. },
  15088. "TrackedTimeList": {
  15089. "description": "TrackedTimeList",
  15090. "schema": {
  15091. "type": "array",
  15092. "items": {
  15093. "$ref": "#/definitions/TrackedTime"
  15094. }
  15095. }
  15096. },
  15097. "User": {
  15098. "description": "User",
  15099. "schema": {
  15100. "$ref": "#/definitions/User"
  15101. }
  15102. },
  15103. "UserHeatmapData": {
  15104. "description": "UserHeatmapData",
  15105. "schema": {
  15106. "type": "array",
  15107. "items": {
  15108. "$ref": "#/definitions/UserHeatmapData"
  15109. }
  15110. }
  15111. },
  15112. "UserList": {
  15113. "description": "UserList",
  15114. "schema": {
  15115. "type": "array",
  15116. "items": {
  15117. "$ref": "#/definitions/User"
  15118. }
  15119. }
  15120. },
  15121. "WatchInfo": {
  15122. "description": "WatchInfo",
  15123. "schema": {
  15124. "$ref": "#/definitions/WatchInfo"
  15125. }
  15126. },
  15127. "empty": {
  15128. "description": "APIEmpty is an empty response"
  15129. },
  15130. "error": {
  15131. "description": "APIError is error format response",
  15132. "headers": {
  15133. "message": {
  15134. "type": "string"
  15135. },
  15136. "url": {
  15137. "type": "string"
  15138. }
  15139. }
  15140. },
  15141. "forbidden": {
  15142. "description": "APIForbiddenError is a forbidden error response",
  15143. "headers": {
  15144. "message": {
  15145. "type": "string"
  15146. },
  15147. "url": {
  15148. "type": "string"
  15149. }
  15150. }
  15151. },
  15152. "invalidTopicsError": {
  15153. "description": "APIInvalidTopicsError is error format response to invalid topics",
  15154. "headers": {
  15155. "invalidTopics": {
  15156. "type": "array",
  15157. "items": {
  15158. "type": "string"
  15159. }
  15160. },
  15161. "message": {
  15162. "type": "string"
  15163. }
  15164. }
  15165. },
  15166. "notFound": {
  15167. "description": "APINotFound is a not found empty response"
  15168. },
  15169. "parameterBodies": {
  15170. "description": "parameterBodies",
  15171. "schema": {
  15172. "$ref": "#/definitions/SubmitPullReviewOptions"
  15173. }
  15174. },
  15175. "redirect": {
  15176. "description": "APIRedirect is a redirect response"
  15177. },
  15178. "validationError": {
  15179. "description": "APIValidationError is error format response related to input validation",
  15180. "headers": {
  15181. "message": {
  15182. "type": "string"
  15183. },
  15184. "url": {
  15185. "type": "string"
  15186. }
  15187. }
  15188. }
  15189. },
  15190. "securityDefinitions": {
  15191. "AccessToken": {
  15192. "type": "apiKey",
  15193. "name": "access_token",
  15194. "in": "query"
  15195. },
  15196. "AuthorizationHeaderToken": {
  15197. "description": "API tokens must be prepended with \"token\" followed by a space.",
  15198. "type": "apiKey",
  15199. "name": "Authorization",
  15200. "in": "header"
  15201. },
  15202. "BasicAuth": {
  15203. "type": "basic"
  15204. },
  15205. "SudoHeader": {
  15206. "description": "Sudo API request as the user provided as the key. Admin privileges are required.",
  15207. "type": "apiKey",
  15208. "name": "Sudo",
  15209. "in": "header"
  15210. },
  15211. "SudoParam": {
  15212. "description": "Sudo API request as the user provided as the key. Admin privileges are required.",
  15213. "type": "apiKey",
  15214. "name": "sudo",
  15215. "in": "query"
  15216. },
  15217. "Token": {
  15218. "type": "apiKey",
  15219. "name": "token",
  15220. "in": "query"
  15221. }
  15222. },
  15223. "security": [
  15224. {
  15225. "BasicAuth": []
  15226. },
  15227. {
  15228. "Token": []
  15229. },
  15230. {
  15231. "AccessToken": []
  15232. },
  15233. {
  15234. "AuthorizationHeaderToken": []
  15235. },
  15236. {
  15237. "SudoParam": []
  15238. },
  15239. {
  15240. "SudoHeader": []
  15241. }
  15242. ]
  15243. }