Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

freeCodeCamp

Python API Development - Comprehensive Course for Beginners

via freeCodeCamp

Overview

This course on Python API development aims to teach learners how to build a full-fledged API using FastAPI. By the end of the course, students will be able to design APIs, work with routes, perform serialization/deserialization, validate schemas, and understand models. Additionally, students will gain skills in SQL, testing with pytest, and setting up a CI/CD pipeline using GitHub actions. The course employs a hands-on approach with practical coding examples and demonstrations. It is designed for beginners who are interested in learning Python API development from scratch.

Syllabus

Intro.
Project Overview.
Mac Python Installation.
Mac VS Code install and setup.
Windows Python Installation.
Windows VS Code install and setup.
Python virtual Env Basics.
Virtual Env on windows.
Virtual Env on Mac.
Install dependencies w/ pip.
Starting FastAPI.
Path Operations.
Intro toman.
HTTP Requests.
Schema Validation with Pydantic.
CRUD Operations.
Storing in Array.
Creating.
Postman Collections & saving requests.
Retrieve One.
Path order Matters.
Changing response Status Codes.
Deleting.
Updating.
Automatic Documentation.
Python packages.
Database Intro.
Postgres Windows Install.
Postgres Mac Install.
Database Schema & Tables.
Managing Postgres with PgAdmin GUI.
Your first SQL Query.
Filter results with "where".
SQL Operators.
IN.
Pattern matching with LIKE.
Ordering Results.
LIMIT & OFFSET.
Modifying Data.
Setup App Database.
Connecting to database w/ Python.
Database CRUD.
ORM intro.
SQLALCHEMY setup.
Adding CreatedAt Column.
Get All.
Create.
Get by ID.
Delete.
Update.
Pydantic vs ORM Models.
Pydantic Models Deep Dive.
Response Model.
Creating Users Table.
User Registration Path Operation.
Hashing Passwords.
Refractor Hashing Logic.
Get User by ID.
FastAPI Routers.
Router Prefix.
Router Tags.
JWT Token Basics.
Login Process .
Creating Token.
OAuth2 PasswordRequestForm.
Verify user is Logged In.
Fixing Bugs.
Protecting Routes.
Test Expired Token.
Fetching User in Protected Routes.
Postman advanced Features.
SQL Relationship Basics.
Postgres Foreign Keys.
SQLAlchemy Foreign Keys.
Update Schema to include User.
Assigning Owner id when creating new.
Delete and Update only your own.
Only Retrieving Logged in User's.
Sqlalchemy Relationships.
Query Parameters.
Cleanup our main.py file.
Env Variables.
Vote/Like Theory.
Votes Table.
Votes Sqlalchemy.
Votes Route.
SQL Joins.
Joins in SqlAlchemy.
Get One with Joins.
What is a database migration tool.
Alembic Setup.
Disable SqlAlchemy create Engine.
What is CORS?.
Git PreReqs.
Git Install.
Github.
Heroku intro.
Create Heroku App.
Heroku procfile.
Adding a Postgres database.
Env Variables in Heroku.
Alembic migrations on Heroku Postgres instance.
Pushing changed to production.
Create an Ubuntu VM.
Update packages.
Install Python.
Install Postgres & setup password.
Postgres Config.
Create new user and setup python evironment.
Env Variables.
Alembic migrations on production database.
Gunicorn.
Creating a Systemd service.
NGINX.
Setting up Domain name.
SSL/HTTPS.
NGINX enable.
Firewall.
Pushing code changes to Production.
Dockerfile.
Docker Compose.
Postgres Container.
Bind Mounts.
Dockerhub.
Production vs Development.
Testing Intro.
Writing your first test.
The -s & -v flags.
Testing more functions.
Parametrize.
Testing Classes.
Fixtures.
Combining Fixtures + Parametrize.
Testing Exceptions.
FastAPI TestClient.
Pytest flags.
Test create user.
Setup testing database.
Create & destroy database after each test.
More Fixtures to handle database interaction.
Trailing slashes in path.
Fixture scope.
Test user fixture.
Test/validate token.
Conftest.py.
Testing.
CI/CD intro.
Github Actions.
Creating Jobs.
setup python/dependencies/pytest.
Env variables.
Github Secrets.
Testing database.
Building Docker images.
Deploy to heroku.
Failing tests in pipeline.
Deploy to Ubuntu.

Taught by

freeCodeCamp.org

Reviews

5.0 rating, based on 1 Class Central review

Start your review of Python API Development - Comprehensive Course for Beginners

  • I'm extremely satisfied with this course, It is a very complete course. Not only does it teache FastAPI, but also SQLAlchemy, Pydantic, Alembic, Pytest and Docker.
    Sanjeev have a great didactic!

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.