{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "type": "object",
    "properties": {
        "id": {
            "type": "string",
            "pattern": "^[A-Fa-f\\d]{24}$"
        },
        "applicationId": {
            "type": "string",
            "pattern": "^[A-Fa-f\\d]{24}$"
        },
        "creationDate": {
            "type": "string",
            "format": "date-time"
        },
        "lastUpdated": {
            "type": "string",
            "format": "date-time"
        },
        "authorId": {
            "type": "string",
            "pattern": "^[A-Fa-f\\d]{24}$"
        },
        "authorType": {
            "type": "string",
            "enum": [
                "flow",
                "user",
                "device",
                "apiToken",
                "notebook"
            ]
        },
        "status": {
            "type": "string",
            "enum": [
                "pending",
                "moving",
                "deleting",
                "completed"
            ]
        },
        "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 1024
        },
        "parentDirectory": {
            "type": "string",
            "maxLength": 1024
        },
        "type": {
            "type": "string",
            "enum": [
                "file",
                "directory"
            ]
        },
        "fileSize": {
            "type": "number"
        },
        "contentType": {
            "type": "string",
            "maxLength": 1024
        },
        "fileDimensions": {
            "type": "object",
            "properties": {
                "width": {
                    "type": "number"
                },
                "height": {
                    "type": "number"
                }
            }
        },
        "upload": {
            "type": "object",
            "properties": {
                "url": {
                    "type": "string"
                },
                "fields": {
                    "type": "object",
                    "patternProperties": {
                        "^.*$": {
                            "type": "string"
                        }
                    },
                    "properties": {
                        "key": {
                            "type": "string"
                        },
                        "bucket": {
                            "type": "string"
                        }
                    }
                }
            }
        }
    }
}