Skip to content
Rico Suter edited this page Apr 7, 2016 · 14 revisions

The JsonSchema4 class can be used as follows:

var schema = JsonSchema4.FromType<Person>();
var schemaData = schema.ToJson();
var errors = schema.Validate("{...}");

foreach (var error in errors)
    Console.WriteLine(error.Path + ": " + error.Kind);

schema = JsonSchema4.FromJson(schemaData);

ExtensionData property

Any property which is not specified in JSON Schema will be serialized and deserialized from the ExtensionData property on the JsonSchema4 class.

Clone this wiki locally