@letta-ai/letta-client 0.1.50 → 0.1.52

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (195) hide show
  1. package/api/resources/agents/client/Client.js +15 -12
  2. package/api/resources/agents/client/requests/BodyUploadAgentSerialized.d.ts +6 -2
  3. package/api/resources/agents/resources/blocks/client/Client.js +5 -5
  4. package/api/resources/agents/resources/context/client/Client.js +1 -1
  5. package/api/resources/agents/resources/coreMemory/client/Client.js +1 -1
  6. package/api/resources/agents/resources/memoryVariables/client/Client.js +1 -1
  7. package/api/resources/agents/resources/messages/client/Client.d.ts +6 -3
  8. package/api/resources/agents/resources/messages/client/Client.js +14 -11
  9. package/api/resources/agents/resources/messages/client/requests/index.d.ts +0 -1
  10. package/api/resources/agents/resources/messages/types/MessagesModifyRequest.d.ts +5 -0
  11. package/api/resources/agents/resources/messages/types/MessagesModifyResponse.d.ts +5 -0
  12. package/api/resources/agents/resources/messages/types/index.d.ts +2 -1
  13. package/api/resources/agents/resources/messages/types/index.js +2 -1
  14. package/api/resources/agents/resources/passages/client/Client.js +3 -3
  15. package/api/resources/agents/resources/sources/client/Client.js +3 -3
  16. package/api/resources/agents/resources/templates/client/Client.js +3 -3
  17. package/api/resources/agents/resources/tools/client/Client.js +3 -3
  18. package/api/resources/blocks/client/Client.js +6 -6
  19. package/api/resources/health/client/Client.js +1 -1
  20. package/api/resources/identities/client/Client.js +6 -6
  21. package/api/resources/jobs/client/Client.js +4 -4
  22. package/api/resources/models/client/Client.js +2 -2
  23. package/api/resources/providers/client/Client.js +4 -4
  24. package/api/resources/runs/client/Client.js +7 -7
  25. package/api/resources/sources/client/Client.js +6 -6
  26. package/api/resources/sources/resources/files/client/Client.js +3 -3
  27. package/api/resources/sources/resources/passages/client/Client.js +1 -1
  28. package/api/resources/steps/client/Client.js +2 -2
  29. package/api/resources/tag/client/Client.js +1 -1
  30. package/api/resources/templates/client/Client.js +1 -1
  31. package/api/resources/tools/client/Client.js +11 -11
  32. package/api/resources/voice/client/Client.js +1 -1
  33. package/{dist/api/types/ChatCompletionMessageToolCallOutput.d.ts → api/types/ChatCompletionMessageToolCall.d.ts} +1 -1
  34. package/api/types/Message.d.ts +1 -1
  35. package/api/types/UpdateAssistantMessage.d.ts +8 -0
  36. package/api/types/UpdateAssistantMessageContent.d.ts +5 -0
  37. package/api/types/UpdateReasoningMessage.d.ts +8 -0
  38. package/api/types/UpdateReasoningMessageReasoning.d.ts +5 -0
  39. package/api/types/UpdateSystemMessage.d.ts +8 -0
  40. package/api/types/UpdateSystemMessageContent.d.ts +5 -0
  41. package/api/types/UpdateUserMessage.d.ts +8 -0
  42. package/api/types/UpdateUserMessageContent.d.ts +5 -0
  43. package/api/types/UpdateUserMessageContent.js +5 -0
  44. package/api/types/index.d.ts +9 -3
  45. package/api/types/index.js +9 -3
  46. package/dist/api/resources/agents/client/Client.js +15 -12
  47. package/dist/api/resources/agents/client/requests/BodyUploadAgentSerialized.d.ts +6 -2
  48. package/dist/api/resources/agents/resources/blocks/client/Client.js +5 -5
  49. package/dist/api/resources/agents/resources/context/client/Client.js +1 -1
  50. package/dist/api/resources/agents/resources/coreMemory/client/Client.js +1 -1
  51. package/dist/api/resources/agents/resources/memoryVariables/client/Client.js +1 -1
  52. package/dist/api/resources/agents/resources/messages/client/Client.d.ts +6 -3
  53. package/dist/api/resources/agents/resources/messages/client/Client.js +14 -11
  54. package/dist/api/resources/agents/resources/messages/client/requests/index.d.ts +0 -1
  55. package/dist/api/resources/agents/resources/messages/types/MessagesModifyRequest.d.ts +5 -0
  56. package/dist/api/resources/agents/resources/messages/types/MessagesModifyRequest.js +5 -0
  57. package/dist/api/resources/agents/resources/messages/types/MessagesModifyResponse.d.ts +5 -0
  58. package/dist/api/resources/agents/resources/messages/types/MessagesModifyResponse.js +5 -0
  59. package/dist/api/resources/agents/resources/messages/types/index.d.ts +2 -1
  60. package/dist/api/resources/agents/resources/messages/types/index.js +2 -1
  61. package/dist/api/resources/agents/resources/passages/client/Client.js +3 -3
  62. package/dist/api/resources/agents/resources/sources/client/Client.js +3 -3
  63. package/dist/api/resources/agents/resources/templates/client/Client.js +3 -3
  64. package/dist/api/resources/agents/resources/tools/client/Client.js +3 -3
  65. package/dist/api/resources/blocks/client/Client.js +6 -6
  66. package/dist/api/resources/health/client/Client.js +1 -1
  67. package/dist/api/resources/identities/client/Client.js +6 -6
  68. package/dist/api/resources/jobs/client/Client.js +4 -4
  69. package/dist/api/resources/models/client/Client.js +2 -2
  70. package/dist/api/resources/providers/client/Client.js +4 -4
  71. package/dist/api/resources/runs/client/Client.js +7 -7
  72. package/dist/api/resources/sources/client/Client.js +6 -6
  73. package/dist/api/resources/sources/resources/files/client/Client.js +3 -3
  74. package/dist/api/resources/sources/resources/passages/client/Client.js +1 -1
  75. package/dist/api/resources/steps/client/Client.js +2 -2
  76. package/dist/api/resources/tag/client/Client.js +1 -1
  77. package/dist/api/resources/templates/client/Client.js +1 -1
  78. package/dist/api/resources/tools/client/Client.js +11 -11
  79. package/dist/api/resources/voice/client/Client.js +1 -1
  80. package/{api/types/ChatCompletionMessageToolCallOutput.d.ts → dist/api/types/ChatCompletionMessageToolCall.d.ts} +1 -1
  81. package/dist/api/types/ChatCompletionMessageToolCall.js +5 -0
  82. package/dist/api/types/Message.d.ts +1 -1
  83. package/dist/api/types/UpdateAssistantMessage.d.ts +8 -0
  84. package/dist/api/types/UpdateAssistantMessage.js +5 -0
  85. package/dist/api/types/UpdateAssistantMessageContent.d.ts +5 -0
  86. package/dist/api/types/UpdateAssistantMessageContent.js +5 -0
  87. package/dist/api/types/UpdateReasoningMessage.d.ts +8 -0
  88. package/dist/api/types/UpdateReasoningMessage.js +5 -0
  89. package/dist/api/types/UpdateReasoningMessageReasoning.d.ts +5 -0
  90. package/dist/api/types/UpdateReasoningMessageReasoning.js +5 -0
  91. package/dist/api/types/UpdateSystemMessage.d.ts +8 -0
  92. package/dist/api/types/UpdateSystemMessage.js +5 -0
  93. package/dist/api/types/UpdateSystemMessageContent.d.ts +5 -0
  94. package/dist/api/types/UpdateSystemMessageContent.js +5 -0
  95. package/dist/api/types/UpdateUserMessage.d.ts +8 -0
  96. package/dist/api/types/UpdateUserMessage.js +5 -0
  97. package/dist/api/types/UpdateUserMessageContent.d.ts +5 -0
  98. package/dist/api/types/UpdateUserMessageContent.js +5 -0
  99. package/dist/api/types/index.d.ts +9 -3
  100. package/dist/api/types/index.js +9 -3
  101. package/dist/serialization/resources/agents/resources/messages/client/requests/index.d.ts +0 -1
  102. package/dist/serialization/resources/agents/resources/messages/client/requests/index.js +1 -3
  103. package/dist/serialization/resources/agents/resources/messages/types/MessagesModifyRequest.d.ts +14 -0
  104. package/dist/serialization/{types/ChatCompletionMessageToolCallInput.js → resources/agents/resources/messages/types/MessagesModifyRequest.js} +12 -10
  105. package/dist/serialization/resources/agents/resources/messages/types/MessagesModifyResponse.d.ts +14 -0
  106. package/dist/serialization/resources/agents/resources/messages/types/MessagesModifyResponse.js +50 -0
  107. package/dist/serialization/resources/agents/resources/messages/types/index.d.ts +2 -1
  108. package/dist/serialization/resources/agents/resources/messages/types/index.js +2 -1
  109. package/{serialization/types/ChatCompletionMessageToolCallOutput.d.ts → dist/serialization/types/ChatCompletionMessageToolCall.d.ts} +2 -2
  110. package/{serialization/types/ChatCompletionMessageToolCallOutput.js → dist/serialization/types/ChatCompletionMessageToolCall.js} +2 -2
  111. package/dist/serialization/types/Message.d.ts +2 -2
  112. package/dist/serialization/types/Message.js +2 -2
  113. package/dist/serialization/types/UpdateAssistantMessage.d.ts +14 -0
  114. package/dist/serialization/types/UpdateAssistantMessage.js +45 -0
  115. package/dist/serialization/types/UpdateAssistantMessageContent.d.ts +11 -0
  116. package/{serialization/types/OpenaiTypesChatChatCompletionMessageToolCallFunction.js → dist/serialization/types/UpdateAssistantMessageContent.js} +3 -7
  117. package/dist/serialization/types/UpdateReasoningMessage.d.ts +14 -0
  118. package/dist/serialization/types/UpdateReasoningMessage.js +45 -0
  119. package/dist/serialization/types/UpdateReasoningMessageReasoning.d.ts +11 -0
  120. package/dist/serialization/types/{OpenaiTypesChatChatCompletionMessageToolCallFunction.js → UpdateReasoningMessageReasoning.js} +3 -7
  121. package/dist/serialization/types/UpdateSystemMessage.d.ts +14 -0
  122. package/dist/serialization/types/UpdateSystemMessage.js +45 -0
  123. package/dist/serialization/types/UpdateSystemMessageContent.d.ts +11 -0
  124. package/dist/serialization/{resources/agents/resources/messages/types/MessageUpdateContent.js → types/UpdateSystemMessageContent.js} +4 -4
  125. package/dist/serialization/types/UpdateUserMessage.d.ts +14 -0
  126. package/dist/serialization/types/UpdateUserMessage.js +45 -0
  127. package/dist/serialization/types/UpdateUserMessageContent.d.ts +11 -0
  128. package/{serialization/resources/agents/resources/messages/types/MessageUpdateContent.js → dist/serialization/types/UpdateUserMessageContent.js} +4 -4
  129. package/dist/serialization/types/index.d.ts +9 -3
  130. package/dist/serialization/types/index.js +9 -3
  131. package/dist/version.d.ts +1 -1
  132. package/dist/version.js +1 -1
  133. package/package.json +1 -1
  134. package/reference.md +6 -3
  135. package/serialization/resources/agents/resources/messages/client/requests/index.d.ts +0 -1
  136. package/serialization/resources/agents/resources/messages/client/requests/index.js +1 -3
  137. package/serialization/resources/agents/resources/messages/types/MessagesModifyRequest.d.ts +14 -0
  138. package/serialization/resources/agents/resources/messages/types/MessagesModifyRequest.js +50 -0
  139. package/serialization/resources/agents/resources/messages/types/MessagesModifyResponse.d.ts +14 -0
  140. package/serialization/resources/agents/resources/messages/types/MessagesModifyResponse.js +50 -0
  141. package/serialization/resources/agents/resources/messages/types/index.d.ts +2 -1
  142. package/serialization/resources/agents/resources/messages/types/index.js +2 -1
  143. package/{dist/serialization/types/ChatCompletionMessageToolCallOutput.d.ts → serialization/types/ChatCompletionMessageToolCall.d.ts} +2 -2
  144. package/{dist/serialization/types/ChatCompletionMessageToolCallOutput.js → serialization/types/ChatCompletionMessageToolCall.js} +2 -2
  145. package/serialization/types/Message.d.ts +2 -2
  146. package/serialization/types/Message.js +2 -2
  147. package/serialization/types/UpdateAssistantMessage.d.ts +14 -0
  148. package/serialization/types/UpdateAssistantMessage.js +45 -0
  149. package/serialization/types/UpdateAssistantMessageContent.d.ts +11 -0
  150. package/serialization/types/UpdateAssistantMessageContent.js +42 -0
  151. package/serialization/types/UpdateReasoningMessage.d.ts +14 -0
  152. package/serialization/types/UpdateReasoningMessage.js +45 -0
  153. package/serialization/types/UpdateReasoningMessageReasoning.d.ts +11 -0
  154. package/serialization/types/UpdateReasoningMessageReasoning.js +42 -0
  155. package/serialization/types/UpdateSystemMessage.d.ts +14 -0
  156. package/serialization/types/UpdateSystemMessage.js +45 -0
  157. package/serialization/types/UpdateSystemMessageContent.d.ts +11 -0
  158. package/serialization/types/UpdateSystemMessageContent.js +42 -0
  159. package/serialization/types/UpdateUserMessage.d.ts +14 -0
  160. package/serialization/types/UpdateUserMessage.js +45 -0
  161. package/serialization/types/UpdateUserMessageContent.d.ts +11 -0
  162. package/serialization/types/UpdateUserMessageContent.js +42 -0
  163. package/serialization/types/index.d.ts +9 -3
  164. package/serialization/types/index.js +9 -3
  165. package/version.d.ts +1 -1
  166. package/version.js +1 -1
  167. package/api/resources/agents/resources/messages/client/requests/MessageUpdate.d.ts +0 -20
  168. package/api/resources/agents/resources/messages/types/MessageUpdateContent.d.ts +0 -8
  169. package/api/types/ChatCompletionMessageToolCallInput.d.ts +0 -11
  170. package/api/types/OpenaiTypesChatChatCompletionMessageToolCallFunction.d.ts +0 -9
  171. package/dist/api/resources/agents/resources/messages/client/requests/MessageUpdate.d.ts +0 -20
  172. package/dist/api/resources/agents/resources/messages/types/MessageUpdateContent.d.ts +0 -8
  173. package/dist/api/types/ChatCompletionMessageToolCallInput.d.ts +0 -11
  174. package/dist/api/types/OpenaiTypesChatChatCompletionMessageToolCallFunction.d.ts +0 -9
  175. package/dist/serialization/resources/agents/resources/messages/client/requests/MessageUpdate.d.ts +0 -19
  176. package/dist/serialization/resources/agents/resources/messages/client/requests/MessageUpdate.js +0 -50
  177. package/dist/serialization/resources/agents/resources/messages/types/MessageUpdateContent.d.ts +0 -11
  178. package/dist/serialization/types/ChatCompletionMessageToolCallInput.d.ts +0 -16
  179. package/dist/serialization/types/OpenaiTypesChatChatCompletionMessageToolCallFunction.d.ts +0 -14
  180. package/serialization/resources/agents/resources/messages/client/requests/MessageUpdate.d.ts +0 -19
  181. package/serialization/resources/agents/resources/messages/client/requests/MessageUpdate.js +0 -50
  182. package/serialization/resources/agents/resources/messages/types/MessageUpdateContent.d.ts +0 -11
  183. package/serialization/types/ChatCompletionMessageToolCallInput.d.ts +0 -16
  184. package/serialization/types/ChatCompletionMessageToolCallInput.js +0 -48
  185. package/serialization/types/OpenaiTypesChatChatCompletionMessageToolCallFunction.d.ts +0 -14
  186. /package/api/resources/agents/resources/messages/{client/requests/MessageUpdate.js → types/MessagesModifyRequest.js} +0 -0
  187. /package/api/resources/agents/resources/messages/types/{MessageUpdateContent.js → MessagesModifyResponse.js} +0 -0
  188. /package/api/types/{ChatCompletionMessageToolCallInput.js → ChatCompletionMessageToolCall.js} +0 -0
  189. /package/api/types/{ChatCompletionMessageToolCallOutput.js → UpdateAssistantMessage.js} +0 -0
  190. /package/api/types/{OpenaiTypesChatChatCompletionMessageToolCallFunction.js → UpdateAssistantMessageContent.js} +0 -0
  191. /package/{dist/api/resources/agents/resources/messages/client/requests/MessageUpdate.js → api/types/UpdateReasoningMessage.js} +0 -0
  192. /package/{dist/api/resources/agents/resources/messages/types/MessageUpdateContent.js → api/types/UpdateReasoningMessageReasoning.js} +0 -0
  193. /package/{dist/api/types/ChatCompletionMessageToolCallInput.js → api/types/UpdateSystemMessage.js} +0 -0
  194. /package/{dist/api/types/ChatCompletionMessageToolCallOutput.js → api/types/UpdateSystemMessageContent.js} +0 -0
  195. /package/{dist/api/types/OpenaiTypesChatChatCompletionMessageToolCallFunction.js → api/types/UpdateUserMessage.js} +0 -0
