{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/chadwin/json-schema/chadwin-company-search-response-schema.json",
  "title": "CompanySearchResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/chadwin-companies-api-openapi.yml#/components/schemas/CompanySearchResponse",
  "type": "object",
  "properties": {
    "companies": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/CompanySearchResult"
      },
      "maxItems": 25
    }
  },
  "required": [
    "companies"
  ],
  "$defs": {
    "CompanySearchResult": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "Company display name."
        },
        "cik": {
          "type": "string",
          "minLength": 10,
          "maxLength": 10,
          "description": "Zero-padded SEC Central Index Key."
        },
        "website_url": {
          "type": [
            "string",
            "null"
          ],
          "description": "Company main website URL, or null when unknown."
        },
        "ir_website_url": {
          "type": [
            "string",
            "null"
          ],
          "description": "Company investor-relations website URL, or null when unknown."
        },
        "fiscal_year_end": {
          "type": [
            "string",
            "null"
          ],
          "minLength": 4,
          "maxLength": 4,
          "description": "Stored fiscal year end in MMDD form, or null."
        },
        "sic": {
          "type": [
            "object",
            "null"
          ],
          "properties": {
            "code": {
              "type": "string"
            },
            "office": {
              "type": "string"
            },
            "industry_title": {
              "type": "string"
            }
          },
          "required": [
            "code",
            "office",
            "industry_title"
          ]
        },
        "listings": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "ticker": {
                "type": "string"
              },
              "exchange": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Source exchange label."
              },
              "share_class_figi": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "ticker",
              "exchange",
              "share_class_figi"
            ]
          },
          "description": "All stored ticker and exchange associations for this CIK, including historical associations. May be empty; does not establish currentness or effective dates."
        }
      },
      "required": [
        "name",
        "cik",
        "website_url",
        "ir_website_url",
        "fiscal_year_end",
        "sic",
        "listings"
      ]
    }
  }
}