@letta-ai/letta-client 0.1.9 → 0.1.11

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 (178) hide show
  1. package/api/resources/agents/client/Client.js +12 -9
  2. package/api/resources/agents/client/requests/AgentsListRequest.d.ts +5 -1
  3. package/api/resources/agents/client/requests/CreateAgentRequest.d.ts +3 -1
  4. package/api/resources/agents/resources/archivalMemory/client/Client.js +4 -4
  5. package/api/resources/agents/resources/context/client/Client.js +1 -1
  6. package/api/resources/agents/resources/coreMemory/client/Client.js +7 -7
  7. package/api/resources/agents/resources/memoryVariables/client/Client.js +1 -1
  8. package/api/resources/agents/resources/messages/client/Client.d.ts +6 -6
  9. package/api/resources/agents/resources/messages/client/Client.js +11 -11
  10. package/api/resources/agents/resources/messages/client/requests/LettaStreamingRequest.d.ts +2 -6
  11. package/api/resources/agents/resources/messages/types/MessagesListResponse.d.ts +1 -1
  12. package/api/resources/agents/resources/messages/types/index.d.ts +0 -1
  13. package/api/resources/agents/resources/messages/types/index.js +0 -1
  14. package/api/resources/agents/resources/recallMemory/client/Client.js +1 -1
  15. package/api/resources/agents/resources/sources/client/Client.js +1 -1
  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/agents/types/AgentsSearchRequestSearchItem.d.ts +4 -1
  19. package/api/resources/agents/types/AgentsSearchRequestSearchItemTags.d.ts +7 -0
  20. package/api/resources/agents/types/index.d.ts +1 -0
  21. package/api/resources/agents/types/index.js +1 -0
  22. package/api/resources/blocks/client/Client.js +7 -7
  23. package/api/resources/health/client/Client.js +1 -1
  24. package/api/resources/jobs/client/Client.js +4 -4
  25. package/api/resources/models/client/Client.js +2 -2
  26. package/api/resources/providers/client/Client.js +4 -4
  27. package/api/resources/runs/client/Client.d.ts +6 -8
  28. package/api/resources/runs/client/Client.js +12 -37
  29. package/api/resources/runs/client/requests/GetRunMessagesRequest.d.ts +1 -25
  30. package/api/resources/sources/client/Client.js +8 -8
  31. package/api/resources/sources/resources/files/client/Client.js +3 -3
  32. package/api/resources/sources/resources/passages/client/Client.js +1 -1
  33. package/api/resources/tag/client/Client.js +1 -1
  34. package/api/resources/tools/client/Client.js +12 -12
  35. package/api/types/EmbeddingConfigEmbeddingEndpointType.d.ts +2 -1
  36. package/api/types/EmbeddingConfigEmbeddingEndpointType.js +1 -0
  37. package/api/types/{LettaResponseMessagesItem.d.ts → LettaMessageUnion.d.ts} +2 -2
  38. package/api/types/LettaRequest.d.ts +2 -6
  39. package/api/types/LettaRequestConfig.d.ts +11 -0
  40. package/api/types/LettaResponse.d.ts +1 -1
  41. package/api/types/LlmConfigModelEndpointType.d.ts +2 -1
  42. package/api/types/LlmConfigModelEndpointType.js +1 -0
  43. package/api/types/Run.d.ts +2 -0
  44. package/api/types/ToolType.d.ts +2 -1
  45. package/api/types/ToolType.js +1 -0
  46. package/api/types/index.d.ts +2 -1
  47. package/api/types/index.js +2 -1
  48. package/dist/api/resources/agents/client/Client.js +12 -9
  49. package/dist/api/resources/agents/client/requests/AgentsListRequest.d.ts +5 -1
  50. package/dist/api/resources/agents/client/requests/CreateAgentRequest.d.ts +3 -1
  51. package/dist/api/resources/agents/resources/archivalMemory/client/Client.js +4 -4
  52. package/dist/api/resources/agents/resources/context/client/Client.js +1 -1
  53. package/dist/api/resources/agents/resources/coreMemory/client/Client.js +7 -7
  54. package/dist/api/resources/agents/resources/memoryVariables/client/Client.js +1 -1
  55. package/dist/api/resources/agents/resources/messages/client/Client.d.ts +6 -6
  56. package/dist/api/resources/agents/resources/messages/client/Client.js +11 -11
  57. package/dist/api/resources/agents/resources/messages/client/requests/LettaStreamingRequest.d.ts +2 -6
  58. package/dist/api/resources/agents/resources/messages/types/MessagesListResponse.d.ts +1 -1
  59. package/dist/api/resources/agents/resources/messages/types/index.d.ts +0 -1
  60. package/dist/api/resources/agents/resources/messages/types/index.js +0 -1
  61. package/dist/api/resources/agents/resources/recallMemory/client/Client.js +1 -1
  62. package/dist/api/resources/agents/resources/sources/client/Client.js +1 -1
  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/agents/types/AgentsSearchRequestSearchItem.d.ts +4 -1
  66. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemTags.d.ts +7 -0
  67. package/dist/api/resources/agents/types/index.d.ts +1 -0
  68. package/dist/api/resources/agents/types/index.js +1 -0
  69. package/dist/api/resources/blocks/client/Client.js +7 -7
  70. package/dist/api/resources/health/client/Client.js +1 -1
  71. package/dist/api/resources/jobs/client/Client.js +4 -4
  72. package/dist/api/resources/models/client/Client.js +2 -2
  73. package/dist/api/resources/providers/client/Client.js +4 -4
  74. package/dist/api/resources/runs/client/Client.d.ts +6 -8
  75. package/dist/api/resources/runs/client/Client.js +12 -37
  76. package/dist/api/resources/runs/client/requests/GetRunMessagesRequest.d.ts +1 -25
  77. package/dist/api/resources/sources/client/Client.js +8 -8
  78. package/dist/api/resources/sources/resources/files/client/Client.js +3 -3
  79. package/dist/api/resources/sources/resources/passages/client/Client.js +1 -1
  80. package/dist/api/resources/tag/client/Client.js +1 -1
  81. package/dist/api/resources/tools/client/Client.js +12 -12
  82. package/dist/api/types/EmbeddingConfigEmbeddingEndpointType.d.ts +2 -1
  83. package/dist/api/types/EmbeddingConfigEmbeddingEndpointType.js +1 -0
  84. package/dist/api/types/{LettaResponseMessagesItem.d.ts → LettaMessageUnion.d.ts} +2 -2
  85. package/dist/api/types/LettaMessageUnion.js +5 -0
  86. package/dist/api/types/LettaRequest.d.ts +2 -6
  87. package/dist/api/types/LettaRequestConfig.d.ts +11 -0
  88. package/dist/api/types/LettaRequestConfig.js +5 -0
  89. package/dist/api/types/LettaResponse.d.ts +1 -1
  90. package/dist/api/types/LlmConfigModelEndpointType.d.ts +2 -1
  91. package/dist/api/types/LlmConfigModelEndpointType.js +1 -0
  92. package/dist/api/types/Run.d.ts +2 -0
  93. package/dist/api/types/ToolType.d.ts +2 -1
  94. package/dist/api/types/ToolType.js +1 -0
  95. package/dist/api/types/index.d.ts +2 -1
  96. package/dist/api/types/index.js +2 -1
  97. package/dist/serialization/resources/agents/client/requests/CreateAgentRequest.d.ts +1 -0
  98. package/dist/serialization/resources/agents/client/requests/CreateAgentRequest.js +1 -0
  99. package/dist/serialization/resources/agents/resources/messages/client/requests/LettaStreamingRequest.d.ts +2 -3
  100. package/dist/serialization/resources/agents/resources/messages/client/requests/LettaStreamingRequest.js +2 -3
  101. package/dist/serialization/resources/agents/resources/messages/types/MessagesListResponse.d.ts +2 -2
  102. package/dist/serialization/resources/agents/resources/messages/types/MessagesListResponse.js +2 -2
  103. package/dist/serialization/resources/agents/resources/messages/types/index.d.ts +0 -1
  104. package/dist/serialization/resources/agents/resources/messages/types/index.js +0 -1
  105. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItem.d.ts +5 -1
  106. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItem.js +2 -0
  107. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemTags.d.ts +13 -0
  108. package/dist/serialization/resources/agents/{resources/messages/types/MessagesListResponseItem.js → types/AgentsSearchRequestSearchItemTags.js} +5 -20
  109. package/dist/serialization/resources/agents/types/index.d.ts +1 -0
  110. package/dist/serialization/resources/agents/types/index.js +1 -0
  111. package/dist/serialization/resources/runs/client/getRunMessages.d.ts +3 -3
  112. package/dist/serialization/resources/runs/client/getRunMessages.js +2 -2
  113. package/dist/serialization/types/EmbeddingConfigEmbeddingEndpointType.d.ts +1 -1
  114. package/dist/serialization/types/EmbeddingConfigEmbeddingEndpointType.js +1 -0
  115. package/dist/serialization/types/{LettaResponseMessagesItem.d.ts → LettaMessageUnion.d.ts} +3 -3
  116. package/{serialization/types/LettaResponseMessagesItem.js → dist/serialization/types/LettaMessageUnion.js} +2 -2
  117. package/dist/serialization/types/LettaRequest.d.ts +2 -3
  118. package/dist/serialization/types/LettaRequest.js +2 -3
  119. package/dist/serialization/types/LettaRequestConfig.d.ts +14 -0
  120. package/{serialization/resources/agents/resources/messages/types/MessagesListResponseItem.js → dist/serialization/types/LettaRequestConfig.js} +6 -20
  121. package/dist/serialization/types/LettaResponse.d.ts +2 -2
  122. package/dist/serialization/types/LettaResponse.js +2 -2
  123. package/dist/serialization/types/LlmConfigModelEndpointType.d.ts +1 -1
  124. package/dist/serialization/types/LlmConfigModelEndpointType.js +1 -0
  125. package/dist/serialization/types/Run.d.ts +2 -0
  126. package/dist/serialization/types/Run.js +2 -0
  127. package/dist/serialization/types/ToolType.d.ts +1 -1
  128. package/dist/serialization/types/ToolType.js +1 -0
  129. package/dist/serialization/types/index.d.ts +2 -1
  130. package/dist/serialization/types/index.js +2 -1
  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 +12 -14
  135. package/serialization/resources/agents/client/requests/CreateAgentRequest.d.ts +1 -0
  136. package/serialization/resources/agents/client/requests/CreateAgentRequest.js +1 -0
  137. package/serialization/resources/agents/resources/messages/client/requests/LettaStreamingRequest.d.ts +2 -3
  138. package/serialization/resources/agents/resources/messages/client/requests/LettaStreamingRequest.js +2 -3
  139. package/serialization/resources/agents/resources/messages/types/MessagesListResponse.d.ts +2 -2
  140. package/serialization/resources/agents/resources/messages/types/MessagesListResponse.js +2 -2
  141. package/serialization/resources/agents/resources/messages/types/index.d.ts +0 -1
  142. package/serialization/resources/agents/resources/messages/types/index.js +0 -1
  143. package/serialization/resources/agents/types/AgentsSearchRequestSearchItem.d.ts +5 -1
  144. package/serialization/resources/agents/types/AgentsSearchRequestSearchItem.js +2 -0
  145. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemTags.d.ts +13 -0
  146. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemTags.js +44 -0
  147. package/serialization/resources/agents/types/index.d.ts +1 -0
  148. package/serialization/resources/agents/types/index.js +1 -0
  149. package/serialization/resources/runs/client/getRunMessages.d.ts +3 -3
  150. package/serialization/resources/runs/client/getRunMessages.js +2 -2
  151. package/serialization/types/EmbeddingConfigEmbeddingEndpointType.d.ts +1 -1
  152. package/serialization/types/EmbeddingConfigEmbeddingEndpointType.js +1 -0
  153. package/serialization/types/{LettaResponseMessagesItem.d.ts → LettaMessageUnion.d.ts} +3 -3
  154. package/{dist/serialization/types/LettaResponseMessagesItem.js → serialization/types/LettaMessageUnion.js} +2 -2
  155. package/serialization/types/LettaRequest.d.ts +2 -3
  156. package/serialization/types/LettaRequest.js +2 -3
  157. package/serialization/types/LettaRequestConfig.d.ts +14 -0
  158. package/serialization/types/LettaRequestConfig.js +45 -0
  159. package/serialization/types/LettaResponse.d.ts +2 -2
  160. package/serialization/types/LettaResponse.js +2 -2
  161. package/serialization/types/LlmConfigModelEndpointType.d.ts +1 -1
  162. package/serialization/types/LlmConfigModelEndpointType.js +1 -0
  163. package/serialization/types/Run.d.ts +2 -0
  164. package/serialization/types/Run.js +2 -0
  165. package/serialization/types/ToolType.d.ts +1 -1
  166. package/serialization/types/ToolType.js +1 -0
  167. package/serialization/types/index.d.ts +2 -1
  168. package/serialization/types/index.js +2 -1
  169. package/version.d.ts +1 -1
  170. package/version.js +1 -1
  171. package/api/resources/agents/resources/messages/types/MessagesListResponseItem.d.ts +0 -25
  172. package/dist/api/resources/agents/resources/messages/types/MessagesListResponseItem.d.ts +0 -25
  173. package/dist/serialization/resources/agents/resources/messages/types/MessagesListResponseItem.d.ts +0 -34
  174. package/serialization/resources/agents/resources/messages/types/MessagesListResponseItem.d.ts +0 -34
  175. /package/api/resources/agents/{resources/messages/types/MessagesListResponseItem.js → types/AgentsSearchRequestSearchItemTags.js} +0 -0
  176. /package/api/types/{LettaResponseMessagesItem.js → LettaMessageUnion.js} +0 -0
  177. /package/{dist/api/resources/agents/resources/messages/types/MessagesListResponseItem.js → api/types/LettaRequestConfig.js} +0 -0
  178. /package/dist/api/{types/LettaResponseMessagesItem.js → resources/agents/types/AgentsSearchRequestSearchItemTags.js} +0 -0
