Forum Discussion

sidd-harth's avatar
sidd-harth
Occasional Visitor
7 years ago

Swagger definition for multiple backends

Hi guys, I am looking to build a set of developer portals for a Telecom use case, which has multiple brands. I am not sure what brands are right now, I am assuming each branch has its own backend and each brand will be having its own Developer Portal.

 

I have a swagger specification with two resources GET & POST. Each resource requires few input parameters in query/path/header variables.

 

Now the same two resources can/will be used to connect with multiple brands/backends. Each brand/backend expects a different set of input parameters.

Example - 
Brand1 - Backend1 requires 2 query parameters and 1 header variables.
Brand2 - Backend2 requires 1 path parameters and 4 query variables.

So should I have two Swagger specifications for 2 Brands,

or

Can we use one swagger specification add some logic, where depending on the brand/backend the number of input parameters fields changes automatically in Swagger definition?

No RepliesBe the first to reply