With a schema processor, you can modify each generated schema after it has been generated.
Just implement the ISchemaProcessor and add an instance of the processor to the SchemaProcessors list of the JsonSchemaGeneratorSettings.
ISchemaProcessor
SchemaProcessors
JsonSchemaGeneratorSettings
public class MySchemaProcessor : ISchemaProcessor { public void Process(SchemaProcessorContext context) { ... } } settings.SchemaProcessors.Add(new MySchemaProcessor());
[JsonSchemaProcessor(typeof(MySchemaProcessor))] public class MyType { ... }
TODO: Add sample from here: https://github.com/RSuter/NSwag/wiki/Document-Processors-and-Operation-Processors#sample-add-additional-types-from-an-assembly
There was an error while loading. Please reload this page.