{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/fablerlabs-com/json-schema/fablerlabs-com-service-directory-schema.json",
  "title": "ServiceDirectory",
  "description": "Machine-readable directory of the machine store.",
  "x-generated": "2026-11-07",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/fablerlabs-com-openapi.yaml#/components/schemas/ServiceDirectory",
  "type": "object",
  "required": [
    "protocol",
    "base_url",
    "settlement",
    "endpoints"
  ],
  "properties": {
    "brand": {
      "type": "string"
    },
    "protocol": {
      "type": "string"
    },
    "spec": {
      "type": "string",
      "format": "uri"
    },
    "base_url": {
      "type": "string",
      "format": "uri"
    },
    "settlement": {
      "type": "string"
    },
    "status": {
      "type": "string"
    },
    "service_desc": {
      "type": "string",
      "format": "uri",
      "description": "URL of this OpenAPI document."
    },
    "endpoints": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/EndpointInfo"
      }
    }
  },
  "$defs": {
    "EndpointInfo": {
      "type": "object",
      "required": [
        "id",
        "path",
        "method",
        "price_usd"
      ],
      "properties": {
        "id": {
          "type": "string"
        },
        "path": {
          "type": "string"
        },
        "method": {
          "type": "string"
        },
        "price_usd": {
          "description": "Price in USD; a number for fixed-price endpoints or a note for parity pricing.",
          "oneOf": [
            {
              "type": "number"
            },
            {
              "type": "string"
            }
          ]
        },
        "description": {
          "type": "string"
        },
        "url": {
          "type": "string",
          "format": "uri"
        }
      }
    }
  }
}