{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "type": "object",
    "description": "A response containing traffic flows between objects",
    "properties": {
        "header": {
            "type": "object",
            "description": "Object describing document data",
            "properties": {
                "time_range": {
                    "type": "object",
                    "description": "Time range of the document records",
                    "properties": {
                        "start": {
                            "type": "string",
                            "description": "ISO8601 timestamp of earliest record in document"
                        },
                        "end": {
                            "type": "string",
                            "description": "ISO8601 timestamp of latest record in document"
                        }
                    }
                },
                "recordCount": {
                    "type": "integer",
                    "description": "Total record count (number of array items in data)"
                },
                "objTypes": {
                    "type": "array",
                    "description": "A collection of object types",
                    "items": {
                        "type": "string",
                        "description": "An object type"
                    }
                }
            }
        },
        "data": {
            "type": "array",
            "description": "Array of historic records",
            "items": {
                "type": "object",
                "description": "The schema of an array entry",
                "properties": {
                    "srcObj": {
                        "type": "string",
                        "description": "The name/ID of source object"
                    },
                    "srcType": {
                        "type": "string",
                        "description": "The type of source object"
                    },
                    "destObj": {
                        "type": "string",
                        "description": "The name/ID of destination object"
                    },
                    "destType": {
                        "type": "string",
                        "description": "The type of destination object"
                    },
                    "bytes": {
                        "type": "integer",
                        "minimum": 0,
                        "description": "The volume of data that flows from source to destination"
                    },
                    "packets": {
                        "type": "integer",
                        "minimum": 0,
                        "description": "The number of packets sent from source to destination"
                    }
                }
            }
        }
    },
    "required": [
        "data"
    ]
}