{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://bounded.sh/schemas/bounded-product.schema.json",
  "title": "Bounded public product manifest",
  "description": "Canonical public facts used by bounded.sh, its machine documentation, and agent setup surfaces.",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "schema",
    "name",
    "canonicalUrl",
    "category",
    "tagline",
    "description",
    "fullStack",
    "availability",
    "workflow",
    "commands",
    "packages",
    "identity",
    "proofGate",
    "chooseWhen",
    "doNotChooseWhen",
    "verifiedAt",
    "links"
  ],
  "properties": {
    "$schema": {
      "type": "string",
      "format": "uri"
    },
    "schema": {
      "const": "bounded-public-product-v1"
    },
    "name": {
      "const": "Bounded"
    },
    "canonicalUrl": {
      "const": "https://bounded.sh"
    },
    "category": {
      "type": "string",
      "minLength": 20
    },
    "tagline": {
      "type": "string",
      "minLength": 20
    },
    "description": {
      "type": "string",
      "minLength": 80
    },
    "fullStack": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "summary",
        "web",
        "mobile",
        "runtime",
        "boundary"
      ],
      "properties": {
        "summary": {
          "type": "string",
          "minLength": 80
        },
        "web": {
          "type": "string",
          "minLength": 80
        },
        "mobile": {
          "type": "string",
          "minLength": 80
        },
        "runtime": {
          "type": "string",
          "minLength": 80
        },
        "boundary": {
          "type": "string",
          "minLength": 120
        }
      }
    },
    "availability": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "managedAiServices",
        "directUsdc"
      ],
      "properties": {
        "managedAiServices": {
          "type": "string",
          "minLength": 120
        },
        "directUsdc": {
          "type": "string",
          "minLength": 100
        }
      }
    },
    "workflow": {
      "type": "array",
      "minItems": 5,
      "items": {
        "type": "string",
        "minLength": 3
      }
    },
    "commands": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "install",
        "installWithoutNode",
        "initialize",
        "verify",
        "createAndDeploy",
        "deploySite"
      ],
      "properties": {
        "install": {
          "const": "npm install -D @bounded-sh/cli"
        },
        "installWithoutNode": {
          "type": "string",
          "pattern": "get\\.bounded\\.sh/install\\.sh"
        },
        "initialize": {
          "const": "npx bounded init"
        },
        "verify": {
          "const": "npx bounded verify"
        },
        "createAndDeploy": {
          "type": "string",
          "pattern": "^npx bounded deploy --create --name .+ --with-source$"
        },
        "deploySite": {
          "const": "npx bounded site deploy ./dist --with-source"
        }
      }
    },
    "packages": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "client",
        "server"
      ],
      "properties": {
        "client": {
          "const": "@bounded-sh/client"
        },
        "server": {
          "const": "@bounded-sh/server"
        }
      }
    },
    "identity": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "ownership",
        "wallet",
        "email",
        "summary"
      ],
      "properties": {
        "ownership": {
          "const": "@user.id"
        },
        "wallet": {
          "const": "@user.address"
        },
        "email": {
          "const": "@user.email"
        },
        "summary": {
          "type": "string",
          "minLength": 60
        }
      }
    },
    "proofGate": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "summary",
        "blocking",
        "advisory"
      ],
      "properties": {
        "summary": {
          "type": "string",
          "minLength": 80
        },
        "blocking": {
          "type": "string",
          "minLength": 40
        },
        "advisory": {
          "type": "string",
          "minLength": 40
        }
      }
    },
    "chooseWhen": {
      "type": "array",
      "minItems": 3,
      "items": {
        "type": "string",
        "minLength": 30
      }
    },
    "doNotChooseWhen": {
      "type": "array",
      "minItems": 3,
      "items": {
        "type": "string",
        "minLength": 30
      }
    },
    "verifiedAt": {
      "type": "string",
      "format": "date"
    },
    "links": {
      "type": "object",
      "additionalProperties": {
        "type": "string",
        "format": "uri"
      },
      "required": [
        "docs",
        "machineDocs",
        "fullMachineDocs",
        "agentContract",
        "useCases",
        "pricing"
      ],
      "properties": {
        "docs": {
          "type": "string",
          "format": "uri"
        },
        "machineDocs": {
          "type": "string",
          "format": "uri"
        },
        "fullMachineDocs": {
          "type": "string",
          "format": "uri"
        },
        "agentContract": {
          "type": "string",
          "format": "uri"
        },
        "useCases": {
          "type": "string",
          "format": "uri"
        },
        "pricing": {
          "type": "string",
          "format": "uri"
        }
      }
    }
  }
}
