{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.cuddler.dev/standards/artifact-definitions/boostware-module-catalog/1.0.0/data.schema.json",
  "title": "Boostware Module Catalog Data Schema",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "$schema",
    "modules"
  ],
  "cuddler": {
    "specVersion": "1.0.0",
    "documentTypeId": "boostware-module-catalog",
    "schemaVersion": "1.0.0",
    "output": {
      "primaryContentType": "application/json",
      "supportedContentTypes": [
        "application/json"
      ]
    },
    "profile": {
      "id": "boostware-module-catalog",
      "version": "1.0.0",
      "for-ai": [
        {
          "instruction": "Explain what this Cuddler schema profile governs so AI consumers understand when to use this schema family.",
          "input": "",
          "output": "Boostware Module Catalog schema family for publishing a machine-readable inventory of Boostware modules and their versioned package metadata."
        }
      ]
    },
    "schemaLinks": [
      {
        "rel": "self",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/boostware-module-catalog/1.0.0/data.schema.json",
        "targetDocumentTypeId": "boostware-module-catalog",
        "for-ai": [
          {
            "instruction": "Explain why this related schema is linked here and when an AI consumer should follow it.",
            "input": "",
            "output": "Use the canonical Boostware Module Catalog data schema at this immutable URL when validating or generating a module catalog document."
          }
        ]
      }
    ],
    "artifactType": "Boostware Module Catalog",
    "status": "Public normative publication",
    "publisher": "IdeaTilt Inc.",
    "sourceUrl": "https://www.cuddler.dev/standards/artifact-definitions/boostware-module-catalog/",
    "attributionNotice": "© 2026 IdeaTilt. This work is licensed under the Creative Commons Attribution 4.0 International License (CC BY 4.0). See https://www.cuddler.dev/license/ for the site license summary. You are free to share, use, adapt, and modify this material, including for commercial purposes, provided you give appropriate attribution and include a link to the original source URL and the CC BY 4.0 license at https://creativecommons.org/licenses/by/4.0/.",
    "governingDomainSpecification": {
      "title": "Data Document Role",
      "url": "https://www.cuddler.dev/standards/document-role/data/v1.0.0/"
    },
    "governingArtifactSpecification": {
      "title": "Cuddler Artifact Specification",
      "version": "1.0.0",
      "url": "https://www.cuddler.dev/standards/artifact-specification/v1.0.0/"
    }
  },
  "properties": {
    "$schema": {
      "type": "string",
      "format": "uri",
      "const": "https://www.cuddler.dev/standards/artifact-definitions/boostware-module-catalog/1.0.0/data.schema.json",
      "for-ai": [
        {
          "instruction": "Use this guidance when preparing a valid value for this schema node.",
          "input": "",
          "output": "Absolute URI of this immutable Boostware Module Catalog schema."
        }
      ]
    },
    "modules": {
      "type": "array",
      "minItems": 1,
      "uniqueItems": true,
      "items": {
        "$ref": "#/$defs/moduleEntry"
      },
      "for-ai": [
        {
          "instruction": "Use this guidance when preparing a valid value for this schema node.",
          "input": "",
          "output": "Ordered list of published Boostware modules. Include one entry per module package."
        }
      ]
    }
  },
  "$defs": {
    "nonEmptyString": {
      "type": "string",
      "minLength": 1
    },
    "moduleEntry": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "name",
        "author",
        "copyright",
        "description",
        "namespace",
        "version"
      ],
      "properties": {
        "name": {
          "$ref": "#/$defs/nonEmptyString",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Human-readable module name, for example Account or Service Desk."
            }
          ]
        },
        "author": {
          "$ref": "#/$defs/nonEmptyString",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Author or publishing organization for the module package."
            }
          ]
        },
        "copyright": {
          "$ref": "#/$defs/nonEmptyString",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Copyright notice that travels with the published module."
            }
          ]
        },
        "description": {
          "$ref": "#/$defs/nonEmptyString",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Short reader-facing summary of the module."
            }
          ]
        },
        "namespace": {
          "type": "string",
          "minLength": 1,
          "pattern": "^[A-Za-z_][A-Za-z0-9_]*(?:\\.[A-Za-z_][A-Za-z0-9_]*)+$",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Stable .NET namespace for the module, written in dotted identifier form."
            }
          ]
        },
        "version": {
          "type": "string",
          "minLength": 1,
          "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-[0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*)?(?:\\+[0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*)?$",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Semantic version string for the published module package."
            }
          ]
        }
      },
      "for-ai": [
        {
          "instruction": "Use this guidance when preparing a valid value for this schema node.",
          "input": "",
          "output": "One published Boostware module entry with the exact metadata required for catalog and package validation."
        }
      ]
    }
  },
  "for-ai": [
    {
      "instruction": "Use this guidance when preparing a valid value for this schema node.",
      "input": "",
      "output": "Use this schema to generate a Boostware module catalog JSON document that lists published modules with their display, author, namespace, and version metadata."
    }
  ]
}
