{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/stonewake-ai/json-schema/stonewake-ai-v1-node-detail-out-schema.json",
  "title": "V1NodeDetailOut",
  "description": "One node with its identifiers and every current register record as a citation, newest first, and each register's count. A branch also names its head office.",
  "x-generated": "2026-11-26",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/stonewake-ai-openapi.json#/components/schemas/V1NodeDetailOut",
  "properties": {
    "node_id": {
      "type": "integer",
      "title": "Node Id",
      "description": "The node's id, which every /v1/nodes route speaks."
    },
    "node_type": {
      "type": "string",
      "title": "Node Type",
      "description": "company or person."
    },
    "label": {
      "type": "string",
      "title": "Label",
      "description": "The node's name."
    },
    "country_iso3": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Country Iso3",
      "description": "The node's country as an ISO 3166 alpha 3 code, null when unknown."
    },
    "jurisdiction": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Jurisdiction",
      "description": "The register jurisdiction as the register codes it, for example GB-EAW or DE-BY, null when unknown."
    },
    "jurisdiction_label": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Jurisdiction Label",
      "description": "The jurisdiction in English words, for example England and Wales or Bayern, Germany, never the code, null when unknown."
    },
    "legal_form": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Legal Form",
      "description": "The legal form as the register codes it, null when none is stated."
    },
    "legal_form_label": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Legal Form Label",
      "description": "The legal form in words, null when none is stated."
    },
    "company_status": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Company Status",
      "description": "The company's register status as one code of a closed list, the same on every node whatever register states it, namely active, active_proposal_to_strike_off, active_receiver_manager, registered, open, in_liquidation, in_administration, administration_order, in_administration_administrative_receiver, in_administration_receiver_manager, administrative_receiver, receiver_manager_administrative_receiver, receivership, voluntary_arrangement, voluntary_arrangement_administrative_receiver, voluntary_arrangement_receiver_manager, insolvency_proceedings, in_bankruptcy, inactive, dissolved, deleted, converted_closed, closed or unknown, unknown for a wording the list does not name, null when no register states a status."
    },
    "company_status_label": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Company Status Label",
      "description": "The status in English words, the register's own words for unknown, null when no register states a status."
    },
    "company_status_source": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Company Status Source",
      "description": "The register's own words for the status, whole, for example ACTIVE from GLEIF or aktuell from the Handelsregister, null when no register states a status."
    },
    "company_status_current": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "null"
        }
      ],
      "title": "Company Status Current",
      "description": "True when company_status states a company still current on its register, namely active, active_proposal_to_strike_off, active_receiver_manager, open or registered, false for every other code, unknown included, and false whenever company_status_confirmed is false, null when no register states a status."
    },
    "company_status_confirmed": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "null"
        }
      ],
      "title": "Company Status Confirmed",
      "description": "False when only a source that is no longer current states a current status, an LEI record whose registration status is not ISSUED, PENDING_TRANSFER or PENDING_ARCHIVAL, so the status is a past statement and company_status_label says whose and since when; true when a current source states it and for a code that is not current, which stands whatever its source, null when no register states a status."
    },
    "registration_status": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Registration Status",
      "description": "The status of the registration itself, such as an LEI's, null when none is stated."
    },
    "stale": {
      "type": "boolean",
      "title": "Stale",
      "description": "True when the registration has lapsed, so the record is no longer current."
    },
    "branch": {
      "type": "boolean",
      "title": "Branch",
      "description": "True for a branch, which carries its head office's legal name and the branch's host country."
    },
    "identifiers": {
      "items": {
        "$ref": "#/$defs/V1IdentifierOut"
      },
      "type": "array",
      "title": "Identifiers",
      "description": "The node's register identifiers, at most 200."
    },
    "identifiers_total": {
      "type": "integer",
      "title": "Identifiers Total",
      "description": "How many identifiers the node holds."
    },
    "identifiers_truncated": {
      "type": "boolean",
      "title": "Identifiers Truncated",
      "description": "True when identifiers was cut at 200."
    },
    "records": {
      "items": {
        "$ref": "#/$defs/RecordSummaryOut"
      },
      "type": "array",
      "title": "Records",
      "description": "Every current register record of the node as a citation, newest first."
    },
    "records_total": {
      "type": "integer",
      "title": "Records Total",
      "description": "How many records the node holds, the length of records."
    },
    "registers": {
      "items": {
        "$ref": "#/$defs/V1RegisterRecordsOut"
      },
      "type": "array",
      "title": "Registers",
      "description": "Each register's count of records, the register with the newest record first."
    },
    "branch_of_label": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Branch Of Label",
      "description": "The head office's name for a branch, null otherwise."
    },
    "merged_into": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Merged Into",
      "description": "The node this record was joined into, another node of the same company that holds its identifiers, records and events now, null for a node that stands on its own."
    }
  },
  "type": "object",
  "required": [
    "node_id",
    "node_type",
    "label",
    "country_iso3",
    "jurisdiction",
    "legal_form",
    "company_status",
    "registration_status",
    "stale",
    "branch",
    "identifiers",
    "identifiers_total",
    "identifiers_truncated",
    "records",
    "records_total",
    "registers",
    "branch_of_label"
  ],
  "$defs": {
    "RecordSummaryOut": {
      "properties": {
        "record_id": {
          "type": "integer",
          "title": "Record Id",
          "description": "The record's id, as POST /v1/citations/resolve takes it."
        },
        "connector_id": {
          "type": "string",
          "title": "Connector Id",
          "description": "The source the record was read from, such as handelsregister_de for the German commercial register. The records route takes it as connector_id."
        },
        "register": {
          "type": "string",
          "title": "Register",
          "description": "The register's name in words."
        },
        "record_type": {
          "type": "string",
          "title": "Record Type",
          "description": "The kind of record within its register."
        },
        "external_id": {
          "type": "string",
          "title": "External Id",
          "description": "The record's own id in its register."
        },
        "source_url": {
          "type": "string",
          "title": "Source Url",
          "description": "The register's address for the record, the evidence a reader opens."
        },
        "retrieved_at": {
          "type": "string",
          "format": "date-time",
          "title": "Retrieved At",
          "description": "When the record was first read."
        },
        "as_of": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time"
            },
            {
              "type": "null"
            }
          ],
          "title": "As Of",
          "description": "The date the register states the record for, null when it states none."
        },
        "verify_status": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Verify Status",
          "description": "The outcome of the latest check of the record against its source, ok, gone or unreadable, null when no check has been recorded."
        },
        "locator": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Locator",
          "description": "The coordinates to search the record by, as text, where source_url can only open a search form, null where the link opens the record."
        },
        "notice": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Notice",
          "description": "A text to show with the record wherever it is displayed or quoted onward, null for every source whose terms require none."
        },
        "deep_link": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Deep Link",
          "description": "The dashboard path that opens the register's own page for a FIRDS instrument record, whose register keeps no link per record, null for every other record."
        }
      },
      "type": "object",
      "required": [
        "record_id",
        "connector_id",
        "register",
        "record_type",
        "external_id",
        "source_url",
        "retrieved_at",
        "as_of",
        "verify_status"
      ],
      "title": "RecordSummaryOut",
      "description": "A record as citation, never as payload: the register link is the evidence."
    },
    "V1IdentifierOut": {
      "properties": {
        "scheme": {
          "type": "string",
          "title": "Scheme",
          "description": "The identifier's scheme, for example lei for a Legal Entity Identifier, or ra_ra and six digits for a registration authority number GLEIF states, such as ra_ra000406."
        },
        "value": {
          "type": "string",
          "title": "Value",
          "description": "The identifier as the register states it."
        }
      },
      "type": "object",
      "required": [
        "scheme",
        "value"
      ],
      "title": "V1IdentifierOut",
      "description": "One register identifier: the citation-grade identity anchor."
    },
    "V1RegisterRecordsOut": {
      "properties": {
        "connector_id": {
          "type": "string",
          "title": "Connector Id",
          "description": "The register's source id, as the records route takes it."
        },
        "register": {
          "type": "string",
          "title": "Register",
          "description": "The register's name in words."
        },
        "records_total": {
          "type": "integer",
          "title": "Records Total",
          "description": "How many of the node's records come from this register."
        }
      },
      "type": "object",
      "required": [
        "connector_id",
        "register",
        "records_total"
      ],
      "title": "V1RegisterRecordsOut",
      "description": "One register's current records on the node: the exact count of its rows in\n`records`. GET /v1/nodes/{node_id}/records pages the register alone."
    }
  }
}