課程簡介
介紹
- FastAPI vs Django vs Flask
- FastAPI 的功能和優勢概述
開始
- 安裝 FastAPI
- 使用 OpenAPI 定義架構
路徑和查詢參數
- 聲明路徑參數類型
- 解析和驗證數據
- 聲明必要和可選參數
- 轉換查詢參數類型
- 多個路徑和查詢參數
使用 Pydantic 模型聲明請求正文
- 創建數據模型
- 結合路徑、查詢和正文參數
- 聲明驗證和元數據
- 使用深度嵌套模型
- 定義示例數據
- 回應和額外模型
定義表單和檔
- 使用表單字段代替 JSON
- 創建文件參數
- 使用文件和表單參數
處理錯誤
- 使用 HTTPException
- 添加自定義標頭
- 安裝自定義異常處理程序
- 覆蓋默認異常處理程序
使用 Databases
- ORMs 和文件結構
- 創建 SQLAlchemy 部件
- 創建數據庫模型
- 創建 Pydantic 模型
- 執行 CRUD 操作
- 創建表格、依賴項和路徑操作
- 檢查和審查文件
- 與數據庫交互
安全和身份驗證
- 使用 Oauth2 和 OpenID connect
- 使用 OpenAPI 定義多種安全方案
- 使用 FastAPI 工具
部署
- 部署概念、階段和工具
- 使用 Gunicorn 和 Uvicorn
- 使用容器系統(Docker 和 Kubernetes)
故障排除
摘要和後續步驟
最低要求
- 了解API概念
- Python 編程經驗
觀眾
- 開發者
客戶評論 (4)
培訓師非常樂意回答我所做的所有問題
Caterina - Stamtech
Course - Developing APIs with Python and FastAPI
機器翻譯
We were able to quickly get hands on into code, which helped reinforce concepts learned in lecture slides
Keith - Procter & Gamble Polska Sp. z o.o.
Course - Developing APIs with Python and FastAPI
The structured way of the e2e traing. Exercises allow touch the code to prepare some basics api also lectures touch details to which we need pay special attenstion during developig the api
Piotr - Procter & Gamble Polska Sp. z o.o.
Course - Developing APIs with Python and FastAPI
Very good preparation and expertise of a trainer, perfect communication in English. The course was practical (exercises + sharing examples of use cases)