TenantAtlas/specs/074-verification-checklist/contracts/verification-report.schema.json
2026-02-04 00:57:26 +01:00

129 lines
3.5 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://tenantpilot.local/contracts/verification-report.schema.json",
"title": "VerificationReport",
"type": "object",
"additionalProperties": false,
"required": [
"schema_version",
"flow",
"generated_at",
"summary",
"checks"
],
"properties": {
"schema_version": {
"type": "string",
"description": "Version of the verification report schema (SemVer)."
},
"flow": {
"type": "string",
"description": "Verification flow identifier (v1 aligns with OperationRun.type)."
},
"generated_at": {
"type": "string",
"format": "date-time"
},
"identity": {
"type": "object",
"description": "Scope identifiers for what is being verified.",
"additionalProperties": true
},
"summary": {
"type": "object",
"additionalProperties": false,
"required": ["overall", "counts"],
"properties": {
"overall": {
"type": "string",
"enum": ["ready", "needs_attention", "blocked", "running"],
"description": "Overall state derived from check results."
},
"counts": {
"type": "object",
"additionalProperties": false,
"required": ["total", "pass", "fail", "warn", "skip", "running"],
"properties": {
"total": {"type": "integer", "minimum": 0},
"pass": {"type": "integer", "minimum": 0},
"fail": {"type": "integer", "minimum": 0},
"warn": {"type": "integer", "minimum": 0},
"skip": {"type": "integer", "minimum": 0},
"running": {"type": "integer", "minimum": 0}
}
}
}
},
"checks": {
"type": "array",
"minItems": 0,
"items": {"$ref": "#/$defs/CheckResult"}
}
},
"$defs": {
"CheckResult": {
"type": "object",
"additionalProperties": false,
"required": [
"key",
"title",
"status",
"severity",
"blocking",
"reason_code",
"message",
"evidence",
"next_steps"
],
"properties": {
"key": {"type": "string"},
"title": {"type": "string"},
"status": {
"type": "string",
"enum": ["pass", "fail", "warn", "skip", "running"]
},
"severity": {
"type": "string",
"enum": ["info", "low", "medium", "high", "critical"]
},
"blocking": {"type": "boolean"},
"reason_code": {"type": "string"},
"message": {"type": "string"},
"evidence": {
"type": "array",
"items": {"$ref": "#/$defs/EvidencePointer"}
},
"next_steps": {
"type": "array",
"description": "Navigation-only CTAs (links) in v1.",
"items": {"$ref": "#/$defs/NextStep"}
}
}
},
"EvidencePointer": {
"type": "object",
"additionalProperties": false,
"required": ["kind", "value"],
"properties": {
"kind": {"type": "string"},
"value": {
"description": "Safe pointer value (ID/masked string/hash).",
"oneOf": [
{"type": "integer"},
{"type": "string"}
]
}
}
},
"NextStep": {
"type": "object",
"additionalProperties": false,
"required": ["label", "url"],
"properties": {
"label": {"type": "string"},
"url": {"type": "string"}
}
}
}
}