{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "description": "Describes a bulk receiver update resource",
    "items": {
        "additionalProperties": false,
        "properties": {
            "id": {
                "description": "ID of the target receiver to apply parameters to",
                "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"
            },
            "params": {
                "$schema": "http://json-schema.org/draft-04/schema#",
                "additionalProperties": false,
                "description": "Describes a receiver",
                "properties": {
                    "activation": {
                        "$schema": "http://json-schema.org/draft-04/schema#",
                        "additionalProperties": false,
                        "description": "Parameters concerned with activation of the transport parameters",
                        "properties": {
                            "mode": {
                                "anyOf": [
                                    {
                                        "enum": [
                                            "activate_immediate",
                                            "activate_scheduled_absolute",
                                            "activate_scheduled_relative"
                                        ],
                                        "type": "string"
                                    },
                                    {
                                        "type": "null"
                                    }
                                ],
                                "description": "Mode of activation: immediate (on message receipt), scheduled_absolute (when internal clock >= requested_time), scheduled_relative (when internal clock >= time of message receipt + requested_time), or null (no activation scheduled)"
                            },
                            "requested_time": {
                                "anyOf": [
                                    {
                                        "pattern": "^[0-9]+:[0-9]+$",
                                        "type": "string"
                                    },
                                    {
                                        "type": "null"
                                    }
                                ],
                                "description": "String formatted TAI timestamp (<seconds>:<nanoseconds>) indicating time (absolute or relative) for activation. Should be null or not present if 'mode' is null or activate_immediate."
                            }
                        },
                        "required": [
                            "mode"
                        ],
                        "title": "Activation resource",
                        "type": "object"
                    },
                    "master_enable": {
                        "description": "Master on/off control for receiver",
                        "type": "boolean"
                    },
                    "sender_id": {
                        "description": "ID of the Sender subscribed to by this Receiver. This will be null if the receiver has not been configured to receive anything, or if it is receiving from a non-NMOS sender.",
                        "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",
                            "null"
                        ]
                    },
                    "transport_file": {
                        "$schema": "http://json-schema.org/draft-04/schema#",
                        "additionalProperties": false,
                        "description": "Transport file parameters. 'data' and 'type' must both be strings or both be null. If 'type' is non-null 'data' is expected to contain a valid instance of the specified media type.",
                        "properties": {
                            "data": {
                                "description": "Content of the transport file",
                                "type": [
                                    "string",
                                    "null"
                                ]
                            },
                            "type": {
                                "description": "IANA assigned media type for file (e.g application/sdp)",
                                "type": [
                                    "string",
                                    "null"
                                ]
                            }
                        },
                        "required": [
                            "data",
                            "type"
                        ],
                        "title": "Transport file",
                        "type": "object"
                    },
                    "transport_params": {
                        "$schema": "http://json-schema.org/draft-04/schema#",
                        "description": "Transport-specific parameters. If this parameter is included in a client request it must include the same number of array elements (or 'legs') as specified in the constraints. If no changes are required to a specific leg it must be included as an empty object ({}).",
                        "items": {
                            "description": "Transport-specific parameters for a transport",
                            "patternProperties": {
                                "^[a-zA-Z0-9_]+$": {
                                    "type": [
                                        "string",
                                        "boolean",
                                        "null",
                                        "number"
                                    ]
                                }
                            },
                            "type": "object"
                        },
                        "title": "Receiver Transport Parameters",
                        "type": "array"
                    }
                },
                "title": "Receiver resource",
                "type": "object"
            }
        },
        "required": [
            "id",
            "params"
        ],
        "type": "object"
    },
    "title": "Bulk receiver resource",
    "type": "array"
}
