# coding: utf-8

"""
    Streams Api

    API that provides access to Moralis Streams  # noqa: E501

    The version of the OpenAPI document: 1.0.0
    Generated by: https://openapi-generator.tech
"""

from datetime import date, datetime  # noqa: F401
import decimal  # noqa: F401
import functools  # noqa: F401
import io  # noqa: F401
import re  # noqa: F401
import typing  # noqa: F401
import typing_extensions  # noqa: F401
import uuid  # noqa: F401

import frozendict  # noqa: F401

from openapi_streams import schemas  # noqa: F401


class WebhookTypesIWebhookUnParsed(
    schemas.DictSchema
):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """


    class MetaOapg:
        required = {
            "retries",
            "streamId",
            "chainId",
            "abi",
            "block",
            "txsInternal",
            "tag",
            "confirmed",
            "logs",
            "txs",
        }
        
        class properties:
        
            @staticmethod
            def block() -> typing.Type['Block']:
                return Block
            chainId = schemas.StrSchema
            
            
            class logs(
                schemas.ListSchema
            ):
            
            
                class MetaOapg:
                    
                    @staticmethod
                    def items() -> typing.Type['Log']:
                        return Log
            
                def __new__(
                    cls,
                    _arg: typing.Union[typing.Tuple['Log'], typing.List['Log']],
                    _configuration: typing.Optional[schemas.Configuration] = None,
                ) -> 'logs':
                    return super().__new__(
                        cls,
                        _arg,
                        _configuration=_configuration,
                    )
            
                def __getitem__(self, i: int) -> 'Log':
                    return super().__getitem__(i)
            
            
            class txs(
                schemas.ListSchema
            ):
            
            
                class MetaOapg:
                    
                    @staticmethod
                    def items() -> typing.Type['Transaction']:
                        return Transaction
            
                def __new__(
                    cls,
                    _arg: typing.Union[typing.Tuple['Transaction'], typing.List['Transaction']],
                    _configuration: typing.Optional[schemas.Configuration] = None,
                ) -> 'txs':
                    return super().__new__(
                        cls,
                        _arg,
                        _configuration=_configuration,
                    )
            
                def __getitem__(self, i: int) -> 'Transaction':
                    return super().__getitem__(i)
            
            
            class txsInternal(
                schemas.ListSchema
            ):
            
            
                class MetaOapg:
                    
                    @staticmethod
                    def items() -> typing.Type['InternalTransaction']:
                        return InternalTransaction
            
                def __new__(
                    cls,
                    _arg: typing.Union[typing.Tuple['InternalTransaction'], typing.List['InternalTransaction']],
                    _configuration: typing.Optional[schemas.Configuration] = None,
                ) -> 'txsInternal':
                    return super().__new__(
                        cls,
                        _arg,
                        _configuration=_configuration,
                    )
            
                def __getitem__(self, i: int) -> 'InternalTransaction':
                    return super().__getitem__(i)
            
            
            class abi(
                schemas.ListSchema
            ):
            
            
                class MetaOapg:
                    
                    @staticmethod
                    def items() -> typing.Type['AbiItem']:
                        return AbiItem
            
                def __new__(
                    cls,
                    _arg: typing.Union[typing.Tuple['AbiItem'], typing.List['AbiItem']],
                    _configuration: typing.Optional[schemas.Configuration] = None,
                ) -> 'abi':
                    return super().__new__(
                        cls,
                        _arg,
                        _configuration=_configuration,
                    )
            
                def __getitem__(self, i: int) -> 'AbiItem':
                    return super().__getitem__(i)
            retries = schemas.Float64Schema
            confirmed = schemas.BoolSchema
            tag = schemas.StrSchema
            streamId = schemas.StrSchema
            __annotations__ = {
                "block": block,
                "chainId": chainId,
                "logs": logs,
                "txs": txs,
                "txsInternal": txsInternal,
                "abi": abi,
                "retries": retries,
                "confirmed": confirmed,
                "tag": tag,
                "streamId": streamId,
            }
        additional_properties = schemas.NotAnyTypeSchema
    
    retries: MetaOapg.properties.retries
    streamId: MetaOapg.properties.streamId
    chainId: MetaOapg.properties.chainId
    abi: MetaOapg.properties.abi
    block: 'Block'
    txsInternal: MetaOapg.properties.txsInternal
    tag: MetaOapg.properties.tag
    confirmed: MetaOapg.properties.confirmed
    logs: MetaOapg.properties.logs
    txs: MetaOapg.properties.txs
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["retries"]) -> MetaOapg.properties.retries: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["streamId"]) -> MetaOapg.properties.streamId: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["chainId"]) -> MetaOapg.properties.chainId: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["abi"]) -> MetaOapg.properties.abi: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["block"]) -> 'Block': ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["txsInternal"]) -> MetaOapg.properties.txsInternal: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["tag"]) -> MetaOapg.properties.tag: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["confirmed"]) -> MetaOapg.properties.confirmed: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["logs"]) -> MetaOapg.properties.logs: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["txs"]) -> MetaOapg.properties.txs: ...
    
    def __getitem__(self, name: typing.Union[typing_extensions.Literal["retries"], typing_extensions.Literal["streamId"], typing_extensions.Literal["chainId"], typing_extensions.Literal["abi"], typing_extensions.Literal["block"], typing_extensions.Literal["txsInternal"], typing_extensions.Literal["tag"], typing_extensions.Literal["confirmed"], typing_extensions.Literal["logs"], typing_extensions.Literal["txs"], ]):
        # dict_instance[name] accessor
        return super().__getitem__(name)
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["retries"]) -> MetaOapg.properties.retries: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["streamId"]) -> MetaOapg.properties.streamId: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["chainId"]) -> MetaOapg.properties.chainId: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["abi"]) -> MetaOapg.properties.abi: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["block"]) -> 'Block': ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["txsInternal"]) -> MetaOapg.properties.txsInternal: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["tag"]) -> MetaOapg.properties.tag: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["confirmed"]) -> MetaOapg.properties.confirmed: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["logs"]) -> MetaOapg.properties.logs: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["txs"]) -> MetaOapg.properties.txs: ...
    
    def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["retries"], typing_extensions.Literal["streamId"], typing_extensions.Literal["chainId"], typing_extensions.Literal["abi"], typing_extensions.Literal["block"], typing_extensions.Literal["txsInternal"], typing_extensions.Literal["tag"], typing_extensions.Literal["confirmed"], typing_extensions.Literal["logs"], typing_extensions.Literal["txs"], ]):
        return super().get_item_oapg(name)

    def __new__(
        cls,
        *_args: typing.Union[dict, frozendict.frozendict, ],
        retries: typing.Union[MetaOapg.properties.retries, decimal.Decimal, int, float, ],
        streamId: typing.Union[MetaOapg.properties.streamId, str, ],
        chainId: typing.Union[MetaOapg.properties.chainId, str, ],
        abi: typing.Union[MetaOapg.properties.abi, list, tuple, ],
        block: 'Block',
        txsInternal: typing.Union[MetaOapg.properties.txsInternal, list, tuple, ],
        tag: typing.Union[MetaOapg.properties.tag, str, ],
        confirmed: typing.Union[MetaOapg.properties.confirmed, bool, ],
        logs: typing.Union[MetaOapg.properties.logs, list, tuple, ],
        txs: typing.Union[MetaOapg.properties.txs, list, tuple, ],
        _configuration: typing.Optional[schemas.Configuration] = None,
    ) -> 'WebhookTypesIWebhookUnParsed':
        return super().__new__(
            cls,
            *_args,
            retries=retries,
            streamId=streamId,
            chainId=chainId,
            abi=abi,
            block=block,
            txsInternal=txsInternal,
            tag=tag,
            confirmed=confirmed,
            logs=logs,
            txs=txs,
            _configuration=_configuration,
        )

from openapi_streams.model.abi_item import AbiItem
from openapi_streams.model.block import Block
from openapi_streams.model.internal_transaction import InternalTransaction
from openapi_streams.model.log import Log
from openapi_streams.model.transaction import Transaction