@@ -39,7 +39,7 @@ export interface Message {
39
39
  /** The name of the participant. */
40
40
  name?: string;
41
41
  /** The list of tool calls requested. */
42
- toolCalls?: Letta.ChatCompletionMessageToolCallOutput[];
42
+ toolCalls?: Letta.ChatCompletionMessageToolCall[];
43
43
  /** The id of the tool call. */
44
44
  toolCallId?: string;
45
45
  /** The id of the step that this message was created in. */
@@ -0,0 +1,8 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../index";
5
+ export interface UpdateAssistantMessage {
6
+ content: Letta.UpdateAssistantMessageContent;
7
+ messageType: "assistant_message";
8
+ }
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../index";
5
+ export type UpdateAssistantMessageContent = string | Letta.TextContent[];
@@ -0,0 +1,8 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../index";
5
+ export interface UpdateReasoningMessage {
6
+ reasoning: Letta.UpdateReasoningMessageReasoning;
7
+ messageType: "reasoning_message";
8
+ }
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../index";
5
+ export type UpdateReasoningMessageReasoning = string | Letta.TextContent[];
@@ -0,0 +1,8 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../index";
5
+ export interface UpdateSystemMessage {
6
+ content: Letta.UpdateSystemMessageContent;
7
+ messageType: "system_message";
8
+ }
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../index";
5
+ export type UpdateSystemMessageContent = string | Letta.TextContent[];
@@ -0,0 +1,8 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../index";
5
+ export interface UpdateUserMessage {
6
+ content: Letta.UpdateUserMessageContent;
7
+ messageType: "user_message";
8
+ }
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../index";
5
+ export type UpdateUserMessageContent = string | Letta.TextContent[];
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -34,8 +34,7 @@ export * from "./ChatCompletionDeveloperMessageParamContent";
34
34
  export * from "./ChatCompletionDeveloperMessageParam";
35
35
  export * from "./ChatCompletionFunctionCallOptionParam";
36
36
  export * from "./ChatCompletionFunctionMessageParam";
37
- export * from "./ChatCompletionMessageToolCallInput";
38
- export * from "./ChatCompletionMessageToolCallOutput";
37
+ export * from "./ChatCompletionMessageToolCall";
39
38
  export * from "./ChatCompletionMessageToolCallParam";
40
39
  export * from "./ChatCompletionNamedToolChoiceParam";
41
40
  export * from "./ChatCompletionPredictionContentParamContent";
@@ -149,6 +148,14 @@ export * from "./ToolReturn";
149
148
  export * from "./ToolReturnMessageStatus";
150
149
  export * from "./ToolReturnMessage";
151
150
  export * from "./ToolType";
151
+ export * from "./UpdateAssistantMessageContent";
152
+ export * from "./UpdateAssistantMessage";
153
+ export * from "./UpdateReasoningMessageReasoning";
154
+ export * from "./UpdateReasoningMessage";
155
+ export * from "./UpdateSystemMessageContent";
156
+ export * from "./UpdateSystemMessage";
157
+ export * from "./UpdateUserMessageContent";
158
+ export * from "./UpdateUserMessage";
152
159
  export * from "./UsageStatistics";
153
160
  export * from "./User";
154
161
  export * from "./UserCreate";
@@ -157,7 +164,6 @@ export * from "./UserMessage";
157
164
  export * from "./UserUpdate";
158
165
  export * from "./ValidationErrorLocItem";
159
166
  export * from "./ValidationError";
160
- export * from "./OpenaiTypesChatChatCompletionMessageToolCallFunction";
161
167
  export * from "./OpenaiTypesChatChatCompletionMessageToolCallParamFunction";
162
168
  export * from "./OpenaiTypesChatChatCompletionNamedToolChoiceParamFunction";
163
169
  export * from "./OpenaiTypesChatCompletionCreateParamsFunction";
@@ -50,8 +50,7 @@ __exportStar(require("./ChatCompletionDeveloperMessageParamContent"), exports);
50
50
  __exportStar(require("./ChatCompletionDeveloperMessageParam"), exports);
51
51
  __exportStar(require("./ChatCompletionFunctionCallOptionParam"), exports);
52
52
  __exportStar(require("./ChatCompletionFunctionMessageParam"), exports);
53
- __exportStar(require("./ChatCompletionMessageToolCallInput"), exports);
54
- __exportStar(require("./ChatCompletionMessageToolCallOutput"), exports);
53
+ __exportStar(require("./ChatCompletionMessageToolCall"), exports);
55
54
  __exportStar(require("./ChatCompletionMessageToolCallParam"), exports);
56
55
  __exportStar(require("./ChatCompletionNamedToolChoiceParam"), exports);
57
56
  __exportStar(require("./ChatCompletionPredictionContentParamContent"), exports);
@@ -165,6 +164,14 @@ __exportStar(require("./ToolReturn"), exports);
165
164
  __exportStar(require("./ToolReturnMessageStatus"), exports);
166
165
  __exportStar(require("./ToolReturnMessage"), exports);
167
166
  __exportStar(require("./ToolType"), exports);
167
+ __exportStar(require("./UpdateAssistantMessageContent"), exports);
168
+ __exportStar(require("./UpdateAssistantMessage"), exports);
169
+ __exportStar(require("./UpdateReasoningMessageReasoning"), exports);
170
+ __exportStar(require("./UpdateReasoningMessage"), exports);
171
+ __exportStar(require("./UpdateSystemMessageContent"), exports);
172
+ __exportStar(require("./UpdateSystemMessage"), exports);
173
+ __exportStar(require("./UpdateUserMessageContent"), exports);
174
+ __exportStar(require("./UpdateUserMessage"), exports);
168
175
  __exportStar(require("./UsageStatistics"), exports);
169
176
  __exportStar(require("./User"), exports);
170
177
  __exportStar(require("./UserCreate"), exports);
@@ -173,7 +180,6 @@ __exportStar(require("./UserMessage"), exports);
173
180
  __exportStar(require("./UserUpdate"), exports);
174
181
  __exportStar(require("./ValidationErrorLocItem"), exports);
175
182
  __exportStar(require("./ValidationError"), exports);
176
- __exportStar(require("./OpenaiTypesChatChatCompletionMessageToolCallFunction"), exports);
177
183
  __exportStar(require("./OpenaiTypesChatChatCompletionMessageToolCallParamFunction"), exports);
178
184
  __exportStar(require("./OpenaiTypesChatChatCompletionNamedToolChoiceParamFunction"), exports);
179
185
  __exportStar(require("./OpenaiTypesChatCompletionCreateParamsFunction"), exports);
@@ -181,7 +181,7 @@ class Agents {
181
181
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
182
182
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, "v1/agents/"),
183
183
  method: "GET",
184
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
184
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
185
185
  contentType: "application/json",
186
186
  queryParameters: _queryParams,
187
187
  requestType: "json",
@@ -248,7 +248,7 @@ class Agents {
248
248
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
249
249
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, "v1/agents/"),
250
250
  method: "POST",
251
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, "X-Project": project != null ? project : undefined }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
251
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, "X-Project": project != null ? project : undefined }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
252
252
  contentType: "application/json",
