{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/forward-email/json-schema/forward-email-contact-schema.json",
  "title": "Contact",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/forward-email-contacts-api-openapi.yml#/components/schemas/Contact",
  "type": "object",
  "required": [
    "id",
    "uid",
    "full_name",
    "content",
    "etag",
    "is_group",
    "emails",
    "phone_numbers",
    "created_at",
    "updated_at",
    "object"
  ],
  "properties": {
    "id": {
      "type": "string",
      "description": "Contact ID (contact_id from CardDAV)"
    },
    "uid": {
      "type": "string",
      "description": "Contact UID"
    },
    "full_name": {
      "type": "string",
      "description": "Contact's full name"
    },
    "content": {
      "type": "string",
      "description": "vCard content"
    },
    "etag": {
      "type": "string",
      "description": "ETag for versioning"
    },
    "is_group": {
      "type": "boolean",
      "description": "Whether contact is a group"
    },
    "emails": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "value": {
            "type": "string",
            "format": "email"
          },
          "type": {
            "type": "string",
            "default": "INTERNET"
          }
        },
        "required": [
          "value"
        ]
      },
      "description": "Array of email addresses"
    },
    "phone_numbers": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "value": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "default": "CELL"
          }
        },
        "required": [
          "value"
        ]
      },
      "description": "Array of phone numbers"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "object": {
      "type": "string",
      "enum": [
        "contact"
      ]
    }
  }
}