FastAPI - Build your first API with Python's Fastest API Web Framework!

preview_player
Показать описание
API Development with FastAPI, SQLAlchemy, Alembic, PostgreSQL, Uvicorn and Docker. In this tutorial we take a first look at building an API with FastAPI building an API using FastAPI with Uvicorn (Get and Post Data),
SQLAlchemy + Alembic to manage migrations, PostgreSQL + PGAdmin all wrapped deployed in Docker/Docker-Compose.

00:00 Introduction
00:43 Overview of tutorial
02:22 Prerequisite installations

Part 1 (Optional)
04:00 - Downloading and setup repository walkthrough
Part 2
17:36 Docker PostgreSQL and PGAdmin docker configuration
Part 3
35:12 FastAPI building our models and API endpoints

Code Repository:

🐱‍🏍Would you like to SUPPORT US FURTHER so that we can make even more great content - Please consider joining our members community.

👍SUBSCRIBE to get more free tutorials, courses and code snippets!
Рекомендации по теме
Комментарии
Автор

17 mins in and I already know I found the most comprehensive video about this.

joshuamarcano
Автор

As a backend engineer, docker is most important and confusing for beginners. You made it look really easy!! Thank you!

shygrammer
Автор

I had to change the first line in the *'Dockerfile'* to: *FROM python:3.9*

...because it was trying to use *Python 3.11* and caused a build break with *'greenlet'* and the failure when the *c_app* tries to use 'psycopg2'. Hope this helps in case someone else has the same issue I had. It all worked after citing to use *Python 3.9*.

danswaney
Автор

Thank you for making this a more complete tutorial. I find it a little annoying when tutorials give you the basic information you can find on the documentation, but don't take it the step further to make it into an actual production-level app. There's a lack of truly "end-to-end" type tutorials.

vulnerablegrowth
Автор

You are a true saviour to junior devs trying to get through the python eco-system! You're my inspiration Zander!!

DhruvSharma-zupq
Автор

Great video! Very helpful overview and great explanations of the details. It's the most thorough (and practical) I've come across. Thanks!

anthonyjones
Автор

After your Django REST API tutorial, I was looking forward to this. Thank you so much <3

ahmedshahriarsakib
Автор

this tutorial is seriously underrated. Very useful information! Thanks

NvmThemHereIAm
Автор

Ha Ha!!! I had forgotten the env vars for pgadmin... I was going along and ran the 'up' command and it threw an error. Took me a hot second to realize I never added the environment variables for it. Funny enough... I had paused the video to troubleshoot it and work through everything, then sure enough... you hit the same error code. Kind of put a smile on my face.
Love the content!

skysaville
Автор

Excellent video! Making little mistakes is absolutely fantastic. The debugging process is so valuable!

brianoflondon
Автор

Thank you! You explain really calm and sequently 🙏

romabalance
Автор

Very very informative video, crystal clear and straight to the point, Thank your very much for your efforts, Keep the Fast API videos coming.

PrakashReddyK
Автор

For you M1 mac users that get a problem when trying to migrate your db with the "docker-compose run app alembic revision --autogenerate -m "New Migration", you can try what i found to work.

The error text: (psycopg2.OperationalError) SCRAM authentication requires libpq version 10 or above

So to fix that open the Dockerfile and change python version to 3.11 = FROM python:3.11
Then after RUN pip3 install --upgrade pip ..You add the following 2 lines:
RUN apt update -y && apt install -y build-essential libpq-dev
RUN pip3 install psycopg2-binary --no-binary psycopg2-binary

Hope this help!

nottobethatpersonbut
Автор

Absolutely brilliant tutorial. Few and far between to see architecture like this weaved together and used effectively. Well done!

che_coelho
Автор

That's great. Watched a lot of videos and that's what I needed.

zhangmingkai
Автор

Got an error related to greenlet on docker-compose build.

Fixed by changing greenlet version to 2.0.a2 on requirements.txt. Not sure it broke something but the docker-compose build command worked.

matheusc.manoel
Автор

Thank you !!
This is what I was looking for :)

rohitgautam
Автор

So much to learn. Thank you for making this video.

AnsumanSingh
Автор

Thanks a lot for this tutorial, this made my day :)

ChandaKumari-wzor
Автор

Thanks. Appreciate the video and end-to-end tutorial :-)

What could enhance this great video further, is before diving into the walk through in part 3 to set-up the main components and packages in a few slides and explain their purposes and how they interact. We get introduced to them on the fly and I found it hard to digest in one go. I guess one can rewatch this section a few times to get it but if you would make this little shortcut, I think it would bring this great video to GOLD standard :-)

Keep up the good work and valuable content!

al