{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/frihet-io/json-schema/frihet-io-contact-schema.json",
  "title": "Contact",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/frihet-io-contacts-api-openapi.yml#/components/schemas/Contact",
  "allOf": [
    {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "Unique identifier"
        },
        "createdAt": {
          "type": "string",
          "format": "date-time"
        },
        "updatedAt": {
          "type": "string",
          "format": "date-time"
        }
      }
    },
    {
      "$ref": "#/$defs/ContactCreate"
    }
  ],
  "$defs": {
    "ContactCreate": {
      "type": "object",
      "required": [
        "name"
      ],
      "properties": {
        "name": {
          "type": "string",
          "description": "Contact person name"
        },
        "email": {
          "type": "string",
          "format": "email",
          "description": "Contact email"
        },
        "phone": {
          "type": "string",
          "description": "Phone number"
        },
        "role": {
          "type": "string",
          "description": "Job title or role"
        },
        "isPrimary": {
          "type": "boolean",
          "description": "Whether this is the primary contact for the client",
          "default": false
        }
      }
    }
  }
}