{
  "$defs": {
    "CatalogueAct": {
      "description": "One watched act: the watchlist's names for it, and where this site shows it.",
      "properties": {
        "aliases": {
          "description": "Other names the watchlist gives the act.",
          "items": {
            "type": "string"
          },
          "title": "Aliases",
          "type": "array"
        },
        "corpus": {
          "description": "The act's corpus namespace.",
          "title": "Corpus",
          "type": "string"
        },
        "domain": {
          "description": "The watchlist's sector for the act, or ''.",
          "title": "Domain",
          "type": "string"
        },
        "eurlex_url": {
          "description": "The act on EUR-Lex, or ''.",
          "title": "Eurlex Url",
          "type": "string"
        },
        "events": {
          "additionalProperties": {
            "type": "string"
          },
          "description": "Entry key to its event page, for every committed entry.",
          "title": "Events",
          "type": "object"
        },
        "feed": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "description": "The act's Atom feed, by the same rule; null when the build wrote no feeds.",
          "title": "Feed"
        },
        "key": {
          "description": "The act's key within its corpus.",
          "title": "Key",
          "type": "string"
        },
        "label": {
          "description": "The watchlist's short label.",
          "title": "Label",
          "type": "string"
        },
        "long_name": {
          "description": "The watchlist's long form, or ''.",
          "title": "Long Name",
          "type": "string"
        },
        "provisions": {
          "additionalProperties": {
            "type": "string"
          },
          "description": "Canonical top-level location to its provision page, for every location a committed change names.",
          "title": "Provisions",
          "type": "object"
        },
        "url": {
          "description": "The act's page: absolute with a site URL, else root-relative.",
          "title": "Url",
          "type": "string"
        },
        "waiting": {
          "description": "Consolidations announced for the act and still waiting for a text, as the poller's own record held them at build time, oldest first; empty when nothing waits or the build was handed no record.",
          "items": {
            "$ref": "#/$defs/CatalogueWaiting"
          },
          "title": "Waiting",
          "type": "array"
        }
      },
      "required": [
        "corpus",
        "key",
        "label",
        "long_name",
        "aliases",
        "domain",
        "url",
        "feed",
        "eurlex_url",
        "provisions",
        "events",
        "waiting"
      ],
      "title": "CatalogueAct",
      "type": "object"
    },
    "CatalogueWaiting": {
      "description": "One consolidation the poller was told about and could not read yet, at build time.",
      "properties": {
        "first_seen": {
          "anyOf": [
            {
              "format": "date",
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "description": "The day the poller first saw it; null when its record holds no date.",
          "title": "First Seen"
        },
        "state": {
          "description": "`consolidation_pending` while the text is not published yet, or `english_unavailable` when no English text is offered.",
          "title": "State",
          "type": "string"
        },
        "version": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "description": "The consolidated version announced; null when it is not yet known.",
          "title": "Version"
        }
      },
      "required": [
        "version",
        "state",
        "first_seen"
      ],
      "title": "CatalogueWaiting",
      "type": "object"
    }
  },
  "$id": "catalogue.schema.json",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "description": "Every watched act, quiet ones included, sorted by corpus and key.",
  "properties": {
    "acts": {
      "description": "One row per watched act.",
      "items": {
        "$ref": "#/$defs/CatalogueAct"
      },
      "title": "Acts",
      "type": "array"
    },
    "catalogue_schema": {
      "default": "1.1",
      "description": "The catalogue format's version.",
      "title": "Catalogue Schema",
      "type": "string"
    },
    "checked_through": {
      "anyOf": [
        {
          "format": "date",
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "description": "The end of the last window the poller read, from its own record at build time: changes published up to this day were looked for. Null when the build was handed no record or the poller has never closed a window.",
      "title": "Checked Through"
    },
    "disclaimer": {
      "default": "Not legal advice: this output is machine-computed from published texts, carries no lawyer's review, and is engineering assistance only.",
      "description": "Not legal advice.",
      "title": "Disclaimer",
      "type": "string"
    },
    "provenance": {
      "default": "Derived by the site build from the watchlist and the committed changelogs; not part of the record.",
      "description": "Where this file comes from.",
      "title": "Provenance",
      "type": "string"
    }
  },
  "required": [
    "acts",
    "checked_through"
  ],
  "title": "catalogue",
  "type": "object"
}
