Commit bff85cdd

stainless-app[bot] <142633134+stainless-app[bot]@users.noreply.github.com>
2025-08-11 20:56:29
fix(types): rename ChatCompletionMessageToolCallParam
1 parent 4d8c14c
src/openai/types/chat/__init__.py
@@ -31,7 +31,7 @@ from .chat_completion_reasoning_effort import ChatCompletionReasoningEffort as C
 from .chat_completion_tool_union_param import ChatCompletionToolUnionParam as ChatCompletionToolUnionParam
 from .chat_completion_content_part_text import ChatCompletionContentPartText as ChatCompletionContentPartText
 from .chat_completion_custom_tool_param import ChatCompletionCustomToolParam as ChatCompletionCustomToolParam
-from .chat_completion_message_tool_call import ChatCompletionMessageToolCall as ChatCompletionMessageToolCall
+from .chat_completion_message_tool_call import ChatCompletionMessageToolCallUnion as ChatCompletionMessageToolCallUnion
 from .chat_completion_content_part_image import ChatCompletionContentPartImage as ChatCompletionContentPartImage
 from .chat_completion_content_part_param import ChatCompletionContentPartParam as ChatCompletionContentPartParam
 from .chat_completion_tool_message_param import ChatCompletionToolMessageParam as ChatCompletionToolMessageParam
@@ -52,9 +52,6 @@ from .chat_completion_content_part_text_param import (
 from .chat_completion_developer_message_param import (
     ChatCompletionDeveloperMessageParam as ChatCompletionDeveloperMessageParam,
 )
-from .chat_completion_message_tool_call_param import (
-    ChatCompletionMessageToolCallParam as ChatCompletionMessageToolCallParam,
-)
 from .chat_completion_named_tool_choice_param import (
     ChatCompletionNamedToolChoiceParam as ChatCompletionNamedToolChoiceParam,
 )
@@ -82,6 +79,9 @@ from .chat_completion_function_call_option_param import (
 from .chat_completion_message_function_tool_call import (
     ChatCompletionMessageFunctionToolCall as ChatCompletionMessageFunctionToolCall,
 )
+from .chat_completion_message_tool_call_union_param import (
+    ChatCompletionMessageToolCallUnionParam as ChatCompletionMessageToolCallUnionParam,
+)
 from .chat_completion_content_part_input_audio_param import (
     ChatCompletionContentPartInputAudioParam as ChatCompletionContentPartInputAudioParam,
 )
src/openai/types/chat/chat_completion_assistant_message_param.py
@@ -6,8 +6,8 @@ from typing import Union, Iterable, Optional
 from typing_extensions import Literal, Required, TypeAlias, TypedDict
 
 from .chat_completion_content_part_text_param import ChatCompletionContentPartTextParam
-from .chat_completion_message_tool_call_param import ChatCompletionMessageToolCallParam
 from .chat_completion_content_part_refusal_param import ChatCompletionContentPartRefusalParam
+from .chat_completion_message_tool_call_union_param import ChatCompletionMessageToolCallUnionParam
 
 __all__ = ["ChatCompletionAssistantMessageParam", "Audio", "ContentArrayOfContentPart", "FunctionCall"]
 
@@ -66,5 +66,5 @@ class ChatCompletionAssistantMessageParam(TypedDict, total=False):
     refusal: Optional[str]
     """The refusal message by the assistant."""
 
-    tool_calls: Iterable[ChatCompletionMessageToolCallParam]
+    tool_calls: Iterable[ChatCompletionMessageToolCallUnionParam]
     """The tool calls generated by the model, such as function calls."""
src/openai/types/chat/chat_completion_message.py
@@ -5,7 +5,7 @@ from typing_extensions import Literal
 
 from ..._models import BaseModel
 from .chat_completion_audio import ChatCompletionAudio
-from .chat_completion_message_tool_call import ChatCompletionMessageToolCall
+from .chat_completion_message_tool_call import ChatCompletionMessageToolCallUnion
 
 __all__ = ["ChatCompletionMessage", "Annotation", "AnnotationURLCitation", "FunctionCall"]
 
@@ -75,5 +75,5 @@ class ChatCompletionMessage(BaseModel):
     model.
     """
 
-    tool_calls: Optional[List[ChatCompletionMessageToolCall]] = None
+    tool_calls: Optional[List[ChatCompletionMessageToolCallUnion]] = None
     """The tool calls generated by the model, such as function calls."""
src/openai/types/chat/chat_completion_message_tool_call.py
@@ -7,9 +7,9 @@ from ..._utils import PropertyInfo
 from .chat_completion_message_custom_tool_call import ChatCompletionMessageCustomToolCall
 from .chat_completion_message_function_tool_call import Function as Function, ChatCompletionMessageFunctionToolCall
 
-__all__ = ["ChatCompletionMessageToolCall", "Function"]
+__all__ = [ "Function", "ChatCompletionMessageToolCallUnion"]
 
-ChatCompletionMessageToolCall: TypeAlias = Annotated[
+ChatCompletionMessageToolCallUnion: TypeAlias = Annotated[
     Union[ChatCompletionMessageFunctionToolCall, ChatCompletionMessageCustomToolCall],
     PropertyInfo(discriminator="type"),
 ]
src/openai/types/chat/chat_completion_message_tool_call_param.py → src/openai/types/chat/chat_completion_message_tool_call_union_param.py
@@ -8,8 +8,8 @@ from typing_extensions import TypeAlias
 from .chat_completion_message_custom_tool_call_param import ChatCompletionMessageCustomToolCallParam
 from .chat_completion_message_function_tool_call_param import ChatCompletionMessageFunctionToolCallParam
 
-__all__ = ["ChatCompletionMessageToolCallParam"]
+__all__ = ["ChatCompletionMessageToolCallUnionParam"]
 
-ChatCompletionMessageToolCallParam: TypeAlias = Union[
+ChatCompletionMessageToolCallUnionParam: TypeAlias = Union[
     ChatCompletionMessageFunctionToolCallParam, ChatCompletionMessageCustomToolCallParam
 ]
.stats.yml
@@ -1,4 +1,4 @@
 configured_endpoints: 111
-openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-6a1bfd4738fff02ef5becc3fdb2bf0cd6c026f2c924d4147a2a515474477dd9a.yml
+openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-9cadfad609f94f20ebf74fdc06a80302f1a324dc69700a309a8056aabca82fd2.yml
 openapi_spec_hash: 3eb8d86c06f0bb5e1190983e5acfc9ba
-config_hash: a67c5e195a59855fe8a5db0dc61a3e7f
+config_hash: 68337b532875626269c304372a669f67
api.md
@@ -69,7 +69,7 @@ from openai.types.chat import (
     ChatCompletionMessageCustomToolCall,
     ChatCompletionMessageFunctionToolCall,
     ChatCompletionMessageParam,
-    ChatCompletionMessageToolCall,
+    ChatCompletionMessageToolCallUnion,
     ChatCompletionModality,
     ChatCompletionNamedToolChoice,
     ChatCompletionNamedToolChoiceCustom,