{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/layercall-com/json-schema/layercall-com-domain-result-schema.json",
  "title": "DomainResult",
  "x-generated": "2026-10-31",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/layercall-com-openapi.json#/components/schemas/DomainResult",
  "type": "object",
  "required": [
    "domain",
    "risk_score",
    "verdict"
  ],
  "properties": {
    "domain": {
      "type": "string"
    },
    "risk_score": {
      "$ref": "#/$defs/RiskScore"
    },
    "verdict": {
      "$ref": "#/$defs/Verdict"
    },
    "signals": {
      "type": "object",
      "properties": {
        "resolves": {
          "type": "boolean"
        },
        "mx_found": {
          "type": "boolean"
        },
        "has_spf": {
          "type": "boolean"
        },
        "has_dmarc": {
          "type": "boolean"
        },
        "is_disposable": {
          "type": "boolean"
        },
        "is_homograph": {
          "type": "boolean"
        },
        "is_free_provider": {
          "type": "boolean"
        },
        "is_risky_tld": {
          "type": "boolean"
        },
        "newly_registered": {
          "type": [
            "boolean",
            "null"
          ],
          "description": "Registered less than 30 days ago. null means the registration date could not be determined (RDAP unreachable, or the TLD publishes no RDAP) — it does NOT mean the domain is established. Treat null as unknown, not as a negative finding."
        }
      }
    },
    "registration": {
      "type": "object",
      "properties": {
        "created_at": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time"
        }
      }
    },
    "cached": {
      "type": "boolean"
    },
    "request_id": {
      "type": "string"
    },
    "signals_unavailable": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Signals that could not be measured on this request — e.g. [\"tor\", \"vpn_providers\"]. Absent entirely when every feed answered, so the happy-path shape is unchanged. Present means the score was built on incomplete data: a \"clean\" answer and a \"we could not check\" answer are otherwise identical."
    },
    "processing_time_sec": {
      "type": "number"
    },
    "first_seen": {
      "nullable": true
    },
    "times_seen": {
      "type": "integer"
    },
    "abuse_reports": {
      "type": "integer"
    },
    "billable_lookups": {
      "type": "integer"
    }
  },
  "$defs": {
    "RiskScore": {
      "type": "integer",
      "minimum": 0,
      "maximum": 100,
      "description": "0 = clean, 100 = certain fraud."
    },
    "Verdict": {
      "type": "string",
      "enum": [
        "allow",
        "review",
        "block"
      ],
      "description": "Recommended action. Thresholds move with `strictness`."
    }
  }
}