Files
libretro/schemas/database.schema.json
T
Abdessamad Derraz 13a10da993 fix: serve the dump a name's hashes prove
dsi_bios7.bin and dsi_bios9.bin hold the DSi Panda devkit boot ROMs, eMMC
key-Y zeroed. Every md5 and crc32 declared under those names designates
a retail dump in the same directory, yet hashless entries (RetroBat,
dsperate) got the devkit ROMs by name. by_proven_name maps such a name to
the proven primaries beside it. kick13.rom, dsi_firmware.bin and
spectrum.zip follow the same rule.
2026-11-06 15:00:28 +01:00

149 lines
3.2 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://abdess.github.io/retrobios/api/v1/schemas/database.schema.json",
"title": "RetroBIOS content database",
"type": "object",
"additionalProperties": false,
"required": [
"schema_version",
"generated_at",
"total_files",
"total_size",
"files",
"indexes"
],
"properties": {
"schema_version": {
"const": 1
},
"generated_at": {
"type": "string",
"format": "date-time"
},
"total_files": {
"type": "integer",
"minimum": 0
},
"total_size": {
"type": "integer",
"minimum": 0
},
"bios_dir": {
"type": "string",
"description": "Directory the files were scanned from; _mame_clones.json sits beside it."
},
"files": {
"type": "object",
"propertyNames": {
"pattern": "^[a-f0-9]{40}$"
},
"additionalProperties": {
"type": "object",
"additionalProperties": false,
"required": [
"path",
"name",
"size",
"sha1",
"md5",
"sha256",
"crc32",
"adler32"
],
"properties": {
"path": {
"type": "string",
"minLength": 1
},
"name": {
"type": "string",
"minLength": 1
},
"size": {
"type": "integer",
"minimum": 0
},
"sha1": {
"type": "string",
"pattern": "^[a-f0-9]{40}$"
},
"md5": {
"type": "string",
"pattern": "^[a-f0-9]{32}$"
},
"sha256": {
"type": "string",
"pattern": "^[a-f0-9]{64}$"
},
"crc32": {
"type": "string",
"pattern": "^[a-f0-9]{8}$"
},
"adler32": {
"type": "string",
"pattern": "^[a-f0-9]{8}$"
},
"provenance": {
"type": "object"
}
}
}
},
"indexes": {
"type": "object",
"additionalProperties": false,
"required": [
"by_md5",
"by_name",
"by_crc32",
"by_sha256",
"by_path_suffix"
],
"properties": {
"by_md5": {
"$ref": "#/$defs/hashIndex"
},
"by_crc32": {
"$ref": "#/$defs/hashIndex"
},
"by_sha256": {
"$ref": "#/$defs/hashIndex"
},
"by_name": {
"$ref": "#/$defs/listIndex"
},
"by_path_suffix": {
"$ref": "#/$defs/listIndex"
},
"by_shadowed_alias": {
"$ref": "#/$defs/listIndex"
},
"by_proven_name": {
"$ref": "#/$defs/listIndex"
}
}
}
},
"$defs": {
"hashIndex": {
"type": "object",
"additionalProperties": {
"type": "string",
"pattern": "^[a-f0-9]{40}$"
}
},
"listIndex": {
"type": "object",
"additionalProperties": {
"type": "array",
"items": {
"type": "string",
"pattern": "^[a-f0-9]{40}$"
},
"minItems": 1,
"uniqueItems": true
}
}
}
}