Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
OpenAPI 3.* has the body name 'requestBody' which Connexion resolves …
…to the argument tag "request_body" so this line of code is not standards compliant, thus non-object JSON request bodies are not captured as arguments (on line 263) without the artificial use of an explicit 'x-body-name' with value 'request_body'
  • Loading branch information
Richard Bruskiewich committed Sep 25, 2019
commit fc303814c3469afa22579f1b244526151dd4cadf
2 changes: 1 addition & 1 deletion connexion/operations/openapi.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ def body_definition(self):
return {}

def _get_body_argument(self, body, arguments, has_kwargs, sanitize):
x_body_name = self.body_schema.get('x-body-name', 'body')
x_body_name = self.body_schema.get('x-body-name', 'request_body')
if is_nullable(self.body_schema) and is_null(body):
return {x_body_name: None}

Expand Down