sanic-org / sanic-openapi

Easily document your Sanic API with a UI

Home Page:https://sanic-openapi.readthedocs.io/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

does not produce the doc for this end point

kporika opened this issue · comments

@doc.consumes({'Authorization': str}, location='header')
@Scoped('admin')
@doc.consumes(
{"view":
{
"username": str,
"password" :str,
"email" : str,
"first_name": str,
"last_name" : str,
"is_superuser" : bool
}
},
location="body")
async def add_user(request):
sanic==20.12.1
sanic-jwt==1.6.0
sanic-openapi==0.6.2
on python3.9

it only produces authorization doc, but not for body
Screen Shot 2021-02-09 at 3 41 23 PM

Please put code tags around the code so that your issue displays better

It's because you're using a decorator @Scoped, and everything after that gets out of doc. I'm facing the same problem.