diff --git a/marshmallow_jsonschema/base.py b/marshmallow_jsonschema/base.py index 2e3d891..9d45b1c 100644 --- a/marshmallow_jsonschema/base.py +++ b/marshmallow_jsonschema/base.py @@ -157,6 +157,9 @@ def _from_python_type(self, obj, field, pytype): if metadata.get('title'): json_schema['title'] = metadata.get('title') + if metadata.get('format'): + json_schema['format'] = metadata.get('format') + if isinstance(field, fields.List): json_schema['items'] = self._get_schema_for_field( obj, field.container