Mô tả

Welcome to the advanced course on how to Build a Backend REST API using Python, Django (3.2), Django REST Framework (3.12), Docker, GitHub Actions, Postgres and Test Driven Development!

Whether you’re a freelance programmer, tech entrepreneur, or just starting out building backends - this course will help lay the foundation of your knowledge base and give you the tools to advance your skills with some of the most in-demand programming languages today.

APIs are the unsung heroes behind the technologies that we all love and use religiously.

One of the most critical components for any tech-based business is an API. So knowing how to create an API from start to finish is a vital skill to have as a developer. You cannot build a successful app without a backend REST API!

In this course I’ll show you how to build an advanced API that handles creating and updating user profiles, changing passwords, creating objects, uploading images, filtering and searching objects, and more.

The best way to learn anything is to do it. So the practical application of the course -- the project that you’ll build along side me -- is an API. A recipe API, to be specific.

You will learn how to build an advanced recipe API that allows you to upload and store some of your favourite recipes from photos and the web.

You’ll learn how to create objects i.e. recipes with titles, price points, cooking times, ingredients and tags like “comfort food”, “vegan” or “dessert”. Think of it as a virtual recipe box.

By the end of this course you will have built a fully functioning REST API that can handle:

  • User authentication

  • Creating objects

  • Filtering and sorting objects

  • Uploading and viewing images

You’ll also learn, in detail how to:

  • Setup a project with Docker and Docker-Compose

  • Configure GitHub Actions to automatically run linting and unit tests

  • Write unit tests using the Django Test Framework

  • Apply best practice principles including Test Driven Development  

  • Handle uploading media files with Django

  • Customize the Django admin

  • Configure a Postgres database

This course has one singular focus: To teach you how to create an advanced API from start to finish using best practice principles and Test Driven Development.

This course is NOT FOR YOU:

  • If you’re looking for a course to build an API, a front end, and deployment

  • If you’re looking to build 10 different apps in one course

  • If you want to learn lots of different technologies and approaches to app development in general

This is a hands-on course, with a bit of theory and lots of opportunities to test your knowledge.

The content is challenging but rewarding. Ready for it? Let’s dive in!

**PLEASE NOTE: You cannot run Docker on Windows 10 Home edition. This is because Windows 10 Pro or Enterprise is required in order to use Hyper-V which Docker uses for virtualization. To take this course you have two options. These are covered in Lecture 6, which is free to preview before purchasing the course.

Bạn sẽ học được gì

Yêu cầu

Nội dung khoá học

20 sections

Introduction

4 lectures
Technical requirements
01:08
API details & Upgrades
01:55
Course structure
01:53
Getting help
05:16

App Design

3 lectures
App overview
04:09
Technologies
02:28
Django project structure
01:02

Test Driven Development

2 lectures
What is Test Driven Development?
03:24
Test Driven Development Quiz
3 questions

System Setup

2 lectures
What to install
00:54
Setup confirmation [Follow Along]
01:35

Project Setup

12 lectures
New project overview
06:26
Create GitHub project [Follow Along]
05:27
Docker and Django
04:25
Define Python requirements [Follow Along]
03:46
Create project Dockerfile [Follow Along]
17:46
Create Docker Compose configuration [Follow Along]
04:03
Linting and Tests
03:04
Configure flake8 [Follow Along]
10:04
Create Django project [Follow Along]
02:39
Run project with Docker Compose [Follow Along]
01:58
Project setup overview
01:03
Quiz: Docker and Docker Compose
2 questions

Configure GitHub Actions

5 lectures
What is GitHub Actions
02:30
Configuring GitHub Actions
04:09
Create GitHub Actions config [Follow Along]
11:15
Test GitHub Actions [Follow Along]
06:49
Quiz: GitHub Actions configuration
3 questions

Test Driven Development with Django

7 lectures
Testing in Django
07:43
Write a test [Follow Along]
05:35
Write a test using TDD [Follow Along]
03:54
Mocking
04:23
Testing web requests
02:25
Common testing problems
03:53
Quiz: TDD with Django
2 questions

Configure Database

12 lectures
Database architecture overview
04:51
Add database service [Follow Along]
06:47
Database configuration with Django
08:13
Install PostgreSQL database adaptor [Follow Along]
05:29
Configure database in Django [Follow Along]
02:53
Fixing database race condition
04:46
Create core app [Follow Along]
02:05
Write tests for wait_for_db command [Follow Along]
19:45
Add wait_for_db command [Follow Along]
09:15
Database migrations
07:54
Update Docker Compose and CI/CD [Follow Along]
04:21
Summary
00:57

Create User Model

9 lectures
The Django user model
05:16
Design custom user model
02:08
Add user model tests [Follow Along]
07:01
Implement user model [Follow Along]
17:27
Normalize email addresses [Follow Along]
06:10
Require email input [Follow Along]
02:50
Add superuser support [Follow Along]
04:29
Test user model [Follow Along]
02:40
Summary of Create User Model
00:24

Setup Django Admin

5 lectures
Django admin overview
04:00
Write tests for listing users [Follow Along]
07:58
Make Django admin list users [Follow Along]
05:16
Support modifying users [Follow Along]
08:19
Support creating users [Follow Along]
05:15

