{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "definitions": {
        "pets": {
            "type": "object",
            "properties": {
                "dog": {
                    "type": "string"
                },
                "cat": {
                    "type": "string"
                }
            },
            "required": [
                "dog",
                "cat"
            ]
        },
        "shapes": {
            "type": "object",
            "properties": {
                "circle": {
                    "type": "string"
                },
                "square": {
                    "type": "string"
                }
            },
            "required": [
                "circle",
                "square"
            ]
        }
    },
    "properties": {
        "pets": {
            "$ref": "#/definitions/pets"
        },
        "shapes": {
            "$ref": "#/definitions/shapes"
        }
    },
    "required": [
        "pets",
        "shapes"
    ]
}