253
253
  requestType: "json",
254
254
  body: serializers.CreateAgentRequest.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
@@ -314,7 +314,7 @@ class Agents {
314
314
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
315
315
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/download`),
316
316
  method: "GET",
317
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
317
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
318
318
  contentType: "application/json",
319
319
  requestType: "json",
320
320
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -372,8 +372,11 @@ class Agents {
372
372
  return __awaiter(this, void 0, void 0, function* () {
373
373
  var _a, _b, _c;
374
374
  const _queryParams = {};
375
- if (request.markAsCopy != null) {
376
- _queryParams["mark_as_copy"] = request.markAsCopy.toString();
375
+ if (request.appendCopySuffix != null) {
376
+ _queryParams["append_copy_suffix"] = request.appendCopySuffix.toString();
377
+ }
378
+ if (request.overrideExistingTools != null) {
379
+ _queryParams["override_existing_tools"] = request.overrideExistingTools.toString();
377
380
  }
378
381
  const _request = yield core.newFormData();
379
382
  yield _request.appendFile("file", file);
@@ -381,7 +384,7 @@ class Agents {
381
384
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
382
385
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, "v1/agents/upload"),
383
386
  method: "POST",
384
- headers: Object.assign(Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), _maybeEncodedRequest.headers), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
387
+ headers: Object.assign(Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), _maybeEncodedRequest.headers), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
385
388
  queryParameters: _queryParams,
386
389
  requestType: "file",
387
390
  duplex: _maybeEncodedRequest.duplex,
@@ -448,7 +451,7 @@ class Agents {
448
451
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
449
452
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}`),
450
453
  method: "GET",
