'Using flask and restplus, how does one receive json in the body of get?
A snippet from my flask app is like so:
scopes = api.model('Resource', {
'scopes': fields.List(fields.String),
})
@api.doc(body=scopes)
def get(self, account_id, pvp_type):
...
The sample body content that I supply on the swagger page is like so:
{ "scopes": [ "string" ] }
With the above, I get a response body like so:
{ "message": "Failed to decode JSON object: Expecting value: line 1 column 1 (char 0)" }
Please suggest what I might be doing wrong, Thx.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
