From fe67abb97ed472bad359cc606c2d63289277cabf Mon Sep 17 00:00:00 2001 From: Donnie Flood Date: Wed, 15 Nov 2023 09:06:57 -0700 Subject: [PATCH] fix: add beta assistant header to CreateMessage call (#566) --- messages.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/messages.go b/messages.go index 4e691a8ba..3fd377fcb 100644 --- a/messages.go +++ b/messages.go @@ -71,7 +71,7 @@ type MessageFilesList struct { // CreateMessage creates a new message. func (c *Client) CreateMessage(ctx context.Context, threadID string, request MessageRequest) (msg Message, err error) { urlSuffix := fmt.Sprintf("/threads/%s/%s", threadID, messagesSuffix) - req, err := c.newRequest(ctx, http.MethodPost, c.fullURL(urlSuffix), withBody(request)) + req, err := c.newRequest(ctx, http.MethodPost, c.fullURL(urlSuffix), withBody(request), withBetaAssistantV1()) if err != nil { return }