451
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
454
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
452
455
  contentType: "application/json",
453
456
  requestType: "json",
454
457
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -513,7 +516,7 @@ class Agents {
513
516
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
514
517
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}`),
515
518
  method: "DELETE",
516
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
519
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
517
520
  contentType: "application/json",
518
521
  requestType: "json",
519
522
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -573,7 +576,7 @@ class Agents {
573
576
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
574
577
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}`),
575
578
  method: "PATCH",
576
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
579
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
577
580
  contentType: "application/json",
578
581
  requestType: "json",
579
582
  body: serializers.UpdateAgent.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -643,7 +646,7 @@ class Agents {
643
646
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
644
647
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/archival-memory/${encodeURIComponent(memoryId)}`),
645
648
  method: "PATCH",
646
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
649
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
647
650
  contentType: "application/json",
648
651
  requestType: "json",
649
652
  body: serializers.PassageUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -715,7 +718,7 @@ class Agents {
715
718
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
716
719
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/reset-messages`),
717
720
  method: "PATCH",
718
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
721
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
719
722
  contentType: "application/json",
720
723
  queryParameters: _queryParams,
721
724
  requestType: "json",
@@ -781,7 +784,7 @@ class Agents {
781
784
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
782
785
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, "v1/agents/search"),
783
786
  method: "POST",
