- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 166 for Cookies (0.13 sec)
-
docs/zh/docs/advanced/response-headers.md
你可以在你的*路径操作函数*中声明一个`Response`类型的参数(就像你可以为cookies做的那样)。 然后你可以在这个*临时*响应对象中设置头部。 ```Python hl_lines="1 7-8" {!../../../docs_src/response_headers/tutorial002.py!} ``` 然后你可以像平常一样返回任何你需要的对象(例如一个`dict`或者一个数据库模型)。如果你声明了一个`response_model`,它仍然会被用来过滤和转换你返回的对象。 **FastAPI**将使用这个临时响应来提取头部(也包括cookies和状态码),并将它们放入包含你返回的值的最终响应中,该响应由任何`response_model`过滤。 你也可以在依赖项中声明`Response`参数,并在其中设置头部(和cookies)。 ## 直接返回 `Response`
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Thu Apr 18 19:53:19 UTC 2024 - 2K bytes - Viewed (0) -
docs/uk/docs/tutorial/cookie-params.md
``` !!! note "Технічні Деталі" `Cookie` це "сестра" класів `Path` і `Query`. Вони наслідуються від одного батьківського класу `Param`. Але пам'ятайте, що коли ви імпортуєте `Query`, `Path`, `Cookie` та інше з `fastapi`, це фактично функції, що повертають спеціальні класи. !!! info Для визначення cookies ви маєте використовувати `Cookie`, тому що в іншому випадку параметри будуть інтерпритовані, як параметри запиту.
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Tue Oct 17 05:59:11 UTC 2023 - 3.2K bytes - Viewed (0) -
docs/en/docs/tutorial/cookie-params.md
``` !!! note "Technical Details" `Cookie` is a "sister" class of `Path` and `Query`. It also inherits from the same common `Param` class. But remember that when you import `Query`, `Path`, `Cookie` and others from `fastapi`, those are actually functions that return special classes. !!! info To declare cookies, you need to use `Cookie`, because otherwise the parameters would be interpreted as query parameters.
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Tue Oct 17 05:59:11 UTC 2023 - 2.4K bytes - Viewed (0) -
docs/es/docs/tutorial/cookie-params.md
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Fri Apr 19 19:30:26 UTC 2024 - 2.4K bytes - Viewed (0) -
docs/de/docs/tutorial/cookie-params.md
# Cookie-Parameter So wie `Query`- und `Path`-Parameter können Sie auch <abbr title='Cookie – „Keks“: Mechanismus, der kurze Daten in Textform im Browser des Benutzers speichert und abfragt'>Cookie</abbr>-Parameter definieren. ## `Cookie` importieren Importieren Sie zuerst `Cookie`: === "Python 3.10+" ```Python hl_lines="3" {!> ../../../docs_src/cookie_params/tutorial001_an_py310.py!} ``` === "Python 3.9+"
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Sat Mar 30 18:02:19 UTC 2024 - 2.7K bytes - Viewed (0) -
tests/test_param_include_in_schema.py
{"hidden_cookie": "somevalue"}, 200, {"hidden_cookie": "somevalue"}, ), ], ) def test_hidden_cookie(path, cookies, expected_status, expected_response): client = TestClient(app, cookies=cookies) response = client.get(path) assert response.status_code == expected_status assert response.json() == expected_response @pytest.mark.parametrize(
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Tue Mar 26 16:56:53 UTC 2024 - 7.4K bytes - Viewed (0) -
docs/es/docs/advanced/response-headers.md
# Headers de Respuesta ## Usar un parámetro `Response` Puedes declarar un parámetro de tipo `Response` en tu *función de operación de path* (de manera similar como se hace con las cookies). Y entonces, podrás configurar las cookies en ese objeto de response *temporal*. ```Python hl_lines="1 7-8" {!../../../docs_src/response_headers/tutorial002.py!} ```
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Wed Feb 07 12:51:12 UTC 2024 - 2.5K bytes - Viewed (0) -
docs/de/docs/advanced/response-headers.md
**FastAPI** verwendet diese *vorübergehende* Response, um die Header (auch Cookies und Statuscode) zu extrahieren und fügt diese in die endgültige Response ein, die den von Ihnen zurückgegebenen Wert enthält, gefiltert nach einem beliebigen `response_model`. Sie können den Parameter `Response` auch in Abhängigkeiten deklarieren und darin Header (und Cookies) festlegen. ## Eine `Response` direkt zurückgeben
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Sat Mar 30 20:19:06 UTC 2024 - 2.6K bytes - Viewed (0) -
docs/en/docs/advanced/response-headers.md
**FastAPI** will use that *temporal* response to extract the headers (also cookies and status code), and will put them in the final response that contains the value you returned, filtered by any `response_model`. You can also declare the `Response` parameter in dependencies, and set headers (and cookies) in them. ## Return a `Response` directly You can also add headers when you return a `Response` directly.
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Thu Jan 11 16:31:18 UTC 2024 - 2.2K bytes - Viewed (0) -
doc/next/6-stdlib/99-minor/net/http/62490.md
The new [Cookie.Partitioned] field identifies cookies with the Partitioned attribute....
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 22 18:33:05 UTC 2024 - 85 bytes - Viewed (0)