Get access to our entire course catalogue, with our new subscription: Dometrain Pro

From Zero to Hero: REST APIs in .NET

author
by Nick Chapsas

Build REST APIs the way billion-dollar companies do

When people say, "I want to build an API", nowadays, they almost always mean a REST API. RESTful APIs have been the dominant way of building APIs nowadays and for a good reason. Their properties make them scalable and robust for the modern world of distributed computing, and even though they are far from the only way of building APIs, they are the most popular by a wide margin. In this course, Nick will teach you how to build REST APIs based on his experience building them for millions of users in billion-dollar companies.

Curriculum

Welcome

1:22

What will you learn in this course?

2:05

Who is the course for and prerequisites

1:03

What is REST?

1:07

The 6 constraints of REST

5:32

Resource naming and routing

2:09

HTTP Verbs are meaningful

2:05

Using response codes to indicate status

2:26

Flexible response body options

0:59

Understanding Idempotency

1:40

Using hypermedia for connectedness

1:44

The different types of errors

1:28

Section recap

0:53

The system we will build an API for

2:17

Creating the projects

2:27

Defining the movie API contracts

3:28

Creating a temporary database

6:23

Creating the movies controller

1:03

Implementing movie creation

4:26

Introducing mapping

2:04

Keeping track of the endpoints

2:17

Implementing movie retrieval

4:35

Perfecting the movie creation endpoint

1:37

Implementing movie update

2:52

Implementing movie deletion

1:32

Why partial updates are not used

1:24

Section recap

0:36

Implementing slug-based retrieval

6:04

Moving to a real database

1:39

Adding the database infrastructure code

6:35

Removing the old in-memory database

8:17

Adding a business logic layer

4:20

Implementing validation

9:37

Cancellation token passing

5:08

Section recap

0:40

Authentication and Authorization in REST APIs

2:20

What is the JSON Web Token?

3:58

The token generation service

1:31

Implementing JWT Authorization

7:07

Limiting actions for an admin

3:39

Limiting actions for a trusted member

2:36

Section recap

0:38

The concept of movie ratings

0:49

Where should ratings live?

2:27

Preparing the database

0:56

Using the user id

3:21

Updating the existing functionality to support ratings

5:35

Rating a movie

8:03

Deleting a rating

2:44

Retrieving user ratings

4:29

Section recap

0:43

Filtering

8:07

Sorting

6:35

Pagination

9:19

HATEOAS

5:12

Basic versioning

5:06

Advanced versioning

5:56

What is Swagger?

3:58

Integrating versioning in Swagger

3:37

Integrating auth in Swagger

2:00

Extending Swagger documentation

2:28

Adding health checks

4:54

Implementing Response caching

5:22

Implementing Output caching

6:11

Implementing API-key based auth

4:19

Implementing multiple auth

4:34

Section recap

0:57

Why create an SDK?

1:13

Creating the SDK project and the client example

2:03

Introducing Refit

2:40

Retrieving movies

2:00

Using the HttpClientFactory

1:44

Adding authentication

1:41

Handling token generation and refreshing

4:34

Adding the remaining requests

2:23

Section recap

0:39

What are Minimal APIs?

1:49

Creating the new endpoint structure

2:31

Migrating movie retrieval

3:17

Migrating movie creation

3:08

Migrating movie listing

3:10

Migrating movie update

1:11

Migrating movie deletion

1:54

Migrating rating endpoints

0:37

Migrating Auth

1:25

Updating Swagger

3:42

Updating versioning

3:36

Updating output cache

1:03

Section recap

0:34

Course conclusion

0:23

Course Info

Level:
From Zero to Hero
Duration:
4h 41m
$99.99

Lifetime access

Buy Course
Dometrain Pro

Want access to all of our courses? Subscribe to Dometrain Pro!

More info

About the Author

author_img

Nick Chapsas

Nick Chapsas is a .NET & C# content creator, educator and a Microsoft MVP for Developer Technologies with years of experience in Software Engineering and Engineering Management.

He has worked for some of the biggest companies in the world, building systems that served millions of users and tens of thousands of requests per second.

Nick creates free content on YouTube and is the host of the Keep Coding Podcast.

More courses by Nick Chapsas