StreamingRequestHandler Класс

Конструктор

StreamingRequestHandler(bot: Bot, activity_processor: StreamingActivityProcessor, web_socket: WebSocket, logger: Logger = None)

Параметры

Имя Описание
bot
Обязательно
activity_processor
Обязательно
web_socket
Обязательно
logger
Default value: None

Методы

conversation_added_time
forget_conversation
has_conversation
listen
process_request
send_activity
send_streaming_request

conversation_added_time

conversation_added_time(conversation_id: str) -> datetime

Параметры

Имя Описание
conversation_id
Обязательно

forget_conversation

forget_conversation(conversation_id: str)

Параметры

Имя Описание
conversation_id
Обязательно

has_conversation

has_conversation(conversation_id: str) -> bool

Параметры

Имя Описание
conversation_id
Обязательно

listen

async listen()

process_request

async process_request(request: ReceiveRequest, logger: Logger, context: object) -> StreamingResponse

Параметры

Имя Описание
request
Обязательно
logger
Обязательно
context
Обязательно

send_activity

async send_activity(activity: Activity) -> ResourceResponse

Параметры

Имя Описание
activity
Обязательно

send_streaming_request

async send_streaming_request(request: StreamingRequest) -> ReceiveResponse

Параметры

Имя Описание
request
Обязательно

Атрибуты

service_url