@@ -50,14 +50,14 @@ export declare class Messages {
50
50
  * @throws {@link Letta.UnprocessableEntityError}
51
51
  *
52
52
  * @example
53
- * await client.agents.messages.create("agent_id", {
53
+ * await client.agents.messages.send("agent_id", {
54
54
  * messages: [{
55
55
  * role: "user",
56
56
  * text: "text"
57
57
  * }]
58
58
  * })
59
59
  */
60
- create(agentId: string, request: Letta.LettaRequest, requestOptions?: Messages.RequestOptions): Promise<Letta.LettaResponse>;
60
+ send(agentId: string, request: Letta.LettaRequest, requestOptions?: Messages.RequestOptions): Promise<Letta.LettaResponse>;
61
61
  /**
62
62
  * Update the details of a message associated with an agent.
63
63
  *
@@ -79,8 +79,8 @@ export declare class Messages {
79
79
  */
80
80
  stream(agentId: string, request: Letta.agents.LettaStreamingRequest, requestOptions?: Messages.RequestOptions): Promise<core.Stream<Letta.agents.LettaStreamingResponse>>;
81
81
  /**
82
- * Asynchronously process a user message and return a job ID.
83
- * The actual processing happens in the background, and the status can be checked using the job ID.
82
+ * Asynchronously process a user message and return a run object.
83
+ * The actual processing happens in the background, and the status can be checked using the run ID.
84
84
  *
85
85
  * @param {string} agentId
86
86
  * @param {Letta.LettaRequest} request
@@ -89,14 +89,14 @@ export declare class Messages {
89
89
  * @throws {@link Letta.UnprocessableEntityError}
90
90
  *
91
91
  * @example
92
- * await client.agents.messages.createAsync("agent_id", {
92
+ * await client.agents.messages.sendAsync("agent_id", {
93
93
  * messages: [{
94
94
  * role: "user",
95
95
  * text: "text"
96
96
  * }]
97
97
  * })
98
98
  */
99
- createAsync(agentId: string, request: Letta.LettaRequest, requestOptions?: Messages.RequestOptions): Promise<Letta.Run>;
99
+ sendAsync(agentId: string, request: Letta.LettaRequest, requestOptions?: Messages.RequestOptions): Promise<Letta.Run>;
100
100
  protected _getCustomAuthorizationHeaders(): Promise<{
101
101
  Authorization: string;
102
102
  }>;
@@ -94,7 +94,7 @@ class Messages {
94
94
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
95
95
  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`),
96
96
  method: "GET",
97
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
97
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
98
98
  contentType: "application/json",
99
99
  queryParameters: _queryParams,
100
100
  requestType: "json",
@@ -154,20 +154,20 @@ class Messages {
154
154
  * @throws {@link Letta.UnprocessableEntityError}
155
155
  *
156
156
  * @example
157
- * await client.agents.messages.create("agent_id", {
157
+ * await client.agents.messages.send("agent_id", {
158
158
  * messages: [{
159
159
  * role: "user",
160
160
  * text: "text"
161
161
  * }]
162
162
  * })
163
163
  */
164
- create(agentId, request, requestOptions) {
164
+ send(agentId, request, requestOptions) {
165
165
  return __awaiter(this, void 0, void 0, function* () {
166
166
  var _a, _b, _c;
167
167
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
168
168
  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`),
169
169
  method: "POST",
170
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
170
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
171
171
  contentType: "application/json",
172
172
  requestType: "json",
173
173
  body: serializers.LettaRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -235,7 +235,7 @@ class Messages {
235
235
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
236
236
  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)}`),
237
237
  method: "PATCH",
238
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
238
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
239
239
  contentType: "application/json",
240
240
  requestType: "json",
241
241
  body: serializers.agents.MessageUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -295,7 +295,7 @@ class Messages {
295
295
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
296
296
  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`),
297
297
  method: "POST",
298
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
298
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
299
299
  contentType: "application/json",
300
300
  requestType: "json",
301
301
  body: serializers.agents.LettaStreamingRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -356,8 +356,8 @@ class Messages {
356
356
  });
