{
    "$schema": "http://json-schema.org/draft-07/schema#",
    "properties": {
        "clusterHostname": {
            "title": "Cluster Hostname",
            "type": "string",
            "description": "Your MongoDB cluster hostname(s).",
            "format": "string",
            "minLength": 1,
            "examples": [
                "yourCluster-xxxyzzz.mongodb.net",
                "localhost:27017,localhost:27018,localhost:27019"
            ]
        },
        "username": {
            "title": "Username",
            "type": "string",
            "description": "Your MongoDB instance username",
            "minLength": 1,
            "examples": [
                "admin"
            ]
        },
        "password": {
            "title": "Password",
            "type": "string",
            "description": "Your MongoDB instance password",
            "writeOnly": true,
            "minLength": 1,
            "examples": [
                "@secret(!)Pass"
            ]
        },
        "protocol": {
            "title": "Protocol",
            "type": "string",
            "description": "The protocol to use for the MongoDB connection. Default is 'mongodb+srv'.",
            "enum": [
                "mongodb",
                "mongodb+srv"
            ],
            "default": "mongodb+srv",
            "examples": [
                "mongodb+srv"
            ]
        },
        "options": {
            "title": "Options",
            "type": "object",
            "description": "Additional options for the MongoDB connection.",
            "additionalProperties": true,
            "default": {
                "retryWrites": true,
                "w": "majority"
            },
            "examples": [
                {
                    "retryWrites": true,
                    "w": "majority",
                    "rs": "replicaSet"
                }
            ]
        }
    },
    "type": "object",
    "additionalProperties": true,
    "required": [
        "clusterHostname",
        "username",
        "password"
    ]
}