From 16bfa3521b5c9c0bd9e7f1b2bab9518a20dcb239 Mon Sep 17 00:00:00 2001 From: Ryan P Kilby Date: Fri, 22 Jun 2018 17:34:58 -0400 Subject: [PATCH] Add docs note about disabling schemas for actions --- docs/api-guide/schemas.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/api-guide/schemas.md b/docs/api-guide/schemas.md index aaefe3db8..25ce9df0d 100644 --- a/docs/api-guide/schemas.md +++ b/docs/api-guide/schemas.md @@ -243,6 +243,14 @@ You may disable schema generation for a view by setting `schema` to `None`: ... schema = None # Will not appear in schema +This also applies to extra actions for `ViewSet`s: + + class CustomViewSet(viewsets.ModelViewSet): + + @action(detail=True, schema=None) + def extra_action(self, request, pk=None): + ... + --- **Note**: For full details on `SchemaGenerator` plus the `AutoSchema` and