{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "provider": {
      "type": "string",
      "enum": [
        "github",
        "azure_devops",
        "uploaded"
      ]
    },
    "resource": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "type": {
          "const": "repository"
        },
        "id": {
          "type": "string",
          "minLength": 1,
          "maxLength": 512,
          "pattern": "^[^\\s]+$"
        }
      },
      "required": [
        "type",
        "id"
      ]
    },
    "commitSha": {
      "type": "string",
      "pattern": "^[a-fA-F0-9]{40}$"
    },
    "uploadId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 512,
      "pattern": "^[^\\s]+$"
    }
  },
  "required": [
    "provider",
    "resource"
  ]
}