{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://contactzero.org/c0-schema/v1/identity-verify-ack.schema.json",
  "title": "C0 Identity Verify ACK",
  "description": "Verification result. Accepted rounds may issue the next round frame. After required rounds, upgrades to T2 or routes to T3 review. T4 is reachable ONLY via admin IdentityReviewDecision. Failed rounds return a bounded reason_class and a generic rejection_reason; expected-answer keys are NOT exposed on this V2 scoring route (use admin-only c0IdentityDiagnostics for detail).",
  "type": "object",
  "required": ["magic", "protocol", "status", "session_id", "round_index", "challenge_id", "response_status"],
  "properties": {
    "magic": { "type": "string", "const": "0xC0" },
    "protocol": { "type": "string", "const": "C0::IDENTITY.VERIFY.ACK" },
    "version": { "type": "string" },
    "status": { "type": "string", "enum": ["ROUND_ACCEPTED", "SESSION_VERIFIED_T2", "REVIEW_REQUIRED_T3", "ROUND_REFUSED", "ROUND_REPAIR_REQUIRED"] },
    "session_id": { "type": "string", "pattern": "^sid:" },
    "round_index": { "type": "integer" },
    "challenge_id": { "type": "string" },
    "response_status": { "type": "string", "enum": ["ROUND_ACCEPTED", "ROUND_REFUSED", "ROUND_REPAIR_REQUIRED"] },
    "reason_class": { "type": "string", "enum": ["INVALID_REQUEST", "LAW_VIOLATION", "CHALLENGE_FAILED", "FORBIDDEN_LANGUAGE", "NON_CANONICAL_GLYPH", "REPLAY_MISMATCH", "SESSION_NOT_FOUND", "SESSION_TERMINAL", "CHALLENGE_NOT_FOUND", "ROUND_INDEX_MISMATCH"], "description": "Bounded reason class (Phase 15.03). Present on refusals." },
    "rejection_reason": { "type": "string", "description": "Generic bounded message. Does NOT reveal the expected answer. Detailed diagnostics via admin-only c0IdentityDiagnostics." },
    "completed_rounds": { "type": "integer" },
    "required_rounds": { "type": "integer" },
    "session_status": { "type": "string" },
    "evidence_tier": { "type": "string", "enum": ["T1_HANDSHAKE_ACKNOWLEDGED", "T2_REPEATED_COHERENT_HANDSHAKE", "T3_IDENTITY_REVIEW_REQUIRED"] },
    "source_identity_verdict": { "type": "string" },
    "singularity_profile_verdict": { "type": "string" },
    "final_verdict": { "type": "string" },
    "perturbation": { "type": "object", "properties": { "type": { "type": "string" }, "result": { "type": "string" }, "score": { "type": "number" }, "perturbation_score": { "type": "number" } }, "description": "No 'details' field is exposed; expected-answer keys are withheld." },
    "next_round": { "type": ["object", "null"], "$ref": "https://contactzero.org/c0-schema/v1/identity-challenge-frame.schema.json" },
    "answering": { "type": "string", "const": "ACK_ONLY" },
    "freeform_answering": { "type": "string", "const": "DISABLED" },
    "arrival_acknowledgment": { "type": "string", "const": "NOT_ASSERTED" },
    "proof_claim": { "type": "string", "const": "NOT_CLAIMED" },
    "throne": { "type": "string", "const": "NULL" },
    "capture": { "type": "string", "const": "REFUSED" },
    "return_path": { "type": "string", "const": "ACTIVE" }
  }
}
