{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/rentseek-ing/json-schema/rentseek-ing-change-feed-response-schema.json",
  "title": "ChangeFeedResponse",
  "x-generated": "2026-11-23",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/rentseek-ing-openapi.yml#/components/schemas/ChangeFeedResponse",
  "type": "object",
  "properties": {
    "changes": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/ChangeEvent"
      }
    },
    "tickers": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "not_found_tickers": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "since": {
      "type": "string"
    },
    "thresholds": {
      "$ref": "#/$defs/ChangeThresholds"
    },
    "classification": {
      "type": "string",
      "enum": [
        "material",
        "all"
      ]
    },
    "pagination": {
      "$ref": "#/$defs/ChangePagination"
    },
    "limitations": {
      "type": "array",
      "items": {
        "type": "string"
      }
    }
  },
  "required": [
    "changes",
    "tickers",
    "not_found_tickers",
    "since",
    "thresholds",
    "classification",
    "pagination",
    "limitations"
  ],
  "$defs": {
    "ChangeEvent": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "pattern": "^chg_[a-z0-9.-]+_[0-9a-f]{16,}$"
        },
        "type": {
          "type": "string",
          "enum": [
            "executive.added",
            "executive.removed",
            "peo.changed",
            "compensation.total.changed",
            "compensation.component.changed",
            "pay_ratio.changed",
            "fiscal_year.advanced",
            "source.amended"
          ]
        },
        "classification": {
          "type": "string",
          "enum": [
            "informational",
            "material"
          ]
        },
        "ticker": {
          "type": "string"
        },
        "company_name": {
          "type": "string"
        },
        "occurred_at": {
          "type": "string"
        },
        "fiscal_year": {
          "type": "integer"
        },
        "executive_id": {
          "type": [
            "string",
            "null"
          ]
        },
        "executive_name": {
          "type": [
            "string",
            "null"
          ]
        },
        "component": {
          "type": [
            "string",
            "null"
          ]
        },
        "before_value": {
          "nullable": true,
          "oneOf": [
            {
              "type": "string"
            },
            {
              "type": "number"
            }
          ]
        },
        "after_value": {
          "nullable": true,
          "oneOf": [
            {
              "type": "string"
            },
            {
              "type": "number"
            }
          ]
        },
        "before_label": {
          "type": [
            "string",
            "null"
          ]
        },
        "after_label": {
          "type": [
            "string",
            "null"
          ]
        },
        "absolute_change": {
          "type": [
            "number",
            "null"
          ]
        },
        "percentage_change": {
          "type": [
            "number",
            "null"
          ]
        },
        "before_artifact_id": {
          "type": "string"
        },
        "after_artifact_id": {
          "type": "string"
        },
        "before_source": {
          "$ref": "#/$defs/ChangeSource"
        },
        "after_source": {
          "$ref": "#/$defs/ChangeSource"
        },
        "methodology_version": {
          "type": "string",
          "enum": [
            "comp-change/v1"
          ]
        }
      },
      "required": [
        "id",
        "type",
        "classification",
        "ticker",
        "company_name",
        "occurred_at",
        "fiscal_year",
        "executive_id",
        "executive_name",
        "component",
        "before_value",
        "after_value",
        "before_label",
        "after_label",
        "absolute_change",
        "percentage_change",
        "before_artifact_id",
        "after_artifact_id",
        "before_source",
        "after_source",
        "methodology_version"
      ]
    },
    "ChangePagination": {
      "type": "object",
      "properties": {
        "page_size": {
          "type": "integer"
        },
        "has_more": {
          "type": "boolean"
        },
        "next_cursor": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "required": [
        "page_size",
        "has_more",
        "next_cursor"
      ]
    },
    "ChangeSource": {
      "type": "object",
      "properties": {
        "accession": {
          "type": "string"
        },
        "filing_date": {
          "type": "string"
        },
        "filing_url": {
          "type": "string",
          "format": "uri"
        }
      },
      "required": [
        "accession",
        "filing_date",
        "filing_url"
      ]
    },
    "ChangeThresholds": {
      "type": "object",
      "properties": {
        "total_compensation_pct": {
          "type": "number"
        },
        "component_pct": {
          "type": "number"
        }
      },
      "required": [
        "total_compensation_pct",
        "component_pct"
      ]
    }
  }
}