Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitab0c577

Browse files
nmgeeklovelydinosaur
authored andcommitted
Direct readers to info on how to add viewset docs (#4844)
I believe the original statement was wrong. You can, in fact, document the various API endpoints of a ViewSet.
1 parent6b399f1 commitab0c577

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

‎docs/topics/documenting-your-api.md‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ If the python `markdown` library is installed, then [markdown syntax][markdown]
105105
[ref]: http://example.com/activating-accounts
106106
"""
107107

108-
Note thatone constraint ofusing viewsetsis that any documentation beused for all generated views, so for example, you cannot have differing documentationfor thegenerated listviewanddetail view.
108+
Note thatwhenusing viewsetsthe basic docstring isused for all generated views. To provide descriptions for each view, such asfor thethe list andretrieve views, use docstring sections as described in[Schemas as documentation: Examples][schemas-examples].
109109

110110
####The`OPTIONS` method
111111

@@ -148,3 +148,4 @@ To implement a hypermedia API you'll need to decide on an appropriate media type
148148
[image-django-rest-swagger]:../img/django-rest-swagger.png
149149
[image-apiary]:../img/apiary.png
150150
[image-self-describing-api]:../img/self-describing.png
151+
[schemas-examples]:api-guide/schemas/#examples

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp