diff --git a/openapi_codec/encode.py b/openapi_codec/encode.py index a95aaed..5a6fea8 100644 --- a/openapi_codec/encode.py +++ b/openapi_codec/encode.py @@ -115,14 +115,15 @@ def _get_parameters(link, encoding): 'required': field.required, 'in': 'formData', 'description': field.description, - 'type': 'string' + 'type': field.type or 'string' } parameters.append(parameter) else: # Expand coreapi fields with location='form' into a single swagger # parameter, with a schema containing multiple properties. schema_property = { - 'description': field.description + 'description': field.description, + 'type': field.type or 'string' } properties[field.name] = schema_property if field.required: @@ -147,7 +148,7 @@ def _get_parameters(link, encoding): 'required': field.required, 'in': location, 'description': field.description, - 'type': 'string' + 'type': field.type or 'string' } parameters.append(parameter)
Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.
Alternative Proxies: