{
  "$defs": {
    "__schema0": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        },
        {
          "type": "boolean"
        },
        {
          "type": "null"
        },
        {
          "items": {
            "$ref": "#/$defs/__schema0"
          },
          "type": "array"
        },
        {
          "additionalProperties": {
            "$ref": "#/$defs/__schema0"
          },
          "propertyNames": {
            "type": "string"
          },
          "type": "object"
        }
      ]
    }
  },
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "properties": {
    "commit_sha": {
      "anyOf": [
        {
          "pattern": "^[0-9a-f]{40}$",
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "manifest": {
      "properties": {
        "entries_evidence": {
          "properties": {
            "sha256": {
              "pattern": "^[0-9a-f]{64}$",
              "type": "string"
            },
            "size_bytes": {
              "maximum": 9007199254740991,
              "minimum": 0,
              "type": "integer"
            },
            "uri": {
              "minLength": 1,
              "type": "string"
            }
          },
          "required": [
            "uri",
            "sha256",
            "size_bytes"
          ],
          "type": "object"
        },
        "file_count": {
          "maximum": 9007199254740991,
          "minimum": 0,
          "type": "integer"
        },
        "ignored_submodule_count": {
          "maximum": 9007199254740991,
          "minimum": 0,
          "type": "integer"
        }
      },
      "required": [
        "file_count",
        "ignored_submodule_count",
        "entries_evidence"
      ],
      "type": "object"
    },
    "manifest_hints": {
      "properties": {
        "entrypoint_files": {
          "properties": {
            "index_js": {
              "type": "boolean"
            },
            "server_js": {
              "type": "boolean"
            }
          },
          "required": [
            "index_js",
            "server_js"
          ],
          "type": "object"
        },
        "lockfile": {
          "enum": [
            "pnpm",
            "npm",
            "yarn",
            "none"
          ],
          "type": "string"
        },
        "package_json": {
          "properties": {
            "belld": {
              "additionalProperties": {
                "$ref": "#/$defs/__schema0"
              },
              "propertyNames": {
                "type": "string"
              },
              "type": "object"
            },
            "dependencies": {
              "properties": {
                "next": {
                  "maxLength": 64,
                  "type": "string"
                }
              },
              "type": "object"
            },
            "engines": {
              "properties": {
                "node": {
                  "maxLength": 64,
                  "type": "string"
                }
              },
              "type": "object"
            },
            "main": {
              "maxLength": 256,
              "type": "string"
            },
            "name": {
              "maxLength": 214,
              "type": "string"
            },
            "scripts": {
              "properties": {
                "build": {
                  "maxLength": 1024,
                  "type": "string"
                },
                "start": {
                  "maxLength": 1024,
                  "type": "string"
                }
              },
              "type": "object"
            }
          },
          "type": "object"
        }
      },
      "type": "object"
    },
    "manifest_hints_truncated": {
      "type": "boolean"
    },
    "product_id": {
      "pattern": "^prod_[0-7][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
      "type": "string"
    },
    "rejection": {
      "oneOf": [
        {
          "properties": {
            "code": {
              "enum": [
                "size_limit",
                "file_count_limit",
                "depth_limit",
                "file_size_limit",
                "path_length",
                "traversal",
                "symlink_escape",
                "ref_not_found",
                "host_not_allowed",
                "private_source_unsupported",
                "fetch_timeout",
                "fetch_failed",
                "archive_bomb",
                "nested_archive",
                "archive_invalid",
                "upload_mismatch"
              ],
              "type": "string"
            },
            "detail": {
              "properties": {
                "actual": {
                  "type": "number"
                },
                "limit": {
                  "type": "number"
                }
              },
              "required": [
                "actual",
                "limit"
              ],
              "type": "object"
            }
          },
          "required": [
            "code"
          ],
          "type": "object"
        },
        {
          "properties": {
            "code": {
              "const": "credential_in_descriptor",
              "type": "string"
            },
            "detail": {
              "properties": {
                "field": {
                  "type": "string"
                }
              },
              "required": [
                "field"
              ],
              "type": "object"
            }
          },
          "required": [
            "code"
          ],
          "type": "object"
        }
      ]
    },
    "reported_at": {
      "format": "date-time",
      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
      "type": "string"
    },
    "revision_id": {
      "pattern": "^rev_[0-7][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
      "type": "string"
    },
    "snapshot": {
      "properties": {
        "sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "type": "string"
        },
        "size_bytes": {
          "maximum": 9007199254740991,
          "minimum": 0,
          "type": "integer"
        },
        "uri": {
          "minLength": 1,
          "type": "string"
        }
      },
      "required": [
        "uri",
        "sha256",
        "size_bytes"
      ],
      "type": "object"
    },
    "source_freeze_id": {
      "pattern": "^frz_[0-7][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
      "type": "string"
    },
    "status": {
      "enum": [
        "frozen",
        "rejected",
        "failed"
      ],
      "type": "string"
    },
    "workspace_id": {
      "pattern": "^ws_[0-7][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
      "type": "string"
    }
  },
  "required": [
    "source_freeze_id",
    "product_id",
    "revision_id",
    "workspace_id",
    "status",
    "reported_at"
  ],
  "type": "object"
}