784
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
787
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
785
788
  contentType: "application/json",
786
789
  requestType: "json",
787
790
  body: serializers.AgentsSearchRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -7,7 +7,11 @@
7
7
  */
8
8
  export interface BodyUploadAgentSerialized {
9
9
  /**
10
- * Whether to mark the uploaded agent as a copy
10
+ * If set to True, appends "_copy" to the end of the agent name.
11
11
  */
12
- markAsCopy?: boolean;
12
+ appendCopySuffix?: boolean;
13
+ /**
14
+ * If set to True, existing tools can get their source code overwritten by the uploaded tool definitions. Note that Letta core tools can never be updated externally.
15
+ */
16
+ overrideExistingTools?: boolean;
13
17
  }
@@ -77,7 +77,7 @@ class Blocks {
77
77
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
78
78
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/core-memory/blocks/${encodeURIComponent(blockLabel)}`),
79
79
  method: "GET",
80
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
80
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
81
81
  contentType: "application/json",
82
82
  requestType: "json",
83
83
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -144,7 +144,7 @@ class Blocks {
144
144
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
145
145
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/core-memory/blocks/${encodeURIComponent(blockLabel)}`),
146
146
  method: "PATCH",
147
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
147
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
148
148
  contentType: "application/json",
149
149
  requestType: "json",
