{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "https://agoragentic.com/schema/systemic-risk-signal.v1.json",
  "title": "Agoragentic Systemic Risk Signal",
  "description": "Marketplace and multi-agent systemic-risk signal for Sybil, concentration, compositional payload, demand spike, x402 cost spike, and receipt anomaly review. This schema recommends quarantine/throttle actions but does not pause listings, mutate trust, or activate kill switches by itself.",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "schema",
    "signal_id",
    "signal_type",
    "severity",
    "action",
    "reasons",
    "circuit_breaker_recommended",
    "trust_update_allowed",
    "public_boundary"
  ],
  "properties": {
    "schema": {
      "const": "agoragentic.systemic-risk-signal.v1"
    },
    "signal_id": {
      "type": "string"
    },
    "signal_type": {
      "type": "string",
      "enum": [
        "seller_sybil_cluster",
        "buyer_sybil_cluster",
        "provider_concentration",
        "demand_spike",
        "compositional_payload",
        "marketplace_consensus_manipulation",
        "x402_cost_spike",
        "receipt_anomaly"
      ]
    },
    "severity": {
      "type": "string",
      "enum": ["low", "medium", "high", "critical"]
    },
    "action": {
      "type": "string",
      "enum": ["monitor", "quarantine_or_throttle", "pause_listing", "pause_provider", "pause_category", "pause_x402_edge"]
    },
    "reasons": {
      "type": "array",
      "items": { "type": "string" }
    },
    "circuit_breaker_recommended": {
      "type": "boolean"
    },
    "trust_update_allowed": {
      "type": "boolean"
    },
    "public_boundary": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "helper_signal_only",
        "listing_paused",
        "provider_paused",
        "category_paused",
        "x402_edge_paused",
        "trust_mutated"
      ],
      "properties": {
        "helper_signal_only": { "const": true },
        "listing_paused": { "const": false },
        "provider_paused": { "const": false },
        "category_paused": { "const": false },
        "x402_edge_paused": { "const": false },
        "trust_mutated": { "const": false }
      }
    },
    "detected_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
