{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "title": "Task workload",
    "description": "Format of workload that's sending from Gearman Client to Gearman Worker",
    "type": "object",
    "properties": {
        "key": {
            "description": "Request key for sign notifications and data in storage",
            "type": "string"
        },
        "commands": {
            "description": "Array of commands",
            "type": "array",
            "minItems": 1,
            "items": {
                "type": "object",
                "properties": {
                    "name": {
                        "description": "Name of command",
                        "type": "string"
                    },
                    "params": {
                        "description": "Array of command params with key => value pairs",
                        "type": "object"
                    }
                },
                "required": [
                    "name"
                ]
            }
        }
    }
}