cknadler/nidyx

View on GitHub
examples/complex_properties/complex_properties.json.schema

Summary

Maintainability
Test Coverage
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "required": [
    "array",
    "similar_stuff",
    "positive",
    "not_really_similar_stuff"
  ],
  "properties": {
    "array": {
      "type": ["array", "null"],
      "items": { "type": "string" }
    },
    "similar_stuff": {
      "type": ["boolean", "integer", "number", "null"]
    },
    "not_really_similar_stuff": {
      "type": ["number", "object", "string"]
    },
    "positive": {
      "type": "integer",
      "minimum": 0
    },
    "nothing": {
      "type": "null"
    },
    "not_required": {
      "type": "integer"
    }
  }
}