FastAPI is different from Flask....Is it???
# Web Site Writing Basics # Fastapi # Pythonprogramming # Flask # Trending
In a simple way, Flask is a "tool." The REST API is a "data transmission format." 1.What is Flask? (The Tool) Flask is a web framework of the Python language. It's like a "device box" that makes it easier for you to build a website or a backyard system. You don't have to write all the server management code from the page center: Routing, User traffic, Connect Ability Database: Flask can do either a website with an HTML page or just through the data (API). 2.What is the REST API? (The Concept / Architecture) The REST API is an "architecture or rule" to communicate data between computers through the HTTP protocol, focusing on sending data in a standardized format (mostly JSON). Duty: Intermediary, let the App command a Server, or let Frontend talk to the Backend. Characteristics: Not focusing on the face (UI), but focusing on sending pure "information," such as username, product price, etc. 3. Difference Comparison Table Topic FlaskREST API Type Framework (Written Software) Architecture Style (Design Pattern) The driver page for the web to work, how to send data to other machines, understand what to see, the .py code file we run, the URL format and the JSON / XML relationship data, we use Flask to create the REST API as the result of writing Flask4. For example, imagine opening a restaurant.: Flask is "Kitchen and Chef": it is responsible for cooking, handling raw materials (manage the Logic in the back of the house). REST API is "Menu and Reception": It is an agreement that if the customer orders Menu A (Request), the chef will send out this dish in any form. Response: You do not choose between Flask or REST API, but usually you will "use Flask to create a REST API" (like using kitchen utensils to cook.





































































































