Replies: 3 comments
-
|
@renuka-fernando @pubudu538 Any thoughts on this? This needs to be finalized soon as this could break the existing functionalities if changed continuously. |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Beta Was this translation helpful? Give feedback.
0 replies
-
|
I don't really understand the problem being discussed here. There is a massive spec file (or something) provided but I'm not sure where to look at. Can you explain the problem in simpler terms please? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
In the gateway controller there's only one endpoint to accept both REST and Async API imports. Hence the
specfield should accept eitherAPIConfigDataorWebHookAPIData. To do this, there's a standard way introduced by openapi definition.oneOfwithdiscriminatorThis approach only accepts either of objects defined under the schema based on a specific property. This way, there should be an unique property such as
apiTypeto identify which object needs to be resolved during the runtime. This approach conflicts with the current api definition finalized[1][2].anyOfThis validates any of the objects (one or more) at a given time. With respect to the API YAMLs accepted for different API types, there will be only one specific object per API.
[1] #369 (comment)
[2] https://swagger.io/docs/specification/v3_0/data-models/oneof-anyof-allof-not/#anyof
Following is the sample openapi definition that is used by the codebase to process API Configuration files received.
Beta Was this translation helpful? Give feedback.
All reactions