- Sort Score
- Result 10 results
- Languages All
Results 151 - 160 of 1,976 for Fastapi (0.06 sec)
-
fastapi/security/api_key.py
The dependency result will be a string containing the key value. ## Example ```python from fastapi import Depends, FastAPI from fastapi.security import APIKeyQuery app = FastAPI() query_scheme = APIKeyQuery(name="api_key") @app.get("/items/") async def read_items(api_key: str = Depends(query_scheme)):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Apr 23 22:29:18 UTC 2024 - 9.1K bytes - Viewed (0) -
tests/test_dependency_security_overrides.py
from typing import List, Tuple from fastapi import Depends, FastAPI, Security from fastapi.security import SecurityScopes from fastapi.testclient import TestClient app = FastAPI() def get_user(required_scopes: SecurityScopes): return "john", required_scopes.scopes def get_user_override(required_scopes: SecurityScopes): return "alice", required_scopes.scopes def get_data(): return [1, 2, 3]
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Jun 14 15:54:46 UTC 2020 - 1.4K bytes - Viewed (0) -
docs_src/response_model/tutorial003_05_py310.py
from fastapi import FastAPI, Response from fastapi.responses import RedirectResponse app = FastAPI() @app.get("/portal", response_model=None) async def get_portal(teleport: bool = False) -> Response | dict: if teleport: return RedirectResponse(url="https://www.youtube.com/watch?v=dQw4w9WgXcQ")
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Jan 10 16:22:47 UTC 2023 - 373 bytes - Viewed (0) -
docs_src/custom_response/tutorial005.py
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Mar 26 19:09:53 UTC 2020 - 186 bytes - Viewed (0) -
docs/de/docs/tutorial/response-model.md
### FastAPI Datenfilterung FastAPI seinerseits wird den Rückgabetyp sehen und sicherstellen, dass das, was zurückgegeben wird, **nur** diejenigen Felder enthält, welche im Typ deklariert sind.
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 19.8K bytes - Viewed (0) -
docs/es/docs/project-generation.md
Repositorio en GitHub: [Full Stack FastAPI Template](https://github.com/tiangolo/full-stack-fastapi-template) ## Plantilla de FastAPI Full Stack - Tecnología y Características - ⚡ [**FastAPI**](https://fastapi.tiangolo.com) para el backend API en Python. - 🧰 [SQLModel](https://sqlmodel.tiangolo.com) para las interacciones con la base de datos SQL en Python (ORM).
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Oct 04 11:16:34 UTC 2024 - 2K bytes - Viewed (0) -
tests/test_security_oauth2_password_bearer_optional_description.py
from typing import Optional from fastapi import FastAPI, Security from fastapi.security import OAuth2PasswordBearer from fastapi.testclient import TestClient app = FastAPI() oauth2_scheme = OAuth2PasswordBearer( tokenUrl="/token", description="OAuth2PasswordBearer security scheme", auto_error=False, ) @app.get("/items/") async def read_items(token: Optional[str] = Security(oauth2_scheme)): if token is None:
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.2K bytes - Viewed (0) -
tests/test_security_openid_connect.py
from fastapi import Depends, FastAPI, Security from fastapi.security.open_id_connect_url import OpenIdConnect from fastapi.testclient import TestClient from pydantic import BaseModel app = FastAPI() oid = OpenIdConnect(openIdConnectUrl="/openid") class User(BaseModel): username: str def get_current_user(oauth_header: str = Security(oid)): user = User(username=oauth_header) return user
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.2K bytes - Viewed (0) -
tests/test_security_openid_connect_description.py
from fastapi import Depends, FastAPI, Security from fastapi.security.open_id_connect_url import OpenIdConnect from fastapi.testclient import TestClient from pydantic import BaseModel app = FastAPI() oid = OpenIdConnect( openIdConnectUrl="/openid", description="OpenIdConnect security scheme" ) class User(BaseModel): username: str def get_current_user(oauth_header: str = Security(oid)):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.4K bytes - Viewed (0) -
docs_src/custom_response/tutorial009.py
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Mar 26 19:09:53 UTC 2020 - 202 bytes - Viewed (0)