From 46be2ffd34e2118e905fa3f0cbcab918d482134f Mon Sep 17 00:00:00 2001 From: Sardorbek Imomaliev Date: Tue, 5 May 2020 20:04:35 +0700 Subject: [PATCH] Fix schema endpoint example (#7178) * Fix schema endpoint example Endpoint `schema` collides with `schema` class variable `schema` which is use for specification generation * Update metadata.md Co-authored-by: Tom Christie --- docs/api-guide/metadata.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/api-guide/metadata.md b/docs/api-guide/metadata.md index fdb778626..20708c6e3 100644 --- a/docs/api-guide/metadata.md +++ b/docs/api-guide/metadata.md @@ -71,7 +71,7 @@ If you have specific requirements for creating schema endpoints that are accesse For example, the following additional route could be used on a viewset to provide a linkable schema endpoint. @action(methods=['GET'], detail=False) - def schema(self, request): + def api_schema(self, request): meta = self.metadata_class() data = meta.determine_metadata(request, self) return Response(data)