Skip to content

jason810496/iThome2023-FastAPI-Tutorial

 
 

Repository files navigation

iThome 2023 FastAPI Tutorial

鐵人賽文章列表
Author: Liu Zhe You(Jason)
LinkedIn : Jason Liu

Welcome to have any discussion with me about this tutorial 🙌

FastAPI : RestfulAPI 前後端分離的支柱

  • [Day01] FastAPI 推坑與框架的朋友們
    • FastAPI 優點
    • django / flask / FastAPI 大比拼
    • FastAPI 之於 其他 python 後端框架架,就像 typescript 之於 javascript(指的是語法層面)
    • 在各個 function 傳遞之間都會定義好 schema , 更容易 Debus ( Schema 設定好)
  • [Day02] FastAPI 起步: 環境安裝
    • venv
    • poetry
    • uvicorn
  • [Day03] FastAPI 設定與 Uvicorn 包裝
    • CROS
    • app.py 包裝
  • [Day04] FastAPI 基礎架構
    • app instance
    • router
    • swagger docs
    • typing
  • [Day05] Schema & Pydanic
    • Pydanic
    • FastAPI 中的 Schema
  • [Day06] Response model
  • [Day07] Example & Field
  • [Day08] 再談 Python Typing
  • [Day09] 再談 Schema 常見錯誤
  • [Day10] Dpendency 萬用刀
  • [Day11] 再談 Dpendency 常見錯誤
  • [Day12] 依據項目切分 Router
  • [Day13] 連接 DB
  • [Day14] 使用 SQLalchemy
  • [Day15] Model
  • [Day16] Schema 與 Model 差別
  • [Day17] 架構優化:將 CRUD 與 api endpoint 分離
  • [Day18] 架構優化:非同步存取 DB 與 .env
  • [Day19] 架構優化:透過 Depends 注入非同步 DB Session 到 CRUD
  • [Day20] OAuth2 實例:OAuth2 Login / Refresh JWT 機制
  • [Day21] OAuth2 實例:內建 OAuth2_schema
  • [Day22] OAuth2 實例:密碼驗證
  • [Day23] OAuth2 實例: JWT 驗證
  • [Day24] OAuth2 實例:需要 Authorize 的 router
  • [Day25] OAuth2 實例:User api & CRUD
  • [Day26] OAuth2 實例:Me api & CRUD
  • [Day27] 測試:pytest 入門與安裝
  • [Day28] 測試:pytest CRUD 與驗證
  • [Day29] 部署:使用 docker-compose 部署
  • [Day30] 總結:
  • [Day31] 延伸功能:使用 redis 作為 server cache (設定)
  • [Day32] 延伸功能:在 CRUD 查詢加上 cache
  • [Day33] 延伸功能:使用 decorator 重構 redis 架構
  • [Day34] 延伸功能:專案細節調整與部署

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages