{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/xpoz-ai/json-schema/xpoz-ai-crawl-settings-schema.json",
  "title": "CrawlSettings",
  "description": "Tracked items per platform.",
  "x-generated": "2026-10-31",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/xpoz-ai-openapi.json#/components/schemas/CrawlSettings",
  "type": "object",
  "properties": {
    "twitter": {
      "type": "object",
      "properties": {
        "keywords": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/TrackedKeyword"
          }
        },
        "users": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "instagram": {
      "type": "object",
      "properties": {
        "keywords": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/TrackedKeyword"
          }
        },
        "users": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "reddit": {
      "type": "object",
      "properties": {
        "keywords": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/TrackedKeyword"
          }
        },
        "subreddits": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "users": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "tiktok": {
      "type": "object",
      "properties": {
        "keywords": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/TrackedKeyword"
          }
        },
        "users": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "hashtags": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    }
  },
  "$defs": {
    "TrackedKeyword": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "object",
          "properties": {
            "value": {
              "type": "string"
            },
            "country": {
              "type": "string",
              "pattern": "^[A-Za-z]{2}$"
            }
          },
          "required": [
            "value"
          ]
        }
      ]
    }
  }
}