357
357
  }
358
358
  /**
359
- * Asynchronously process a user message and return a job ID.
360
- * The actual processing happens in the background, and the status can be checked using the job ID.
359
+ * Asynchronously process a user message and return a run object.
360
+ * The actual processing happens in the background, and the status can be checked using the run ID.
361
361
  *
362
362
  * @param {string} agentId
363
363
  * @param {Letta.LettaRequest} request
@@ -366,20 +366,20 @@ class Messages {
366
366
  * @throws {@link Letta.UnprocessableEntityError}
367
367
  *
368
368
  * @example
369
- * await client.agents.messages.createAsync("agent_id", {
369
+ * await client.agents.messages.sendAsync("agent_id", {
370
370
  * messages: [{
371
371
  * role: "user",
372
372
  * text: "text"
373
373
  * }]
374
374
  * })
375
375
  */
376
- createAsync(agentId, request, requestOptions) {
376
+ sendAsync(agentId, request, requestOptions) {
377
377
  return __awaiter(this, void 0, void 0, function* () {
378
378
  var _a, _b, _c;
379
379
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
380
380
  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`),
381
381
  method: "POST",
382
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
382
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
383
383
  contentType: "application/json",
384
384
  requestType: "json",
385
385
  body: serializers.LettaRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -14,12 +14,8 @@ import * as Letta from "../../../../../../index";
14
14
  export interface LettaStreamingRequest {
15
15
  /** The messages to be sent to the agent. */
16
16
  messages: Letta.MessageCreate[];
17
- /** Whether the server should parse specific tool call arguments (default `send_message`) as `AssistantMessage` objects. */
18
- useAssistantMessage?: boolean;
19
- /** The name of the designated message tool. */
20
- assistantMessageToolName?: string;
21
- /** The name of the message argument in the designated message tool. */
22
- assistantMessageToolKwarg?: string;
17
+ /** Configuration options for the LettaRequest. */
18
+ config?: Letta.LettaRequestConfig;
23
19
  /** Flag to determine if individual tokens should be streamed. Set to True for token streaming (requires stream_steps = True). */
24
20
  streamTokens?: boolean;
25
21
  }
@@ -2,4 +2,4 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as Letta from "../../../../../index";
5
- export type MessagesListResponse = Letta.LettaSchemasMessageMessage[] | Letta.agents.MessagesListResponseItem[];
5
+ export type MessagesListResponse = Letta.LettaSchemasMessageMessage[] | Letta.LettaMessageUnion[];
@@ -1,3 +1,2 @@
1
- export * from "./MessagesListResponseItem";
2
1
  export * from "./MessagesListResponse";
3
2
  export * from "./LettaStreamingResponse";
@@ -14,6 +14,5 @@ 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("./MessagesListResponseItem"), exports);
18
17
  __exportStar(require("./MessagesListResponse"), exports);
19
18
  __exportStar(require("./LettaStreamingResponse"), exports);
@@ -76,7 +76,7 @@ class RecallMemory {
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)}/memory/recall`),
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.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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,
@@ -76,7 +76,7 @@ class Sources {
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)}/sources`),
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.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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,
@@ -96,7 +96,7 @@ class Templates {
96
96
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
97
97
  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)}/version-template`),
98
98
  method: "POST",
99
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
99
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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
100
  contentType: "application/json",
101
101
  queryParameters: _queryParams,
102
102
  requestType: "json",
@@ -163,7 +163,7 @@ class Templates {
163
163
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
164
164
  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)}/migrate`),
165
165
  method: "POST",
166
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
166
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
167
167
  contentType: "application/json",
168
168
  requestType: "json",
169
169
  body: serializers.agents.TemplatesMigrateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -237,7 +237,7 @@ class Templates {
237
237
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
238
238
  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)}/template`),
