Files
JWeBot/config/schemas/debug-event.schema.json
T

43 lines
1.1 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://jwebot.example/schemas/debug-event.schema.json",
"title": "JWeBot privacy-safe debug event",
"type": "object",
"additionalProperties": false,
"required": ["version", "timestamp", "name", "status"],
"properties": {
"version": {"const": 1},
"timestamp": {"type": "string", "format": "date-time"},
"name": {
"type": "string",
"pattern": "^[a-z0-9_.-]{1,120}$"
},
"status": {
"enum": ["ok", "error", "timeout", "skipped", "uncertain"]
},
"elapsed_ms": {
"type": "number",
"minimum": 0
},
"event_hash": {
"type": "string",
"pattern": "^[a-f0-9]{0,64}$"
},
"group_hash": {
"type": "string",
"pattern": "^[a-f0-9]{0,64}$"
},
"error_class": {
"type": "string",
"pattern": "^[A-Za-z0-9_.-]{0,120}$"
},
"fields": {
"type": "object",
"maxProperties": 32,
"additionalProperties": {
"type": ["string", "number", "integer", "boolean", "null"]
}
}
}
}