{
    "$id": "https://github.com/hyperjumptech/monika/main/monika-config-schema.json",
    "$schema": "http://json-schema.org/draft-07/schema#",
    "additionalProperties": false,
    "definitions": {
        "urlFormat": {
            "type": "string",
            "pattern": "^https?://"
        },
        "incidentThreshold": {
            "type": "integer",
            "description": "Number of times an alert should return true before Monika sends incident notifications",
            "default": 5
        },
        "recoveryThreshold": {
            "type": "integer",
            "description": "Number of times an alert should return false before Monika sends recovery notifications",
            "default": 5
        },
        "interval": {
            "title": "Interval",
            "type": "integer",
            "description": "The number of seconds to repeat the probe",
            "default": 10
        },
        "postgres": {
            "title": "Postgres",
            "type": "array",
            "description": "Monitor postgres readiness",
            "items": {
                "type": "object",
                "anyOf": [
                    {
                        "required": ["uri"],
                        "additionalProperties": false,
                        "properties": {
                            "uri": {
                                "title": "URI connection",
                                "type": "string",
                                "description": "Postgres uri connection configuration",
                                "examples": ["postgres://user:password@172.1.0.1:5432/mydb"]
                            }
                        }
                    },
                    {
                        "required": ["host", "port", "database"],
                        "additionalProperties": true,
                        "properties": {
                            "host": {
                                "type": "string",
                                "description": "Postgres host address to connect to",
                                "default": "172.15.0.1"
                            },
                            "port": {
                                "title": "Port",
                                "type": "integer",
                                "description": "Postgres port to connect to",
                                "default": "5432"
                            },
                            "database": {
                                "title": "Database",
                                "type": "string",
                                "description": "Name of the database",
                                "default": ""
                            },
                            "username": {
                                "title": "Username",
                                "type": "string",
                                "description": "Username with access to the database",
                                "default": ""
                            },
                            "password": {
                                "title": "Password",
                                "type": "string",
                                "description": "User's database password",
                                "default": ""
                            }
                        }
                    }
                ]
            }
        },
        "redis": {
            "title": "Redis",
            "type": "array",
            "description": "Monitor redis health ",
            "items": {
                "type": "object",
                "anyOf": [
                    {
                        "required": ["uri"],
                        "additionalProperties": true,
                        "properties": {
                            "uri": {
                                "title": "URI connection",
                                "type": "string",
                                "description": "redis uri connection configuration",
                                "examples": ["redis://alice:mypassword@172.15.0.2:6379"]
                            }
                        }
                    },
                    {
                        "required": ["host", "port"],
                        "additionalProperties": true,
                        "properties": {
                            "host": {
                                "title": "Redis host",
                                "description": "The hostname or IP address of the redis server",
                                "type": "string",
                                "default": "172.15.0.1",
                                "examples": ["localhost", "192.168.0.1"]
                            },
                            "port": {
                                "title": "Port number",
                                "description": "Port number used for the redis",
                                "type": "integer",
                                "default": "6379"
                            },
                            "password": {
                                "title": "Password",
                                "description": "Password used for the redis AUTH, if set.",
                                "type": "string",
                                "default": ""
                            },
                            "username": {
                                "title": "Username",
                                "description": "Username used for the redis AUTH, if set.",
                                "type": "string",
                                "default": ""
                            }
                        }
                    }
                ]
            }
        },
        "mongo": {
            "title": "MongoDB",
            "type": "array",
            "description": "Monitor MongoDB health ",
            "items": {
                "type": "object",
                "additionalProperties": true,
                "required": [],
                "properties": {
                    "uri": {
                        "title": "MongoDB URI",
                        "description": "The hostname or IP address of the MongoDB server",
                        "type": "string",
                        "examples": ["mongodb://user:password@127.0.0.1:27017/database"],
                        "default": "mongodb://127.0.0.1:27017"
                    },
                    "host": {
                        "title": "MongoDB host",
                        "description": "The hostname or IP address of the MongoDB server",
                        "type": "string",
                        "examples": ["localhost", "127.0.0.1"],
                        "default": "0.0.0.0.0"
                    },
                    "port": {
                        "title": "Port number",
                        "description": "Port number used for the MongoDB",
                        "type": "integer",
                        "examples": ["27017"],
                        "default": "27017"
                    },
                    "password": {
                        "title": "Password",
                        "description": "Password used for the MongoDB AUTH, if set.",
                        "type": "string",
                        "default": ""
                    },
                    "username": {
                        "title": "Username",
                        "description": "Username used for the MongoDB AUTH, if set.",
                        "type": "string",
                        "default": ""
                    }
                }
            }
        },
        "mariadb": {
            "title": "MariaDB/Mysql",
            "type": "array",
            "description": "Monitor MariaDB/Mysql health",
            "items": {
                "type": "object",
                "additionalProperties": false,
                "required": ["host", "port", "username", "password", "database"],
                "properties": {
                    "host": {
                        "title": "Database host",
                        "description": "The hostname or IP address of the database server",
                        "type": "string",
                        "examples": ["localhost", "127.0.0.1", "172.11.0.1"],
                        "default": "0.0.0.0"
                    },
                    "port": {
                        "title": "Port number",
                        "description": "Port number used by your database server",
                        "type": "integer",
                        "default": "3306"
                    },
                    "username": {
                        "title": "Username",
                        "description": "User with access to the database",
                        "type": "string",
                        "default": ""
                    },
                    "password": {
                        "title": "Password",
                        "description": "User password for authentication",
                        "type": "string",
                        "default": ""
                    },
                    "database": {
                        "title": "Database",
                        "default": "Name of the database"
                    }
                }
            }
        },
        "ping": {
            "title": "Ping",
            "type": "array",
            "description": "The ICMP ping probe",
            "items": {
                "type": "object",
                "additionalProperties": false,
                "required": ["uri"],
                "properties": {
                    "uri": {
                        "title": "Uri",
                        "type": "string",
                        "description": "The uri address to probe",
                        "default": "https://api.github.com/zen",
                        "examples": ["https://github.com", "https://httpbin.org/status/200"]
                    }
                }
            }
        },
        "requests": {
            "title": "Requests",
            "type": "array",
            "description": "The http or ping request to probe for",
            "items": {
                "type": "object",
                "additionalProperties": false,
                "required": ["url"],
                "properties": {
                    "method": {
                        "title": "HTTP Method",
                        "type": "string",
                        "description": "The http method",
                        "enum": [
                            "CONNECT",
                            "DELETE",
                            "GET",
                            "HEAD",
                            "LINK",
                            "OPTIONS",
                            "PATCH",
                            "POST",
                            "PURGE",
                            "PUT",
                            "TRACE",
                            "UNLINK"
                        ],
                        "default": "GET"
                    },
                    "url": {
                        "title": "Url",
                        "type": "string",
                        "description": "The remote URL address to probe",
                        "default": "https://api.github.com/zen",
                        "examples": ["https://github.com", "https://httpbin.org/status/200"]
                    },
                    "timeout": {
                        "title": "Timeout",
                        "type": "integer",
                        "description": "Set the timeout for the request in milliseconds, default is 10 seconds",
                        "default": 10000
                    },
                    "saveBody": {
                        "title": "SaveBody",
                        "type": "boolean",
                        "description": "Should response body be saved in the database",
                        "default": false
                    },
                    "alerts": {
                        "$ref": "#/definitions/alerts"
                    },
                    "ping": {
                        "title": "Ping",
                        "type": "boolean",
                        "description": "If defined and to true, the request is an ICMP ping"
                    },
                    "allowUnauthorized": {
                        "title": "AllowUnauthorized",
                        "type": "boolean",
                        "description": "If defined and to true, the request will ignore SSL certificate validity"
                    },
                    "body": {
                        "$ref": "#/definitions/body"
                    },
                    "headers": {
                        "$ref": "#/definitions/headers"
                    }
                }
            }
        },
        "socket": {
            "title": "Socket",
            "type": "object",
            "description": "Socket is a TCP type request",
            "additionalProperties": false,
            "required": ["host", "port", "data"],
            "properties": {
                "host": {
                    "type": "string",
                    "description": "Address to your host"
                },
                "port": {
                    "title": "Port",
                    "type": "integer",
                    "description": "Host port to connect to"
                },
                "data": {
                    "title": "Data",
                    "type": "string",
                    "description": "Data payload for the request"
                }
            }
        },
        "alerts": {
            "title": "Alerts",
            "type": "array",
            "description": "The condition which will trigger an alert and the subsequent notification",
            "items": {
                "type": "object",
                "anyOf": [
                    {
                        "required": ["assertion", "message"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "title": "Id",
                                "type": "string",
                                "description": "Unique string identification of the alert",
                                "examples": ["alert-1"],
                                "default": "alert-1"
                            },
                            "assertion": {
                                "title": "Assertion",
                                "type": "string",
                                "description": "An expression that will trigger an alert when its is logically true. See the assertions here: https://monika.hyperjump.tech/guides/alerts#alert-query",
                                "default": "response.status != 200"
                            },
                            "message": {
                                "title": "Message",
                                "type": "string",
                                "description": "Message that will be sent to the notification channel",
                                "default": "Http Response status code is not 200!"
                            }
                        }
                    },
                    {
                        "required": ["query", "message"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "title": "Id",
                                "type": "string",
                                "description": "Unique string identification of the alert",
                                "examples": ["alert-1"],
                                "default": "alert-1"
                            },
                            "query": {
                                "title": "Query",
                                "type": "string",
                                "description": "Note: Query is deprecated, please use assertion",
                                "default": "response.status != 200"
                            },
                            "message": {
                                "title": "Message",
                                "type": "string",
                                "description": "Message that will be sent to the notification channel",
                                "default": "Http Response status code is not 200!"
                            }
                        }
                    }
                ]
            }
        },
        "body": {
            "title": "Body",
            "description": "The data bytes transmitted in an HTTP transaction message immediately following the headers if there are any"
        },
        "headers": {
            "title": "Headers",
            "type": "object",
            "description": "A list of strings sent and received by both the client program and server on every HTTP request and response",
            "additionalProperties": true,
            "properties": {
                "Accept": {
                    "type": "string",
                    "description": "Media type(s) that is/are acceptable for the response"
                },
                "Accept-Charset": {
                    "type": "string",
                    "description": "Character sets that are acceptable"
                },
                "Accept-Encoding": {
                    "type": "string",
                    "description": "List of acceptable encodings"
                },
                "Authorization": {
                    "type": "string",
                    "description": "Authentication credentials for HTTP authentication"
                },
                "Cache-Control": {
                    "type": "string",
                    "description": "Used to specify directives that must be obeyed by all caching mechanisms along the request-response chain"
                },
                "Cookie": {
                    "type": "string",
                    "description": "An HTTP cookie previously sent by the server with Set-Cookie"
                },
                "Connection": {
                    "type": "string",
                    "description": "General header that allows the sender or client to specify options that are desired for that particular connection"
                },
                "Content-Type": {
                    "type": "string",
                    "description": "The Media type of the body of the request (used with POST and PUT requests"
                },
                "Keep-Alive": {
                    "type": "string",
                    "description": "General header used to inform how long a persistent connection should stay open"
                },
                "Origin": {
                    "type": "string",
                    "description": "Initiates a request for cross-origin resource sharing (asks server for Access-Control-* response fields)"
                },
                "Referer": {
                    "type": "string",
                    "description": "This is the address of the previous web page (referrer) from which a link to the currently requested page was followed"
                },
                "User-Agent": {
                    "type": "string",
                    "description": "The user agent string of the user agent"
                }
            }
        }
    },
    "description": "Monika monitoring configuration schema",
    "properties": {
        "probes": {
            "title": "Probes",
            "type": "array",
            "description": "Probe is a description of the target, methods, timing and payloads to begin monitoring/probing a target.",
            "items": {
                "type": "object",
                "additionalProperties": false,
                "required": ["id"],
                "properties": {
                    "id": {
                        "title": "Id",
                        "type": "string",
                        "description": "Unique string identification of the probe",
                        "examples": ["probe-01", "login-probe-01"],
                        "default": "probe-01"
                    },
                    "name": {
                        "title": "Name",
                        "type": "string",
                        "description": "A human-readible probe name",
                        "examples": ["get-user", "login-check", "web-heatlh-check"],
                        "default": "zen-check-01"
                    },
                    "description": {
                        "title": "Description",
                        "type": "string",
                        "description": "Description of the probe",
                        "examples": ["ensure service health is good"],
                        "default": "Ensure connectivity to github is successful"
                    },
                    "interval": {
                        "$ref": "#/definitions/interval"
                    },
                    "postgres": {
                        "$ref": "#/definitions/postgres"
                    },
                    "redis": {
                        "$ref": "#/definitions/redis"
                    },
                    "mongo": {
                        "$ref": "#/definitions/mongo"
                    },
                    "mariadb": {
                        "$ref": "#/definitions/mariadb"
                    },
                    "mysql": {
                        "$ref": "#/definitions/mariadb"
                    },
                    "requests": {
                        "$ref": "#/definitions/requests"
                    },
                    "socket": {
                        "$ref": "#/definitions/socket"
                    },
                    "incidentThreshold": {
                        "$ref": "#/definitions/incidentThreshold"
                    },
                    "recoveryThreshold": {
                        "$ref": "#/definitions/recoveryThreshold"
                    },
                    "alerts": {
                        "$ref": "#/definitions/alerts"
                    },
                    "ping": {
                        "$ref": "#/definitions/ping"
                    }
                }
            }
        },
        "notifications": {
            "title": "Notifications",
            "type": "array",
            "description": "Alerts of incidents and recoveries will be sent via these notification channels",
            "items": {
                "anyOf": [
                    {
                        "title": "Desktop",
                        "type": "object",
                        "required": ["id", "type"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique notification id",
                                "default": "desktop-01"
                            },
                            "type": {
                                "const": "desktop"
                            }
                        }
                    },
                    {
                        "title": "Discord",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique notification id",
                                "default": "discord-01"
                            },
                            "type": {
                                "const": "discord"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["url"],
                                "properties": {
                                    "url": {
                                        "$ref": "#/definitions/urlFormat",
                                        "description": "The URL of the Discord Webhook that will receive notification",
                                        "examples": [
                                            "https://discord.com/api/webhook/<webhook.id>/<webhook.token>"
                                        ]
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Workplace",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique notification id",
                                "default": "workplace-01"
                            },
                            "type": {
                                "const": "workplace"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["thread_id", "access_token"],
                                "properties": {
                                    "thread_id": {
                                        "type": "string",
                                        "description": "Thread id is the set of numbers at the end of the url"
                                    },
                                    "access_token": {
                                        "type": "string",
                                        "description": "Workplace access token for custom integration"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Google Chat",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique notification id",
                                "default": "google-chat-01"
                            },
                            "type": {
                                "const": "google-chat"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["url"],
                                "properties": {
                                    "url": {
                                        "$ref": "#/definitions/urlFormat",
                                        "description": "The webhook URL for your google chat",
                                        "examples": [
                                            "https://chat.googleapis.com/v1/spaces/XXXXX/messages?key=1122334455"
                                        ]
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Lark",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique notification id",
                                "default": "lark-01"
                            },
                            "type": {
                                "const": "lark"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["url"],
                                "properties": {
                                    "url": {
                                        "$ref": "#/definitions/urlFormat",
                                        "description": "The webhook URL for your lark suite",
                                        "examples": [
                                            "https://open.larksuite.com/open-apis/bot/v2/hook/your-webhook-key-here"
                                        ]
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Mailgun",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "type": {
                                "const": "mailgun"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["recipients", "apiKey", "domain"],
                                "properties": {
                                    "recipients": {
                                        "type": "array",
                                        "description": "An array of email addresses that will receive the e-mail from Monika",
                                        "items": {
                                            "type": "string"
                                        }
                                    },
                                    "apiKey": {
                                        "type": "string",
                                        "description": "Mailgun account API key, mailgun registered key to identify your account"
                                    },
                                    "domain": {
                                        "type": "string",
                                        "description": "The domain to set in Mailgun"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Microsoft Teams",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique notification id",
                                "default": "teams-01"
                            },
                            "type": {
                                "const": "teams"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["url"],
                                "properties": {
                                    "url": {
                                        "$ref": "#/definitions/urlFormat",
                                        "description": "Your teams webhook URL"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Monika Notification",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique notification id",
                                "default": "monika-01"
                            },
                            "type": {
                                "const": "monika-notif"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["url"],
                                "properties": {
                                    "url": {
                                        "$ref": "#/definitions/urlFormat",
                                        "description": "Your Monika notification URL",
                                        "examples": [
                                            "https://whatsapp.hyperjump.tech/api/notify?token=<webhook.token>"
                                        ]
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Pagerduty",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique pagerduty notif id",
                                "default": "pagerduty-01"
                            },
                            "type": {
                                "const": "pagerduty"
                            },
                            "data": {
                                "type": "array",
                                "description": "An array of email addresses that will receive the e-mail from Monika",
                                "items": {
                                    "type": "object",
                                    "description": "Data for your payload",
                                    "additionalProperties": false,
                                    "required": ["key", "probeID"],
                                    "properties": {
                                        "key": {
                                            "type": "string",
                                            "description": "Pagerduty integration key"
                                        },
                                        "probeID": {
                                            "type": "string",
                                            "description": "Monika Probe ID"
                                        }
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Sendgrid",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique sendgrid notification id",
                                "default": "sendgrid-01"
                            },
                            "type": {
                                "const": "sendgrid"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["sender", "recipients", "apiKey"],
                                "properties": {
                                    "sender": {
                                        "type": "string",
                                        "description": "A string of email addresses that has been verified in your sendgrid account"
                                    },
                                    "recipients": {
                                        "type": "array",
                                        "description": "An array of email addresses that will receive the e-mail from Monika",
                                        "items": {
                                            "type": "string"
                                        }
                                    },
                                    "apiKey": {
                                        "type": "string",
                                        "description": "Sendgrid account api key, sendgrid registered key to identify your account"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Slack",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique slack notification id",
                                "default": "slack-01"
                            },
                            "type": {
                                "const": "slack"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["url"],
                                "properties": {
                                    "url": {
                                        "$ref": "#/definitions/urlFormat",
                                        "description": "The URL webhook for Slack",
                                        "examples": ["https://slackwebhook.com/channel"]
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "SMTP",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique smtp notification id",
                                "default": "smtp-01"
                            },
                            "type": {
                                "const": "smtp"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": true,
                                "required": ["recipients", "hostname", "port"],
                                "properties": {
                                    "recipients": {
                                        "type": "array",
                                        "description": "An array of email address that will receive the email from Monika",
                                        "items": {
                                            "type": "string"
                                        }
                                    },
                                    "hostname": {
                                        "type": "string",
                                        "description": "The smtp host that you will be using for sending the email"
                                    },
                                    "port": {
                                        "type": "integer",
                                        "description": "The port allowed to be used for sending mail in your host"
                                    },
                                    "username": {
                                        "type": "string",
                                        "description": "Registered username on your smtp server"
                                    },
                                    "password": {
                                        "type": "string",
                                        "description": "The password set for your username"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Statuspage",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Notification identity number",
                                "default": "statuspage"
                            },
                            "type": {
                                "const": "statuspage"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["pageID", "apiKey"],
                                "properties": {
                                    "apiKey": {
                                        "type": "string",
                                        "description": "Statuspage API key"
                                    },
                                    "pageID": {
                                        "type": "string",
                                        "description": "Statuspage page ID "
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Telegram",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique telegram notification id",
                                "default": "telegram-01"
                            },
                            "type": {
                                "const": "telegram"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["group_id", "bot_token"],
                                "properties": {
                                    "group_id": {
                                        "type": "string",
                                        "description": "The ID of the group where the bot should send the messages"
                                    },
                                    "bot_token": {
                                        "type": "string",
                                        "description": "Token for your telegram bot"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Webhook",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique webhook notification id",
                                "default": "webhook-01"
                            },
                            "type": {
                                "const": "webhook"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["url"],
                                "properties": {
                                    "url": {
                                        "$ref": "#/definitions/urlFormat",
                                        "description": "The URL of the server that will receive the webhook notification",
                                        "examples": ["https://yourwebsite.com/webhook"]
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "WhatsApp for Business",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique whatsapp notification id",
                                "default": "whatsapp-01"
                            },
                            "type": {
                                "const": "whatsapp"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["recipients", "url", "username", "password"],
                                "properties": {
                                    "recipients": {
                                        "type": "array",
                                        "description": "An array of phone numbers registered for WhatsApp, should start with your controu code number",
                                        "items": {
                                            "type": "string"
                                        }
                                    },
                                    "url": {
                                        "$ref": "#/definitions/urlFormat",
                                        "description": "The URL of the server that will receive the webhook notification"
                                    },
                                    "username": {
                                        "type": "string",
                                        "description": "Your WhatsApp API username"
                                    },
                                    "password": {
                                        "type": "string",
                                        "description": "Your Whatsapp API user password"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Dingtalk",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique Dingtalk notification id",
                                "default": "dingtalk-01"
                            },
                            "type": {
                                "const": "dingtalk"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["access_token"],
                                "properties": {
                                    "access_token": {
                                        "type": "string",
                                        "description": "the token of your Dingtalk account"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Pushover",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique Pushover notification id",
                                "default": "pushover-01"
                            },
                            "type": {
                                "const": "pushover"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["token", "user"],
                                "properties": {
                                    "token": {
                                        "type": "string",
                                        "description": "Pushover application token"
                                    },
                                    "user": {
                                        "type": "string",
                                        "description": "Pushover user key"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Gotify",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique Gotify notification id",
                                "default": "Gotify-01"
                            },
                            "type": {
                                "const": "gotify"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["token", "url"],
                                "properties": {
                                    "token": {
                                        "type": "string",
                                        "description": "Gotify application token"
                                    },
                                    "url": {
                                        "type": "string",
                                        "description": "Gotify base url"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Opsgenie",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique opsgenie notification id",
                                "default": "opsgenie-01"
                            },
                            "type": {
                                "const": "opsgenie"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["geniekey"],
                                "properties": {
                                    "geniekey": {
                                        "type": "string",
                                        "description": "Opsgenie application token"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Pushbullet",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Unique notification id",
                                "default": "pushbullet-01"
                            },
                            "type": {
                                "const": "pushbullet"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["token"],
                                "properties": {
                                    "token": {
                                        "type": "string",
                                        "description": "Pushbullet application token."
                                    },
                                    "deviceID": {
                                        "type": "string",
                                        "description": "Pushbullet device identifier (optional)"
                                    }
                                }
                            }
                        }
                    },
                    {
                        "title": "Instatus",
                        "type": "object",
                        "required": ["id", "type", "data"],
                        "additionalProperties": false,
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "The type of notification",
                                "default": "instatus"
                            },
                            "type": {
                                "const": "instatus"
                            },
                            "data": {
                                "type": "object",
                                "description": "Data for your payload",
                                "additionalProperties": false,
                                "required": ["apiKey", "pageID"],
                                "properties": {
                                    "apiKey": {
                                        "type": "string",
                                        "description": "Instatus API key"
                                    },
                                    "pageID": {
                                        "type": "string",
                                        "description": "Instatus Page ID"
                                    }
                                }
                            }
                        }
                    }
                ]
            }
        },
        "db_limit": {
            "type": "object",
            "description": "Database internal configuration",
            "additionalProperties": false,
            "properties": {
                "max_db_size": {
                    "type": "number",
                    "description": "Maximum Monika database size",
                    "default": 1000000000
                },
                "deleted_data": {
                    "type": "integer",
                    "description": "Delete strategy when limit reached",
                    "default": 1
                },
                "cron_schedule": {
                    "type": "string",
                    "description": "Schedule to trim the db in crontab",
                    "default": "*/1 * * * *"
                }
            },
            "required": ["max_db_size", "deleted_data", "cron_schedule"]
        },
        "status-notification": {
            "type": "string",
            "title": "Status notification",
            "description": "Sends status notification periodically according to a cron schedule. Set to false to disable.",
            "default": "0 6 * * *"
        },
        "certificate": {
            "title": "Certificate",
            "type": "object",
            "description": "Check validity of your TLS certificate(s).",
            "additionalProperties": false,
            "required": ["domains"],
            "properties": {
                "domains": {
                    "type": "array",
                    "description": "The list of domains to check",
                    "items": {
                        "anyOf": [
                            {
                                "type": "string"
                            },
                            {
                                "type": "object",
                                "required": ["domain"],
                                "additionalProperties": false,
                                "properties": {
                                    "domain": {
                                        "type": "string",
                                        "description": "Hostname to check",
                                        "examples": ["https://github.com"]
                                    },
                                    "options": {
                                        "type": "object",
                                        "description": "Custom HTTPs Options",
                                        "additionalProperties": true,
                                        "properties": {
                                            "path": {
                                                "type": "string"
                                            }
                                        }
                                    }
                                }
                            }
                        ]
                    }
                },
                "reminder": {
                    "type": "integer",
                    "description": "The number of days to send notification to user before the domain expires",
                    "examples": [30]
                }
            }
        }
    },
    "type": "object"
}
