Skip to content

Commit 38d75d7

Browse files
authored
Merge pull request #3205 from openai/release-please--branches--main--changes--next
release: 2.36.0
2 parents 5e8f09c + ff683ff commit 38d75d7

28 files changed

Lines changed: 226 additions & 56 deletions

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "2.35.1"
2+
".": "2.36.0"
33
}

.stats.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 233
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai/openai-84d31411083374ec6cdb4a722f8b8b83c1230741157306b1ca7ba1a3cf246672.yml
3-
openapi_spec_hash: 051fce676f959b8207e2317225ec4bdc
4-
config_hash: a2916f18a94ff65c8116ca2fe3256f10
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai/openai-371f497afe4d6070f6e252e5febbe8f453c7058a8dff0c26a01b4d88442a4ac2.yml
3+
openapi_spec_hash: d39f46e8fda45f77096448105efd175a
4+
config_hash: b64135fff1fe9cf4069b9ecf59ae8b07

CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
# Changelog
22

3+
## 2.36.0 (2026-05-07)
4+
5+
Full Changelog: [v2.35.1...v2.36.0](https://github.com/openai/openai-python/compare/v2.35.1...v2.36.0)
6+
7+
### Features
8+
9+
* **api:** manual updates ([13c639c](https://github.com/openai/openai-python/commit/13c639cc7d57e4fbd4406563511e15eeb88a54b2))
10+
* **api:** realtime 2 ([8fe0ab8](https://github.com/openai/openai-python/commit/8fe0ab87e67eeb3cc27426b50093845229520f0e))
11+
312
## 2.35.1 (2026-05-06)
413

514
Full Changelog: [v2.35.0...v2.35.1](https://github.com/openai/openai-python/compare/v2.35.0...v2.35.1)

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "openai"
3-
version = "2.35.1"
3+
version = "2.36.0"
44
description = "The official Python library for the openai API"
55
dynamic = ["readme"]
66
license = "Apache-2.0"

src/openai/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

33
__title__ = "openai"
4-
__version__ = "2.35.1" # x-release-please-version
4+
__version__ = "2.36.0" # x-release-please-version

src/openai/resources/realtime/api.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,8 @@ from openai.types.realtime import (
5858
RealtimeMcpToolCall,
5959
RealtimeMcpToolExecutionError,
6060
RealtimeMcphttpError,
61+
RealtimeReasoning,
62+
RealtimeReasoningEffort,
6163
RealtimeResponse,
6264
RealtimeResponseCreateAudioOutput,
6365
RealtimeResponseCreateMcpTool,
@@ -77,6 +79,22 @@ from openai.types.realtime import (
7779
RealtimeTranscriptionSessionAudioInput,
7880
RealtimeTranscriptionSessionAudioInputTurnDetection,
7981
RealtimeTranscriptionSessionCreateRequest,
82+
RealtimeTranslationClientEvent,
83+
RealtimeTranslationClientSecretCreateRequest,
84+
RealtimeTranslationClientSecretCreateResponse,
85+
RealtimeTranslationInputAudioBufferAppendEvent,
86+
RealtimeTranslationInputTranscriptDeltaEvent,
87+
RealtimeTranslationOutputAudioDeltaEvent,
88+
RealtimeTranslationOutputTranscriptDeltaEvent,
89+
RealtimeTranslationServerEvent,
90+
RealtimeTranslationSession,
91+
RealtimeTranslationSessionCloseEvent,
92+
RealtimeTranslationSessionClosedEvent,
93+
RealtimeTranslationSessionCreateRequest,
94+
RealtimeTranslationSessionCreatedEvent,
95+
RealtimeTranslationSessionUpdateEvent,
96+
RealtimeTranslationSessionUpdateRequest,
97+
RealtimeTranslationSessionUpdatedEvent,
8098
RealtimeTruncation,
8199
RealtimeTruncationRetentionRatio,
82100
ResponseAudioDeltaEvent,
@@ -114,7 +132,6 @@ Types:
114132

115133
```python
116134
from openai.types.realtime import (
117-
RealtimeSessionClientSecret,
118135
RealtimeSessionCreateResponse,
119136
RealtimeTranscriptionSessionCreateResponse,
120137
RealtimeTranscriptionSessionTurnDetection,

src/openai/resources/realtime/calls.py

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
call_reject_params,
2929
)
3030
from ...types.responses.response_prompt_param import ResponsePromptParam
31+
from ...types.realtime.realtime_reasoning_param import RealtimeReasoningParam
3132
from ...types.realtime.realtime_truncation_param import RealtimeTruncationParam
3233
from ...types.realtime.realtime_audio_config_param import RealtimeAudioConfigParam
3334
from ...types.realtime.realtime_tools_config_param import RealtimeToolsConfigParam
@@ -121,6 +122,7 @@ def accept(
121122
Literal[
122123
"gpt-realtime",
123124
"gpt-realtime-1.5",
125+
"gpt-realtime-2",
124126
"gpt-realtime-2025-08-28",
125127
"gpt-4o-realtime-preview",
126128
"gpt-4o-realtime-preview-2024-10-01",
@@ -139,7 +141,9 @@ def accept(
139141
]
140142
| Omit = omit,
141143
output_modalities: List[Literal["text", "audio"]] | Omit = omit,
144+
parallel_tool_calls: bool | Omit = omit,
142145
prompt: Optional[ResponsePromptParam] | Omit = omit,
146+
reasoning: RealtimeReasoningParam | Omit = omit,
143147
tool_choice: RealtimeToolChoiceConfigParam | Omit = omit,
144148
tools: RealtimeToolsConfigParam | Omit = omit,
145149
tracing: Optional[RealtimeTracingConfigParam] | Omit = omit,
@@ -188,9 +192,14 @@ def accept(
188192
can be used to make the model respond with text only. It is not possible to
189193
request both `text` and `audio` at the same time.
190194
195+
parallel_tool_calls: Whether the model may call multiple tools in parallel. Only supported by
196+
reasoning Realtime models such as `gpt-realtime-2`.
197+
191198
prompt: Reference to a prompt template and its variables.
192199
[Learn more](https://platform.openai.com/docs/guides/text?api-mode=responses#reusable-prompts).
193200
201+
reasoning: Configuration for reasoning-capable Realtime models such as `gpt-realtime-2`.
202+
194203
tool_choice: How the model chooses tools. Provide one of the string modes or force a specific
195204
function/MCP tool.
196205
@@ -245,7 +254,9 @@ def accept(
245254
"max_output_tokens": max_output_tokens,
246255
"model": model,
247256
"output_modalities": output_modalities,
257+
"parallel_tool_calls": parallel_tool_calls,
248258
"prompt": prompt,
259+
"reasoning": reasoning,
249260
"tool_choice": tool_choice,
250261
"tools": tools,
251262
"tracing": tracing,
@@ -471,6 +482,7 @@ async def accept(
471482
Literal[
472483
"gpt-realtime",
473484
"gpt-realtime-1.5",
485+
"gpt-realtime-2",
474486
"gpt-realtime-2025-08-28",
475487
"gpt-4o-realtime-preview",
476488
"gpt-4o-realtime-preview-2024-10-01",
@@ -489,7 +501,9 @@ async def accept(
489501
]
490502
| Omit = omit,
491503
output_modalities: List[Literal["text", "audio"]] | Omit = omit,
504+
parallel_tool_calls: bool | Omit = omit,
492505
prompt: Optional[ResponsePromptParam] | Omit = omit,
506+
reasoning: RealtimeReasoningParam | Omit = omit,
493507
tool_choice: RealtimeToolChoiceConfigParam | Omit = omit,
494508
tools: RealtimeToolsConfigParam | Omit = omit,
495509
tracing: Optional[RealtimeTracingConfigParam] | Omit = omit,
@@ -538,9 +552,14 @@ async def accept(
538552
can be used to make the model respond with text only. It is not possible to
539553
request both `text` and `audio` at the same time.
540554
555+
parallel_tool_calls: Whether the model may call multiple tools in parallel. Only supported by
556+
reasoning Realtime models such as `gpt-realtime-2`.
557+
541558
prompt: Reference to a prompt template and its variables.
542559
[Learn more](https://platform.openai.com/docs/guides/text?api-mode=responses#reusable-prompts).
543560
561+
reasoning: Configuration for reasoning-capable Realtime models such as `gpt-realtime-2`.
562+
544563
tool_choice: How the model chooses tools. Provide one of the string modes or force a specific
545564
function/MCP tool.
546565
@@ -595,7 +614,9 @@ async def accept(
595614
"max_output_tokens": max_output_tokens,
596615
"model": model,
597616
"output_modalities": output_modalities,
617+
"parallel_tool_calls": parallel_tool_calls,
598618
"prompt": prompt,
619+
"reasoning": reasoning,
599620
"tool_choice": tool_choice,
600621
"tools": tools,
601622
"tracing": tracing,

src/openai/types/realtime/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
from .call_accept_params import CallAcceptParams as CallAcceptParams
1010
from .call_create_params import CallCreateParams as CallCreateParams
1111
from .call_reject_params import CallRejectParams as CallRejectParams
12+
from .realtime_reasoning import RealtimeReasoning as RealtimeReasoning
1213
from .audio_transcription import AudioTranscription as AudioTranscription
1314
from .log_prob_properties import LogProbProperties as LogProbProperties
1415
from .realtime_truncation import RealtimeTruncation as RealtimeTruncation
@@ -38,11 +39,13 @@
3839
from .realtime_response_usage import RealtimeResponseUsage as RealtimeResponseUsage
3940
from .realtime_tracing_config import RealtimeTracingConfig as RealtimeTracingConfig
4041
from .mcp_list_tools_completed import McpListToolsCompleted as McpListToolsCompleted
42+
from .realtime_reasoning_param import RealtimeReasoningParam as RealtimeReasoningParam
4143
from .realtime_response_status import RealtimeResponseStatus as RealtimeResponseStatus
4244
from .response_mcp_call_failed import ResponseMcpCallFailed as ResponseMcpCallFailed
4345
from .response_text_done_event import ResponseTextDoneEvent as ResponseTextDoneEvent
4446
from .audio_transcription_param import AudioTranscriptionParam as AudioTranscriptionParam
4547
from .rate_limits_updated_event import RateLimitsUpdatedEvent as RateLimitsUpdatedEvent
48+
from .realtime_reasoning_effort import RealtimeReasoningEffort as RealtimeReasoningEffort
4649
from .realtime_truncation_param import RealtimeTruncationParam as RealtimeTruncationParam
4750
from .response_audio_done_event import ResponseAudioDoneEvent as ResponseAudioDoneEvent
4851
from .response_text_delta_event import ResponseTextDeltaEvent as ResponseTextDeltaEvent
@@ -75,7 +78,6 @@
7578
from .conversation_item_delete_event import ConversationItemDeleteEvent as ConversationItemDeleteEvent
7679
from .input_audio_buffer_clear_event import InputAudioBufferClearEvent as InputAudioBufferClearEvent
7780
from .realtime_mcp_approval_response import RealtimeMcpApprovalResponse as RealtimeMcpApprovalResponse
78-
from .realtime_session_client_secret import RealtimeSessionClientSecret as RealtimeSessionClientSecret
7981
from .conversation_item_created_event import ConversationItemCreatedEvent as ConversationItemCreatedEvent
8082
from .conversation_item_deleted_event import ConversationItemDeletedEvent as ConversationItemDeletedEvent
8183
from .input_audio_buffer_append_event import InputAudioBufferAppendEvent as InputAudioBufferAppendEvent

src/openai/types/realtime/audio_transcription.py

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,13 @@
99

1010

1111
class AudioTranscription(BaseModel):
12+
delay: Optional[Literal["minimal", "low", "medium", "high", "xhigh"]] = None
13+
"""
14+
Controls how long the model waits before emitting transcription text. Higher
15+
values can improve transcription accuracy at the cost of latency. Only supported
16+
with `gpt-realtime-whisper` in GA Realtime sessions.
17+
"""
18+
1219
language: Optional[str] = None
1320
"""The language of the input audio.
1421
@@ -25,15 +32,16 @@ class AudioTranscription(BaseModel):
2532
"gpt-4o-mini-transcribe-2025-12-15",
2633
"gpt-4o-transcribe",
2734
"gpt-4o-transcribe-diarize",
35+
"gpt-realtime-whisper",
2836
],
2937
None,
3038
] = None
3139
"""The model to use for transcription.
3240
3341
Current options are `whisper-1`, `gpt-4o-mini-transcribe`,
34-
`gpt-4o-mini-transcribe-2025-12-15`, `gpt-4o-transcribe`, and
35-
`gpt-4o-transcribe-diarize`. Use `gpt-4o-transcribe-diarize` when you need
36-
diarization with speaker labels.
42+
`gpt-4o-mini-transcribe-2025-12-15`, `gpt-4o-transcribe`,
43+
`gpt-4o-transcribe-diarize`, and `gpt-realtime-whisper`. Use
44+
`gpt-4o-transcribe-diarize` when you need diarization with speaker labels.
3745
"""
3846

3947
prompt: Optional[str] = None
@@ -43,4 +51,5 @@ class AudioTranscription(BaseModel):
4351
[prompt is a list of keywords](https://platform.openai.com/docs/guides/speech-to-text#prompting).
4452
For `gpt-4o-transcribe` models (excluding `gpt-4o-transcribe-diarize`), the
4553
prompt is a free text string, for example "expect words related to technology".
54+
Prompt is not supported with `gpt-realtime-whisper` in GA Realtime sessions.
4655
"""

src/openai/types/realtime/audio_transcription_param.py

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,13 @@
99

1010

1111
class AudioTranscriptionParam(TypedDict, total=False):
12+
delay: Literal["minimal", "low", "medium", "high", "xhigh"]
13+
"""
14+
Controls how long the model waits before emitting transcription text. Higher
15+
values can improve transcription accuracy at the cost of latency. Only supported
16+
with `gpt-realtime-whisper` in GA Realtime sessions.
17+
"""
18+
1219
language: str
1320
"""The language of the input audio.
1421
@@ -25,14 +32,15 @@ class AudioTranscriptionParam(TypedDict, total=False):
2532
"gpt-4o-mini-transcribe-2025-12-15",
2633
"gpt-4o-transcribe",
2734
"gpt-4o-transcribe-diarize",
35+
"gpt-realtime-whisper",
2836
],
2937
]
3038
"""The model to use for transcription.
3139
3240
Current options are `whisper-1`, `gpt-4o-mini-transcribe`,
33-
`gpt-4o-mini-transcribe-2025-12-15`, `gpt-4o-transcribe`, and
34-
`gpt-4o-transcribe-diarize`. Use `gpt-4o-transcribe-diarize` when you need
35-
diarization with speaker labels.
41+
`gpt-4o-mini-transcribe-2025-12-15`, `gpt-4o-transcribe`,
42+
`gpt-4o-transcribe-diarize`, and `gpt-realtime-whisper`. Use
43+
`gpt-4o-transcribe-diarize` when you need diarization with speaker labels.
3644
"""
3745

3846
prompt: str
@@ -42,4 +50,5 @@ class AudioTranscriptionParam(TypedDict, total=False):
4250
[prompt is a list of keywords](https://platform.openai.com/docs/guides/speech-to-text#prompting).
4351
For `gpt-4o-transcribe` models (excluding `gpt-4o-transcribe-diarize`), the
4452
prompt is a free text string, for example "expect words related to technology".
53+
Prompt is not supported with `gpt-realtime-whisper` in GA Realtime sessions.
4554
"""

0 commit comments

Comments
 (0)