{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://docs.demiton.io/registers/insurance_certificate/v2.json",
  "title": "insurance_certificate contract v2",
  "type": "object",
  "required": [
    "expires_on",
    "insurance_type",
    "insured_party"
  ],
  "properties": {
    "status": {
      "type": "string",
      "description": "the record's compliance state at source",
      "x-demiton-requiredness": "optional"
    },
    "insurer": {
      "type": "string",
      "description": "the insurer that issued the policy",
      "x-demiton-requiredness": "optional"
    },
    "currency": {
      "type": "currency",
      "description": "the currency of the sum insured",
      "x-demiton-requiredness": "optional"
    },
    "expires_on": {
      "type": "string",
      "description": "when the cover lapses",
      "x-demiton-requiredness": "required",
      "x-demiton-unit": "day",
      "format": "date",
      "x-demiton-type": "date"
    },
    "external_id": {
      "type": "string",
      "description": "the source system's own record id",
      "x-demiton-requiredness": "optional"
    },
    "sum_insured": {
      "type": "number",
      "description": "the cover limit",
      "x-demiton-requiredness": "optional",
      "x-demiton-type": "money"
    },
    "insured_party": {
      "type": "string",
      "description": "the company the policy covers",
      "x-demiton-requiredness": "required",
      "x-demiton-reference": true
    },
    "policy_number": {
      "type": "string",
      "description": "the policy number",
      "x-demiton-requiredness": "optional"
    },
    "insurance_type": {
      "type": "string",
      "description": "the kind of cover, e.g. public liability or workers compensation",
      "x-demiton-requiredness": "required"
    },
    "certificate_uploaded": {
      "type": "boolean",
      "description": "whether a certificate of currency has been provided",
      "x-demiton-requiredness": "optional"
    }
  },
  "x-demiton-register-type": "insurance_certificate",
  "x-demiton-contract-version": "2.0.2",
  "x-demiton-store": "tenant",
  "x-demiton-axes": [],
  "x-demiton-measures": [],
  "x-demiton-provenance": {
    "standards": []
  },
  "description": "A counterparty's certificates of currency, which gate site access.",
  "x-demiton-contract-url": "https://docs.demiton.io/registers/insurance_certificate/",
  "x-demiton-register-catalog": "https://docs.demiton.io/concepts/register-catalog"
}