150
150
  body: serializers.BlockUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -210,7 +210,7 @@ class Blocks {
210
210
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
211
211
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/core-memory/blocks`),
212
212
  method: "GET",
213
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
213
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
214
214
  contentType: "application/json",
215
215
  requestType: "json",
216
216
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -276,7 +276,7 @@ class Blocks {
276
276
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
277
277
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/core-memory/blocks/attach/${encodeURIComponent(blockId)}`),
278
278
  method: "PATCH",
279
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
279
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
280
280
  contentType: "application/json",
281
281
  requestType: "json",
282
282
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -342,7 +342,7 @@ class Blocks {
342
342
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
343
343
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/core-memory/blocks/detach/${encodeURIComponent(blockId)}`),
344
344
  method: "PATCH",
345
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
345
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
346
346
  contentType: "application/json",
347
347
  requestType: "json",
348
348
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -76,7 +76,7 @@ class Context {
76
76
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
77
77
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/context`),
78
78
  method: "GET",
79
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
79
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
80
80
  contentType: "application/json",
81
81
  requestType: "json",
82
82
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -77,7 +77,7 @@ class CoreMemory {
77
77
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
78
78
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/core-memory`),
79
79
  method: "GET",
80
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
80
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
81
81
  contentType: "application/json",
82
82
  requestType: "json",
83
83
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -78,7 +78,7 @@ class MemoryVariables {
78
78
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
79
79
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/core-memory/variables`),
80
80
  method: "GET",
