{
    "$schema": "http://json-schema.org/draft-04/schema",
    "allOf": [
        {
            "$schema": "http://json-schema.org/draft-04/schema#",
            "description": "Describes the foundations of all NMOS resources",
            "properties": {
                "description": {
                    "description": "Detailed description of the resource",
                    "type": "string"
                },
                "id": {
                    "description": "Globally unique identifier for the resource",
                    "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
                    "type": "string"
                },
                "label": {
                    "description": "Freeform string label for the resource",
                    "type": "string"
                },
                "tags": {
                    "description": "Key value set of freeform string tags to aid in filtering resources. Values should be represented as an array of strings. Can be empty.",
                    "patternProperties": {
                        "": {
                            "items": {
                                "type": "string"
                            },
                            "type": "array"
                        }
                    },
                    "type": "object"
                },
                "version": {
                    "description": "String formatted TAI timestamp (<seconds>:<nanoseconds>) indicating precisely when an attribute of the resource last changed",
                    "pattern": "^[0-9]+:[0-9]+$",
                    "type": "string"
                }
            },
            "required": [
                "id",
                "version",
                "label",
                "description",
                "tags"
            ],
            "title": "Base resource",
            "type": "object"
        },
        {
            "properties": {
                "adjust_to_caps": {
                    "description": "Whether the Input is configured to adjust Base EDID to internal capabilities. The property exists if the Input supports this feature",
                    "type": "boolean"
                },
                "base_edid_support": {
                    "description": "Whether the Input supports Base EDID",
                    "type": "boolean"
                },
                "connected": {
                    "description": "Whether the upstream counterpart of this Input is connected",
                    "type": "boolean"
                },
                "device_id": {
                    "description": "Device ID which this Input forms part of",
                    "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
                    "type": "string"
                },
                "edid_support": {
                    "description": "Whether the Input supports EDID",
                    "type": "boolean"
                },
                "status": {
                    "description": "Status of Input",
                    "properties": {
                        "debug": {
                            "description": "Debug information which may give additional information on the state",
                            "type": "string"
                        },
                        "state": {
                            "enum": [
                                "no_signal",
                                "awaiting_signal",
                                "signal_present"
                            ],
                            "type": "string"
                        }
                    },
                    "required": [
                        "state"
                    ]
                }
            },
            "required": [
                "base_edid_support",
                "connected",
                "edid_support",
                "status",
                "device_id"
            ],
            "type": "object"
        }
    ],
    "description": "Describes an Input",
    "title": "Input resource",
    "type": "object"
}
