Skip to content

OpenApi spec shows all fields for the models as nullable. #361

@JulesImmerzeel

Description

@JulesImmerzeel

Hey all, I am new to this package. I like it, but there is one inconvience I have noticed so far.

image
All fields are marked as nullable as you can see in this screenshot (this is just one example it's for all). One way to resolve this is by adding the RequiredAttribute to the properties that are not nullable.

The reason why it might be important to fix this:

  • It gives better documentation about the models for frontend development.
  • In my particular case I am using a generator in the frontend to generate TypeScript classes based on the OpenApi file. So all my typescript classes would have nullable fields even though they should never be null.

Is there a reason why [Required] is not used or just something that was not taken into consideration?
If the later is the case I could have a look into it, as I am quiet familiar with WebAuthn specifications.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationDocumentation, comments, guides, info etc.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions