Booking options
£82.99
£82.99
On-Demand course
5 hours 58 minutes
All levels
Take your REST APIs to a whole new level with this advanced Flask and Python course!
This Advanced REST API course takes your REST API development to a whole new level by familiarizing you with more of the Flask ecosystem. We start with a simple REST API and teach you everything you need to know about it. We introduce new features and technologies by baking them into this application so you can see how a professional REST API is developed. Every new feature is added to a fully working application and tested. We also help you understand more about how to build features incrementally so you can get them to your users quickly and minimize risk.
Remember, this is our most advanced course yet! You should have adequate programming experience with Python or another programming language. Some knowledge of how the web works will also be helpful.
You should have prior knowledge of how to install Python packages and how to run your Python applications. If you've used virtualenv or Pipenv before, that's excellent! Knowledge of how to use PyCharm for debugging is also a plus, although we cover using the debugger in the course!
The codes and supporting files for this course are available at: https://github.com/PacktPublishing/Advanced-REST-APIs-with-Flask-and-Python
Use Marshmallow for data serialization and deserialization
Send e-mails and user confirmations
Upload images, Database migrations
Easy ways to write documentation and test your API
Handle payments using Stripe
Third-party login using OAuth
Master software development, refactoring, debugging, and more!
Use the latest technologies and best practices.
This course is designed for software developers who want to add advanced functionality to REST APIs, backend developers interested in gaining knowledge of Flask and its ecosystem, and advanced developers of other programming languages who want to get up-to-speed quickly with advanced REST API development in Python
An exhaustive course packed with step-by-step instructions, working examples, and helpful advice. This course is divided into clear chunks so you can learn at your own pace and focus on your own area of interest
Integrate advanced functionality (such as image uploading, payments, or user confirmation e-mails) in your API * Improve operations in existing REST APIs with database migrations and extensive refactoring knowledge * Take your REST API development to a whole new level by getting familiar with more of the Flask ecosystem
https://github.com/packtpublishing/advanced-rest-apis-with-flask-and-python
Jose Salvatierra has been teaching online for over seven years, and he loves helping students learn to code and master software development. He founded Teclado to bring software development to everyone; his objective is for you to truly understand everything that goes on behind the scenes. Coding is extremely rewarding. As you learn, things start to click and make sense. You can join the dots of all the things that weren't quite clear before. Jose can help you with Python and JavaScript issues, particularly in web and backend development. He is experienced with programming libraries and frameworks such as Flask, React, React Native, and AngularJS. He has worked extensively with UNIX systems, MongoDB, PostgreSQL, and advanced system architecture design.
1. Introduction
1. Introduction to this section Introduction: Introduction to this section |
2. Our project and endpoints Introduction: Our project and endpoints |
3. Reviewing the beginner course code Introduction: Reviewing the beginner course code |
4. Simplifying our error handling Introduction: Simplifying our error handling |
5. Refactoring our resources Introduction: Refactoring our resources |
6. Should we have unique names? Introduction: Should we have unique names? |
7. Adding basic type hinting Introduction: Adding basic type hinting |
8. Adding custom JSON types Introduction: Adding custom JSON types |
9. Using the current class as a type hint Introduction: Using the current class as a type hint |
10. Using Black for code formatting Introduction: Using Black for code formatting |
11. Improving errors with constants Introduction: Improving errors with constants |
12. @classmethod across the board Introduction: @classmethod across the board |
13. Testing our API with Postman Introduction: Testing our API with Postman |
14. Conclusion of this section Introduction: Conclusion of this section |
2. Serialization with Marshmallow
1. Introduction to this section Serialization with Marshmallow: Introduction to this section |
2. Serialization with Marshmallow Serialization with Marshmallow: Serialization with Marshmallow |
3. Deserialization with Marshmallow Serialization with Marshmallow: Deserialization with Marshmallow |
4. Migrating from virtualenv to Pipenv Serialization with Marshmallow: Migrating from virtualenv to Pipenv |
5. Using vanilla Marshmallow with the API Serialization with Marshmallow: Using vanilla Marshmallow with the API |
6. Introduction to Flask-Marshmallow Serialization with Marshmallow: Introduction to Flask-Marshmallow |
7. Adding items to our REST API Serialization with Marshmallow: Adding items to our REST API |
8. Adding stores to our REST API Serialization with Marshmallow: Adding stores to our REST API |
9. Deduplicating error handling Serialization with Marshmallow: Deduplicating error handling |
10. Conclusion of this section Serialization with Marshmallow: Conclusion of this section |
3. E-mail confirmations
1. Introduction to this section E-mail confirmations: Introduction to this section |
2. Introduction to e-mail confirmation E-mail confirmations: Introduction to e-mail confirmation |
3. Adding an activated property E-mail confirmations: Adding an activated property |
4. Activating users manually E-mail confirmations: Activating users manually |
5. Telling users, they are active E-mail confirmations: Telling users, they are active |
6. Setting up Mailgun E-mail confirmations: Setting up Mailgun |
7. Sending e-mails with Mailgun (Part 1) E-mail confirmations: Sending e-mails with Mailgun (Part 1) |
8. Sending e-mails with Mailgun (Part 2) E-mail confirmations: Sending e-mails with Mailgun (Part 2) |
9. Creating our Mailgun library file E-mail confirmations: Creating our Mailgun library file |
10. Using .env files in Flask E-mail confirmations: Using .env files in Flask |
11. Adding more configuration to. Env E-mail confirmations: Adding more configuration to. Env |
12. Error handling in Mailgun E-mail confirmations: Error handling in Mailgun |
13. Conclusion of this section E-mail confirmations: Conclusion of this section |
4. Advanced e-mail confirmation
1. Introduction to this section Advanced e-mail confirmation: Introduction to this section |
2. Creating the Confirmation Model Advanced e-mail confirmation: Creating the Confirmation Model |
3. Changes in our User Model Advanced e-mail confirmation: Changes in our User Model |
4. Creating our Confirmation Resource Advanced e-mail confirmation: Creating our Confirmation Resource |
5. Updating our User Resource Advanced e-mail confirmation: Updating our User Resource |
6. Adding the last confirmation to the user schema Advanced e-mail confirmation: Adding the last confirmation to the user schema |
7. Fixing our app.py Advanced e-mail confirmation: Fixing our app.py |
8. Cross-resource dependencies are (generally) bad Advanced e-mail confirmation: Cross-resource dependencies are (generally) bad |
9. What are localisation and internationalisation? Advanced e-mail confirmation: What are localisation and internationalisation? |
10. Storing strings in config files Advanced e-mail confirmation: Storing strings in config files |
11. Creating a simple translation library Advanced e-mail confirmation: Creating a simple translation library |
12. Updating our resources to use translations Advanced e-mail confirmation: Updating our resources to use translations |
13. Adding a new language to our API Advanced e-mail confirmation: Adding a new language to our API |
14. What is Flask-Babel? Advanced e-mail confirmation: What is Flask-Babel? |
15. Common pitfalls and advice Advanced e-mail confirmation: Common pitfalls and advice |
16. Conclusion of this section Advanced e-mail confirmation: Conclusion of this section |
5. Postman documentation and tests
1. Introduction to this section Postman documentation and tests: Introduction to this section |
2. Collection and request descriptions Postman documentation and tests: Collection and request descriptions |
3. Recap of Postman environments Postman documentation and tests: Recap of Postman environments |
4. JavaScript tests in Postman Postman documentation and tests: JavaScript tests in Postman |
5. Running entire collections in Postman Postman documentation and tests: Running entire collections in Postman |
6. Adding example requests and responses Postman documentation and tests: Adding example requests and responses |
7. Previewing our Postman documentation Postman documentation and tests: Previewing our Postman documentation |
8. Publishing our documentation page Postman documentation and tests: Publishing our documentation page |
9. More options for publishing documentation Postman documentation and tests: More options for publishing documentation |
10. Conclusion of this section Postman documentation and tests: Conclusion of this section |
6. Image uploads
1. Introduction to this section Image uploads: Introduction to this section |
2. Installing Flask-Uploads Image uploads: Installing Flask-Uploads |
3. Config files in Flask Image uploads: Config files in Flask |
4. What are wsgi and Werkzeug? Image uploads: What are wsgi and Werkzeug? |
5. Creating our image helper library Image uploads: Creating our image helper library |
6. Creating our image schema Image uploads: Creating our image schema |
7. Creating our image upload resource Image uploads: Creating our image upload resource |
8. Trying out our image upload Image uploads: Trying out our image upload |
9. Retrieving and deleting images Image uploads: Retrieving and deleting images |
10. Another example: user avatars Image uploads: Another example: user avatars |
11. Adding the avatar resource Image uploads: Adding the avatar resource |
12. Conclusion of this section Image uploads: Conclusion of this section |
7. Database migrations
1. Introduction to this section Database migrations: Introduction to this section |
2. What's in our starter code? Database migrations: What's in our starter code? |
3. Connecting to our remote database Database migrations: Connecting to our remote database |
4. Initialising Flask-Migrate and Alembic Database migrations: Initialising Flask-Migrate and Alembic |
5. Creating our initial table structure Database migrations: Creating our initial table structure |
6. Our first database migration Database migrations: Our first database migration |
7. Checking the Alembic script (important!) Database migrations: Checking the Alembic script (important!) |
8. Adding a new column with migrations Database migrations: Adding a new column with migrations |
9. Problems that can happen while migrating Database migrations: Problems that can happen while migrating |
10. A word of caution! Database migrations: A word of caution! |
11. Defining a SQLAlchemy naming convention Database migrations: Defining a SQLAlchemy naming convention |
12. When should you read documentation? Database migrations: When should you read documentation? |
13. Conclusion of this section Database migrations: Conclusion of this section |
8. Third party login with OAuth
1. Introduction to this lecture Third party login with OAuth: Introduction to this lecture |
2. Introduction to OAuth 2.0 Third party login with OAuth: Introduction to OAuth 2.0 |
3. What's in our starter code? Third party login with OAuth: What's in our starter code? |
4. Creating a GitHub OAuth App Third party login with OAuth: Creating a GitHub OAuth App |
5. Flask-OAuthlib Third party login with OAuth: Flask-OAuthlib |
6. Setting up our GitHub client Third party login with OAuth: Setting up our GitHub client |
7. Our GithubLogin resource Third party login with OAuth: Our GithubLogin resource |
8. What is Flask's g? Third party login with OAuth: What is Flask's g? |
9. What is a tokengetter? Third party login with OAuth: What is a tokengetter? |
10. Finishing our GithubAuthorize resource Third party login with OAuth: Finishing our GithubAuthorize resource |
11. Adding some error handling Third party login with OAuth: Adding some error handling |
12. Setting user passwords Third party login with OAuth: Setting user passwords |
13. Using url_for with Flask-RESTful Third party login with OAuth: Using url_for with Flask-RESTful |
14. Conclusion of this section Third party login with OAuth: Conclusion of this section |
9. Payments with Stripe
1. Introduction to this section Payments with Stripe: Introduction to this section |
2. Setting up our Stripe account Payments with Stripe: Setting up our Stripe account |
3. What's in our starter code? Payments with Stripe: What's in our starter code? |
4. Where do users pay? Payments with Stripe: Where do users pay? |
5. After payment: receiving order data Payments with Stripe: After payment: receiving order data |
6. Creating our OrderModel Payments with Stripe: Creating our OrderModel |
7. Many-to-many relationships with SQLAlchemy Payments with Stripe: Many-to-many relationships with SQLAlchemy |
8. Using the Association Object in our Resource Payments with Stripe: Using the Association Object in our Resource |
9. Charging orders with Stripe Payments with Stripe: Charging orders with Stripe |
10. Calculating the amount and description Payments with Stripe: Calculating the amount and description |
11. Testing our OrderResource Payments with Stripe: Testing our OrderResource |
12. Creating a way to view existing orders Payments with Stripe: Creating a way to view existing orders |
13. When things go wrong: error handling in Stripe Payments with Stripe: When things go wrong: error handling in Stripe |
14. Security considerations in payments Payments with Stripe: Security considerations in payments |
15. Conclusion of this section Payments with Stripe: Conclusion of this section |
10. Bonus section
1. Conclusion of the course Bonus section: Conclusion of the course |