- Sort Score
- Result 10 results
- Languages All
Results 1121 - 1130 of 1,916 for FastApi (0.04 sec)
-
docs/ru/docs/tutorial/header-param-models.md
/// note | Заметка Этот функционал доступен в FastAPI начиная с версии `0.115.0`. 🤓 /// ## Header-параметры в виде Pydantic-модели { #header-parameters-with-a-pydantic-model } Объявите нужные **header-параметры** в **Pydantic-модели** и затем аннотируйте параметр как `Header`: {* ../../docs_src/header_param_models/tutorial001_an_py310.py hl[9:14,18] *}Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Tue Sep 30 11:24:39 UTC 2025 - 4.3K bytes - Viewed (0) -
docs/zh-hant/docs/async.md
但同時,使用 `async def` 定義的函式本身也必須被「等待」。所以,帶有 `async def` 函式只能在其他使用 `async def` 定義的函式內呼叫。 那麼,這就像「先有雞還是先有蛋」的問題,要如何呼叫第一個 `async` 函式呢? 如果你使用 FastAPI,無需擔心這個問題,因為「第一個」函式將是你的*路徑操作函式*,FastAPI 會知道如何正確處理這個問題。 但如果你想在沒有 FastAPI 的情況下使用 `async` / `await`,你也可以這樣做。 ### 編寫自己的非同步程式碼
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sun Aug 31 09:56:21 UTC 2025 - 21.1K bytes - Viewed (0) -
docs/zh/docs/async.md
但与此同时,必须"等待"通过 `async def` 定义的函数。因此,带 `async def` 的函数也只能在 `async def` 定义的函数内部调用。 那么,这关于先有鸡还是先有蛋的问题,如何调用第一个 `async` 函数? 如果你使用 **FastAPI**,你不必担心这一点,因为"第一个"函数将是你的路径操作函数,FastAPI 将知道如何做正确的事情。 但如果你想在没有 FastAPI 的情况下使用 `async` / `await`,则可以这样做。 ### 编写自己的异步代码
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sun Aug 31 09:56:21 UTC 2025 - 21.5K bytes - Viewed (0) -
tests/test_tutorial/test_additional_responses/test_tutorial001.py
from fastapi.testclient import TestClient from docs_src.additional_responses.tutorial001_py39 import app client = TestClient(app) def test_path_operation(): response = client.get("/items/foo") assert response.status_code == 200, response.text assert response.json() == {"id": "foo", "value": "there goes my hero"} def test_path_operation_not_found(): response = client.get("/items/bar")
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 4.3K bytes - Viewed (0) -
tests/test_tutorial/test_handling_errors/test_tutorial005.py
from fastapi.testclient import TestClient from docs_src.handling_errors.tutorial005_py39 import app client = TestClient(app) def test_post_validation_error(): response = client.post("/items/", json={"title": "towel", "size": "XL"}) assert response.status_code == 422, response.text assert response.json() == { "detail": [ { "type": "int_parsing", "loc": ["body", "size"],
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 18:19:10 UTC 2025 - 3.9K bytes - Viewed (0) -
tests/test_tutorial/test_custom_response/test_tutorial001.py
import importlib import pytest from fastapi.testclient import TestClient @pytest.fixture( name="client", params=[ pytest.param("tutorial001_py39"), pytest.param("tutorial010_py39"), ], ) def get_client(request: pytest.FixtureRequest): mod = importlib.import_module(f"docs_src.custom_response.{request.param}") client = TestClient(mod.app) return client
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Dec 26 10:43:02 UTC 2025 - 1.3K bytes - Viewed (0) -
docs/uk/docs/tutorial/request-forms.md
```console $ pip install python-multipart ``` /// ## Імпорт `Form` Імпортуйте `Form` з `fastapi`: {* ../../docs_src/request_forms/tutorial001_an_py39.py hl[3] *} ## Оголошення параметрів `Form` Створюйте параметри форми так само як Ви б створювали `Body` або `Query`:Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Feb 28 14:13:50 UTC 2025 - 4K bytes - Viewed (0) -
docs/es/docs/tutorial/response-status-code.md
/// note | Detalles técnicos También podrías usar `from starlette import status`. **FastAPI** proporciona el mismo `starlette.status` como `fastapi.status` solo como una conveniencia para ti, el desarrollador. Pero proviene directamente de Starlette. /// ## Cambiando el valor por defecto { #changing-the-default }Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 4.4K bytes - Viewed (0) -
docs/zh/docs/advanced/openapi-webhooks.md
## 使用 `FastAPI` 和 OpenAPI 文档化网络钩子 使用 **FastAPI**,您可以利用 OpenAPI 来自定义这些网络钩子的名称、您的应用可以发送的 HTTP 操作类型(例如 `POST`、`PUT` 等)以及您的应用将发送的**请求体**。 这能让您的用户更轻松地**实现他们的 API** 来接收您的**网络钩子**请求,他们甚至可能能够自动生成一些自己的 API 代码。 /// info 网络钩子在 OpenAPI 3.1.0 及以上版本中可用,FastAPI `0.99.0` 及以上版本支持。 /// ## 带有网络钩子的应用程序
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Thu Dec 19 15:30:38 UTC 2024 - 2.9K bytes - Viewed (0) -
docs/es/docs/how-to/authentication-error-status-code.md
# Usar los códigos de estado antiguos 403 para errores de autenticación { #use-old-403-authentication-error-status-codes } Antes de FastAPI versión `0.122.0`, cuando las utilidades de seguridad integradas devolvían un error al cliente después de una autenticación fallida, usaban el código de estado HTTP `403 Forbidden`.Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Tue Dec 16 16:16:35 UTC 2025 - 1.3K bytes - Viewed (0)