{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/gainsight/main/json-schema/gainsight-custom-event-2-schema.json",
  "title": "CustomEvent",
  "description": "Custom Event object",
  "x-generated": "2026-10-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/gainsight-custom-events-api-openapi.yml#/components/schemas/CustomEvent_2",
  "type": "object",
  "required": [
    "eventName",
    "identifyId",
    "propertyKey",
    "userType"
  ],
  "properties": {
    "eventId": {
      "type": "string"
    },
    "identifyId": {
      "type": "string"
    },
    "propertyKey": {
      "type": "string"
    },
    "date": {
      "type": "integer",
      "format": "int64"
    },
    "eventType": {
      "type": "string"
    },
    "sessionId": {
      "type": "string"
    },
    "userType": {
      "type": "string",
      "enum": [
        "LEAD",
        "USER",
        "VISITOR",
        "EMPTY_USER_TYPE"
      ]
    },
    "accountId": {
      "type": "string"
    },
    "globalContext": {
      "type": "object"
    },
    "eventName": {
      "type": "string"
    },
    "attributes": {
      "type": "object"
    },
    "url": {
      "type": "string"
    },
    "referrer": {
      "type": "string"
    },
    "remoteHost": {
      "type": "string"
    }
  }
}