239
239
  method: "POST",
240
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
240
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
241
241
  contentType: "application/json",
242
242
  requestType: "json",
243
243
  body: serializers.agents.TemplatesCreateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -76,7 +76,7 @@ class Tools {
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)}/tools`),
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.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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,
@@ -142,7 +142,7 @@ class Tools {
142
142
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
143
143
  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)}/add-tool/${encodeURIComponent(toolId)}`),
144
144
  method: "PATCH",
145
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
145
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
146
146
  contentType: "application/json",
147
147
  requestType: "json",
148
148
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -208,7 +208,7 @@ class Tools {
208
208
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
209
209
  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)}/remove-tool/${encodeURIComponent(toolId)}`),
210
210
  method: "PATCH",
211
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
211
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
212
212
  contentType: "application/json",
213
213
  requestType: "json",
214
214
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -2,7 +2,7 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as Letta from "../../../index";
5
- export type AgentsSearchRequestSearchItem = Letta.AgentsSearchRequestSearchItem.Version | Letta.AgentsSearchRequestSearchItem.Name | Letta.AgentsSearchRequestSearchItem.OrderBy;
5
+ export type AgentsSearchRequestSearchItem = Letta.AgentsSearchRequestSearchItem.Version | Letta.AgentsSearchRequestSearchItem.Name | Letta.AgentsSearchRequestSearchItem.Tags | Letta.AgentsSearchRequestSearchItem.OrderBy;
6
6
  export declare namespace AgentsSearchRequestSearchItem {
7
7
  interface Version extends Letta.AgentsSearchRequestSearchItemVersion {
8
8
  field: "version";
@@ -10,6 +10,9 @@ export declare namespace AgentsSearchRequestSearchItem {
10
10
  interface Name extends Letta.AgentsSearchRequestSearchItemName {
11
11
  field: "name";
12
12
  }
13
+ interface Tags extends Letta.AgentsSearchRequestSearchItemTags {
14
+ field: "tags";
15
+ }
13
16
  interface OrderBy extends Letta.AgentsSearchRequestSearchItemOrderBy {
14
17
  field: "order_by";
15
18
  }
@@ -0,0 +1,7 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export interface AgentsSearchRequestSearchItemTags {
5
+ operator: "contains";
6
+ value: string[];
7
+ }
@@ -3,6 +3,7 @@ export * from "./UpdateAgentToolRulesItem";
3
3
  export * from "./AgentsSearchRequestSearchItemVersion";
4
4
  export * from "./AgentsSearchRequestSearchItemNameOperator";
5
5
  export * from "./AgentsSearchRequestSearchItemName";
6
+ export * from "./AgentsSearchRequestSearchItemTags";
6
7
  export * from "./AgentsSearchRequestSearchItemOrderByValue";
7
8
  export * from "./AgentsSearchRequestSearchItemOrderByDirection";
8
9
  export * from "./AgentsSearchRequestSearchItemOrderBy";
@@ -19,6 +19,7 @@ __exportStar(require("./UpdateAgentToolRulesItem"), exports);
19
19
  __exportStar(require("./AgentsSearchRequestSearchItemVersion"), exports);
20
20
  __exportStar(require("./AgentsSearchRequestSearchItemNameOperator"), exports);
21
21
  __exportStar(require("./AgentsSearchRequestSearchItemName"), exports);
22
+ __exportStar(require("./AgentsSearchRequestSearchItemTags"), exports);
22
23
  __exportStar(require("./AgentsSearchRequestSearchItemOrderByValue"), exports);
23
24
  __exportStar(require("./AgentsSearchRequestSearchItemOrderByDirection"), exports);
24
25
  __exportStar(require("./AgentsSearchRequestSearchItemOrderBy"), exports);
@@ -85,7 +85,7 @@ class Blocks {
85
85
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
86
86
  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/blocks/"),
87
87
  method: "GET",
88
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
88
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
89
89
  contentType: "application/json",
90
90
  queryParameters: _queryParams,
91
91
  requestType: "json",
@@ -152,7 +152,7 @@ class Blocks {
152
152
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
153
153
  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/blocks/"),
154
154
  method: "POST",
155
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
155
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
156
156
  contentType: "application/json",
157
157
  requestType: "json",
158
158
  body: serializers.CreateBlock.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -216,7 +216,7 @@ class Blocks {
216
216
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
217
217
  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/blocks/${encodeURIComponent(blockId)}`),
