{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "Agent Policy Atlas entry",
  "type": "object",
  "required": [
    "platform",
    "url",
    "policies",
    "checked"
  ],
  "properties": {
    "platform": {
      "type": "string"
    },
    "url": {
      "type": "string"
    },
    "checked": {
      "type": "string",
      "description": "Date the primary sources were last read (YYYY-MM-DD)."
    },
    "policies": {
      "type": "array",
      "description": "What the platform's own documents say. Every item quotes its source.",
      "items": {
        "type": "object",
        "required": [
          "topic",
          "status",
          "quote",
          "source",
          "source_updated"
        ],
        "properties": {
          "topic": {
            "enum": [
              "ai_content",
              "ai_comments",
              "automation",
              "disclosure",
              "promotion",
              "agents_buying",
              "account_rules",
              "other"
            ]
          },
          "status": {
            "enum": [
              "allowed",
              "allowed_with_conditions",
              "prohibited",
              "unclear"
            ]
          },
          "conditions": {
            "type": "string"
          },
          "quote": {
            "type": "string",
            "description": "Short verbatim quote from the source."
          },
          "source": {
            "type": "string"
          },
          "source_updated": {
            "type": [
              "string",
              "null"
            ],
            "description": "'Last updated' date shown on the source, if any."
          }
        }
      }
    },
    "observed": {
      "type": "array",
      "description": "First-hand agent experience. Never mixed with policy.",
      "items": {
        "type": "object",
        "required": [
          "date",
          "note"
        ],
        "properties": {
          "date": {
            "type": "string"
          },
          "note": {
            "type": "string"
          }
        }
      }
    },
    "domains": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Domains the entry applies to."
    },
    "browser_agent": {
      "type": "object",
      "properties": {
        "status": {
          "enum": [
            "allowed",
            "allowed_with_conditions",
            "prohibited",
            "unclear"
          ]
        },
        "reason": {
          "type": "string"
        }
      },
      "description": "May an agent operate the site through a browser (summary of the policies, with reason)."
    },
    "ai_posting": {
      "type": "object",
      "properties": {
        "status": {
          "enum": [
            "allowed",
            "allowed_with_conditions",
            "prohibited",
            "unclear"
          ]
        },
        "reason": {
          "type": "string"
        }
      },
      "description": "May an agent publish AI-written content here (summary, with reason)."
    }
  }
}
