Member-only story
Implementing FastAPI in 10 Minutes
Develop, test, and use your custom API
API (Application Programming Interface) is a connection between computer programs. In layman’s terms, we can think of API as a Python function where users can perform a task or get certain results when they “call an API”. A popular example would be likening API to a waiter, whereby you tell the waiter your order from a menu of choices, and the waiter will communicate that to the kitchen (a “system”) that prepares your order and the waiter will return your completed order to you.
APIs are valuable and can be monetized — and almost everything is an API now! If you want to know the weather forecast, the website interface calls a Weather API. If you want to know the shortest route from one location to another, the Google Maps website/mobile application calls the Google Directions Service API. You get the idea.
APIs can be implemented in Python using multiple frameworks, some of which include Django, Flask, or FastAPI. This article is a step-by-step guide on how to develop, test, and use your custom API using the FastAPI framework. You can skip the first two sections if you already have some knowledge of APIs.
Update: This article is part of a series. Check out other “in 10 Minutes” topics here!