{
    "$schema": "http://json-schema.org/draft-07/schema#",
    "type": "object",
    "title": "entity_definition_declare_finished_event",
    "description": "Entity definition declare finished event schema.",
    "additionalProperties": false,
    "required": [
        "service_id",
        "entity_type"
    ],
    "properties": {
        "service_id": {
            "type": "string",
            "minLength": 1,
            "pattern": "^$|.*\\S.*",
            "description": "The string has a minimum length of one character and it cannot consist of only whitespace characters."
        },
        "entity_type": {
            "type": "string",
            "minLength": 1,
            "pattern": "^$|.*\\S.*",
            "description": "The string has a minimum length of one character and it cannot consist of only whitespace characters."
        },
        "new_fields": {
            "type": "array",
            "description": "An array of entity fields that were newly added.",
            "uniqueItems": true,
            "additionalItems": false,
            "items": {
                "type": "string",
                "minLength": 1,
                "pattern": "^$|.*\\S.*",
                "description": "The string has a minimum length of one character and it cannot consist of only whitespace characters."
            }
        },
        "existing_fields": {
            "type": "array",
            "description": "An array of entity fields that already existed and were still defined as part of the command.",
            "uniqueItems": true,
            "additionalItems": false,
            "items": {
                "type": "string",
                "minLength": 1,
                "pattern": "^$|.*\\S.*",
                "description": "The string has a minimum length of one character and it cannot consist of only whitespace characters."
            }
        },
        "inactive_fields": {
            "type": "array",
            "description": "An array of entity fields that already existed and were explicitly made inactive.",
            "uniqueItems": true,
            "additionalItems": false,
            "items": {
                "type": "string",
                "minLength": 1,
                "pattern": "^$|.*\\S.*",
                "description": "The string has a minimum length of one character and it cannot consist of only whitespace characters."
            }
        },
        "deleted_fields": {
            "type": "array",
            "description": "An array of entity fields that already existed in an inactive state, but were not defined anymore as part of the command, so they were deleted.",
            "uniqueItems": true,
            "additionalItems": false,
            "items": {
                "type": "string",
                "minLength": 1,
                "pattern": "^$|.*\\S.*",
                "description": "The string has a minimum length of one character and it cannot consist of only whitespace characters."
            }
        }
    }
}
