Our API application operates dynamically using SQL-defined metadata to generate reports based on the requests it receives. When a JSON request is passed in like the examples below:
{
"Field1": "Value1"
"GroupBy": ["GroupByValue1", "GroupByValue2"]
}
The API will return a corresponding result set, as shown:
{
"GroupByValue1": "SomeValue1"
"GroupByValue2": "SomeValue2"
... other fields based on GroupBy1 and GroupBy2
}
This mapping between request and result set is defined in the SQL database. We need to create swagger documentation for this dynamic functionality. Is there a way to generate documentation automatically based on the API endpoints that provide information on request/resultset relationships? This can be done using C# code or Typescript.