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

from __future__ import annotations
from .deletetopicsubscriberidentifierdto import (
    DeleteTopicSubscriberIdentifierDto,
    DeleteTopicSubscriberIdentifierDtoTypedDict,
)
from novu_py.types import BaseModel
import pydantic
from typing import List, Optional, Union
from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict


DeleteTopicSubscriptionsRequestDtoSubscriptionsTypedDict = TypeAliasType(
    "DeleteTopicSubscriptionsRequestDtoSubscriptionsTypedDict",
    Union[DeleteTopicSubscriberIdentifierDtoTypedDict, str],
)


DeleteTopicSubscriptionsRequestDtoSubscriptions = TypeAliasType(
    "DeleteTopicSubscriptionsRequestDtoSubscriptions",
    Union[DeleteTopicSubscriberIdentifierDto, str],
)


class DeleteTopicSubscriptionsRequestDtoTypedDict(TypedDict):
    subscriber_ids: NotRequired[List[str]]
    r"""List of subscriber identifiers to unsubscribe from the topic (max: 100). @deprecated Use the \"subscriptions\" property instead."""
    subscriptions: NotRequired[
        List[DeleteTopicSubscriptionsRequestDtoSubscriptionsTypedDict]
    ]
    r"""List of subscriptions to unsubscribe from the topic (max: 100). Can be either a string array of subscriber IDs or an array of objects with identifier and/or subscriberId. If only subscriberId is provided, all subscriptions for that subscriber within the topic will be deleted."""


class DeleteTopicSubscriptionsRequestDto(BaseModel):
    subscriber_ids: Annotated[
        Optional[List[str]],
        pydantic.Field(
            deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible.",
            alias="subscriberIds",
        ),
    ] = None
    r"""List of subscriber identifiers to unsubscribe from the topic (max: 100). @deprecated Use the \"subscriptions\" property instead."""

    subscriptions: Optional[List[DeleteTopicSubscriptionsRequestDtoSubscriptions]] = (
        None
    )
    r"""List of subscriptions to unsubscribe from the topic (max: 100). Can be either a string array of subscriber IDs or an array of objects with identifier and/or subscriberId. If only subscriberId is provided, all subscriptions for that subscriber within the topic will be deleted."""
