{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/nuget/json-schema/nuget-service-index-schema.json",
  "title": "ServiceIndex",
  "description": "The service index document that lists all available NuGet API resources.",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/nuget-service-index-api-openapi.yml#/components/schemas/ServiceIndex",
  "type": "object",
  "required": [
    "version",
    "resources"
  ],
  "properties": {
    "version": {
      "type": "string",
      "description": "The schema version of the service index. The major version must be 3."
    },
    "resources": {
      "type": "array",
      "description": "The list of resources available on this package source.",
      "items": {
        "$ref": "#/$defs/ServiceIndexResource"
      }
    }
  },
  "$defs": {
    "ServiceIndexResource": {
      "type": "object",
      "description": "A resource available on the NuGet package source.",
      "required": [
        "@id",
        "@type"
      ],
      "properties": {
        "@id": {
          "type": "string",
          "format": "uri",
          "description": "The URL to the resource."
        },
        "@type": {
          "type": "string",
          "description": "A string representing the resource type, such as SearchQueryService, RegistrationsBaseUrl, PackageBaseAddress, PackagePublish, or Catalog."
        },
        "comment": {
          "type": "string",
          "description": "A human-readable description of the resource."
        }
      }
    }
  }
}