{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://abdess.github.io/retrobios/api/v1/schemas/target-manifest.schema.json",
  "title": "RetroBIOS hardware target manifest",
  "description": "Per-target core availability. A null core list means the target publishes no inventory: a known target with no filter, not an absent one.",
  "type": "object",
  "additionalProperties": {
    "oneOf": [
      { "type": "null" },
      { "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true },
      {
        "type": "object",
        "additionalProperties": false,
        "required": ["cores"],
        "properties": {
          "cores": { "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true },
          "images": {
            "description": "The image names the target builds, as a card's board file writes them (boot/batocera.board, boot/knulli.board).",
            "type": "array", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true
          }
        }
      }
    ]
  }
}
