- Sort Score
- Result 10 results
- Languages All
Results 131 - 140 of 465 for userHome (0.05 sec)
-
docs/ru/docs/tutorial/request-forms.md
<abbr title="specification – спецификация">spec</abbr> требует, чтобы поля были строго названы `username` и `password` и отправлялись как поля формы, а не JSON. С помощью `Form` вы можете объявить те же настройки, что и с `Body` (и `Query`, `Path`, `Cookie`), включая валидацию, примеры, псевдоним (например, `user-name` вместо `username`) и т.д.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Tue Sep 30 11:24:39 UTC 2025 - 4.4K bytes - Viewed (0) -
docs_src/response_model/tutorial003_py310.py
from typing import Any from fastapi import FastAPI from pydantic import BaseModel, EmailStr app = FastAPI() class UserIn(BaseModel): username: str password: str email: EmailStr full_name: str | None = None class UserOut(BaseModel): username: str email: EmailStr full_name: str | None = None @app.post("/user/", response_model=UserOut) async def create_user(user: UserIn) -> Any:
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Jan 07 13:45:48 UTC 2023 - 431 bytes - Viewed (0) -
docs_src/security/tutorial006_an_py39.py
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Mar 18 12:29:59 UTC 2023 - 361 bytes - Viewed (0) -
docs/zh/docs/tutorial/extra-models.md
```Python UserInDB(**user_dict) ``` 就会生成如下结果: ```Python UserInDB( username="john", password="secret", email="******@****.***", full_name=None, ) ``` 或更精准,直接把可能会用到的内容与 `user_dict` 一起使用: ```Python UserInDB( username = user_dict["username"], password = user_dict["password"], email = user_dict["email"], full_name = user_dict["full_name"], )Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Mon Nov 18 02:25:44 UTC 2024 - 5.7K bytes - Viewed (0) -
tests/test_security_api_key_cookie_description.py
from pydantic import BaseModel app = FastAPI() api_key = APIKeyCookie(name="key", description="An API Cookie Key") class User(BaseModel): username: str def get_current_user(oauth_header: str = Security(api_key)): user = User(username=oauth_header) return user @app.get("/users/me") def read_current_user(current_user: User = Depends(get_current_user)): return current_user
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Mon Nov 24 19:03:06 UTC 2025 - 2.1K bytes - Viewed (0) -
docs/tr/docs/tutorial/request-forms.md
Bu <abbr title="Spesifikasyon: Specification">spesifikasyon</abbr> form alanlarını adlandırırken isimlerinin birebir `username` ve `password` olmasını ve JSON verisi yerine form verisi olarak gönderilmesini gerektirir.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Mon Nov 18 02:25:44 UTC 2024 - 3.1K bytes - Viewed (0) -
docs_src/custom_docs_ui/tutorial002_py39.py
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 1.1K bytes - Viewed (0) -
tests/test_tutorial/test_security/test_tutorial007.py
assert response.json() == {"detail": "Incorrect username or password"} assert response.headers["WWW-Authenticate"] == "Basic" def test_security_http_basic_invalid_password(client: TestClient): response = client.get("/users/me", auth=("stanleyjobson", "wrongpassword")) assert response.status_code == 401, response.text assert response.json() == {"detail": "Incorrect username or password"}
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Dec 26 10:43:02 UTC 2025 - 3.2K bytes - Viewed (0) -
docs_src/dependencies/tutorial008c_py39.py
print("Oops, we didn't raise again, Britney 😱") @app.get("/items/{item_id}") def get_item(item_id: str, username: str = Depends(get_username)): if item_id == "portal-gun": raise InternalError( f"The portal gun is too dangerous to be owned by {username}" ) if item_id != "plumbus": raise HTTPException(
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 660 bytes - Viewed (0) -
docs/es/docs/advanced/security/http-basic-auth.md
Para manejar eso, primero convertimos el `username` y `password` a `bytes` codificándolos con UTF-8. Luego podemos usar `secrets.compare_digest()` para asegurar que `credentials.username` es `"stanleyjobson"`, y que `credentials.password` es `"swordfish"`. {* ../../docs_src/security/tutorial007_an_py39.py hl[1,12:24] *} Esto sería similar a: ```Python
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Tue Dec 16 16:33:45 UTC 2025 - 5.4K bytes - Viewed (0)