Skip to content

Commit

Permalink
Add to docstring
Browse files Browse the repository at this point in the history
  • Loading branch information
mortenkrane committed Aug 3, 2023
1 parent 20c8d3e commit ecba9ef
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions django_api_decorator/decorators.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ def api(
HTTP status code to use if the view _does not_ return an
Response object, but rather just the data we should return.
* serialize_by_alias:
Is passed as the by_alias argument to TypeAdapter.dump_json(), making
the model use the aliases defined in model_config when serializing.
The request body parsing is done by inspecting the view parameter types. If
the view has a body parameter, we will try to decode the payload to that
type. Currently Django Rest Framework serializers and pydantic models are are
Expand Down

0 comments on commit ecba9ef

Please sign in to comment.