{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/fettle-sh/json-schema/fettle-sh-ssl-check-response-schema.json",
  "title": "SslCheckResponse",
  "description": "Certificate facts for one host, or an honest \"no handshake\" answer.",
  "x-generated": "2026-10-30",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/_original/fettle-sh-api-openapi.json#/components/schemas/SslCheckResponse",
  "properties": {
    "host": {
      "type": "string",
      "title": "Host"
    },
    "port": {
      "type": "integer",
      "title": "Port"
    },
    "resolved_ip": {
      "type": "string",
      "title": "Resolved Ip"
    },
    "reachable": {
      "type": "boolean",
      "title": "Reachable"
    },
    "valid": {
      "type": "boolean",
      "title": "Valid"
    },
    "probe_error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Probe Error"
    },
    "verify_error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Verify Error"
    },
    "tls_version": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Tls Version"
    },
    "cipher": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Cipher"
    },
    "subject_common_name": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Subject Common Name"
    },
    "subject_alternative_names": {
      "items": {
        "type": "string"
      },
      "type": "array",
      "title": "Subject Alternative Names"
    },
    "issuer": {
      "anyOf": [
        {
          "$ref": "#/$defs/SslIssuer"
        },
        {
          "type": "null"
        }
      ]
    },
    "not_before": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ],
      "title": "Not Before"
    },
    "not_after": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ],
      "title": "Not After"
    },
    "days_left": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Days Left"
    },
    "chain": {
      "items": {
        "$ref": "#/$defs/SslChainLink"
      },
      "type": "array",
      "title": "Chain"
    },
    "checked_at": {
      "type": "string",
      "format": "date-time",
      "title": "Checked At"
    }
  },
  "type": "object",
  "required": [
    "host",
    "port",
    "resolved_ip",
    "reachable",
    "valid",
    "checked_at"
  ],
  "$defs": {
    "SslChainLink": {
      "properties": {
        "subject_common_name": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Subject Common Name"
        },
        "issuer_common_name": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Issuer Common Name"
        },
        "not_after": {
          "type": "string",
          "format": "date-time",
          "title": "Not After"
        }
      },
      "type": "object",
      "required": [
        "not_after"
      ],
      "title": "SslChainLink"
    },
    "SslIssuer": {
      "properties": {
        "common_name": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Common Name"
        },
        "organization": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Organization"
        }
      },
      "type": "object",
      "title": "SslIssuer"
    }
  }
}