{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/evictionsapi-com/json-schema/evictionsapi-com-managed-facts-schema.json",
  "title": "ManagedFacts",
  "x-generated": "2026-10-30",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/_original/evictionsapi-com-openapi-openapi.json#/components/schemas/ManagedFacts",
  "type": "object",
  "required": [
    "action",
    "declared",
    "declaredAt",
    "problem",
    "missing",
    "sources",
    "note"
  ],
  "properties": {
    "action": {
      "type": "string",
      "description": "The proposed act the answer is about."
    },
    "declared": {
      "type": "boolean",
      "description": "Whether the customer declared these facts, and not only a suggestion."
    },
    "declaredAt": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "When the customer declared them last."
    },
    "problem": {
      "type": [
        "string",
        "null"
      ],
      "description": "Why the stored facts do not read as a complete declaration."
    },
    "missing": {
      "type": "array",
      "description": "The facts this act is missing, each with the question to ask. An empty list is not permission to perform the act.",
      "items": {
        "type": "object",
        "required": [
          "key",
          "question"
        ],
        "properties": {
          "key": {
            "type": "string"
          },
          "question": {
            "type": "string"
          }
        }
      }
    },
    "sources": {
      "type": "object",
      "description": "Where each declared fact came from: the source of the last write that set it, `customer` or `suggestion`. A fact that is absent was never declared by anyone.",
      "additionalProperties": {
        "type": "string",
        "enum": [
          "customer",
          "suggestion"
        ]
      }
    },
    "note": {
      "type": "string"
    }
  }
}