{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "additionalProperties": false,
    "title": "Invenio Community v1.0.0",
    "type": "object",
    "definitions": {
        "identifier": {
            "description": "A generic identifier.",
            "additionalProperties": true,
            "type": "object",
            "properties": {
                "scheme": {
                    "type": "string",
                    "description": "Identifier scheme."
                },
                "identifier": {
                    "type": "string"
                }
            },
            "required": [
                "scheme",
                "identifier"
            ]
        }
    },
    "properties": {
        "$schema": {
            "description": "JSONSchema for the community.",
            "type": "string"
        },
        "id": {
            "description": "Community identifier.",
            "type": "string"
        },
        "title": {
            "description": "Community title.",
            "type": "string"
        },
        "description": {
            "description": "Community description.",
            "type": "string"
        },
        "type": {
            "description": "Community type.",
            "enum": [
                "organization",
                "event",
                "topic",
                "project"
            ]
        },
        "alternate_identifiers": {
            "type": "array",
            "description": "Alternate identifiers for the community",
            "_uniqueItems": true,
            "items": {
                "$ref": "#/definitions/identifier"
            }
        },
        "curation_policy": {
            "description": "Community curation policy.",
            "type": "string"
        },
        "page": {
            "description": "Community page.",
            "type": "string"
        },
        "website": {
            "description": "Community website.",
            "type": "string"
        },
        "domains": {
            "description": "Community domain.",
            "type": "array",
            "_uniqueItems": true,
            "items": {
                "type": "string"
            }
        },
        "funding": {
            "description": "Community funding.",
            "type": "array",
            "_uniqueItems": true,
            "items": {
                "type": "string"
            }
        },
        "verified": {
            "description": "Community verified.",
            "type": "boolean"
        },
        "visibility": {
            "description": "Community visibility.",
            "enum": [
                "public",
                "private",
                "hidden"
            ]
        },
        "member_policy": {
            "description": "Community member policy.",
            "enum": [
                "open",
                "closed"
            ]
        },
        "record_policy": {
            "description": "Community record policy.",
            "enum": [
                "open",
                "closed",
                "restricted"
            ]
        },
        "archived": {
            "description": "Community archived.",
            "type": "boolean"
        },
        "created_by": {
            "description": "Community creator.",
            "type": "integer"
        }
    },
    "required": [
        "$schema",
        "id",
        "title",
        "type"
    ]
}