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

from __future__ import annotations
from censys_platform.types import BaseModel
from enum import Enum
from typing import Optional
from typing_extensions import NotRequired, TypedDict


class ServiceIDTransportProtocol(str, Enum):
    UNKNOWN = ""
    TCP = "tcp"
    UDP = "udp"
    ICMP = "icmp"
    QUIC = "quic"


class ServiceIDTypedDict(TypedDict):
    ip: NotRequired[str]
    port: NotRequired[int]
    protocol: NotRequired[str]
    transport_protocol: NotRequired[ServiceIDTransportProtocol]


class ServiceID(BaseModel):
    ip: Optional[str] = None

    port: Optional[int] = None

    protocol: Optional[str] = None

    transport_protocol: Optional[ServiceIDTransportProtocol] = None
