{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/hackforddata-com/json-schema/hackforddata-com-firm-detail-schema.json",
  "title": "FirmDetail",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/hackforddata-com-openapi.yml#/components/schemas/FirmDetail",
  "type": "object",
  "properties": {
    "core": {
      "$ref": "#/$defs/FirmCore"
    },
    "identifiers": {
      "$ref": "#/$defs/FirmIdentifiers"
    },
    "firm_type": {
      "$ref": "#/$defs/FirmType"
    },
    "authorities": {
      "$ref": "#/$defs/FirmAuthorities"
    },
    "links": {
      "$ref": "#/$defs/FirmLinks"
    },
    "meta": {
      "$ref": "#/$defs/FirmMeta"
    },
    "people_summary": {},
    "relationships_summary": {},
    "financials_summary": {},
    "sec_summary": {},
    "permissions_summary": {}
  },
  "required": [
    "authorities",
    "core",
    "firm_type",
    "identifiers",
    "links",
    "meta"
  ],
  "$defs": {
    "FirmAuthorities": {
      "type": "object",
      "properties": {
        "fca": {
          "$ref": "#/$defs/FirmAuthoritySection"
        },
        "sec": {
          "$ref": "#/$defs/FirmAuthoritySection"
        },
        "psd": {
          "$ref": "#/$defs/FirmAuthoritySection"
        },
        "esma": {
          "$ref": "#/$defs/FirmAuthoritySection"
        }
      },
      "required": [
        "esma",
        "fca",
        "psd",
        "sec"
      ]
    },
    "FirmAuthoritySection": {
      "type": "object",
      "properties": {
        "is_present": {
          "type": "boolean"
        },
        "is_entitled": {
          "type": "boolean"
        },
        "redacted": {
          "type": "boolean"
        },
        "data": {
          "nullable": true
        }
      },
      "required": [
        "data",
        "is_present"
      ]
    },
    "FirmCore": {
      "type": "object",
      "properties": {
        "adviser_bracket_as_of": {
          "type": [
            "string",
            "null"
          ],
          "format": "date"
        },
        "adviser_bracket": {
          "type": [
            "string",
            "null"
          ]
        },
        "adviser_bracket_is_estimated": {
          "type": "boolean"
        },
        "adviser_bracket_description": {
          "type": "string"
        },
        "hackford_id": {
          "type": "string"
        },
        "display_name": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "canonical_url": {
          "type": "string"
        },
        "status_normalised": {
          "type": [
            "string",
            "null"
          ]
        },
        "authority_keys": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "website": {
          "type": [
            "string",
            "null"
          ]
        },
        "country": {
          "type": [
            "string",
            "null"
          ]
        },
        "region": {
          "type": [
            "string",
            "null"
          ]
        },
        "city": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "required": [
        "authority_keys",
        "canonical_url",
        "city",
        "country",
        "display_name",
        "hackford_id",
        "region",
        "slug",
        "status_normalised",
        "website"
      ]
    },
    "FirmIdentifiers": {
      "type": "object",
      "properties": {
        "fca_frn": {
          "type": [
            "string",
            "null"
          ]
        },
        "sec_crd": {
          "type": [
            "string",
            "null"
          ]
        },
        "sec_file": {
          "type": [
            "string",
            "null"
          ]
        },
        "cik": {
          "type": [
            "string",
            "null"
          ]
        },
        "companies_house": {
          "type": [
            "string",
            "null"
          ]
        },
        "lei": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "FirmLinks": {
      "type": "object",
      "properties": {
        "canonical": {
          "type": "string"
        },
        "people": {
          "type": "string"
        },
        "relationships": {
          "type": "string"
        }
      },
      "required": [
        "canonical"
      ]
    },
    "FirmMeta": {
      "type": "object",
      "properties": {
        "source_coverage": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "last_refreshed": {
          "type": [
            "string",
            "null"
          ],
          "format": "date"
        },
        "limitations": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "required": [
        "last_refreshed",
        "limitations",
        "source_coverage"
      ]
    },
    "FirmType": {
      "type": "object",
      "properties": {
        "category": {
          "allOf": [
            {
              "$ref": "#/$defs/FirmTypeReference"
            }
          ],
          "nullable": true
        },
        "type": {
          "allOf": [
            {
              "$ref": "#/$defs/FirmTypeReference"
            }
          ],
          "nullable": true
        },
        "tags": {
          "$ref": "#/$defs/FirmTypeTags"
        }
      },
      "required": [
        "category",
        "tags",
        "type"
      ]
    },
    "FirmTypeReference": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string"
        },
        "display_name": {
          "type": "string"
        }
      },
      "required": [
        "code",
        "display_name"
      ]
    },
    "FirmTypeTag": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string"
        },
        "display_name": {
          "type": "string"
        }
      },
      "required": [
        "code",
        "display_name"
      ]
    },
    "FirmTypeTags": {
      "type": "object",
      "properties": {
        "technology": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/FirmTypeTag"
          }
        },
        "strategy": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/FirmTypeTag"
          }
        },
        "client_focus": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/FirmTypeTag"
          }
        },
        "service": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/FirmTypeTag"
          }
        }
      },
      "required": [
        "client_focus",
        "service",
        "strategy",
        "technology"
      ]
    }
  }
}