ebowman / api-first-hand

API-First bootstrapping tool for building RESTful web services from a Swagger/OpenAPI spec
MIT License
142 stars 22 forks source link

Is this doc still relevant? #68

Closed LappleApple closed 7 years ago

LappleApple commented 7 years ago

https://github.com/zalando/api-first-hand/blob/master/docs/REFERENCES.md

Asking because the main README has this:

If not, we can delete it.

slavaschmidt commented 7 years ago

The REFERENCES is in-depth explanation how we work with json references in the plugin's source code. This is supposed to be useful for plugin developers as opposed to the plugin uses, for which is the section in the README

LappleApple commented 7 years ago

Thanks, @slavaschmidt! This sentence is a little confusing: "A $ref element of the specification is allowed to contain a name of file as its part." As its part of what, exactly? And "a name of file" means ... can we be a bit more specific?

LappleApple commented 7 years ago

Also this sentence: "It is also possible to reference a definition in one specification from another specification." [rewrite as?] => "You can reference a definition in one specification across other specifications."

slavaschmidt commented 7 years ago

This sentence is a little confusing: "A $ref element of the specification is allowed to contain a name of file as its part." As its part of what, exactly? And "a name of file" means ... can we be a bit more specific?

It basically means, you can use filename to reference part of another specification.

LappleApple commented 7 years ago

Does this make sense to you, @slavaschmidt?

You can use a filename to reference part of another specification with the $ref element. You can split a single specification into multiple files (as shown in cross_spec_references.yaml). You can also reference a definition in one specification across other specifications.

slavaschmidt commented 7 years ago

Totally. For example one can create domain_model.yaml and then reference it from any other API specification

LappleApple commented 7 years ago

Awesome, thank you @slavaschmidt!