Complete API Tutorial (from design to implementation with OpenAPI)

preview_player
Показать описание
In this tutorial, we will learn how to design and implement a REST API using an API-first approach. That means we start from designing and documenting the API using the OpenAPI specification. Then we use the specification to auto-generate our microservices in any language we wish. I created chapters as well to help you find what you need!

0:00 Intro
0:22 High Level Plan
6:13 Specification Setup
7:40 Resource Definition
8:53 Request and Responses
10:01 List Products
12:02 Create Product
13:01 Read Update Delete Product
14:44 Pagination
16:59 Security
18:07 Code Generation
19:22 Customize Spring Boot
20:11 Customize Python Flask
21:11 Interactive Documentation
21:37 Conclusion

In the first section we create a high-level plan of the API while discussing the theory behind it. We cover operation paths, resource representations, HTTP methods (their idempotency and safety) and status codes.

Once the plan is created, we move to compiling the OpenAPI specification. The documentation is rendered automatically as we move along. We cover all CRUD operations to manage a sample Product catalog in an online store. We also deal with pagination and security (authentication and authorization).

Finally, we auto generate the code from the specification in multiple languages, like Java, Python, JavaScript and Go. Then we showcase how we can customize the auto generated code. We use two examples: Java Spring Boot and Python Flask.

Connect with me:

#softwaredevelopment #softwarearchitecture #restapi
Рекомендации по теме
Комментарии
Автор

Does your team use the Contract-First approach for APIs or you go Code-First?

MarcoLenzo
Автор

I wish all tutorials were this concise yet detailed. Thank you!

procrastipractice
Автор

swagger editor also has an official docker image if you want to run it isolated locally or your company network

animanaut
Автор

Thanks, Super video. Although at 18:07 problems started. In the end took your GIT code for python, various errors (with connexion, etc).. but after a few hours worked. :)

ttaylor
Автор

22 minutes well spent - great tutorial - thank you @MarcoLenzo, how about tutorial on keeping microservices in good health e.g. ELK for visibility of the problem and Notifications upon a problem, not sure if it could go under one tutorial, nevertheless thank you for this tutorial

danish
join shbcf.ru