Files
fastapi/docs/en/docs/reference/response.md
Nils Lindemann ebc8ac7295 📝 Tweak docs and translations links, typos, format (#11389)
Co-authored-by: Sebastián Ramírez <tiangolo@gmail.com>
2024-04-18 14:53:19 -05:00

397 B

Response class

You can declare a parameter in a path operation function or dependency to be of type Response and then you can set data for the response like headers or cookies.

You can also use it directly to create an instance of it and return it from your path operations.

You can import it directly from fastapi:

from fastapi import Response

::: fastapi.Response