{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "title": "Environment Modules",
    "description": "Information about the modules in a Puppet code environment",
    "type": "object",
    "properties": {
        "modules": {
            "description": "The array of modules which exist in an environment.",
            "type": "array",
            "items": {
                "type": "object",
                "properties": {
                    "name": {
                        "description": "The name of the puppet module",
                        "type": "string"
                    },
                    "version": {
                        "description": "The version of the puppet module",
                        "type": [
                            "string",
                            "null"
                        ]
                    }
                },
                "required": [
                    "name",
                    "version"
                ],
                "additionalProperties": false
            }
        },
        "name": {
            "description": "Name of the environment",
            "type": "string"
        }
    },
    "required": [
        "modules",
        "name"
    ],
    "additionalProperties": false
}