{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/poptin/json-schema/poptin-update-contact-request-schema.json",
  "title": "UpdateContactRequest",
  "x-generated": "2026-12-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/poptin-api-openapi.yml#/components/schemas/UpdateContactRequest",
  "type": "object",
  "properties": {
    "info": {
      "type": [
        "object",
        "null"
      ],
      "description": "Default contact fields keyed by field tag (e.g. `FIRST_NAME`, `BIRTHDAY`, `COUNTRY`). Keys are case-insensitive and must exist on your mail list. Only the fields you send are overwritten; omitted fields are left unchanged. `EMAIL` cannot be changed. `COUNTRY` accepts an ISO country code. `BIRTHDAY` must be a date that is not in the future.",
      "additionalProperties": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "integer"
          },
          {
            "type": "number"
          },
          {
            "type": "boolean"
          },
          {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        ]
      }
    },
    "custom": {
      "type": [
        "object",
        "null"
      ],
      "description": "Mail-list custom fields keyed by tag (e.g. `CUSTOM_1`). Keys are case-insensitive; values are validated against each field's type (text, number, date, boolean). Only the fields you send are overwritten.",
      "additionalProperties": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "integer"
          },
          {
            "type": "number"
          },
          {
            "type": "boolean"
          },
          {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        ]
      }
    },
    "tags": {
      "type": [
        "array",
        "null"
      ],
      "description": "Tag names to assign to the contact. Include this key to replace all tags (send `[]` to remove all tags); omit it to leave existing tags unchanged.",
      "items": {
        "type": "string"
      },
      "uniqueItems": true
    },
    "preferences": {
      "type": [
        "array",
        "null"
      ],
      "description": "Subscription preference names to assign. Include this key to replace preferences; omit it to leave them unchanged. Unknown names are rejected.",
      "items": {
        "type": "string"
      },
      "uniqueItems": true
    }
  }
}