{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$ref": "#/definitions/PremiumBasis",
  "definitions": {
    "PremiumBasis": {
      "type": "object",
      "properties": {
        "ratePerUnit": {
          "type": "number",
          "description": "Rate per unit of exposure (e.g., 2.45 per $100 of payroll)"
        },
        "rateBasis": {
          "$ref": "#/definitions/CodeableConcept",
          "description": "Description of the rate basis (e.g., \"per $100 of payroll\", \"per $1,000 of revenue\")."
        },
        "exposureAmount": {
          "$ref": "#/definitions/Quantity",
          "description": "The exposure measure used in the calculation"
        },
        "basePremium": {
          "$ref": "#/definitions/Money",
          "description": "Base premium before adjustments (if flat-rated or minimum applies)"
        }
      },
      "additionalProperties": false,
      "description": "The rating basis used to calculate premium. Captures the rate, what it's applied to, and the exposure measure."
    },
    "CodeableConcept": {
      "type": "object",
      "properties": {
        "coding": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/Coding"
          },
          "description": "Code(s) from formal code systems"
        },
        "text": {
          "type": "string",
          "description": "Plain text representation of the concept"
        }
      },
      "additionalProperties": false,
      "description": "A concept with a coding and optional text. Wraps one or more Coding values with a human-readable summary."
    },
    "Coding": {
      "type": "object",
      "properties": {
        "system": {
          "type": "string",
          "description": "The code system URI that defines the code.",
          "format": "uri"
        },
        "code": {
          "type": "string",
          "description": "The code value from the code system"
        },
        "display": {
          "type": "string",
          "description": "Human-readable display text for the code"
        }
      },
      "required": [
        "code"
      ],
      "additionalProperties": false,
      "description": "A coded value from a defined code system. Used throughout BIND for standardized enumerations.",
      "examples": [
        {
          "system": "https://bind.codes/line-of-business",
          "code": "GL",
          "display": "General Liability"
        }
      ]
    },
    "Quantity": {
      "type": "object",
      "properties": {
        "value": {
          "type": "number",
          "description": "Numeric value"
        },
        "unit": {
          "type": "string",
          "description": "Unit of measure (e.g. \"sqft\", \"vehicles\", \"employees\")"
        },
        "system": {
          "type": "string",
          "description": "Code system URI for the unit.",
          "format": "uri"
        },
        "code": {
          "type": "string",
          "description": "Coded form of the unit"
        }
      },
      "required": [
        "value"
      ],
      "additionalProperties": false,
      "description": "A quantity with a value and unit.",
      "examples": [
        {
          "value": 50000,
          "unit": "sqft"
        }
      ]
    },
    "Money": {
      "type": "object",
      "properties": {
        "value": {
          "type": "number",
          "description": "Numeric amount. Represented as a number; precision should be maintained by the consuming system."
        },
        "currency": {
          "type": "string",
          "description": "ISO 4217 currency code.",
          "default": "USD"
        }
      },
      "required": [
        "value"
      ],
      "additionalProperties": false,
      "description": "A monetary amount with currency.",
      "examples": [
        {
          "value": 1000000,
          "currency": "USD"
        }
      ]
    }
  },
  "$id": "https://bind-standard.org/schema/PremiumBasis",
  "title": "PremiumBasis"
}
