{
    "$schema": "http://json-schema.org/draft-07/schema#",
    "title": "Multiple user details",
    "description": "All fields present in a multi-user data request.",
    "type": "array",
    "additionalProperties": true,
    "required": [
        "result",
        "jsonrpc",
        "id"
    ],
    "items": {
        "jsonrpc": {
            "type": "string",
            "enum": [
                "2.0"
            ]
        },
        "result": {
            "type": "array",
            "additionalItems": false,
            "items": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                    "id",
                    "memberType",
                    "firstName",
                    "middleName",
                    "lastName",
                    "email",
                    "startDate",
                    "endDate",
                    "memberDay"
                ],
                "properties": {
                    "id": {
                        "type": "number"
                    },
                    "memberType": {
                        "type": "array",
                        "uniqueness": "true",
                        "additionalItems": false,
                        "items": {
                            "type": "string",
                            "enum": [
                                "lid",
                                "begeleider",
                                "bestuur",
                                "sponsor",
                                "ondersteuning",
                                "aspirant_begeleider",
                                "strippenkaart"
                            ]
                        }
                    },
                    "firstName": {
                        "oneOf": [
                            {
                                "type": "null"
                            },
                            {
                                "type": "string"
                            }
                        ]
                    },
                    "middleName": {
                        "oneOf": [
                            {
                                "type": "null"
                            },
                            {
                                "type": "string"
                            }
                        ]
                    },
                    "lastName": {
                        "oneOf": [
                            {
                                "type": "null"
                            },
                            {
                                "type": "string"
                            }
                        ]
                    },
                    "email": {
                        "oneOf": [
                            {
                                "type": "null"
                            },
                            {
                                "type": "string",
                                "format": "email"
                            }
                        ]
                    },
                    "startDate": {
                        "oneOf": [
                            {
                                "type": "null"
                            },
                            {
                                "type": "string",
                                "format": "^\\d{4}-\\d{2}-\\d{2}$"
                            }
                        ]
                    },
                    "endDate": {
                        "oneOf": [
                            {
                                "type": "null"
                            },
                            {
                                "type": "string",
                                "format": "^\\d{4}-\\d{2}-\\d{2}$"
                            }
                        ]
                    },
                    "memberDay": {
                        "oneOf": [
                            {
                                "type": "null"
                            },
                            {
                                "type": "string",
                                "enum": [
                                    "ma",
                                    "di",
                                    "wo",
                                    "do",
                                    "vr",
                                    "za",
                                    "zo"
                                ]
                            }
                        ]
                    }
                }
            }
        },
        "id": {
            "type": "number"
        }
    }
}