mirror of
https://github.com/pchuan98/codex.git
synced 2026-07-01 00:31:56 +08:00
Add WebRTC transport to realtime start (#16960)
Adds WebRTC startup to the experimental app-server `thread/realtime/start` method with an optional transport enum. The websocket path remains the default; WebRTC offers create the realtime session through the shared start flow and emit the answer SDP via `thread/realtime/sdp`. --------- Co-authored-by: Codex <noreply@openai.com>
This commit is contained in:
committed by
GitHub
Unverified
parent
6c36e7d688
commit
fb3dcfde1d
@@ -391,6 +391,9 @@ fn server_notification_thread_target(
|
||||
ServerNotification::ThreadRealtimeOutputAudioDelta(notification) => {
|
||||
Some(notification.thread_id.as_str())
|
||||
}
|
||||
ServerNotification::ThreadRealtimeSdp(notification) => {
|
||||
Some(notification.thread_id.as_str())
|
||||
}
|
||||
ServerNotification::ThreadRealtimeError(notification) => {
|
||||
Some(notification.thread_id.as_str())
|
||||
}
|
||||
@@ -625,6 +628,17 @@ fn server_notification_thread_events(
|
||||
}),
|
||||
}],
|
||||
)),
|
||||
ServerNotification::ThreadRealtimeSdp(notification) => Some((
|
||||
ThreadId::from_string(¬ification.thread_id).ok()?,
|
||||
vec![Event {
|
||||
id: String::new(),
|
||||
msg: EventMsg::RealtimeConversationSdp(
|
||||
codex_protocol::protocol::RealtimeConversationSdpEvent {
|
||||
sdp: notification.sdp,
|
||||
},
|
||||
),
|
||||
}],
|
||||
)),
|
||||
ServerNotification::ThreadRealtimeError(notification) => Some((
|
||||
ThreadId::from_string(¬ification.thread_id).ok()?,
|
||||
vec![Event {
|
||||
|
||||
Reference in New Issue
Block a user