{% if schemas %}
"""Generated Marshmallow schemas for {{ spec.name }} {{ version }}."""

import marshmallow as ma
{% for schema in schemas %}


class {{ schema.name }}(ma.Schema):
{% if not schema.fields %}
    pass
{% else %}
{% for field in schema.fields %}
    {{ field.name }} = ma.fields.{{ field.field_type }}({{ field | field_kwargs }})
{% endfor %}
{% endif %}
{% endfor %}
{% endif %}
