{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/snitcher/json-schema/snitcher-organisation-organisation-schema.json",
  "title": "Organisation_Organisation",
  "x-generated": "2026-11-16",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/snitcher-openapi.yml#/components/schemas/Organisation_Organisation",
  "required": [
    "uuid",
    "name",
    "website",
    "first_seen",
    "last_seen",
    "profiles",
    "tags",
    "segments"
  ],
  "properties": {
    "uuid": {
      "type": "string",
      "format": "uuid"
    },
    "unique_visitor_count": {
      "description": "Unique tracked visitors currently attributed to this company in this workspace. Counts non-merged identities, independent of date filters and tracking-event retention. Hiding a visitor does not remove its attribution.",
      "type": "integer",
      "minimum": 0
    },
    "name": {
      "type": "string"
    },
    "website": {
      "type": "string"
    },
    "first_seen": {
      "type": "string",
      "format": "date-time"
    },
    "last_seen": {
      "type": "string",
      "format": "date-time"
    },
    "logo": {
      "type": [
        "string",
        "null"
      ]
    },
    "address": {
      "$ref": "#/$defs/Value_Address"
    },
    "founded": {
      "type": [
        "number",
        "null"
      ]
    },
    "size": {
      "$ref": "#/$defs/Organisation_EmployeeRange"
    },
    "industry": {
      "type": [
        "string",
        "null"
      ]
    },
    "phone": {
      "type": [
        "string",
        "null"
      ]
    },
    "email": {
      "type": [
        "string",
        "null"
      ]
    },
    "profiles": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Organisation_SocialProfile"
      }
    },
    "tags": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "segments": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Organisation_Segment"
      }
    },
    "total_pageviews": {
      "type": [
        "integer",
        "null"
      ]
    },
    "total_time_on_site": {
      "type": [
        "string",
        "null"
      ]
    },
    "visitor_locations": {
      "type": "array",
      "items": {
        "type": "string"
      }
    }
  },
  "type": "object",
  "$defs": {
    "Organisation_EmployeeRange": {
      "type": "string",
      "enum": [
        "1-10 employees",
        "11-50 employees",
        "51-200 employees",
        "201-500 employees",
        "501-1000 employees",
        "1001-5000 employees",
        "5001-10,000 employees",
        "10,001+ employees"
      ]
    },
    "Organisation_Segment": {
      "required": [
        "uuid",
        "name"
      ],
      "properties": {
        "uuid": {
          "type": "string",
          "format": "uuid"
        },
        "name": {
          "type": "string"
        }
      },
      "type": "object"
    },
    "Organisation_SocialProfile": {
      "required": [
        "name"
      ],
      "properties": {
        "name": {
          "type": "string"
        },
        "handle": {
          "type": [
            "string",
            "null"
          ]
        },
        "url": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "type": "object"
    },
    "Value_Address": {
      "required": [
        "street",
        "address",
        "full_address",
        "city",
        "state"
      ],
      "properties": {
        "street": {
          "type": "string"
        },
        "street_number": {
          "type": [
            "string",
            "null"
          ]
        },
        "postal_code": {
          "type": [
            "string",
            "null"
          ]
        },
        "address": {
          "type": "string"
        },
        "full_address": {
          "type": "string"
        },
        "city": {
          "type": "string"
        },
        "state": {
          "type": "string"
        },
        "country": {
          "type": [
            "string",
            "null"
          ]
        },
        "latitude": {
          "type": [
            "number",
            "null"
          ]
        },
        "longitude": {
          "type": [
            "number",
            "null"
          ]
        }
      },
      "type": "object"
    }
  }
}