{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/frihet-io/json-schema/frihet-io-quote-create-schema.json",
  "title": "QuoteCreate",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/frihet-io-quotes-api-openapi.yml#/components/schemas/QuoteCreate",
  "type": "object",
  "required": [
    "clientName",
    "items"
  ],
  "properties": {
    "clientName": {
      "type": "string",
      "description": "Client name"
    },
    "items": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/LineItem"
      },
      "minItems": 1
    },
    "validUntil": {
      "type": "string",
      "format": "date",
      "description": "Quote expiration date"
    },
    "status": {
      "$ref": "#/$defs/QuoteStatus"
    },
    "notes": {
      "type": "string",
      "description": "Additional notes"
    }
  },
  "$defs": {
    "LineItem": {
      "type": "object",
      "required": [
        "description",
        "quantity",
        "unitPrice"
      ],
      "properties": {
        "description": {
          "type": "string",
          "description": "Item description"
        },
        "quantity": {
          "type": "number",
          "description": "Quantity"
        },
        "unitPrice": {
          "type": "number",
          "description": "Price per unit"
        }
      }
    },
    "QuoteStatus": {
      "type": "string",
      "enum": [
        "draft",
        "sent",
        "accepted",
        "rejected",
        "expired"
      ]
    }
  }
}