question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Swagger 2.0 ModelConverter support for required/not required items

See original GitHub issue

With the Required field having moved to the parent property (example), I’m wondering how to get swagger-scala-module ModelConverter to be able to control which items in a case class are marked as required. The resolve method doesn’t appear to expose the parent property. Is there another way to do this, or do we need to change the ModelConverter resolve to allow access to the parent property?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:11 (11 by maintainers)

github_iconTop GitHub Comments

1reaction
frantumacommented, Aug 10, 2018

@pjfanning not sure if this helps in all cases, however #2909 adds propName to annotatedType, try to give it a go.

0reactions
pjfanningcommented, Aug 10, 2018

Closing because @frantuma 's has helped me to progress my scala solution

Read more comments on GitHub >

github_iconTop Results From Across the Web

OpenAPI Specification - Version 2.0 - Swagger
Version 2.0 specification defines a set of files required to describe an API. These files can then be used by the Swagger-UI project...
Read more >
Describing Parameters - Swagger
Query parameters only support primitive types. You can have an array , but the items must be a primitive value type. Objects are...
Read more >
Basic Structure - Swagger
A Swagger version defines the overall structure of an API specification – what you can document and how you document it. swagger: "2.0"....
Read more >
Describing Parameters - Swagger
In OpenAPI, a path parameter is defined using in: path . The parameter name must be the same as specified in the path....
Read more >
Supported JSON Schema Keywords - Swagger
The item schema must be an OpenAPI schema and not a standard JSON Schema. properties – individual property definitions must follow OpenAPI schema...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found