Class: OpenAI::Models::Realtime::Transports::AsyncWebSocket

Inherits:
Object
  • Object
show all
Defined in:
sig/openai/helpers/realtime/transports/async_websocket.rbs

Defined Under Namespace

Classes: Socket

Instance Method Summary collapse

Constructor Details

#initialize {|context| ... } ⇒ AsyncWebSocket

Returns a new instance of AsyncWebSocket.

Yields:

Yield Parameters:

  • context (OpenSSL::SSL::SSLContext)

Yield Returns:

  • (void)


6
7
8
# File 'sig/openai/helpers/realtime/transports/async_websocket.rbs', line 6

def initialize: ?{
  (OpenSSL::SSL::SSLContext context) -> void
} -> void

Instance Method Details

#open {|socket| ... } ⇒ top

Parameters:

  • url: (URI::Generic)
  • headers: (::Hash[String, String])
  • timeout: (Float, nil)
  • endpoint_options (Object)

Yields:

Yield Parameters:

Yield Returns:

  • (top)

Returns:

  • (top)


28
29
30
31
32
33
34
35
# File 'sig/openai/helpers/realtime/transports/async_websocket.rbs', line 28

def open: (
  url: URI::Generic,
  headers: ::Hash[String, String],
  timeout: Float?,
  **untyped endpoint_options
) {
  (Socket socket) -> top
} -> top