API Documentation

7 lectures
Importance of API documentation
04:34
Auto docs with DRF
06:11
Quiz: Documentation
2 questions
Install drf-spectacular [Follow Along]
03:51
Configure URLs [Follow Along]
03:32
Test Swagger UI [Follow Along]
01:49
Summary
00:27

Build user API

12 lectures
User API design
02:03
Create user app [Follow Along]
02:13
Write tests for create user API [Follow Along]
14:03
Implement create user API [Follow Along]
13:47
Authentication
07:59
Quiz: Authentication
1 question
Write tests for token API [Follow Along]
07:11
Implement token API [Follow Along]
13:49
Write tests for manage user API [Follow Along]
10:11
Implement manage user API [Follow Along]
09:20
Review user API in browser [Follow Along]
07:00
Summary
00:53

Build recipe API

14 lectures
Recipe API design
01:54
APIView vs Viewsets
03:59
Write test for recipe model [Follow Along]
05:57
Implement recipe model [Follow Along]
09:13
Create recipe app [Follow Along]
01:30
Write tests for listing recipes [Follow Along]
16:26
Implement recipe listing API [Follow Along]
11:53
Write tests for recipe detail API [Follow Along]
04:03
Implement recipe detail API [Follow Along]
06:26
Write tests for creating recipes [Follow Along]
06:11
Implement create recipe API [Follow Along]
02:31
Add additional tests [Follow Along]
16:07
Review recipe API in browser [Follow Along]
08:34
Summary
00:25

Build tags API

15 lectures
Tags API design
01:27
Add tag model [Follow Along]
07:14
Write tests for listing tags [Follow Along]
14:01
Implement tag listing API [Follow Along]
07:28
Write tests for updating tags [Follow Along]
04:15
Implement update tag API [Follow Along]
01:45
Write tests for deleting tags [Follow Along]
02:38
Implement delete tag API [Follow Along]
01:12
Nested serializers
02:16
Write tests for creating tags [Follow Along]
11:40
Implement create tag feature [Follow Along]
07:36
Write tests for updating recipe tags [Follow Along]
09:56
Implement update recipe tags feature [Follow Along]
07:04
Review tags API in browser [Follow Along]
05:26
Summary
00:28

Build ingredients API

16 lectures
Ingredients API Design
02:20
Add ingredient model [Follow Along]
05:53
Write tests for listing ingredients [Follow Along]
12:51
Implement ingredient listing API [Follow Along]
06:32
Write tests for updating ingredients [Follow Along]
04:05
Implement update ingredient API [Follow Along]
01:31
Write tests for deleting ingredients [Follow Along]
03:16
Implement delete ingredient API [Follow Along]
00:50
Write tests for creating ingredients [Follow Along]
11:44
Implement create ingredients feature [Follow Along]
06:51
Write tests for updating recipe ingredients [Follow Along]
10:04
Implement update recipe ingredients feature [Follow Along]
02:29
Refactoring
01:27
Refactor recipe views [Follow Along]
05:21
Review ingredient API in browser [Follow Along]
05:12
Summary
00:36

Recipe image API

9 lectures
Recipe image API design
02:04
Add image handling dependencies [Follow Along]
02:54
Static files with Django and Docker
08:11
Configure project for static files [Follow Along]
08:50
Modify recipe model [Follow Along]
10:11
Write tests for uploading images [Follow Along]
12:30
Implement image API [Follow Along]
10:08
Review image uploading in browser [Follow Along]
05:27
Summary
00:24

Implement filtering

7 lectures
Filtering design
04:45
Add tests for filtering recipes [Follow Along]
09:54
Implement recipe filter feature [Follow Along]
12:22
Add tests for filtering tags and ingredients [Follow Along]
13:25
Implement tag and ingredient filtering [Follow Along]
05:38
Review filtering in browser [Follow Along]
07:30
Summary
00:26

Deployment

18 lectures
Deployment plan
03:28
Django deployment overview
11:37
Add uWSGI to project [Follow Along]
09:14
Create proxy configs [Follow Along]
11:52
Create proxy Dockerfile [Follow Along]
09:18
Handling configuration
01:41
Create docker compose config [Follow Along]
08:38
Update Django settings [Follow Along]
08:59
Creating a virtual server
03:16
Create AWS account and user [Follow Along]
04:56
Upload SSH Key to AWS [Follow Along]
04:29
Create EC2 instance [Follow Along]
04:57
Setup GitHub deploy key [Follow Along]
02:21
Install Docker, Compose and Git [Follow Along]
03:14
Clone and configure project [Follow Along]
03:19
Run service [Follow Along]
02:50
Updating service [Follow Along]
08:33
Deployment summary
00:38

Summary

1 lectures
Course overview
00:50

Upgrades

1 lectures
Upgrading to Django 4 [Follow Along]
04:12

Đánh giá của học viên

Chưa có đánh giá
Course Rating
5
0%
4
0%
3
0%
2
0%
1
0%

Bình luận khách hàng

Viết Bình Luận

Bạn đánh giá khoá học này thế nào?

image

Đăng ký get khoá học Udemy - Unica - Gitiho giá chỉ 50k!

Get khoá học giá rẻ ngay trước khi bị fix.