Forum Discussion

kip's avatar
kip
New Contributor
6 years ago

Reducing redundant endpoint definitions

Hey forum,   I have a design question concerning the best practise for the following scenario.   I have a bunch of endpoints defined in my OpenAPI specification, but actually double what real...
  • RonRatovsky's avatar
    6 years ago

    Hi there! Great question. Based on what you're describing, the operations are not really the same, because the input is different. However, it's clear the output is the same. What you can do, is define the responses as shared components and reference them, so you don't have to duplicate the definition. At the moment, that means you'll have to do that for each reference, as there's no support for grouped references, but hopefully will change in the future.