81
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
81
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
82
82
  contentType: "application/json",
83
83
  requestType: "json",
84
84
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -63,15 +63,18 @@ export declare class Messages {
63
63
  *
64
64
  * @param {string} agentId
65
65
  * @param {string} messageId
66
- * @param {Letta.agents.MessageUpdate} request
66
+ * @param {Letta.agents.MessagesModifyRequest} request
67
67
  * @param {Messages.RequestOptions} requestOptions - Request-specific configuration.
68
68
  *
69
69
  * @throws {@link Letta.UnprocessableEntityError}
70
70
  *
71
71
  * @example
72
- * await client.agents.messages.modify("agent_id", "message_id")
72
+ * await client.agents.messages.modify("agent_id", "message_id", {
73
+ * content: "content",
74
+ * messageType: "system_message"
75
+ * })
73
76
  */
74
- modify(agentId: string, messageId: string, request?: Letta.agents.MessageUpdate, requestOptions?: Messages.RequestOptions): Promise<Letta.Message>;
77
+ modify(agentId: string, messageId: string, request: Letta.agents.MessagesModifyRequest, requestOptions?: Messages.RequestOptions): Promise<Letta.agents.MessagesModifyResponse>;
75
78
  /**
76
79
  * Process a user message and return the agent's response.
77
80
  * This endpoint accepts a message from a user and processes it through the agent.
@@ -97,7 +97,7 @@ class Messages {
97
97
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
98
98
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/messages`),
99
99
  method: "GET",
100
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
100
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
101
101
  contentType: "application/json",
102
102
  queryParameters: _queryParams,
103
103
  requestType: "json",
@@ -170,7 +170,7 @@ class Messages {
170
170
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
171
171
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/messages`),
172
172
  method: "POST",
173
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
173
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
174
174
  contentType: "application/json",
175
175
  requestType: "json",
176
176
  body: serializers.LettaRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -224,30 +224,33 @@ class Messages {
224
224
  *
225
225
  * @param {string} agentId
226
226
  * @param {string} messageId
227
- * @param {Letta.agents.MessageUpdate} request
227
+ * @param {Letta.agents.MessagesModifyRequest} request
228
228
  * @param {Messages.RequestOptions} requestOptions - Request-specific configuration.
229
229
  *
230
230
  * @throws {@link Letta.UnprocessableEntityError}
231
231
  *
232
232
  * @example
233
- * await client.agents.messages.modify("agent_id", "message_id")
233
+ * await client.agents.messages.modify("agent_id", "message_id", {
234
+ * content: "content",
235
+ * messageType: "system_message"
236
+ * })
234
237
  */
235
- modify(agentId_1, messageId_1) {
236
- return __awaiter(this, arguments, void 0, function* (agentId, messageId, request = {}, requestOptions) {
238
+ modify(agentId, messageId, request, requestOptions) {
239
+ return __awaiter(this, void 0, void 0, function* () {
237
240
  var _a, _b, _c;
238
241
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
239
242
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/messages/${encodeURIComponent(messageId)}`),
240
243
  method: "PATCH",
241
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
244
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
242
245
  contentType: "application/json",
243
246
  requestType: "json",
244
- body: serializers.agents.MessageUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
247
+ body: serializers.agents.MessagesModifyRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
245
248
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
246
249
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
247
250
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
248
251
  });
249
252
  if (_response.ok) {
250
- return serializers.Message.parseOrThrow(_response.body, {
253
+ return serializers.agents.MessagesModifyResponse.parseOrThrow(_response.body, {
251
254
  unrecognizedObjectKeys: "passthrough",
252
255
  allowUnrecognizedUnionMembers: true,
253
256
  allowUnrecognizedEnumValues: true,
@@ -298,7 +301,7 @@ class Messages {
298
301
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
299
302
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/messages/stream`),
300
303
  method: "POST",
301
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
304
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
302
305
  contentType: "application/json",
303
306
  requestType: "json",
304
307
  body: serializers.agents.LettaStreamingRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -382,7 +385,7 @@ class Messages {
382
385
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
383
386
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/messages/async`),
384
387
  method: "POST",
385
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
388
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
386
389
  contentType: "application/json",
387
390
  requestType: "json",
388
391
  body: serializers.LettaRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -1,3 +1,2 @@
1
1
  export { type MessagesListRequest } from "./MessagesListRequest";
2
- export { type MessageUpdate } from "./MessageUpdate";
3
2
  export { type LettaStreamingRequest } from "./LettaStreamingRequest";
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../../../../../index";
5
+ export type MessagesModifyRequest = Letta.UpdateSystemMessage | Letta.UpdateUserMessage | Letta.UpdateReasoningMessage | Letta.UpdateAssistantMessage;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../../../../../index";
5
+ export type MessagesModifyResponse = Letta.UpdateSystemMessage | Letta.UpdateUserMessage | Letta.UpdateReasoningMessage | Letta.UpdateAssistantMessage;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,2 +1,3 @@
1
- export * from "./MessageUpdateContent";
1
+ export * from "./MessagesModifyRequest";
2
+ export * from "./MessagesModifyResponse";
2
3
  export * from "./LettaStreamingResponse";
@@ -14,5 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./MessageUpdateContent"), exports);
17
+ __exportStar(require("./MessagesModifyRequest"), exports);
18
+ __exportStar(require("./MessagesModifyResponse"), exports);
18
19
  __exportStar(require("./LettaStreamingResponse"), exports);
@@ -88,7 +88,7 @@ class Passages {
88
88
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
89
89
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/archival-memory`),
90
90
  method: "GET",
91
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
91
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
92
92
  contentType: "application/json",
93
93
  queryParameters: _queryParams,
94
94
  requestType: "json",
@@ -157,7 +157,7 @@ class Passages {
157
157
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
158
158
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/archival-memory`),
159
159
  method: "POST",
160
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
160
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
161
161
  contentType: "application/json",
162
162
  requestType: "json",
163
163
  body: serializers.agents.CreateArchivalMemory.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -224,7 +224,7 @@ class Passages {
224
224
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
225
225
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/agents/${encodeURIComponent(agentId)}/archival-memory/${encodeURIComponent(memoryId)}`),
226
226
  method: "DELETE",
227
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.50", "User-Agent": "@letta-ai/letta-client/0.1.50", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
227
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.52", "User-Agent": "@letta-ai/letta-client/0.1.52", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
228
228
  contentType: "application/json",
229
229
  requestType: "json",
230
230
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,