Curso de FastAPI - Rest API com Python - Aula 04: Criar conta de usuário, Schemas e Criptografia

Want to learn more about our Complete Python Course? Click the link below to secure your spot in the next class: https://lp.hashtagtreinamentos.com/es... ----------------------------------------------------------------------- 📁 Files Used in Video: https://dlp.hashtagtreinamentos.com/p... 💻 Recommended video: FastAPI Course Playlist - Rest API with Python (Complete Backend)    • Curso de FastAPI - Rest API com Python (Ba...   ----------------------------------------------------------------------- If you prefer the video Text format: https://www.hashtagtreinamentos.com/c... ----------------------------------------------------------------------- TO HIRE HASHTAG FOR YOUR COMPANY: https://www.hashtagtreinamentos.com/t... ----------------------------------------------------------------------- 🚀 Let's move on to the fourth lesson of the FastAPI Course - Rest API with Python (Complete Backend)! In this lesson, we'll transform user registration into a secure, standardized, and professional system, essential for any modern and scalable application. You'll learn hands-on how to create registration routes using FastAPI, perform automatic data validation with Pydantic, and implement efficient database session management using SQLAlchemy, ensuring security and preventing connection leaks. We'll also cover the importance of password encryption to protect sensitive information, using the Passlib library with the bcrypt algorithm. I'll show you how to configure the environment with secure variables (.env) and apply best practices to return custom errors with HTTPException. Furthermore, you'll learn how to structure input data using schemas with Pydantic, ensure your API follows RESTful standards, and avoid common errors. 📌 Enjoying this comprehensive content on APIs with Python? Then subscribe to the channel, activate the bell, and like so you don't miss the next lessons! ----------------------------------------------------------------------- Hashtag Programming ► Subscribe to our channel: http://bit.ly/3c0LJQi ► Turn on notifications (click the bell)! ► Like our video! ----------------------------------------------------------------------- Social Media ► Blog: https://bit.ly/2MRUZs0 ► YouTube: http://bit.ly/3c0LJQi ► Instagram: https://bit.ly/3o6dw42 ► Facebook: http://bit.ly/3qGtaF2 Here in the videos on the Hashtag Programming channel, we teach several Python tips so you can develop in this programming language and create your own projects and automations! ----------------------------------------------------------------------- Class Content 00:00 Introduction 01:18 Creating authentication routes with FastAPI 04:10 How to verify users in the database with SQLAlchemy 05:00 Creating and managing database sessions 07:33 How to search for records in the database 09:27 Creating new users securely 12:10 Important precautions when creating users 14:04 Testing the account creation route in the FastAPI documentation 16:00 Best practices for session management 17:37 Understanding dependencies in FastAPI 19:12 Creating dependencies to manage sessions 20:40 Passing dependencies to routes with SQLAlchemy and FastAPI 22:53 How to use Yield to ensure session closure 25:30 Error handling: using Try-Finally in session management 28:25 Securely encrypting user passwords in FastAPI 29:55 Creating and using a Secret Key to protect the API 31:00 How to store security keys as environment variables 32:40 Implementing password encryption with Passlib and Bcrypt 35:55 Testing user registration with encrypted passwords 37:21 How to interpret the Bcrypt error message 38:40 API responses with HTTP codes 41:55 Customizing data input with schemas 43:20 Creating the User class with Pydantic 47:00 Defining API data and inputs from the Schema 49:08 Viewing and testing Schemas in the FastAPI documentation 51:00 Why standardizing parameters improves API quality 53:00 Advantages of using FastAPI to create APIs 54:10 Conclusion #python #hashtagprogramacao

FastAPI Course - Rest API with Python (Complete Backend) - Class 05: Creating Orders and Logging In
▶︎

FastAPI Course - Rest API with Python (Complete Backend) - Class 05: Creating Orders and Logging In

Curso Básico de Python - Aula 1 - Introdução ao Python
▶︎

Curso Básico de Python - Aula 1 - Introdução ao Python

Python Full Course 2026 🔴 | Coding, Projects & Interview Preparation
▶︎

Python Full Course 2026 🔴 | Coding, Projects & Interview Preparation

JavaScript Tutorial For Beginners | JavaScript Training | JavaScript Course | Intellipaat
▶︎

JavaScript Tutorial For Beginners | JavaScript Training | JavaScript Course | Intellipaat

Aprenda SQL do ZERO (jeito mais rápido possível) | Curso Básico – Parte 1
▶︎

Aprenda SQL do ZERO (jeito mais rápido possível) | Curso Básico – Parte 1

FastAPI Course - Rest API with Python - Class 06: Authentication, OAuth2 and JWT Tokens
▶︎

FastAPI Course - Rest API with Python - Class 06: Authentication, OAuth2 and JWT Tokens

React Tutorial For Beginners [ReactJS] | ReactJS Course | ReactJS For Beginners | Intellipaat
▶︎

React Tutorial For Beginners [ReactJS] | ReactJS Course | ReactJS For Beginners | Intellipaat

Jensen Huang: The Mindset That Built NVIDIA
▶︎

Jensen Huang: The Mindset That Built NVIDIA

ASP.NET Core Full Course For Beginners (.NET 10)
▶︎

ASP.NET Core Full Course For Beginners (.NET 10)

AI Bubble: ‘OpenAI will be dead by 2030’ | Ed Zitron
▶︎

AI Bubble: ‘OpenAI will be dead by 2030’ | Ed Zitron

PHP Full Course For Beginners | PHP Full Course | PHP Tutorial | Intellipaat
▶︎

PHP Full Course For Beginners | PHP Full Course | PHP Tutorial | Intellipaat

Data Analytics for Beginners | Data Analytics Training | Data Analytics Course | Intellipaat
▶︎

Data Analytics for Beginners | Data Analytics Training | Data Analytics Course | Intellipaat

Aprenda de vez o que é uma API com esse exemplo simples em Python
▶︎

Aprenda de vez o que é uma API com esse exemplo simples em Python

FastAPI Course - Rest API with Python - Class 07: Blocking Endpoints for Authenticated Users
▶︎

FastAPI Course - Rest API with Python - Class 07: Blocking Endpoints for Authenticated Users

Selenium - Automate Any Internet Task with Python
▶︎

Selenium - Automate Any Internet Task with Python

FastAPI Course - Rest API with Python - Class 03: Database, Models and Migrations
▶︎

FastAPI Course - Rest API with Python - Class 03: Database, Models and Migrations

Building an AI Dark Factory:  A Codebase That Writes Its Own Code, Live
▶︎

Building an AI Dark Factory: A Codebase That Writes Its Own Code, Live

You're Probably Building FASTAPI Apps WRONG (Clean Architecture)
▶︎

You're Probably Building FASTAPI Apps WRONG (Clean Architecture)

Python Course #01 - Become a Programmer
▶︎

Python Course #01 - Become a Programmer