跳至内容
首页Programming

课程

FastAPI 入门

中级技能水平
更新时间 2025年10月
用 FastAPI 构建稳健、生产级 API,掌握 HTTP 操作、验证和异步执行,打造高效的数据与 ML 管道。
免费开始课程
FastAPIProgramming
4 小时
10 视频
29 练习
2,300 经验值
13,481
成就声明

创建您的免费帐户

继续操作即表示您接受我们的《使用条款》和《隐私政策》,并同意您的数据存储在美国。

深受数千家公司学习者的喜爱

Group

Training a Team?

Try for Business

课程描述

FastAPI及其应用简介

API常用于在网络上管理数据,而FastAPI是一个用于使用Python构建API的流行新型Web框架。 数据和机器学习工程师利用 FastAPI 构建应用程序,使其在 Web 上作为具备上下文感知的数据事务和管道运行。

使用 FastAPI 构建生产级 Web 应用程序

在本课程中,您将学习如何利用您的 Python 技能和 FastAPI 框架构建生产级 Web 应用程序。 最后,你将了解 FastAPI 相对于其他 Python Web 框架的核心使用场景。 你将学习使用所有四种 HTTP 操作来构建 API,并定义请求和响应模式。 此外,你还将验证 API 请求,使用适当的 HTTP 状态码和消息进行响应,并异步执行代码以提升应用性能。 一个实战项目将带你构建经典的 CRUD(Create, Read, Update, Delete)API,并使用 Python 的 requests 模块测试工作流程。

课程目标和目标受众

本课程专为希望使用 FastAPI 构建管理数据的 Web 应用程序的有经验 Python 程序员而设计。 完成本课程后,您将具备创建适用于高吞吐量数据管理和 ML 模型服务管道的 FastAPI 项目所需的基础。

先决条件

Introduction to APIs in PythonIntroduction to Object-Oriented Programming in Python
1

FastAPI Basics

We’ll start by learning FastAPI’s key features and core use cases. Then we will run our first application and test it out! Finally, we will learn the details of supporting GET and POST operations that include request parameters and build and test those endpoints.
开始章节
2

FastAPI Advanced topics

We’ll start by learning how to support PUT and DELETE operations using FastAPI. Then we will learn how to handle different kinds of errors and always return an appropriate status code in the response. Lastly we'll learn how to use async to enable concurrent requests that can handle higher workloads.
开始章节
3

Building and testing a JSON CRUD API

We'll start by learning how to write system tests to validate individual FastAPI endpoints. Next we'll build a full JSON CRUD API to manage object lifecycles over HTTP. Finally, we'll learn how to test different application endpoints working together with manual functional tests.
开始章节
FastAPI 入门
课程完成

获得成就证明

将此证书添加到你的 LinkedIn 档案、简历或履历中
在社交媒体和绩效评估中分享
立即注册

加入超过19百万学习者,今天就开始FastAPI 入门!

创建您的免费帐户

继续操作即表示您接受我们的《使用条款》和《隐私政策》,并同意您的数据存储在美国。

通过 DataCamp for Mobile 提升您的数据技能

随时随地通过我们的移动课程和每日 5 分钟编程挑战提升技能。