from __future__ import annotations from typing import Annotated from pydantic import Field from yuxi.gateway.protocol.channels import ChannelLogoutRequest, ChannelStartRequest, ChannelStatusRequest from yuxi.gateway.protocol.errors import ErrorCode, ErrorDetail from yuxi.gateway.protocol.frames import EventFrame, RequestFrame, ResponseFrame from yuxi.gateway.protocol.handshake import ConnectParams, HelloFeatures, HelloOk, handle_handshake from yuxi.gateway.protocol.primitives import NonEmptyString, PositiveInt from yuxi.gateway.protocol.version import PROTOCOL_VERSION, negotiate_version GatewayFrame = Annotated[ RequestFrame | ResponseFrame | EventFrame, Field(discriminator="type"), ] __all__ = [ "RequestFrame", "ResponseFrame", "EventFrame", "GatewayFrame", "ErrorCode", "ErrorDetail", "PROTOCOL_VERSION", "negotiate_version", "ConnectParams", "HelloFeatures", "HelloOk", "handle_handshake", "NonEmptyString", "PositiveInt", "ChannelStatusRequest", "ChannelStartRequest", "ChannelLogoutRequest", ]