Class: OpenAI::Realtime::SidebandConnection

Inherits:
Connection
  • Object
show all
Defined in:
lib/openai/helpers/realtime/sideband_connection.rb

Overview

A server-side control connection attached to an existing WebRTC or SIP call.

Instance Attribute Summary collapse

Attributes inherited from Connection

#conversation, #input_audio_buffer, #response, #session, #url

Instance Method Summary collapse

Methods inherited from Connection

#abort, #close, #closed?, #each, #parse_event, #receive, #receive_raw, #send_event, #send_raw

Constructor Details

#initialize(socket:, url:) ⇒ SidebandConnection

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of SidebandConnection.



11
12
13
14
# File 'lib/openai/helpers/realtime/sideband_connection.rb', line 11

def initialize(socket:, url:)
  super
  @output_audio_buffer = OpenAI::Realtime::ConnectionResources::OutputAudioBuffer.new(self)
end

Instance Attribute Details

#output_audio_bufferOpenAI::Realtime::ConnectionResources::OutputAudioBuffer (readonly)



8
9
10
# File 'lib/openai/helpers/realtime/sideband_connection.rb', line 8

def output_audio_buffer
  @output_audio_buffer
end