{
  "$defs": {
    "candidate": {
      "properties": {
        "batch_id": {
          "minLength": 1,
          "type": "string"
        },
        "candidate_type": {
          "enum": [
            "repository-discovery",
            "followed-source-lead"
          ]
        },
        "id": {
          "minLength": 1,
          "type": "string"
        },
        "review_status": {
          "const": "unreviewed"
        },
        "url": {
          "pattern": "^https?://",
          "type": "string"
        },
        "verification": {
          "enum": [
            "automated-readme-scan",
            "automated-source-lead"
          ]
        }
      },
      "required": [
        "candidate_type",
        "id",
        "url",
        "review_status",
        "verification",
        "batch_id"
      ],
      "type": "object"
    },
    "candidatesFile": {
      "additionalProperties": false,
      "properties": {
        "candidates": {
          "items": {
            "$ref": "#/$defs/candidate"
          },
          "type": "array"
        },
        "counts": {
          "additionalProperties": {
            "minimum": 0,
            "type": "integer"
          },
          "type": "object"
        },
        "docs": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "generated_at": {
          "format": "date-time",
          "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
          "type": "string"
        },
        "kind": {
          "const": "awesome-rea-candidates"
        },
        "license": {
          "minLength": 1,
          "type": "string"
        },
        "note": {
          "minLength": 1,
          "type": "string"
        },
        "note_zh": {
          "minLength": 1,
          "type": "string"
        },
        "pagination": {
          "minLength": 1,
          "type": "string"
        },
        "review_status": {
          "const": "unreviewed"
        },
        "schema": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "site_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "version": {
          "pattern": "^1\\.\\d+\\.\\d+$",
          "type": "string"
        }
      },
      "required": [
        "version",
        "generated_at",
        "kind",
        "schema",
        "review_status",
        "counts",
        "candidates"
      ],
      "type": "object"
    },
    "categoriesFile": {
      "additionalProperties": false,
      "properties": {
        "curated": {
          "additionalProperties": {
            "items": {
              "$ref": "#/$defs/label"
            },
            "type": "array"
          },
          "required": [
            "categories",
            "sections",
            "kinds",
            "targets",
            "relationships"
          ],
          "type": "object"
        },
        "docs": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "generated_at": {
          "format": "date-time",
          "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
          "type": "string"
        },
        "kind": {
          "const": "awesome-rea-categories"
        },
        "license": {
          "minLength": 1,
          "type": "string"
        },
        "repositories": {
          "additionalProperties": false,
          "properties": {
            "categories": {
              "items": {
                "$ref": "#/$defs/label"
              },
              "type": "array"
            },
            "count": {
              "minimum": 0,
              "type": "integer"
            },
            "snapshot": {
              "anyOf": [
                {
                  "minLength": 1,
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ]
            },
            "verification": {
              "const": "automated-readme-scan"
            }
          },
          "required": [
            "verification",
            "count",
            "categories"
          ],
          "type": "object"
        },
        "schema": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "site_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "version": {
          "pattern": "^1\\.\\d+\\.\\d+$",
          "type": "string"
        }
      },
      "required": [
        "version",
        "generated_at",
        "kind",
        "schema",
        "curated",
        "repositories"
      ],
      "type": "object"
    },
    "change": {
      "additionalProperties": false,
      "properties": {
        "change": {
          "enum": [
            "added",
            "reviewed",
            "discovered",
            "leads-collected"
          ]
        },
        "date": {
          "anyOf": [
            {
              "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
              "type": "string"
            },
            {
              "format": "date-time",
              "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
              "type": "string"
            }
          ]
        },
        "id": {
          "minLength": 1,
          "type": "string"
        },
        "json_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "name": {
          "minLength": 1,
          "type": "string"
        },
        "record_type": {
          "enum": [
            "resource",
            "paper",
            "discovery-batch",
            "lead-batch"
          ]
        },
        "url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        }
      },
      "required": [
        "date",
        "change",
        "record_type",
        "id",
        "name",
        "url"
      ],
      "type": "object"
    },
    "changesFile": {
      "additionalProperties": false,
      "properties": {
        "changes": {
          "items": {
            "$ref": "#/$defs/change"
          },
          "type": "array"
        },
        "count": {
          "minimum": 0,
          "type": "integer"
        },
        "docs": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "generated_at": {
          "format": "date-time",
          "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
          "type": "string"
        },
        "kind": {
          "const": "awesome-rea-changes"
        },
        "license": {
          "minLength": 1,
          "type": "string"
        },
        "schema": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "site_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "version": {
          "pattern": "^1\\.\\d+\\.\\d+$",
          "type": "string"
        },
        "window_days": {
          "const": 30
        },
        "window_end": {
          "format": "date-time",
          "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
          "type": "string"
        },
        "window_start": {
          "format": "date-time",
          "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
          "type": "string"
        }
      },
      "required": [
        "version",
        "generated_at",
        "kind",
        "schema",
        "window_days",
        "window_start",
        "window_end",
        "count",
        "changes"
      ],
      "type": "object"
    },
    "indexFile": {
      "additionalProperties": false,
      "properties": {
        "docs": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "endpoints": {
          "items": {
            "enum": [
              "resources",
              "papers",
              "categories",
              "candidates",
              "changes"
            ]
          },
          "type": "array"
        },
        "files": {
          "items": {
            "$ref": "#/$defs/indexFile_entry"
          },
          "type": "array"
        },
        "generated_at": {
          "format": "date-time",
          "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
          "type": "string"
        },
        "kind": {
          "const": "awesome-rea-api-index"
        },
        "license": {
          "minLength": 1,
          "type": "string"
        },
        "schema": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "site_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "version": {
          "pattern": "^1\\.\\d+\\.\\d+$",
          "type": "string"
        }
      },
      "required": [
        "version",
        "generated_at",
        "kind",
        "schema",
        "files"
      ],
      "type": "object"
    },
    "indexFile_entry": {
      "additionalProperties": false,
      "properties": {
        "bytes": {
          "minimum": 1,
          "type": "integer"
        },
        "media_type": {
          "minLength": 1,
          "type": "string"
        },
        "path": {
          "minLength": 1,
          "type": "string"
        },
        "records": {
          "minimum": 0,
          "type": "integer"
        },
        "schema": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "type": "string"
        },
        "url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        }
      },
      "required": [
        "path",
        "url",
        "media_type",
        "bytes",
        "sha256"
      ],
      "type": "object"
    },
    "label": {
      "additionalProperties": false,
      "properties": {
        "count": {
          "minimum": 0,
          "type": "integer"
        },
        "id": {
          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$",
          "type": "string"
        },
        "json_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "label": {
          "minLength": 1,
          "type": "string"
        },
        "label_zh": {
          "minLength": 1,
          "type": "string"
        },
        "markdown_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "url_zh": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        }
      },
      "required": [
        "id",
        "label",
        "label_zh",
        "count"
      ],
      "type": "object"
    },
    "paper": {
      "additionalProperties": false,
      "properties": {
        "added_at": {
          "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
          "type": "string"
        },
        "arxiv_id": {
          "anyOf": [
            {
              "minLength": 1,
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "arxiv_version_reviewed": {
          "anyOf": [
            {
              "minLength": 1,
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "authors": {
          "description": "Empty when authors_omitted is true; the paper lists them.",
          "items": {
            "minLength": 1,
            "type": "string"
          },
          "type": "array"
        },
        "authors_omitted": {
          "const": true
        },
        "bibtex_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "citation": {
          "propertyNames": {
            "enum": [
              "article_number",
              "container_title",
              "issue",
              "pages",
              "publisher",
              "series",
              "sources",
              "volume"
            ]
          },
          "type": "object"
        },
        "class": {
          "enum": [
            "software",
            "game",
            "apps",
            "website",
            "science",
            "hardware"
          ]
        },
        "code_url": {
          "anyOf": [
            {
              "format": "uri",
              "pattern": "^https://",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "date_basis": {
          "minLength": 1,
          "type": "string"
        },
        "date_basis_zh": {
          "minLength": 1,
          "type": "string"
        },
        "date_precision": {
          "enum": [
            "year",
            "month",
            "day"
          ]
        },
        "description_en": {
          "minLength": 1,
          "type": "string"
        },
        "description_zh": {
          "minLength": 1,
          "type": "string"
        },
        "doi": {
          "anyOf": [
            {
              "minLength": 1,
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "entry_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "entry_url_zh": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "evidence_urls": {
          "items": {
            "format": "uri",
            "pattern": "^https://",
            "type": "string"
          },
          "minItems": 1,
          "type": "array"
        },
        "first_arxiv_date": {
          "anyOf": [
            {
              "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "id": {
          "pattern": "^paper-[a-z0-9]+(?:-[a-z0-9]+)*$",
          "type": "string"
        },
        "json_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "kind": {
          "const": "research"
        },
        "markdown_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "markdown_url_zh": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "metadata_notes": {
          "minLength": 1,
          "type": "string"
        },
        "metadata_notes_zh": {
          "minLength": 1,
          "type": "string"
        },
        "pdf_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "project_url": {
          "anyOf": [
            {
              "format": "uri",
              "pattern": "^https://",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "publication_date": {
          "anyOf": [
            {
              "pattern": "^\\d{4}(?:-\\d{2}){0,2}$",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "publication_status": {
          "enum": [
            "conference-paper",
            "conference-accepted",
            "journal-article",
            "preprint"
          ]
        },
        "record_type": {
          "const": "paper"
        },
        "runtime_tested": {
          "const": false
        },
        "scope_limitations_en": {
          "minLength": 1,
          "type": "string"
        },
        "scope_limitations_zh": {
          "minLength": 1,
          "type": "string"
        },
        "targets": {
          "items": {
            "enum": [
              "website",
              "game",
              "app",
              "binary",
              "firmware",
              "protocol"
            ]
          },
          "minItems": 1,
          "type": "array"
        },
        "title": {
          "minLength": 1,
          "type": "string"
        },
        "title_zh": {
          "minLength": 1,
          "type": "string"
        },
        "url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "venue": {
          "minLength": 1,
          "type": "string"
        },
        "verification": {
          "const": "source-reviewed"
        },
        "verified_at": {
          "anyOf": [
            {
              "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
              "type": "string"
            },
            {
              "format": "date-time",
              "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
              "type": "string"
            }
          ]
        },
        "why_fits_en": {
          "minLength": 1,
          "type": "string"
        },
        "why_fits_zh": {
          "minLength": 1,
          "type": "string"
        },
        "year": {
          "minimum": 1900,
          "type": "integer"
        }
      },
      "required": [
        "id",
        "record_type",
        "title",
        "title_zh",
        "authors",
        "year",
        "venue",
        "publication_status",
        "url",
        "pdf_url",
        "targets",
        "description_en",
        "description_zh",
        "scope_limitations_en",
        "scope_limitations_zh",
        "why_fits_en",
        "why_fits_zh",
        "evidence_urls",
        "added_at",
        "verified_at",
        "verification",
        "runtime_tested",
        "bibtex_url",
        "entry_url",
        "entry_url_zh",
        "markdown_url",
        "markdown_url_zh",
        "json_url"
      ],
      "type": "object"
    },
    "papersFile": {
      "additionalProperties": false,
      "properties": {
        "count": {
          "minimum": 0,
          "type": "integer"
        },
        "docs": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "generated_at": {
          "format": "date-time",
          "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
          "type": "string"
        },
        "kind": {
          "const": "awesome-rea-papers"
        },
        "license": {
          "minLength": 1,
          "type": "string"
        },
        "note": {
          "minLength": 1,
          "type": "string"
        },
        "note_zh": {
          "minLength": 1,
          "type": "string"
        },
        "papers": {
          "items": {
            "$ref": "#/$defs/paper"
          },
          "type": "array"
        },
        "schema": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "site_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "version": {
          "pattern": "^1\\.\\d+\\.\\d+$",
          "type": "string"
        }
      },
      "required": [
        "version",
        "generated_at",
        "kind",
        "schema",
        "count",
        "papers"
      ],
      "type": "object"
    },
    "repositoryCategoryFile": {
      "properties": {
        "category": {
          "enum": [
            "web-analysis",
            "game-analysis",
            "android",
            "managed-code",
            "native-analysis",
            "dynamic-analysis",
            "firmware",
            "protocol-analysis",
            "reverse-engineering"
          ]
        },
        "kind": {
          "const": "repository-category"
        },
        "verification": {
          "const": "automated-readme-scan"
        }
      },
      "required": [
        "kind",
        "category",
        "verification",
        "repositories"
      ],
      "type": "object"
    },
    "resource": {
      "additionalProperties": false,
      "properties": {
        "added_at": {
          "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
          "type": "string"
        },
        "additional_evidence_urls": {
          "items": {
            "format": "uri",
            "pattern": "^https://",
            "type": "string"
          },
          "type": "array"
        },
        "category": {
          "enum": [
            "core",
            "workflow-guides",
            "official-case-studies",
            "community-integrations",
            "community-labs",
            "community-case-studies",
            "reconstruction-cases",
            "agent-mcp",
            "agent-workflows",
            "game-analysis",
            "web-analysis",
            "protocol-analysis",
            "native-analysis",
            "dynamic-analysis",
            "android",
            "dotnet",
            "jvm",
            "javascript-electron",
            "webassembly",
            "firmware",
            "binary-libraries",
            "binary-diffing",
            "learning",
            "related-lists"
          ]
        },
        "class": {
          "enum": [
            "software",
            "game",
            "apps",
            "website",
            "science",
            "hardware"
          ]
        },
        "description_en": {
          "minLength": 1,
          "type": "string"
        },
        "description_zh": {
          "minLength": 1,
          "type": "string"
        },
        "entry_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "entry_url_zh": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "evidence_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "group": {
          "minLength": 1,
          "type": "string"
        },
        "id": {
          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$",
          "type": "string"
        },
        "json_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "kind": {
          "enum": [
            "project",
            "tool",
            "integration",
            "case-study",
            "collection",
            "documentation",
            "learning-resource",
            "research"
          ]
        },
        "markdown_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "markdown_url_zh": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "name": {
          "minLength": 1,
          "type": "string"
        },
        "name_zh": {
          "minLength": 1,
          "type": "string"
        },
        "reconstruction_method": {
          "minLength": 1,
          "type": "string"
        },
        "record_type": {
          "const": "resource"
        },
        "relationship": {
          "enum": [
            "official-core",
            "official-skill",
            "official-documentation",
            "official-guide",
            "official-case-study",
            "community-integration",
            "community-learning-resource",
            "community-reported-mixed-workflow",
            "upstream-maintainer-companion-list",
            "independent-agent-integration",
            "independent-reconstruction",
            "foundation",
            "learning"
          ]
        },
        "requirement_facets": {
          "items": {
            "enum": [
              "prerequisites",
              "scope",
              "limits",
              "testing",
              "license",
              "attribution"
            ]
          },
          "type": "array"
        },
        "requirements": {
          "items": {
            "minLength": 1,
            "type": "string"
          },
          "type": "array"
        },
        "requirements_zh": {
          "items": {
            "minLength": 1,
            "type": "string"
          },
          "type": "array"
        },
        "targets": {
          "items": {
            "enum": [
              "website",
              "game",
              "app",
              "binary",
              "firmware",
              "protocol"
            ]
          },
          "minItems": 1,
          "type": "array"
        },
        "url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "verification": {
          "const": "source-reviewed"
        },
        "verified_at": {
          "anyOf": [
            {
              "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
              "type": "string"
            },
            {
              "format": "date-time",
              "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
              "type": "string"
            }
          ]
        }
      },
      "required": [
        "id",
        "record_type",
        "name",
        "name_zh",
        "url",
        "kind",
        "category",
        "relationship",
        "targets",
        "description_en",
        "description_zh",
        "requirements",
        "requirements_zh",
        "evidence_url",
        "added_at",
        "verified_at",
        "verification",
        "entry_url",
        "entry_url_zh",
        "markdown_url",
        "markdown_url_zh",
        "json_url"
      ],
      "type": "object"
    },
    "resourcesFile": {
      "additionalProperties": false,
      "properties": {
        "count": {
          "minimum": 0,
          "type": "integer"
        },
        "docs": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "generated_at": {
          "format": "date-time",
          "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})$",
          "type": "string"
        },
        "kind": {
          "const": "awesome-rea-resources"
        },
        "license": {
          "minLength": 1,
          "type": "string"
        },
        "note": {
          "minLength": 1,
          "type": "string"
        },
        "note_zh": {
          "minLength": 1,
          "type": "string"
        },
        "resources": {
          "items": {
            "$ref": "#/$defs/resource"
          },
          "type": "array"
        },
        "schema": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "site_url": {
          "format": "uri",
          "pattern": "^https://",
          "type": "string"
        },
        "version": {
          "pattern": "^1\\.\\d+\\.\\d+$",
          "type": "string"
        }
      },
      "required": [
        "version",
        "generated_at",
        "kind",
        "schema",
        "count",
        "resources"
      ],
      "type": "object"
    }
  },
  "$id": "https://awesomerea.org/api/v1/schema.json",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "description": "Schema of every JSON file under /api/v1/. Each file names its definition in its schema field.",
  "title": "Awesome REA static API v1"
}
