{
    "title": "List of Git credentials",
    "$schema": "http://json-schema.org/draft-04/schema#",
    "javaType": "com.sos.joc.model.publish.git.GitCredentialsList",
    "type": "object",
    "required": [
        "credentials"
    ],
    "properties": {
        "credentials": {
            "type": "array",
            "items": {
                "javaType": "com.sos.joc.model.publish.git.GitCredentials",
                "type": "object",
                "anyOf": [
                    {
                        "required": [
                            "gitAccount",
                            "username",
                            "email",
                            "password",
                            "gitServer"
                        ]
                    },
                    {
                        "required": [
                            "gitAccount",
                            "username",
                            "email",
                            "personalAccessToken",
                            "gitServer"
                        ]
                    },
                    {
                        "required": [
                            "gitAccount",
                            "username",
                            "email",
                            "keyfilePath",
                            "gitServer"
                        ]
                    }
                ],
                "properties": {
                    "gitAccount": {
                        "type": "string",
                        "pattern": "^[^<>]*$",
                        "maxLength": 100
                    },
                    "username": {
                        "type": "string",
                        "pattern": "^[^<>]*$",
                        "maxLength": 100
                    },
                    "email": {
                        "type": "string",
                        "pattern": "^[^<>]*$",
                        "maxLength": 100
                    },
                    "keyfilePath": {
                        "description": "path or filename of a private Key. Empty filename possible.",
                        "type": "string",
                        "maxLength": 255
                    },
                    "password": {
                        "type": "string"
                    },
                    "personalAccessToken": {
                        "type": "string",
                        "pattern": "^[^<>]*$",
                        "maxLength": 100
                    },
                    "gitServer": {
                        "type": "string",
                        "pattern": "^[^<>]*$",
                        "maxLength": 255
                    }
                }
            }
        },
        "remoteUris": {
            "type": "array",
            "items": {
                "type": "string",
                "pattern": "^[^<>]*$",
                "maxLength": 255
            }
        }
    }
}