[{"data":1,"prerenderedAt":402},["ShallowReactive",2],{"project-19441195":3},{"id":4,"name":5,"line":6,"line_source":7,"title":8,"url":9,"domain":10,"maker":11,"posted_at":12,"year":13,"points":14,"comments":15,"rank_in_year":16,"shown_in_year":17,"top":18,"tier":19,"category":20,"subcategory":21,"format":22,"keywords":23,"reception":29,"sentiment":30,"stance_mix":31,"scored_comments":36,"aspects":37,"strip":43,"post_text":44,"what":45,"said":99,"maker_in_thread":188,"shape":196,"grid":200,"attempts":363,"same_week":364,"maker_shows":39,"maker_hidden":394,"reader_version":395,"card":396},"19441195","FastAPI","build Python APIs with Go-like speed and automatic UI docs","title","Show HN: FastAPI: build Python APIs with Go-like speed and automatic UI docs","https:\u002F\u002Ffastapi.tiangolo.com\u002F","fastapi.tiangolo.com","tiangolo",1553083305,2019,88,71,546,2195,25,"notable","languages","web framework","library",[24,25,26,27,28],"python api framework","openapi","type hints","pydantic","asgi","mixed",0.272,{"positive":32,"neutral":33,"mixed":34,"critical":35},13,7,0,4,24,{"idea":38,"docs":40},{"positive":39,"critical":39},3,{"positive":41,"critical":42},5,1,[34,39,39,42,42,34,34,34,34,39,41,41,42,34,41,39,41,39,34,39,41,34,34,34,34,34,34,41,41,39,34,41,41,41,42,34,41,34,34,41],null,{"problem":46,"audience":56,"pricing":44,"motivation":62,"time_to_build":44,"stack":71,"openness":96,"stage":97,"team_size":98},{"value":47,"source":48,"evidence":49},"Building Python web APIs with automatic validation, serialization and interactive docs","maker",[50,53],{"id":51,"by":11,"text":52},"19441201","FastAPI is a modern, fast (high-performance), web framework for building APIs with Python 3.6+. It is one of the fastest Python frameworks available, as measured by independent…",{"id":54,"by":11,"text":55},"19454706","To use Python type hints, and get automatic data validation, serialization, and documentation for your API (including interactive UI docs for your API). All that, even for deeply…",{"value":57,"source":58,"evidence":59},"Python developers building web APIs","inferred",[60,61],{"id":51,"by":11,"text":52},{"id":54,"by":11,"text":55},{"value":63,"source":48,"evidence":64},"Maker wanted type-hint based API tooling after years building APIs with Flask",[65,68],{"id":66,"by":11,"text":67},"19453409","About reinventing the wheel, let me copy my answer from Reddit: Good question. I ask the same questions myself every time. And I avoided creating FastAPI for a long time. I tried…",{"id":69,"by":11,"text":70},"19453720","Yeah, in fact, up to FastAPI, my main stack was based on Flask with several plug-ins, and I created several project generators with all that. FastAPI learned a lot from many of…",[72,76,85,90],{"value":73,"source":48,"evidence":74},"Python 3.6+",[75],{"id":51,"by":11,"text":52},{"value":77,"source":48,"evidence":78},"Starlette",[79,82],{"id":80,"by":11,"text":81},"19453577","Yes! Sort of... Most of FastAPI features come from Starlette AND Pydantic. In FastAPI you declare the parameters of your request (including deeply nested JSON bodies) as function…",{"id":83,"by":11,"text":84},"19453642","Yep, FastAPI is based on Starlette, heavily inspired by the (now \"deprecated\") APIStar. What it adds is automatic data validation, serialization, and documentation, with Python…",{"value":86,"source":48,"evidence":87},"Pydantic",[88,89],{"id":80,"by":11,"text":81},{"id":83,"by":11,"text":84},{"value":91,"source":48,"evidence":92},"Uvicorn",[93],{"id":94,"by":11,"text":95},"19455156","And Uvicorn, the server, is compatible with PyPy. So, you can run FastAPI with PyPy, if you need :)","open_source","launched","solo",{"praise":100,"objections":128,"requests":146,"questions":147,"alternatives":163},[101,117],{"value":102,"source":103,"evidence":104},"Documentation is clear and well done","commenter",[105,109,113],{"id":106,"by":107,"text":108},"19454923","zedpm","Great documentation! The extra level of detail like explaining the command for running the server is super helpful for less experienced users.",{"id":110,"by":111,"text":112},"19443387","darkwinx","It's looks great. I've been looking for something like this. I like the documentation. It's very clear.",{"id":114,"by":115,"text":116},"19441631","andres32a","Best completion I've ever seen and a breath of fresh air. Love it.",{"value":118,"source":103,"evidence":119},"Works well in practice and looks polished",[120,124],{"id":121,"by":122,"text":123},"19441265","mahesh_rm","Been using it, works great.",{"id":125,"by":126,"text":127},"19455465","timothycrosley","Glad to hear that :)! Honestly, what you've built looks super solid and polished. In many ways, it's what I wanted hug to be - it's really inspiring to see someone build that.",[129,139],{"value":130,"source":103,"evidence":131},"Go already offers equivalent validation and tooling",[132,136],{"id":133,"by":134,"text":135},"19454700","ilovecaching","Another way to get Go like speed is to use Go. Go has an excellent built in http web server, and unlike Python it comes standard with a bug reducing type system and an easy and…",{"id":137,"by":134,"text":138},"19454896","> Yeah, the advantage here over Go would be to have automatic data validation, serialization, and documentation, all based on standards: OpenAPI and JSON Schema. Including…",{"value":140,"source":103,"evidence":141},"Another framework adds maintenance burden versus Django or Flask",[142],{"id":143,"by":144,"text":145},"19452997","mlevental","honest,sincere question: i don't understand why people do this - build these frameworks. it's hundreds of independent labor hours and forgoes the key value prop of python (or…",[],[148],{"value":149,"source":103,"evidence":150},"How does it compare to Falcon, Molten, or Flask?",[151,155,159],{"id":152,"by":153,"text":154},"19454633","rmdashrfstar","Why should I use this instead of Falcon?",{"id":156,"by":157,"text":158},"19455003","qb","How does this compare to https:\u002F\u002Fmoltenframework.com\u002F? They both provide type hints and are inspired by API Star. Why should I use FastAPI over molten?",{"id":160,"by":161,"text":162},"19454472","wodenokoto","For someone who is a little lost when somebody just says \"API\" ... Is this like flask but without jinja-templating?",[164,170,174,178,182],{"value":77,"source":103,"evidence":165},[166],{"id":167,"by":168,"text":169},"19453283","m_ke","You should also check out starlette and other supporting projects that Tom Christie (of DRF fame) is working on right now. Both FastAPI and Responder are thin wrappers around…",{"value":171,"source":103,"evidence":172},"Molten",[173],{"id":156,"by":157,"text":158},{"value":175,"source":103,"evidence":176},"Flask",[177],{"id":160,"by":161,"text":162},{"value":179,"source":103,"evidence":180},"Falcon",[181],{"id":152,"by":153,"text":154},{"value":183,"source":48,"evidence":184},"Hug",[185],{"id":186,"by":11,"text":187},"19455020","Yep, and Hug was one of the first tools I saw with this style of declaring parameters with types in the functions, along with APIStar. Great job! And thanks. It helped inspiring…",{"comments":189,"answered":33,"key":190},31,[191,192,193],{"id":51,"text":52},{"id":80,"text":81},{"id":194,"text":195},"19455071","Yep, there are a couple of project generators, including Docker integration, Celery, a simple frontend, load balancer with HTTPS etc. In two flavors: * With PostgreSQL and…",{"commenters":197,"max_depth":198,"maker_replies":189,"first_comment_mins":42,"lifespan_hours":199},29,6,255,[201,203,207,208,212,213,215,217,218,222,224,226,229,231,234,237,239,240,242,244,247,250,253,257,259,261,263,264,266,268,271,272,274,279,282,284,286,288,290,294,297,300,303,307,309,311,313,315,320,322,324,326,328,329,332,333,334,336,338,340,342,343,346,349,350,352,354,355,357,359,361],[51,34,34,202,11,42],"project\u002Fpositive\u002Fidea",[204,34,39,205,206,34],"19453182","project\u002Fneutral\u002Fidea","franey",[80,34,34,205,11,42],[209,34,39,210,211,34],"19454498","project\u002Fneutral\u002Fdocs","gravypod",[194,34,34,210,11,42],[133,42,42,214,134,34],"project\u002Fcritical\u002Fidea",[216,42,34,202,11,42],"19454773",[137,42,42,214,134,34],[219,42,34,220,221,34],"19455034","commenter\u002Fneutral\u002Fnone","lapnitnelav",[223,42,34,220,134,34],"19455234",[225,42,34,205,11,42],"19455400",[227,42,34,220,228,34],"19455519","dr_wolf",[230,42,34,220,134,34],"19455565",[232,42,34,220,233,34],"19462594","haolez",[235,42,34,220,236,34],"19461302","tomchristie",[167,238,39,205,168,34],2,[83,238,34,205,11,42],[106,39,41,241,107,34],"maker\u002Fpositive\u002Fdocs",[243,39,41,241,115,34],"19454963",[245,39,34,246,11,42],"19455042","maker\u002Fpositive\u002Fnone",[248,39,41,241,249,34],"19471526","svenhof",[251,39,34,252,11,42],"19533493","maker\u002Fneutral\u002Fdocs",[254,35,42,255,256,34],"19454108","project\u002Fcritical\u002Fdocs","darrenf",[258,35,34,252,11,42],"19454324",[110,41,41,260,111,34],"project\u002Fpositive\u002Fdocs",[262,41,34,246,11,42],"19453678",[156,198,39,205,157,34],[265,198,34,202,11,42],"19455349",[267,198,41,246,157,34],"19455440",[269,198,34,270,11,42],"19455946","maker\u002Fneutral\u002Fnone",[160,33,39,205,161,34],[273,33,34,202,11,42],"19454855",[275,276,34,277,278,34],"19453269",8,"other\u002Fneutral\u002Fperformance","Thaxll",[280,276,39,205,281,34],"19453313","jniedrauer",[283,276,34,205,11,42],"19453784",[285,276,34,202,11,42],"19453514",[287,276,41,202,168,34],"19453674",[289,276,34,270,11,42],"19453791",[291,276,34,292,293,34],"19454564","other\u002Fneutral\u002Fnone","grumpopotamus",[295,276,34,296,11,42],"19455129","maker\u002Fneutral\u002Fperformance",[298,276,34,277,299,34],"19454607","linuxftw",[301,276,34,277,302,34],"19454795","j88439h84",[304,276,34,305,306,34],"19454947","commenter\u002Fneutral\u002Fperformance","jerf",[308,276,34,296,11,42],"19455147",[310,276,34,305,306,34],"19458729",[312,276,34,270,11,42],"19458771",[94,276,34,314,11,42],"project\u002Fpositive\u002Fperformance",[316,317,41,318,319,34],"19502503",9,"project\u002Fpositive\u002Fnone","Splendor",[321,317,34,246,11,42],"19521556",[114,323,41,260,115,34],10,[325,323,34,246,11,42],"19453978",[152,327,39,205,153,34],11,[54,327,34,202,11,42],[330,327,34,331,126,34],"19454835","other\u002Fneutral\u002Fidea",[186,327,34,202,11,42],[125,327,41,246,126,34],[335,327,34,246,11,42],"19456033",[337,327,41,246,236,34],"19460880",[121,339,41,318,122,34],12,[341,339,34,246,11,42],"19453979",[143,32,42,214,144,34],[344,32,34,220,345,34],"19453070","heavenlyblue",[347,32,34,220,348,34],"19453179","piquadrat",[69,32,34,270,11,42],[351,32,41,202,206,34],"19453280",[353,32,34,270,11,42],"19453671",[66,32,34,202,11,42],[356,32,34,220,299,34],"19454516",[358,32,34,205,11,42],"19455090",[360,32,41,202,236,34],"19461343",[362,32,34,246,11,42],"19461538",[],[365,370,375,380,384,389],{"id":366,"name":367,"points":368,"category":369},"19393279","2019",2690,"hardware",{"id":371,"name":372,"points":373,"category":374},"19408329","Hello Goodbye",510,"security_privacy",{"id":376,"name":377,"points":378,"category":379},"19386093","Stackroboflow",274,"ai",{"id":381,"name":382,"points":383,"category":20},"19427332","Drogon",189,{"id":385,"name":386,"points":387,"category":388},"19444960","RemoteHub",171,"learning_science",{"id":390,"name":391,"points":392,"category":393},"19443733","Songcraft",152,"creative",false,"v2",{"id":397,"name":5,"line":6,"ai":394,"cat":20,"year":13,"points":14,"comments":15,"rec":29,"s":398,"top":18,"kw":399,"maker":11,"domain":10,"tier":19,"attempts":34,"strip":400,"url":9,"mix":401,"praise":102,"objection":130,"sub":21},19441195,0.27,[24,25,26,27,28],"0331100003551053530350000005530555105005",[32,33,34,35],1794036575934]