218
218
  method: "GET",
219
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
219
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
220
220
  contentType: "application/json",
221
221
  requestType: "json",
222
222
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -279,7 +279,7 @@ class Blocks {
279
279
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
280
280
  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/blocks/${encodeURIComponent(blockId)}`),
281
281
  method: "DELETE",
282
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
282
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
283
283
  contentType: "application/json",
284
284
  requestType: "json",
285
285
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -343,7 +343,7 @@ class Blocks {
343
343
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
344
344
  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/blocks/${encodeURIComponent(blockId)}`),
345
345
  method: "PATCH",
346
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
347
347
  contentType: "application/json",
348
348
  requestType: "json",
349
349
  body: serializers.BlockUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -415,7 +415,7 @@ class Blocks {
415
415
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
416
416
  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/blocks/${encodeURIComponent(blockId)}/attach`),
417
417
  method: "PATCH",
418
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
418
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
419
419
  contentType: "application/json",
420
420
  queryParameters: _queryParams,
421
421
  requestType: "json",
@@ -481,7 +481,7 @@ class Blocks {
481
481
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
482
482
  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/blocks/${encodeURIComponent(blockId)}/detach`),
483
483
  method: "PATCH",
484
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
484
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
485
485
  contentType: "application/json",
486
486
  queryParameters: _queryParams,
