{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/passage-data-com/json-schema/passage-data-com-check-values-schema.json",
  "title": "CheckValues",
  "x-generated": "2026-11-20",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/passage-data-com-openapi.json#/components/schemas/CheckValues",
  "type": "object",
  "properties": {
    "query": {
      "type": "object"
    },
    "searched": {
      "type": "object",
      "properties": {
        "places": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "parameters": {
          "type": "object",
          "description": "Each parameter as typed: how it was matched (parameter_keys, names_matched, match)."
        }
      }
    },
    "summary": {
      "type": "object",
      "properties": {
        "rows": {
          "type": "integer"
        },
        "over": {
          "type": "integer"
        },
        "under": {
          "type": "integer"
        },
        "within": {
          "type": "integer"
        },
        "not_comparable": {
          "type": "integer"
        },
        "refused": {
          "type": "integer"
        },
        "refused_by": {
          "type": "object",
          "additionalProperties": {
            "type": "integer"
          }
        },
        "says": {
          "type": "string"
        }
      }
    },
    "reads_as": {
      "type": "string"
    },
    "packed_as": {
      "type": "string"
    },
    "sources_searched": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "When a row is rows.none_held: the instruments searched for this place and medium, once."
    },
    "limits": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Row"
      }
    },
    "results": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "index": {
            "type": "integer"
          },
          "outcome": {
            "type": "string",
            "enum": [
              "over",
              "under",
              "within",
              "not_comparable",
              "refused"
            ]
          },
          "query": {
            "type": "object"
          },
          "value": {
            "type": "object"
          },
          "counts": {
            "type": "object"
          },
          "not_comparable_by": {
            "type": "object"
          },
          "says": {
            "type": "string"
          },
          "total": {
            "type": "integer"
          },
          "returned": {
            "type": "integer"
          },
          "next_offset": {
            "type": [
              "integer",
              "null"
            ]
          },
          "verdicts": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "limit": {
                  "type": "integer"
                },
                "verdict": {
                  "type": "string",
                  "enum": [
                    "over",
                    "under",
                    "within",
                    "not_comparable"
                  ]
                },
                "why": {
                  "type": "object"
                },
                "compared": {
                  "type": "object",
                  "properties": {
                    "value_in_row_unit": {
                      "type": "string"
                    },
                    "exact": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "refused": {
            "type": "object"
          }
        }
      }
    },
    "refused": {
      "type": "object"
    }
  },
  "$defs": {
    "Cite": {
      "type": "object",
      "properties": {
        "instrument": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "issuer": {
          "type": [
            "string",
            "null"
          ]
        },
        "edition": {
          "type": [
            "string",
            "null"
          ]
        },
        "section": {
          "type": [
            "string",
            "null"
          ]
        },
        "page": {
          "type": [
            "integer",
            "string",
            "null"
          ]
        },
        "quote": {
          "type": [
            "string",
            "null"
          ]
        },
        "source_url": {
          "type": [
            "string",
            "null"
          ]
        },
        "source_sha256": {
          "type": [
            "string",
            "null"
          ]
        },
        "source_status": {
          "type": "object",
          "description": "What the daily edition watch last saw at the source: status unchanged, changed (with changed_on and says: the rows are as read from the edition named, not yet re-read) or not verified; checked is the day.",
          "properties": {
            "checked": {
              "type": "string"
            },
            "status": {
              "type": "string",
              "enum": [
                "unchanged",
                "changed",
                "not verified"
              ]
            },
            "changed_on": {
              "type": "string"
            },
            "says": {
              "type": "string"
            }
          }
        },
        "note": {
          "type": "string",
          "description": "What the register prints beside the value (e.g. a later or earlier value and its date)."
        },
        "table": {
          "type": "string"
        },
        "column": {
          "type": "string",
          "description": "The register column the value sits in (e.g. mcl, mclg)."
        }
      }
    },
    "Row": {
      "type": "object",
      "properties": {
        "parameter": {
          "type": "string"
        },
        "parameter_key": {
          "type": "string"
        },
        "value": {
          "type": "string"
        },
        "value_num": {
          "type": [
            "number",
            "null"
          ]
        },
        "range": {
          "type": [
            "array",
            "null"
          ]
        },
        "unit": {
          "type": [
            "string",
            "null"
          ]
        },
        "statistic": {
          "type": [
            "string",
            "null"
          ]
        },
        "direction": {
          "type": [
            "string",
            "null"
          ]
        },
        "kind": {
          "type": "string"
        },
        "medium": {
          "type": "string"
        },
        "place": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "conditions": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "cite": {
          "$ref": "#/$defs/Cite"
        }
      }
    }
  }
}