"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""

from __future__ import annotations
from .webhookeventtype import WebhookEventType
from .webhookstatus import WebhookStatus
from moovio_sdk.types import BaseModel
import pydantic
from typing import List
from typing_extensions import Annotated, TypedDict


class UpdateWebhookTypedDict(TypedDict):
    r"""Request body for updating an existing webhook."""

    url: str
    r"""The URL where webhook events will be sent."""
    status: WebhookStatus
    r"""The status of the webhook."""
    event_types: List[WebhookEventType]
    r"""The list of event types this webhook should subscribe to."""
    description: str
    r"""A description of the webhook for reference. Can be an empty string."""


class UpdateWebhook(BaseModel):
    r"""Request body for updating an existing webhook."""

    url: str
    r"""The URL where webhook events will be sent."""

    status: WebhookStatus
    r"""The status of the webhook."""

    event_types: Annotated[List[WebhookEventType], pydantic.Field(alias="eventTypes")]
    r"""The list of event types this webhook should subscribe to."""

    description: str
    r"""A description of the webhook for reference. Can be an empty string."""


try:
    UpdateWebhook.model_rebuild()
except NameError:
    pass