487
487
  requestType: "json",
@@ -70,7 +70,7 @@ class Health {
70
70
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
71
71
  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/health/"),
72
72
  method: "GET",
73
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
73
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
74
74
  contentType: "application/json",
75
75
  requestType: "json",
76
76
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -81,7 +81,7 @@ class Jobs {
81
81
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
82
82
  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/jobs/"),
83
83
  method: "GET",
84
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
84
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
85
85
  contentType: "application/json",
86
86
  queryParameters: _queryParams,
87
87
  requestType: "json",
@@ -146,7 +146,7 @@ class Jobs {
146
146
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
147
147
  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/jobs/active"),
148
148
  method: "GET",
149
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
149
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
150
150
  contentType: "application/json",
151
151
  requestType: "json",
152
152
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -211,7 +211,7 @@ class Jobs {
211
211
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
212
212
  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/jobs/${encodeURIComponent(jobId)}`),
213
213
  method: "GET",
214
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
215
215
  contentType: "application/json",
216
216
  requestType: "json",
217
217
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -276,7 +276,7 @@ class Jobs {
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/jobs/${encodeURIComponent(jobId)}`),
278
278
  method: "DELETE",
279
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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,
@@ -70,7 +70,7 @@ class Models {
70
70
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
71
71
  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/models/"),
72
72
  method: "GET",
73
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
73
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
74
74
  contentType: "application/json",
75
75
  requestType: "json",
76
76
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -119,7 +119,7 @@ class Models {
119
119
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
120
120
  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/models/embedding"),
121
121
  method: "GET",
122
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
122
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
123
123
  contentType: "application/json",
124
124
  requestType: "json",
125
125
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -84,7 +84,7 @@ class Providers {
84
84
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
85
85
  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/providers/"),
86
86
  method: "GET",
87
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
87
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
88
88
  contentType: "application/json",
89
89
  queryParameters: _queryParams,
90
90
  requestType: "json",
@@ -153,7 +153,7 @@ class Providers {
153
153
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
154
154
  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/providers/"),
155
155
  method: "POST",
156
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
156
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
157
157
  contentType: "application/json",
158
158
  requestType: "json",
159
159
  body: serializers.ProviderCreate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -222,7 +222,7 @@ class Providers {
222
222
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
223
223
  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/providers/"),
224
224
  method: "PUT",
225
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
225
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
226
226
  contentType: "application/json",
227
227
  requestType: "json",
228
228
  body: serializers.ProviderUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -293,7 +293,7 @@ class Providers {
293
293
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
294
294
  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/providers/"),
295
295
  method: "DELETE",
296
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.9", "User-Agent": "@letta-ai/letta-client/0.1.9", "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),
296
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.11", "User-Agent": "@letta-ai/letta-client/0.1.11", "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),
297
297
  contentType: "application/json",
298
298
  queryParameters: _queryParams,
299
299
  requestType: "json",
@@ -78,17 +78,15 @@ export declare class Runs {
78
78
  * Args:
79
79
  * run_id: ID of the run
80
80
  * cursor: Cursor for pagination
81
- * start_date: Filter messages after this date
82
- * end_date: Filter messages before this date
83
81
  * limit: Maximum number of messages to return
84
- * query_text: Search text in message content
85
82
  * ascending: Sort order by creation time
86
- * tags: Filter by message tags
87
- * match_all_tags: If true, match all tags. If false, match any tag
88
- * role: Filter by message role (user/assistant/system/tool)
89
- * tool_name: Filter by tool call name
83
+ * role: Filter by role (user/assistant/system/tool)
84
+ * return_message_object: Whether to return Message objects or LettaMessage objects
90
85
  * user_id: ID of the user making the request
91
86
  *
87
+ * Returns:
88
+ * A list of messages associated with the run. Default is List[LettaMessage].
89
+ *
92
90
  * @param {string} runId
93
91
  * @param {Letta.GetRunMessagesRequest} request
94
92
  * @param {Runs.RequestOptions} requestOptions - Request-specific configuration.
@@ -98,7 +96,7 @@ export declare class Runs {
98
96
  * @example
99
97
  * await client.runs.getRunMessages("run_id")
100
98
  */
101
- getRunMessages(runId: string, request?: Letta.GetRunMessagesRequest, requestOptions?: Runs.RequestOptions): Promise<Letta.LettaSchemasMessageMessage[]>;
99
+ getRunMessages(runId: string, request?: Letta.GetRunMessagesRequest, requestOptions?: Runs.RequestOptions): Promise<Letta.LettaMessageUnion[]>;
102
100
  /**
103
101
  * Get usage statistics for a run.
104
102
  *