# fastapi
![FastAPI 中如何发送 get、post 请求?图文教程](https://apifox.com/apiskills/content/images/2024/06/how-to-send-get-and-post-in-fastapi.png)
FastAPI 中如何发送 get、post 请求?图文教程
本文介绍了如何在 FastAPI 中发送 GET 和 POST 请求,帮助你快速掌握基本操作及高级应用。首先,安装 FastAPI 和 Uvicorn,然后编写和运行一个简单的 FastAPI 应用。
![FastAPI 中使用 gRPC](https://apifox.com/apiskills/content/images/2023/12/01-FastAPI-gRPC.png)
FastAPI 中使用 gRPC
FastAPI 是一个现代、快速(高性能)的 web 框架,用于构建 API,基于标准 Python 类型提示。FastAPI 不是直接支持 gRPC 的,gRPC (Google Remote Procedure Call)是一个由 Google 开发的高性能、开源和通用 RPC 框架,用于在微服务架构中进行服务间的通信。
![FastAPI 中怎么进行鉴权?在 FastAPI 中鉴权的方法](https://apifox.com/apiskills/content/images/2023/09/fastapi-authentication.png)
FastAPI 中怎么进行鉴权?在 FastAPI 中鉴权的方法
FastAPI 提供了多种灵活的鉴权方法,使你能够选择最适合你的应用程序需求的方式。从基本 HTTP 认证到 OAuth2.0 和自定义鉴权中间件,FastAPI 为构建安全的 Web 应用程序提供了强大的工具和支持。
![FastAPI 中的 depends 怎么使用?FastAPI 中 depends 的使用方法](https://apifox.com/apiskills/content/images/2023/09/fastapi-depends.png)
FastAPI 中的 depends 怎么使用?FastAPI 中 depends 的使用方法
在 FastAPI 中,depends是一个关键的功能,用于声明和注入依赖项(dependencies)到路由处理函数中,以便处理函数可以使用这些依赖项来获取数据、执行验证、进行身份认证等操作。
![FastAPI 中怎么设置定时任务?FastAPI 中设置定时任务的方法](https://apifox.com/apiskills/content/images/2023/09/fastapi-time.png)
FastAPI 中怎么设置定时任务?FastAPI 中设置定时任务的方法
在 FastAPI 中设置定时任务,可以使用 APScheduler、celery 或者 asyncio 等模块。APScheduler 使用简单,asyncio 适合与 FastAPI 的异步特性。
![FastAPI 中怎么设置超时时间?FastAPI 中设置超时时间的几种方法](https://apifox.com/apiskills/content/images/2023/09/fastapi-timeout-index.png)
FastAPI 中怎么设置超时时间?FastAPI 中设置超时时间的几种方法
FastAPI 提供了多种设置超时时间的方法,从全局级别到路由级别的设置都可用,以确保请求不会无限期地等待响应。
![FastAPI 多线程的使用:提升代码运行性能](https://apifox.com/apiskills/content/images/2023/07/how-to-use-fastapi-threading.png)
FastAPI 多线程的使用:提升代码运行性能
本文介绍了FastAPI框架中多线程的使用方法。
![FastAPI BackgroundTasks 阻塞的问题处理](https://apifox.com/apiskills/content/images/2023/07/FastAPI-BackgroundTasks--------.png)
FastAPI BackgroundTasks 阻塞的问题处理
本文讲解 FastAPI 中 BackgroundTasks 阻塞问题的处理方式
![FastAPI 快速 crud(增删改查)](https://apifox.com/apiskills/content/images/2023/07/---FastAPI---------.png)
FastAPI 快速 crud(增删改查)
本文介绍了如何使用 FastAPI 快速实现 CRUD(增删改查)功能
![FastAPI APIRouter 的用法](https://apifox.com/apiskills/content/images/2023/07/FastAPI-APIRouter----.png)
FastAPI APIRouter 的用法
本文介绍FastAPI APIRouter的用法,它是 FastAPI 中组织和管理路由的强大工具。
![FastAPI 中 StreamingResponse 类怎么使用?一文讲解](https://apifox.com/apiskills/content/images/2023/07/-----FastAPI---StreamingResponse------.png)
FastAPI 中 StreamingResponse 类怎么使用?一文讲解
StreamingResponse 类是 FastAPI 中处理流式响应的强大工具,本文介绍了在 FastAPI 中使用 StreamingResponse 类的方法
![FastAPI 中怎么进行文件上传?](https://apifox.com/apiskills/content/images/2023/07/FastAPI----------.png)
FastAPI 中怎么进行文件上传?
本文介绍了在 FastAPI 中进行文件上传的方法
![FastAPI 中怎么使用 WebSocket 协议](https://apifox.com/apiskills/content/images/2023/07/FastAPI-------websocket---.png)
FastAPI 中怎么使用 WebSocket 协议
本文介绍了在 FastAPI 中使用 WebSocket 协议的方法
![FastAPI 与 Flask:Python Web 两大流行框架综合对比](https://apifox.com/apiskills/content/images/2023/07/FastAPI---Flask-Python-Web-----------.png)
FastAPI 与 Flask:Python Web 两大流行框架综合对比
本文将对 FastAPI 和 Flask 进行综合对比,探讨它们在语法和表达能力、生态系统和社区支持、性能和扩展性等方面的特点
![FastAPI 并发请求:提升性能的关键特性](https://apifox.com/apiskills/content/images/2023/07/FastAPI---------------.png)
FastAPI 并发请求:提升性能的关键特性
本文介绍了如何使用 FastAPI 实现并发请求
![FastAPI 是什么?怎么使用?](https://apifox.com/apiskills/content/images/2023/07/FastAPI----.png)
FastAPI 是什么?怎么使用?
本文介绍 FastAPI 的基本使用