- Sort Score
- Result 10 results
- Languages All
Results 1571 - 1580 of 2,000 for Fastapi (0.07 sec)
-
docs/pt/docs/tutorial/body-nested-models.md
# Corpo - Modelos aninhados Com o **FastAPI**, vocรช pode definir, validar, documentar e usar modelos profundamente aninhados de forma arbitrรกria (graรงas ao Pydantic). ## Campos do tipo Lista Vocรช pode definir um atributo como um subtipo. Por exemplo, uma `list` do Python: ```Python hl_lines="14" {!../../docs_src/body_nested_models/tutorial001.py!} ```
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 7.4K bytes - Viewed (0) -
docs/en/docs/async.md
If you are working with **FastAPI** you don't have to worry about that, because that "first" function will be your *path operation function*, and FastAPI will know how to do the right thing. But if you want to use `async` / `await` without FastAPI, you can do it as well. ### Write your own async code
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Wed Aug 28 23:33:37 UTC 2024 - 23.5K bytes - Viewed (0) -
docs/en/docs/advanced/advanced-dependencies.md
To do that, we declare a method `__call__`: {* ../../docs_src/dependencies/tutorial011_an_py39.py hl[12] *} In this case, this `__call__` is what **FastAPI** will use to check for additional parameters and sub-dependencies, and this is what will be called to pass a value to the parameter in your *path operation function* later. ## Parameterize the instance
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 27 16:10:15 UTC 2024 - 2.4K bytes - Viewed (0) -
tests/test_tutorial/test_custom_response/test_tutorial007.py
from fastapi.testclient import TestClient from docs_src.custom_response.tutorial007 import app client = TestClient(app) def test_get(): fake_content = b"some fake video bytes" response = client.get("/")
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Jul 09 18:06:12 UTC 2020 - 264 bytes - Viewed (0) -
tests/test_tutorial/test_dependencies/test_tutorial008c_an.py
import pytest from fastapi.exceptions import FastAPIError from fastapi.testclient import TestClient @pytest.fixture(name="client") def get_client(): from docs_src.dependencies.tutorial008c_an import app client = TestClient(app) return client def test_get_no_item(client: TestClient): response = client.get("/items/foo") assert response.status_code == 404, response.text
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Feb 24 23:06:37 UTC 2024 - 1.1K bytes - Viewed (0) -
tests/test_tutorial/test_path_operation_configurations/test_tutorial006.py
import pytest from fastapi.testclient import TestClient from docs_src.path_operation_configuration.tutorial006 import app client = TestClient(app) @pytest.mark.parametrize( "path,expected_status,expected_response", [ ("/items/", 200, [{"name": "Foo", "price": 42}]), ("/users/", 200, [{"username": "johndoe"}]), ("/elements/", 200, [{"item_id": "Foo"}]), ], )
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.3K bytes - Viewed (0) -
docs_src/bigger_applications/app_an_py39/routers/users.py
from fastapi import APIRouter router = APIRouter() @router.get("/users/", tags=["users"]) async def read_users(): return [{"username": "Rick"}, {"username": "Morty"}] @router.get("/users/me", tags=["users"]) async def read_user_me(): return {"username": "fakecurrentuser"} @router.get("/users/{username}", tags=["users"]) async def read_user(username: str):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Mar 18 12:29:59 UTC 2023 - 407 bytes - Viewed (0) -
tests/test_tutorial/test_security/test_tutorial001_an.py
from fastapi.testclient import TestClient from docs_src.security.tutorial001_an import app client = TestClient(app) def test_no_token(): response = client.get("/items") assert response.status_code == 401, response.text assert response.json() == {"detail": "Not authenticated"} assert response.headers["WWW-Authenticate"] == "Bearer" def test_token():
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 1.9K bytes - Viewed (0) -
tests/test_tutorial/test_response_cookies/test_tutorial001.py
from fastapi.testclient import TestClient from docs_src.response_cookies.tutorial001 import app client = TestClient(app) def test_path_operation(): response = client.post("/cookie/") assert response.status_code == 200, response.text assert response.json() == {"message": "Come to the dark side, we have cookies"}
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Jul 09 18:06:12 UTC 2020 - 403 bytes - Viewed (0) -
docs/em/docs/tutorial/middleware.md
# ๐ ๏ธ ๐ ๐ช ๐ฎ ๐ ๏ธ **FastAPI** ๐ธ. "๐ ๏ธ" ๐ข ๐ ๐ท โฎ๏ธ ๐ **๐จ** โญ โซ๏ธ ๐ ๏ธ ๐ ๐ฏ *โก ๐ ๏ธ*. & โฎ๏ธ ๐ **๐จ** โญ ๐ฌ โซ๏ธ. * โซ๏ธ โ ๐ **๐จ** ๐ ๐ ๐ ๐ธ. * โซ๏ธ ๐ช โคด๏ธ ๐ณ ๐ **๐จ** โ๏ธ ๐ ๐ ๐ช ๐. * โคด๏ธ โซ๏ธ ๐ถโโ๏ธ **๐จ** ๐ ๏ธ ๐ ๐ธ ( *โก ๐ ๏ธ*). * โซ๏ธ โคด๏ธ โ **๐จ** ๐ ๐ธ ( *โก ๐ ๏ธ*). * โซ๏ธ ๐ช ๐ณ ๐ **๐จ** โ๏ธ ๐ ๐ ๐ช ๐. * โคด๏ธ โซ๏ธ ๐จ **๐จ**. /// note | "๐ก โน" ๐ฅ ๐ โ๏ธ ๐ โฎ๏ธ `yield`, ๐ช ๐ ๐ ๐ *โฎ๏ธ* ๐ ๏ธ. ๐ฅ ๐ค ๐ ๐ฅ ๐ (๐ โช), ๐ซ ๐ ๐ *โฎ๏ธ* ๐ ๐ ๏ธ.
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 2.4K bytes - Viewed (0)