{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/zeeg-me/json-schema/zeeg-me-scheduled-invitee-schema.json",
  "title": "ScheduledInvitee",
  "description": "One invitee of a scheduled event. The scheduled event embeds it in `invitees`, and the invitee endpoints return it as `resource`.",
  "x-generated": "2026-11-29",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/_original/zeeg-me-api-openapi.yml#/components/schemas/ScheduledInvitee",
  "type": "object",
  "required": [
    "fullName",
    "email",
    "timeZone",
    "scheduledAt",
    "noShow"
  ],
  "properties": {
    "uuid": {
      "type": "string",
      "description": "Zeeg attendee identifier (zg-XXX format)"
    },
    "salutation": {
      "type": [
        "string",
        "null"
      ],
      "description": "Salutation for the invitee, if collected."
    },
    "fullName": {
      "type": [
        "string",
        "null"
      ],
      "description": "Full name of the invitee."
    },
    "email": {
      "type": [
        "string",
        "null"
      ],
      "format": "email",
      "description": "Email address of the invitee."
    },
    "guests": {
      "type": "array",
      "description": "Email addresses of additional guests the invitee added. An empty array when the invitee added none.",
      "items": {
        "type": "string"
      }
    },
    "timeZone": {
      "type": [
        "string",
        "null"
      ],
      "description": "IANA time zone of the invitee."
    },
    "cancellation": {
      "type": "object",
      "properties": {
        "cancelledAt": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time",
          "description": "ISO 8601 UTC timestamp when the invitee was cancelled."
        },
        "cancelledBy": {
          "type": [
            "string",
            "null"
          ],
          "description": "Identifier of who cancelled the booking."
        },
        "cancellerType": {
          "type": [
            "string",
            "null"
          ],
          "description": "Type of canceller (e.g. host, invitee)."
        },
        "cancellationReason": {
          "type": [
            "string",
            "null"
          ],
          "description": "Reason given for the cancellation."
        }
      },
      "description": "Cancellation details. All fields are `null` when the invitee is not cancelled."
    },
    "payment": {
      "type": [
        "object",
        "null"
      ],
      "description": "Payment details for the booking, or `null` when no payment applies.",
      "properties": {
        "gateway": {
          "type": "string",
          "description": "Payment provider, e.g. `stripe` or `paypal`."
        },
        "price": {
          "type": "number"
        },
        "currency": {
          "type": "string"
        },
        "transactionId": {
          "type": [
            "string",
            "null"
          ]
        },
        "createdAt": {
          "type": "string",
          "format": "date-time"
        },
        "status": {
          "type": "string",
          "enum": [
            "pending",
            "success"
          ],
          "description": "`pending` until the transaction completes."
        }
      }
    },
    "noShow": {
      "type": "boolean",
      "description": "Whether the invitee has been marked as a no-show. Always present."
    },
    "noShowAt": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "ISO 8601 UTC timestamp when the invitee was marked as a no-show, or `null` when they were not."
    },
    "scheduledAt": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "ISO 8601 UTC timestamp when the invitee booked."
    },
    "utm": {
      "type": "object",
      "required": [
        "utm_campaign",
        "utm_source",
        "utm_medium",
        "utm_term",
        "utm_content"
      ],
      "properties": {
        "utm_campaign": {
          "type": [
            "string",
            "null"
          ]
        },
        "utm_source": {
          "type": [
            "string",
            "null"
          ]
        },
        "utm_medium": {
          "type": [
            "string",
            "null"
          ]
        },
        "utm_content": {
          "type": [
            "string",
            "null"
          ]
        },
        "utm_term": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "description": "UTM tracking parameters captured at booking time. Always holds these five keys, in `snake_case`; a key holds `null` when the booking did not carry a value for it."
    },
    "adAttribution": {
      "type": [
        "object",
        "null"
      ],
      "properties": {
        "gclid": {
          "type": [
            "string",
            "null"
          ],
          "description": "Google Ads click ID."
        },
        "gbraid": {
          "type": [
            "string",
            "null"
          ],
          "description": "Google click ID for iOS app-to-web clicks. Mutually exclusive with `gclid` per click."
        },
        "wbraid": {
          "type": [
            "string",
            "null"
          ],
          "description": "Google click ID for web-to-app clicks. Mutually exclusive with `gclid` per click."
        },
        "fbclid": {
          "type": [
            "string",
            "null"
          ],
          "description": "Meta click ID."
        },
        "fbp": {
          "type": [
            "string",
            "null"
          ],
          "description": "Meta browser ID cookie (`_fbp`) captured at booking time."
        },
        "fbc": {
          "type": [
            "string",
            "null"
          ],
          "description": "Meta click cookie (`_fbc`) captured at booking time."
        },
        "landingUrl": {
          "type": [
            "string",
            "null"
          ],
          "description": "Full URL of the host page the booking widget was embedded on."
        }
      },
      "description": "Ad-click identifiers captured at booking time, keyed by provider. Only the keys that were actually captured are present; `null` when none were captured."
    },
    "customQueryParams": {
      "type": "object",
      "description": "Custom query parameters captured at booking time, keyed by the `c__`-prefixed parameter name. An empty object when the booking captured none."
    },
    "questions": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": "object",
        "properties": {
          "answer": {
            "type": "string"
          },
          "answer_type": {
            "type": "string"
          },
          "question": {
            "type": "string"
          }
        }
      },
      "description": "Booking questions answered by the invitee."
    },
    "agentBookingReference": {
      "type": [
        "string",
        "null"
      ],
      "description": "Reference code for bookings made via the AI agent; `null` otherwise."
    },
    "cancelUrl": {
      "type": [
        "string",
        "null"
      ],
      "format": "uri",
      "description": "Public URL the invitee uses to cancel this booking. `null` once the booking is cancelled."
    },
    "rescheduleUrl": {
      "type": [
        "string",
        "null"
      ],
      "format": "uri",
      "description": "Public URL the invitee uses to reschedule this booking. `null` once the booking is cancelled."
    },
    "rescheduled": {
      "type": "boolean",
      "description": "True once this booking has been superseded by a reschedule. A rescheduled booking reports `status: cancelled` for backward compatibility; `rescheduled` and `nextRescheduling` are how a caller tells a reschedule apart from an actual cancellation."
    },
    "rescheduling": {
      "allOf": [
        {
          "$ref": "#/$defs/EventRescheduling"
        }
      ],
      "nullable": true,
      "description": "Present when this booking is the *result* of a reschedule. `null` when this booking was not itself created by rescheduling an earlier one."
    },
    "nextRescheduling": {
      "allOf": [
        {
          "$ref": "#/$defs/EventRescheduling"
        }
      ],
      "nullable": true,
      "description": "Present when this booking has been superseded by a later reschedule. `null` when the booking has not been rescheduled."
    }
  },
  "$defs": {
    "EventRescheduling": {
      "type": "object",
      "description": "Links one half of a reschedule to the other. Embedded as `rescheduling` (on the new booking) and `nextRescheduling` (on the superseded booking) inside an invitee.",
      "properties": {
        "oldStartAt": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time",
          "description": "ISO 8601 UTC start time the previous booking held before the reschedule."
        },
        "newStartAt": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time",
          "description": "ISO 8601 UTC start time the new booking was moved to."
        },
        "rescheduledAt": {
          "type": "string",
          "format": "date-time",
          "description": "ISO 8601 UTC timestamp when the reschedule was performed."
        },
        "previousEventUuid": {
          "type": [
            "string",
            "null"
          ],
          "description": "uuid of the superseded booking (zg-XXX format). Use it directly as the `uuid` path parameter of `GET /scheduled-events/{uuid}` to fetch that booking."
        },
        "previousInviteeUuid": {
          "type": [
            "string",
            "null"
          ],
          "description": "uuid of the invitee on the superseded booking. No public endpoint accepts an invitee uuid as a path parameter."
        },
        "reason": {
          "type": [
            "string",
            "null"
          ],
          "description": "Reason given for the reschedule, if any."
        },
        "rescheduledBy": {
          "type": [
            "string",
            "null"
          ],
          "description": "Who performed the reschedule (e.g. `host`, `invitee`)."
        },
        "reschedulerFullName": {
          "type": [
            "string",
            "null"
          ],
          "description": "Full name of the person who performed the reschedule, when known."
        }
      }
    }
  }
}