Skip to content

Commit bd7725c

Browse files
dtmeadowsstainless-app[bot]
authored andcommitted
chore(client): undo more naming changes
1 parent dd61a29 commit bd7725c

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

betathreadmessage.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -923,7 +923,7 @@ func (r *MessageAttachment) UnmarshalJSON(data []byte) error {
923923
}
924924

925925
// MessageAttachmentToolUnion contains all possible properties and values from
926-
// [CodeInterpreterTool], [MessageAttachmentToolAssistantToolsFileSearchTypeOnly].
926+
// [CodeInterpreterTool], [MessageAttachmentToolFileSearchTool].
927927
//
928928
// Use the methods beginning with 'As' to cast the union to one of its variants.
929929
type MessageAttachmentToolUnion struct {
@@ -939,7 +939,7 @@ func (u MessageAttachmentToolUnion) AsCodeInterpreterTool() (v CodeInterpreterTo
939939
return
940940
}
941941

942-
func (u MessageAttachmentToolUnion) AsAssistantToolsFileSearchTypeOnly() (v MessageAttachmentToolAssistantToolsFileSearchTypeOnly) {
942+
func (u MessageAttachmentToolUnion) AsFileSearchTool() (v MessageAttachmentToolFileSearchTool) {
943943
apijson.UnmarshalRoot(json.RawMessage(u.JSON.raw), &v)
944944
return
945945
}
@@ -951,7 +951,7 @@ func (r *MessageAttachmentToolUnion) UnmarshalJSON(data []byte) error {
951951
return apijson.UnmarshalRoot(data, r)
952952
}
953953

954-
type MessageAttachmentToolAssistantToolsFileSearchTypeOnly struct {
954+
type MessageAttachmentToolFileSearchTool struct {
955955
// The type of tool being defined: `file_search`
956956
Type constant.FileSearch `json:"type,required"`
957957
// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
@@ -963,8 +963,8 @@ type MessageAttachmentToolAssistantToolsFileSearchTypeOnly struct {
963963
}
964964

965965
// Returns the unmodified JSON received from the API
966-
func (r MessageAttachmentToolAssistantToolsFileSearchTypeOnly) RawJSON() string { return r.JSON.raw }
967-
func (r *MessageAttachmentToolAssistantToolsFileSearchTypeOnly) UnmarshalJSON(data []byte) error {
966+
func (r MessageAttachmentToolFileSearchTool) RawJSON() string { return r.JSON.raw }
967+
func (r *MessageAttachmentToolFileSearchTool) UnmarshalJSON(data []byte) error {
968968
return apijson.UnmarshalRoot(data, r)
969969
}
970970

responses/response.go

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13460,7 +13460,7 @@ func (u ToolCodeInterpreterContainerUnion) AsString() (v string) {
1346013460
return
1346113461
}
1346213462

13463-
func (u ToolCodeInterpreterContainerUnion) AsCodeInterpreterToolAuto() (v ToolCodeInterpreterContainerCodeInterpreterContainerAuto) {
13463+
func (u ToolCodeInterpreterContainerUnion) AsCodeInterpreterContainerAuto() (v ToolCodeInterpreterContainerCodeInterpreterContainerAuto) {
1346413464
apijson.UnmarshalRoot(json.RawMessage(u.JSON.raw), &v)
1346513465
return
1346613466
}
@@ -13647,7 +13647,7 @@ func ToolParamOfCodeInterpreter[
1364713647
case string:
1364813648
codeInterpreter.Container.OfString = param.NewOpt(v)
1364913649
case ToolCodeInterpreterContainerCodeInterpreterContainerAutoParam:
13650-
codeInterpreter.Container.OfCodeInterpreterToolAuto = &v
13650+
codeInterpreter.Container.OfCodeInterpreterContainerAuto = &v
1365113651
}
1365213652
return ToolUnionParam{OfCodeInterpreter: &codeInterpreter}
1365313653
}
@@ -14370,13 +14370,13 @@ func (r *ToolCodeInterpreterParam) UnmarshalJSON(data []byte) error {
1437014370
//
1437114371
// Use [param.IsOmitted] to confirm if a field is set.
1437214372
type ToolCodeInterpreterContainerUnionParam struct {
14373-
OfString param.Opt[string] `json:",omitzero,inline"`
14374-
OfCodeInterpreterToolAuto *ToolCodeInterpreterContainerCodeInterpreterContainerAutoParam `json:",omitzero,inline"`
14373+
OfString param.Opt[string] `json:",omitzero,inline"`
14374+
OfCodeInterpreterContainerAuto *ToolCodeInterpreterContainerCodeInterpreterContainerAutoParam `json:",omitzero,inline"`
1437514375
paramUnion
1437614376
}
1437714377

1437814378
func (u ToolCodeInterpreterContainerUnionParam) MarshalJSON() ([]byte, error) {
14379-
return param.MarshalUnion(u, u.OfString, u.OfCodeInterpreterToolAuto)
14379+
return param.MarshalUnion(u, u.OfString, u.OfCodeInterpreterContainerAuto)
1438014380
}
1438114381
func (u *ToolCodeInterpreterContainerUnionParam) UnmarshalJSON(data []byte) error {
1438214382
return apijson.UnmarshalRoot(data, u)
@@ -14385,8 +14385,8 @@ func (u *ToolCodeInterpreterContainerUnionParam) UnmarshalJSON(data []byte) erro
1438514385
func (u *ToolCodeInterpreterContainerUnionParam) asAny() any {
1438614386
if !param.IsOmitted(u.OfString) {
1438714387
return &u.OfString.Value
14388-
} else if !param.IsOmitted(u.OfCodeInterpreterToolAuto) {
14389-
return u.OfCodeInterpreterToolAuto
14388+
} else if !param.IsOmitted(u.OfCodeInterpreterContainerAuto) {
14389+
return u.OfCodeInterpreterContainerAuto
1439014390
}
1439114391
return nil
1439214392
}

0 commit comments

Comments
 (0)