@letta-ai/letta-client 0.1.12 → 0.1.13

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 (778) hide show
  1. package/api/resources/agents/client/Client.d.ts +129 -10
  2. package/api/resources/agents/client/Client.js +630 -26
  3. package/api/resources/agents/{resources/archivalMemory/client/requests/ArchivalMemoryListRequest.d.ts → client/requests/ListArchivalMemoryRequest.d.ts} +1 -1
  4. package/api/resources/agents/client/requests/index.d.ts +2 -0
  5. package/api/resources/agents/resources/archivalMemory/client/Client.d.ts +4 -21
  6. package/api/resources/agents/resources/archivalMemory/client/Client.js +22 -98
  7. package/api/resources/agents/resources/archivalMemory/client/index.d.ts +1 -1
  8. package/api/resources/agents/resources/archivalMemory/client/index.js +0 -15
  9. package/api/resources/agents/resources/context/client/Client.d.ts +2 -2
  10. package/api/resources/agents/resources/context/client/Client.js +3 -3
  11. package/api/resources/agents/resources/coreMemory/client/Client.d.ts +16 -46
  12. package/api/resources/agents/resources/coreMemory/client/Client.js +64 -199
  13. package/api/resources/agents/resources/index.d.ts +0 -1
  14. package/api/resources/agents/resources/index.js +0 -1
  15. package/api/resources/agents/resources/memoryVariables/client/Client.d.ts +2 -2
  16. package/api/resources/agents/resources/memoryVariables/client/Client.js +4 -4
  17. package/api/resources/agents/resources/memoryVariables/types/{MemoryVariablesGetResponse.d.ts → MemoryVariablesListResponse.d.ts} +1 -1
  18. package/api/resources/agents/resources/memoryVariables/types/index.d.ts +1 -1
  19. package/api/resources/agents/resources/memoryVariables/types/index.js +1 -1
  20. package/api/resources/agents/resources/messages/client/Client.d.ts +2 -2
  21. package/api/resources/agents/resources/messages/client/Client.js +8 -8
  22. package/api/resources/agents/resources/messages/client/requests/MessageUpdate.d.ts +1 -1
  23. package/api/resources/agents/resources/messages/types/LettaStreamingResponse.d.ts +1 -24
  24. package/api/resources/agents/resources/messages/types/MessagesListResponse.d.ts +1 -1
  25. package/api/resources/agents/resources/sources/client/Client.d.ts +28 -2
  26. package/api/resources/agents/resources/sources/client/Client.js +136 -4
  27. package/api/resources/agents/resources/templates/client/Client.js +3 -3
  28. package/api/resources/agents/resources/tools/client/Client.d.ts +7 -7
  29. package/api/resources/agents/resources/tools/client/Client.js +13 -13
  30. package/api/resources/agents/types/AgentsSearchRequestSearchItem.d.ts +1 -15
  31. package/api/resources/agents/types/AgentsSearchRequestSearchItemDirection.d.ts +9 -0
  32. package/api/resources/agents/types/AgentsSearchRequestSearchItemDirectionDirection.d.ts +8 -0
  33. package/{dist/api/resources/agents/types/AgentsSearchRequestSearchItemOrderByDirection.js → api/resources/agents/types/AgentsSearchRequestSearchItemDirectionDirection.js} +2 -2
  34. package/api/resources/agents/types/AgentsSearchRequestSearchItemDirectionValue.d.ts +8 -0
  35. package/{dist/api/resources/agents/types/AgentsSearchRequestSearchItemOrderByValue.js → api/resources/agents/types/AgentsSearchRequestSearchItemDirectionValue.js} +2 -2
  36. package/api/resources/agents/types/{AgentsSearchRequestSearchItemName.d.ts → AgentsSearchRequestSearchItemOne.d.ts} +3 -2
  37. package/api/resources/agents/types/{AgentsSearchRequestSearchItemNameOperator.d.ts → AgentsSearchRequestSearchItemOneOperator.d.ts} +2 -2
  38. package/api/resources/agents/types/{AgentsSearchRequestSearchItemNameOperator.js → AgentsSearchRequestSearchItemOneOperator.js} +2 -2
  39. package/{dist/api/resources/agents/types/AgentsSearchRequestSearchItemTags.d.ts → api/resources/agents/types/AgentsSearchRequestSearchItemTwo.d.ts} +2 -1
  40. package/{dist/api/resources/agents/types/AgentsSearchRequestSearchItemVersion.d.ts → api/resources/agents/types/AgentsSearchRequestSearchItemZero.d.ts} +2 -1
  41. package/api/resources/agents/types/index.d.ts +7 -7
  42. package/api/resources/agents/types/index.js +7 -7
  43. package/api/resources/blocks/client/Client.d.ts +4 -34
  44. package/api/resources/blocks/client/Client.js +9 -141
  45. package/api/resources/blocks/client/requests/index.d.ts +0 -2
  46. package/api/resources/health/client/Client.js +1 -1
  47. package/api/resources/jobs/client/Client.d.ts +2 -2
  48. package/api/resources/jobs/client/Client.js +6 -6
  49. package/api/resources/models/client/Client.js +2 -2
  50. package/api/resources/providers/client/Client.d.ts +2 -2
  51. package/api/resources/providers/client/Client.js +6 -6
  52. package/api/resources/runs/client/Client.d.ts +7 -7
  53. package/api/resources/runs/client/Client.js +14 -14
  54. package/api/resources/runs/client/requests/{GetRunMessagesRequest.d.ts → ListRunMessagesRequest.d.ts} +1 -1
  55. package/api/resources/runs/client/requests/index.d.ts +1 -1
  56. package/api/resources/sources/client/Client.d.ts +4 -34
  57. package/api/resources/sources/client/Client.js +10 -154
  58. package/api/resources/sources/client/requests/index.d.ts +0 -2
  59. package/api/resources/sources/resources/files/client/Client.js +3 -3
  60. package/api/resources/sources/resources/passages/client/Client.js +1 -1
  61. package/api/resources/tag/client/Client.js +1 -1
  62. package/api/resources/tools/client/Client.d.ts +9 -9
  63. package/api/resources/tools/client/Client.js +20 -20
  64. package/api/types/AgentState.d.ts +1 -1
  65. package/{dist/api/types/AssistantMessageOutput.d.ts → api/types/AssistantMessage.d.ts} +2 -1
  66. package/api/types/Block.d.ts +1 -1
  67. package/api/types/ChatCompletionMessageToolCall.d.ts +11 -0
  68. package/api/types/ContextWindowOverview.d.ts +2 -2
  69. package/api/types/{LettaSchemasOpenaiChatCompletionRequestToolCallFunction.d.ts → Function.d.ts} +4 -2
  70. package/{dist/api/types/FunctionSchema.d.ts → api/types/FunctionDefinition.d.ts} +4 -1
  71. package/api/types/FunctionTool.d.ts +10 -0
  72. package/api/types/LettaMessageUnion.d.ts +1 -21
  73. package/api/types/LettaUsageStatistics.d.ts +1 -0
  74. package/api/types/{LettaSchemasMessageMessage.d.ts → Message.d.ts} +3 -3
  75. package/api/types/ReasoningMessage.d.ts +1 -0
  76. package/api/types/Source.d.ts +1 -1
  77. package/api/types/{SystemMessageOutput.d.ts → SystemMessage.d.ts} +2 -1
  78. package/{dist/api/types/LettaSchemasToolTool.d.ts → api/types/Tool.d.ts} +1 -1
  79. package/{dist/api/types/LettaSchemasLettaMessageToolCall.d.ts → api/types/ToolCall.d.ts} +1 -1
  80. package/api/types/ToolCallMessage.d.ts +1 -0
  81. package/api/types/ToolCallMessageToolCall.d.ts +1 -1
  82. package/api/types/ToolReturnMessage.d.ts +1 -0
  83. package/api/types/ToolType.d.ts +2 -1
  84. package/api/types/ToolType.js +1 -0
  85. package/api/types/{UserMessageOutput.d.ts → UserMessage.d.ts} +2 -1
  86. package/api/types/index.d.ts +10 -41
  87. package/api/types/index.js +10 -41
  88. package/dist/api/resources/agents/client/Client.d.ts +129 -10
  89. package/dist/api/resources/agents/client/Client.js +630 -26
  90. package/dist/api/resources/agents/{resources/archivalMemory/client/requests/ArchivalMemoryListRequest.d.ts → client/requests/ListArchivalMemoryRequest.d.ts} +1 -1
  91. package/dist/api/resources/agents/client/requests/index.d.ts +2 -0
  92. package/dist/api/resources/agents/resources/archivalMemory/client/Client.d.ts +4 -21
  93. package/dist/api/resources/agents/resources/archivalMemory/client/Client.js +22 -98
  94. package/dist/api/resources/agents/resources/archivalMemory/client/index.d.ts +1 -1
  95. package/dist/api/resources/agents/resources/archivalMemory/client/index.js +0 -15
  96. package/dist/api/resources/agents/resources/context/client/Client.d.ts +2 -2
  97. package/dist/api/resources/agents/resources/context/client/Client.js +3 -3
  98. package/dist/api/resources/agents/resources/coreMemory/client/Client.d.ts +16 -46
  99. package/dist/api/resources/agents/resources/coreMemory/client/Client.js +64 -199
  100. package/dist/api/resources/agents/resources/index.d.ts +0 -1
  101. package/dist/api/resources/agents/resources/index.js +0 -1
  102. package/dist/api/resources/agents/resources/memoryVariables/client/Client.d.ts +2 -2
  103. package/dist/api/resources/agents/resources/memoryVariables/client/Client.js +4 -4
  104. package/dist/api/resources/agents/resources/memoryVariables/types/{MemoryVariablesGetResponse.d.ts → MemoryVariablesListResponse.d.ts} +1 -1
  105. package/dist/api/resources/agents/resources/memoryVariables/types/index.d.ts +1 -1
  106. package/dist/api/resources/agents/resources/memoryVariables/types/index.js +1 -1
  107. package/dist/api/resources/agents/resources/messages/client/Client.d.ts +2 -2
  108. package/dist/api/resources/agents/resources/messages/client/Client.js +8 -8
  109. package/dist/api/resources/agents/resources/messages/client/requests/MessageUpdate.d.ts +1 -1
  110. package/dist/api/resources/agents/resources/messages/types/LettaStreamingResponse.d.ts +1 -24
  111. package/dist/api/resources/agents/resources/messages/types/MessagesListResponse.d.ts +1 -1
  112. package/dist/api/resources/agents/resources/sources/client/Client.d.ts +28 -2
  113. package/dist/api/resources/agents/resources/sources/client/Client.js +136 -4
  114. package/dist/api/resources/agents/resources/templates/client/Client.js +3 -3
  115. package/dist/api/resources/agents/resources/tools/client/Client.d.ts +7 -7
  116. package/dist/api/resources/agents/resources/tools/client/Client.js +13 -13
  117. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItem.d.ts +1 -15
  118. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemDirection.d.ts +9 -0
  119. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemDirectionDirection.d.ts +8 -0
  120. package/{api/resources/agents/types/AgentsSearchRequestSearchItemOrderByDirection.js → dist/api/resources/agents/types/AgentsSearchRequestSearchItemDirectionDirection.js} +2 -2
  121. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemDirectionValue.d.ts +8 -0
  122. package/{api/resources/agents/types/AgentsSearchRequestSearchItemOrderByValue.js → dist/api/resources/agents/types/AgentsSearchRequestSearchItemDirectionValue.js} +2 -2
  123. package/dist/api/resources/agents/types/{AgentsSearchRequestSearchItemName.d.ts → AgentsSearchRequestSearchItemOne.d.ts} +3 -2
  124. package/dist/api/resources/agents/types/{AgentsSearchRequestSearchItemNameOperator.d.ts → AgentsSearchRequestSearchItemOneOperator.d.ts} +2 -2
  125. package/dist/api/resources/agents/types/{AgentsSearchRequestSearchItemNameOperator.js → AgentsSearchRequestSearchItemOneOperator.js} +2 -2
  126. package/{api/resources/agents/types/AgentsSearchRequestSearchItemTags.d.ts → dist/api/resources/agents/types/AgentsSearchRequestSearchItemTwo.d.ts} +2 -1
  127. package/{api/resources/agents/types/AgentsSearchRequestSearchItemVersion.d.ts → dist/api/resources/agents/types/AgentsSearchRequestSearchItemZero.d.ts} +2 -1
  128. package/dist/api/resources/agents/types/index.d.ts +7 -7
  129. package/dist/api/resources/agents/types/index.js +7 -7
  130. package/dist/api/resources/blocks/client/Client.d.ts +4 -34
  131. package/dist/api/resources/blocks/client/Client.js +9 -141
  132. package/dist/api/resources/blocks/client/requests/index.d.ts +0 -2
  133. package/dist/api/resources/health/client/Client.js +1 -1
  134. package/dist/api/resources/jobs/client/Client.d.ts +2 -2
  135. package/dist/api/resources/jobs/client/Client.js +6 -6
  136. package/dist/api/resources/models/client/Client.js +2 -2
  137. package/dist/api/resources/providers/client/Client.d.ts +2 -2
  138. package/dist/api/resources/providers/client/Client.js +6 -6
  139. package/dist/api/resources/runs/client/Client.d.ts +7 -7
  140. package/dist/api/resources/runs/client/Client.js +14 -14
  141. package/dist/api/resources/runs/client/requests/{GetRunMessagesRequest.d.ts → ListRunMessagesRequest.d.ts} +1 -1
  142. package/dist/api/resources/runs/client/requests/index.d.ts +1 -1
  143. package/dist/api/resources/sources/client/Client.d.ts +4 -34
  144. package/dist/api/resources/sources/client/Client.js +10 -154
  145. package/dist/api/resources/sources/client/requests/index.d.ts +0 -2
  146. package/dist/api/resources/sources/resources/files/client/Client.js +3 -3
  147. package/dist/api/resources/sources/resources/passages/client/Client.js +1 -1
  148. package/dist/api/resources/tag/client/Client.js +1 -1
  149. package/dist/api/resources/tools/client/Client.d.ts +9 -9
  150. package/dist/api/resources/tools/client/Client.js +20 -20
  151. package/dist/api/types/AgentState.d.ts +1 -1
  152. package/{api/types/AssistantMessageOutput.d.ts → dist/api/types/AssistantMessage.d.ts} +2 -1
  153. package/dist/api/types/Block.d.ts +1 -1
  154. package/dist/api/types/ChatCompletionMessageToolCall.d.ts +11 -0
  155. package/dist/api/types/ContextWindowOverview.d.ts +2 -2
  156. package/{api/types/FunctionCallOutput.d.ts → dist/api/types/Function.d.ts} +3 -1
  157. package/{api/types/FunctionSchema.d.ts → dist/api/types/FunctionDefinition.d.ts} +4 -1
  158. package/dist/api/types/FunctionTool.d.ts +10 -0
  159. package/dist/api/types/LettaMessageUnion.d.ts +1 -21
  160. package/dist/api/types/LettaUsageStatistics.d.ts +1 -0
  161. package/dist/api/types/{LettaSchemasMessageMessage.d.ts → Message.d.ts} +3 -3
  162. package/dist/api/types/ReasoningMessage.d.ts +1 -0
  163. package/dist/api/types/Source.d.ts +1 -1
  164. package/dist/api/types/{SystemMessageOutput.d.ts → SystemMessage.d.ts} +2 -1
  165. package/{api/types/LettaSchemasToolTool.d.ts → dist/api/types/Tool.d.ts} +1 -1
  166. package/{api/types/LettaSchemasLettaMessageToolCall.d.ts → dist/api/types/ToolCall.d.ts} +1 -1
  167. package/dist/api/types/ToolCallMessage.d.ts +1 -0
  168. package/dist/api/types/ToolCallMessageToolCall.d.ts +1 -1
  169. package/dist/api/types/ToolReturnMessage.d.ts +1 -0
  170. package/dist/api/types/ToolType.d.ts +2 -1
  171. package/dist/api/types/ToolType.js +1 -0
  172. package/dist/api/types/{UserMessageOutput.d.ts → UserMessage.d.ts} +2 -1
  173. package/dist/api/types/index.d.ts +10 -41
  174. package/dist/api/types/index.js +10 -41
  175. package/dist/serialization/resources/agents/client/createArchivalMemory.d.ts +11 -0
  176. package/dist/serialization/resources/agents/{resources/archivalMemory/client/list.js → client/createArchivalMemory.js} +2 -2
  177. package/dist/serialization/resources/agents/client/index.d.ts +3 -0
  178. package/dist/serialization/resources/agents/client/index.js +4 -1
  179. package/dist/serialization/resources/agents/client/listArchivalMemory.d.ts +11 -0
  180. package/dist/serialization/resources/agents/{resources/archivalMemory/client/create.js → client/listArchivalMemory.js} +2 -2
  181. package/dist/serialization/resources/agents/client/listCoreMemoryBlocks.d.ts +11 -0
  182. package/{serialization/resources/agents/resources/coreMemory/client/list.js → dist/serialization/resources/agents/client/listCoreMemoryBlocks.js} +2 -2
  183. package/dist/serialization/resources/agents/client/requests/CreateAgentRequest.d.ts +1 -1
  184. package/dist/serialization/resources/agents/client/requests/CreateAgentRequest.js +1 -1
  185. package/dist/serialization/resources/agents/client/requests/CreateArchivalMemory.d.ts +12 -0
  186. package/{serialization/resources/agents/resources/archivalMemory → dist/serialization/resources/agents}/client/requests/CreateArchivalMemory.js +1 -1
  187. package/dist/serialization/resources/agents/client/requests/UpdateAgent.d.ts +1 -1
  188. package/dist/serialization/resources/agents/client/requests/UpdateAgent.js +1 -1
  189. package/dist/serialization/resources/agents/client/requests/index.d.ts +1 -0
  190. package/dist/serialization/resources/agents/client/requests/index.js +3 -1
  191. package/dist/serialization/resources/agents/resources/index.d.ts +0 -3
  192. package/dist/serialization/resources/agents/resources/index.js +1 -4
  193. package/{serialization/resources/agents/resources/memoryVariables/types/MemoryVariablesGetResponse.d.ts → dist/serialization/resources/agents/resources/memoryVariables/types/MemoryVariablesListResponse.d.ts} +2 -2
  194. package/{serialization/resources/agents/resources/memoryVariables/types/MemoryVariablesGetResponse.js → dist/serialization/resources/agents/resources/memoryVariables/types/MemoryVariablesListResponse.js} +2 -2
  195. package/dist/serialization/resources/agents/resources/memoryVariables/types/index.d.ts +1 -1
  196. package/dist/serialization/resources/agents/resources/memoryVariables/types/index.js +1 -1
  197. package/dist/serialization/resources/agents/resources/messages/client/requests/MessageUpdate.d.ts +2 -2
  198. package/dist/serialization/resources/agents/resources/messages/client/requests/MessageUpdate.js +2 -2
  199. package/dist/serialization/resources/agents/resources/messages/types/LettaStreamingResponse.d.ts +4 -25
  200. package/dist/serialization/resources/agents/resources/messages/types/LettaStreamingResponse.js +12 -17
  201. package/dist/serialization/resources/agents/resources/messages/types/MessagesListResponse.d.ts +2 -2
  202. package/dist/serialization/resources/agents/resources/messages/types/MessagesListResponse.js +2 -2
  203. package/dist/serialization/resources/agents/resources/sources/client/index.d.ts +1 -1
  204. package/dist/serialization/resources/agents/resources/sources/client/index.js +2 -2
  205. package/{serialization/resources/agents/resources/sources/client/get.d.ts → dist/serialization/resources/agents/resources/sources/client/list.d.ts} +1 -1
  206. package/dist/serialization/resources/agents/resources/tools/client/list.d.ts +3 -3
  207. package/dist/serialization/resources/agents/resources/tools/client/list.js +2 -2
  208. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItem.d.ts +5 -17
  209. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItem.js +10 -15
  210. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemDirection.d.ts +16 -0
  211. package/dist/serialization/resources/agents/types/{AgentsSearchRequestSearchItemOrderBy.js → AgentsSearchRequestSearchItemDirection.js} +7 -6
  212. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemDirectionDirection.d.ts +10 -0
  213. package/dist/serialization/resources/agents/types/{AgentsSearchRequestSearchItemNameOperator.js → AgentsSearchRequestSearchItemDirectionDirection.js} +2 -2
  214. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemDirectionValue.d.ts +10 -0
  215. package/dist/serialization/resources/agents/types/{AgentsSearchRequestSearchItemOrderByValue.js → AgentsSearchRequestSearchItemDirectionValue.js} +2 -2
  216. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemOne.d.ts +15 -0
  217. package/dist/serialization/resources/agents/types/{AgentsSearchRequestSearchItemName.js → AgentsSearchRequestSearchItemOne.js} +5 -4
  218. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemOneOperator.d.ts +10 -0
  219. package/dist/serialization/resources/agents/types/{AgentsSearchRequestSearchItemOrderByDirection.js → AgentsSearchRequestSearchItemOneOperator.js} +2 -2
  220. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemTwo.d.ts +14 -0
  221. package/{serialization/resources/agents/types/AgentsSearchRequestSearchItemTags.js → dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemTwo.js} +3 -2
  222. package/dist/serialization/resources/agents/types/{AgentsSearchRequestSearchItemTags.d.ts → AgentsSearchRequestSearchItemZero.d.ts} +4 -4
  223. package/{serialization/resources/agents/types/AgentsSearchRequestSearchItemVersion.js → dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemZero.js} +3 -2
  224. package/dist/serialization/resources/agents/types/index.d.ts +7 -7
  225. package/dist/serialization/resources/agents/types/index.js +7 -7
  226. package/dist/serialization/resources/runs/client/index.d.ts +1 -1
  227. package/dist/serialization/resources/runs/client/index.js +2 -2
  228. package/dist/serialization/resources/runs/client/{getRunMessages.d.ts → listRunMessages.d.ts} +1 -1
  229. package/dist/serialization/resources/sources/client/requests/SourceCreate.d.ts +1 -1
  230. package/dist/serialization/resources/sources/client/requests/SourceCreate.js +1 -1
  231. package/dist/serialization/resources/sources/client/requests/SourceUpdate.d.ts +1 -1
  232. package/dist/serialization/resources/sources/client/requests/SourceUpdate.js +1 -1
  233. package/dist/serialization/resources/tools/client/addBaseTool.d.ts +3 -3
  234. package/dist/serialization/resources/tools/client/addBaseTool.js +2 -2
  235. package/dist/serialization/resources/tools/client/list.d.ts +3 -3
  236. package/dist/serialization/resources/tools/client/list.js +2 -2
  237. package/dist/serialization/types/AgentState.d.ts +3 -3
  238. package/dist/serialization/types/AgentState.js +3 -3
  239. package/{serialization/types/AssistantMessageOutput.d.ts → dist/serialization/types/AssistantMessage.d.ts} +3 -2
  240. package/dist/serialization/types/{AssistantMessageOutput.js → AssistantMessage.js} +3 -2
  241. package/dist/serialization/types/Block.d.ts +1 -1
  242. package/dist/serialization/types/Block.js +1 -1
  243. package/dist/serialization/types/BlockUpdate.d.ts +1 -1
  244. package/dist/serialization/types/BlockUpdate.js +1 -1
  245. package/dist/serialization/types/ChatCompletionMessageToolCall.d.ts +16 -0
  246. package/dist/serialization/types/{DeleteAssistantFileResponse.js → ChatCompletionMessageToolCall.js} +8 -5
  247. package/dist/serialization/types/ContextWindowOverview.d.ts +4 -4
  248. package/dist/serialization/types/ContextWindowOverview.js +4 -4
  249. package/dist/serialization/types/CreateBlock.d.ts +1 -1
  250. package/dist/serialization/types/CreateBlock.js +1 -1
  251. package/dist/serialization/types/{FunctionCallOutput.d.ts → Function.d.ts} +3 -2
  252. package/{serialization/types/FunctionCallOutput.js → dist/serialization/types/Function.js} +5 -3
  253. package/{serialization/types/FunctionSchema.d.ts → dist/serialization/types/FunctionDefinition.d.ts} +4 -2
  254. package/{serialization/types/FunctionSchema.js → dist/serialization/types/FunctionDefinition.js} +6 -3
  255. package/dist/serialization/types/FunctionTool.d.ts +15 -0
  256. package/dist/serialization/types/{ChatCompletionRequestStop.js → FunctionTool.js} +8 -5
  257. package/dist/serialization/types/Job.d.ts +1 -1
  258. package/dist/serialization/types/Job.js +1 -1
  259. package/dist/serialization/types/LettaMessageUnion.d.ts +4 -22
  260. package/dist/serialization/types/LettaMessageUnion.js +11 -16
  261. package/dist/serialization/types/LettaUsageStatistics.d.ts +1 -0
  262. package/dist/serialization/types/LettaUsageStatistics.js +1 -0
  263. package/{serialization/types/LettaSchemasMessageMessage.d.ts → dist/serialization/types/Message.d.ts} +4 -4
  264. package/{serialization/types/LettaSchemasMessageMessage.js → dist/serialization/types/Message.js} +4 -4
  265. package/dist/serialization/types/Passage.d.ts +1 -1
  266. package/dist/serialization/types/Passage.js +1 -1
  267. package/dist/serialization/types/ReasoningMessage.d.ts +1 -0
  268. package/dist/serialization/types/ReasoningMessage.js +1 -0
  269. package/dist/serialization/types/Run.d.ts +1 -1
  270. package/dist/serialization/types/Run.js +1 -1
  271. package/dist/serialization/types/Source.d.ts +1 -1
  272. package/dist/serialization/types/Source.js +1 -1
  273. package/{serialization/types/SystemMessageOutput.d.ts → dist/serialization/types/SystemMessage.d.ts} +3 -2
  274. package/dist/serialization/types/{UserMessageOutput.js → SystemMessage.js} +3 -2
  275. package/dist/serialization/types/{LettaSchemasToolTool.d.ts → Tool.d.ts} +2 -2
  276. package/dist/serialization/types/{LettaSchemasToolTool.js → Tool.js} +2 -2
  277. package/{serialization/types/FunctionCallOutput.d.ts → dist/serialization/types/ToolCall.d.ts} +4 -3
  278. package/{serialization/types/LettaSchemasLettaMessageToolCall.js → dist/serialization/types/ToolCall.js} +2 -2
  279. package/dist/serialization/types/ToolCallMessage.d.ts +1 -0
  280. package/dist/serialization/types/ToolCallMessage.js +1 -0
  281. package/dist/serialization/types/ToolCallMessageToolCall.d.ts +2 -2
  282. package/dist/serialization/types/ToolCallMessageToolCall.js +2 -2
  283. package/dist/serialization/types/ToolReturnMessage.d.ts +1 -0
  284. package/dist/serialization/types/ToolReturnMessage.js +1 -0
  285. package/dist/serialization/types/ToolType.d.ts +1 -1
  286. package/dist/serialization/types/ToolType.js +1 -0
  287. package/dist/serialization/types/{UserMessageOutput.d.ts → UserMessage.d.ts} +3 -2
  288. package/dist/serialization/types/{SystemMessageOutput.js → UserMessage.js} +3 -2
  289. package/dist/serialization/types/index.d.ts +10 -41
  290. package/dist/serialization/types/index.js +10 -41
  291. package/dist/version.d.ts +1 -1
  292. package/dist/version.js +1 -1
  293. package/package.json +1 -1
  294. package/reference.md +887 -568
  295. package/serialization/resources/agents/client/createArchivalMemory.d.ts +11 -0
  296. package/serialization/resources/agents/{resources/archivalMemory/client/create.js → client/createArchivalMemory.js} +2 -2
  297. package/serialization/resources/agents/client/index.d.ts +3 -0
  298. package/serialization/resources/agents/client/index.js +4 -1
  299. package/serialization/resources/agents/client/listArchivalMemory.d.ts +11 -0
  300. package/serialization/resources/agents/{resources/archivalMemory/client/list.js → client/listArchivalMemory.js} +2 -2
  301. package/serialization/resources/agents/client/listCoreMemoryBlocks.d.ts +11 -0
  302. package/{dist/serialization/resources/agents/resources/coreMemory/client/list.js → serialization/resources/agents/client/listCoreMemoryBlocks.js} +2 -2
  303. package/serialization/resources/agents/client/requests/CreateAgentRequest.d.ts +1 -1
  304. package/serialization/resources/agents/client/requests/CreateAgentRequest.js +1 -1
  305. package/serialization/resources/agents/client/requests/CreateArchivalMemory.d.ts +12 -0
  306. package/{dist/serialization/resources/agents/resources/archivalMemory → serialization/resources/agents}/client/requests/CreateArchivalMemory.js +1 -1
  307. package/serialization/resources/agents/client/requests/UpdateAgent.d.ts +1 -1
  308. package/serialization/resources/agents/client/requests/UpdateAgent.js +1 -1
  309. package/serialization/resources/agents/client/requests/index.d.ts +1 -0
  310. package/serialization/resources/agents/client/requests/index.js +3 -1
  311. package/serialization/resources/agents/resources/index.d.ts +0 -3
  312. package/serialization/resources/agents/resources/index.js +1 -4
  313. package/{dist/serialization/resources/agents/resources/memoryVariables/types/MemoryVariablesGetResponse.d.ts → serialization/resources/agents/resources/memoryVariables/types/MemoryVariablesListResponse.d.ts} +2 -2
  314. package/{dist/serialization/resources/agents/resources/memoryVariables/types/MemoryVariablesGetResponse.js → serialization/resources/agents/resources/memoryVariables/types/MemoryVariablesListResponse.js} +2 -2
  315. package/serialization/resources/agents/resources/memoryVariables/types/index.d.ts +1 -1
  316. package/serialization/resources/agents/resources/memoryVariables/types/index.js +1 -1
  317. package/serialization/resources/agents/resources/messages/client/requests/MessageUpdate.d.ts +2 -2
  318. package/serialization/resources/agents/resources/messages/client/requests/MessageUpdate.js +2 -2
  319. package/serialization/resources/agents/resources/messages/types/LettaStreamingResponse.d.ts +4 -25
  320. package/serialization/resources/agents/resources/messages/types/LettaStreamingResponse.js +12 -17
  321. package/serialization/resources/agents/resources/messages/types/MessagesListResponse.d.ts +2 -2
  322. package/serialization/resources/agents/resources/messages/types/MessagesListResponse.js +2 -2
  323. package/serialization/resources/agents/resources/sources/client/index.d.ts +1 -1
  324. package/serialization/resources/agents/resources/sources/client/index.js +2 -2
  325. package/{dist/serialization/resources/agents/resources/sources/client/get.d.ts → serialization/resources/agents/resources/sources/client/list.d.ts} +1 -1
  326. package/serialization/resources/agents/resources/tools/client/list.d.ts +3 -3
  327. package/serialization/resources/agents/resources/tools/client/list.js +2 -2
  328. package/serialization/resources/agents/types/AgentsSearchRequestSearchItem.d.ts +5 -17
  329. package/serialization/resources/agents/types/AgentsSearchRequestSearchItem.js +10 -15
  330. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemDirection.d.ts +16 -0
  331. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemDirection.js +47 -0
  332. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemDirectionDirection.d.ts +10 -0
  333. package/serialization/resources/agents/types/{AgentsSearchRequestSearchItemNameOperator.js → AgentsSearchRequestSearchItemDirectionDirection.js} +2 -2
  334. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemDirectionValue.d.ts +10 -0
  335. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemDirectionValue.js +41 -0
  336. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemOne.d.ts +15 -0
  337. package/serialization/resources/agents/types/{AgentsSearchRequestSearchItemName.js → AgentsSearchRequestSearchItemOne.js} +5 -4
  338. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemOneOperator.d.ts +10 -0
  339. package/serialization/resources/agents/types/{AgentsSearchRequestSearchItemOrderByDirection.js → AgentsSearchRequestSearchItemOneOperator.js} +2 -2
  340. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemTwo.d.ts +14 -0
  341. package/{dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemTags.js → serialization/resources/agents/types/AgentsSearchRequestSearchItemTwo.js} +3 -2
  342. package/serialization/resources/agents/types/{AgentsSearchRequestSearchItemTags.d.ts → AgentsSearchRequestSearchItemZero.d.ts} +4 -4
  343. package/{dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemVersion.js → serialization/resources/agents/types/AgentsSearchRequestSearchItemZero.js} +3 -2
  344. package/serialization/resources/agents/types/index.d.ts +7 -7
  345. package/serialization/resources/agents/types/index.js +7 -7
  346. package/serialization/resources/runs/client/index.d.ts +1 -1
  347. package/serialization/resources/runs/client/index.js +2 -2
  348. package/serialization/resources/runs/client/{getRunMessages.d.ts → listRunMessages.d.ts} +1 -1
  349. package/serialization/resources/sources/client/requests/SourceCreate.d.ts +1 -1
  350. package/serialization/resources/sources/client/requests/SourceCreate.js +1 -1
  351. package/serialization/resources/sources/client/requests/SourceUpdate.d.ts +1 -1
  352. package/serialization/resources/sources/client/requests/SourceUpdate.js +1 -1
  353. package/serialization/resources/tools/client/addBaseTool.d.ts +3 -3
  354. package/serialization/resources/tools/client/addBaseTool.js +2 -2
  355. package/serialization/resources/tools/client/list.d.ts +3 -3
  356. package/serialization/resources/tools/client/list.js +2 -2
  357. package/serialization/types/AgentState.d.ts +3 -3
  358. package/serialization/types/AgentState.js +3 -3
  359. package/{dist/serialization/types/AssistantMessageOutput.d.ts → serialization/types/AssistantMessage.d.ts} +3 -2
  360. package/serialization/types/{AssistantMessageOutput.js → AssistantMessage.js} +3 -2
  361. package/serialization/types/Block.d.ts +1 -1
  362. package/serialization/types/Block.js +1 -1
  363. package/serialization/types/BlockUpdate.d.ts +1 -1
  364. package/serialization/types/BlockUpdate.js +1 -1
  365. package/serialization/types/ChatCompletionMessageToolCall.d.ts +16 -0
  366. package/{dist/serialization/types/DeleteAssistantResponse.js → serialization/types/ChatCompletionMessageToolCall.js} +8 -5
  367. package/serialization/types/ContextWindowOverview.d.ts +4 -4
  368. package/serialization/types/ContextWindowOverview.js +4 -4
  369. package/serialization/types/CreateBlock.d.ts +1 -1
  370. package/serialization/types/CreateBlock.js +1 -1
  371. package/serialization/types/{ToolCallFunctionOutput.d.ts → Function.d.ts} +4 -3
  372. package/{dist/serialization/types/FunctionCallOutput.js → serialization/types/Function.js} +5 -3
  373. package/{dist/serialization/types/FunctionSchema.d.ts → serialization/types/FunctionDefinition.d.ts} +4 -2
  374. package/{dist/serialization/types/FunctionSchema.js → serialization/types/FunctionDefinition.js} +6 -3
  375. package/serialization/types/FunctionTool.d.ts +15 -0
  376. package/{dist/serialization/types/CreateAssistantFileRequest.js → serialization/types/FunctionTool.js} +8 -4
  377. package/serialization/types/Job.d.ts +1 -1
  378. package/serialization/types/Job.js +1 -1
  379. package/serialization/types/LettaMessageUnion.d.ts +4 -22
  380. package/serialization/types/LettaMessageUnion.js +11 -16
  381. package/serialization/types/LettaUsageStatistics.d.ts +1 -0
  382. package/serialization/types/LettaUsageStatistics.js +1 -0
  383. package/{dist/serialization/types/LettaSchemasMessageMessage.d.ts → serialization/types/Message.d.ts} +4 -4
  384. package/{dist/serialization/types/LettaSchemasMessageMessage.js → serialization/types/Message.js} +4 -4
  385. package/serialization/types/Passage.d.ts +1 -1
  386. package/serialization/types/Passage.js +1 -1
  387. package/serialization/types/ReasoningMessage.d.ts +1 -0
  388. package/serialization/types/ReasoningMessage.js +1 -0
  389. package/serialization/types/Run.d.ts +1 -1
  390. package/serialization/types/Run.js +1 -1
  391. package/serialization/types/Source.d.ts +1 -1
  392. package/serialization/types/Source.js +1 -1
  393. package/serialization/types/{UserMessageOutput.d.ts → SystemMessage.d.ts} +3 -2
  394. package/serialization/types/{UserMessageOutput.js → SystemMessage.js} +3 -2
  395. package/serialization/types/{LettaSchemasToolTool.d.ts → Tool.d.ts} +2 -2
  396. package/serialization/types/{LettaSchemasToolTool.js → Tool.js} +2 -2
  397. package/{dist/serialization/types/ToolCallFunctionOutput.d.ts → serialization/types/ToolCall.d.ts} +3 -2
  398. package/{dist/serialization/types/LettaSchemasLettaMessageToolCall.js → serialization/types/ToolCall.js} +2 -2
  399. package/serialization/types/ToolCallMessage.d.ts +1 -0
  400. package/serialization/types/ToolCallMessage.js +1 -0
  401. package/serialization/types/ToolCallMessageToolCall.d.ts +2 -2
  402. package/serialization/types/ToolCallMessageToolCall.js +2 -2
  403. package/serialization/types/ToolReturnMessage.d.ts +1 -0
  404. package/serialization/types/ToolReturnMessage.js +1 -0
  405. package/serialization/types/ToolType.d.ts +1 -1
  406. package/serialization/types/ToolType.js +1 -0
  407. package/{dist/serialization/types/SystemMessageOutput.d.ts → serialization/types/UserMessage.d.ts} +3 -2
  408. package/serialization/types/{SystemMessageOutput.js → UserMessage.js} +3 -2
  409. package/serialization/types/index.d.ts +10 -41
  410. package/serialization/types/index.js +10 -41
  411. package/version.d.ts +1 -1
  412. package/version.js +1 -1
  413. package/api/resources/agents/resources/archivalMemory/client/requests/index.d.ts +0 -2
  414. package/api/resources/agents/resources/archivalMemory/client/requests/index.js +0 -2
  415. package/api/resources/agents/types/AgentsSearchRequestSearchItemOrderBy.d.ts +0 -8
  416. package/api/resources/agents/types/AgentsSearchRequestSearchItemOrderByDirection.d.ts +0 -8
  417. package/api/resources/agents/types/AgentsSearchRequestSearchItemOrderByValue.d.ts +0 -8
  418. package/api/resources/blocks/client/requests/LinkAgentMemoryBlockRequest.d.ts +0 -15
  419. package/api/resources/blocks/client/requests/UnlinkAgentMemoryBlockRequest.d.ts +0 -15
  420. package/api/resources/sources/client/requests/SourcesAttachRequest.d.ts +0 -15
  421. package/api/resources/sources/client/requests/SourcesDetachRequest.d.ts +0 -15
  422. package/api/types/AssistantFile.d.ts +0 -12
  423. package/api/types/AssistantMessageInput.d.ts +0 -10
  424. package/api/types/ChatCompletionRequest.d.ts +0 -29
  425. package/api/types/ChatCompletionRequestFunctionCall.d.ts +0 -5
  426. package/api/types/ChatCompletionRequestMessagesItem.d.ts +0 -5
  427. package/api/types/ChatCompletionRequestStop.d.ts +0 -4
  428. package/api/types/ChatCompletionRequestToolChoice.d.ts +0 -5
  429. package/api/types/ChatCompletionResponse.d.ts +0 -16
  430. package/api/types/Choice.d.ts +0 -11
  431. package/api/types/CreateAssistantFileRequest.d.ts +0 -7
  432. package/api/types/CreateAssistantRequest.d.ts +0 -21
  433. package/api/types/DeleteAssistantFileResponse.d.ts +0 -10
  434. package/api/types/DeleteAssistantResponse.d.ts +0 -10
  435. package/api/types/FunctionCallInput.d.ts +0 -6
  436. package/api/types/LettaSchemasOpenaiChatCompletionRequestTool.d.ts +0 -8
  437. package/api/types/LettaSchemasOpenaiChatCompletionRequestToolCall.d.ts +0 -9
  438. package/api/types/LettaSchemasOpenaiChatCompletionResponseMessage.d.ts +0 -10
  439. package/api/types/LettaSchemasOpenaiChatCompletionResponseToolCall.d.ts +0 -9
  440. package/api/types/LettaSchemasOpenaiChatCompletionResponseToolCall.js +0 -5
  441. package/api/types/LettaSchemasOpenaiChatCompletionsToolCallFunction.d.ts +0 -9
  442. package/api/types/LettaSchemasOpenaiChatCompletionsToolCallFunction.js +0 -5
  443. package/api/types/LettaSchemasOpenaiChatCompletionsToolCallInput.d.ts +0 -11
  444. package/api/types/LettaSchemasOpenaiChatCompletionsToolCallInput.js +0 -5
  445. package/api/types/LettaSchemasOpenaiChatCompletionsToolCallOutput.d.ts +0 -11
  446. package/api/types/LettaSchemasOpenaiChatCompletionsToolCallOutput.js +0 -5
  447. package/api/types/LettaSchemasToolTool.js +0 -5
  448. package/api/types/LogProbToken.d.ts +0 -8
  449. package/api/types/LogProbToken.js +0 -5
  450. package/api/types/MessageContentLogProb.d.ts +0 -10
  451. package/api/types/MessageContentLogProb.js +0 -5
  452. package/api/types/OpenAiAssistant.d.ts +0 -27
  453. package/api/types/OpenAiAssistant.js +0 -5
  454. package/api/types/ResponseFormat.d.ts +0 -6
  455. package/api/types/ResponseFormat.js +0 -5
  456. package/api/types/SystemMessageInput.d.ts +0 -8
  457. package/api/types/SystemMessageInput.js +0 -5
  458. package/api/types/SystemMessageOutput.js +0 -5
  459. package/api/types/ToolCallFunctionOutput.d.ts +0 -9
  460. package/api/types/ToolCallFunctionOutput.js +0 -5
  461. package/api/types/ToolFunctionChoice.d.ts +0 -8
  462. package/api/types/ToolFunctionChoice.js +0 -5
  463. package/api/types/ToolInput.d.ts +0 -8
  464. package/api/types/ToolInput.js +0 -5
  465. package/api/types/ToolMessage.d.ts +0 -8
  466. package/api/types/ToolMessage.js +0 -5
  467. package/api/types/UserMessageInput.d.ts +0 -9
  468. package/api/types/UserMessageInput.js +0 -5
  469. package/api/types/UserMessageInputContent.d.ts +0 -4
  470. package/api/types/UserMessageInputContent.js +0 -5
  471. package/api/types/UserMessageOutput.js +0 -5
  472. package/dist/api/resources/agents/resources/archivalMemory/client/requests/ArchivalMemoryListRequest.js +0 -5
  473. package/dist/api/resources/agents/resources/archivalMemory/client/requests/index.d.ts +0 -2
  474. package/dist/api/resources/agents/resources/archivalMemory/client/requests/index.js +0 -2
  475. package/dist/api/resources/agents/resources/memoryVariables/types/MemoryVariablesGetResponse.js +0 -5
  476. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemName.js +0 -5
  477. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemOrderBy.d.ts +0 -8
  478. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemOrderBy.js +0 -5
  479. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemOrderByDirection.d.ts +0 -8
  480. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemOrderByValue.d.ts +0 -8
  481. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemTags.js +0 -5
  482. package/dist/api/resources/agents/types/AgentsSearchRequestSearchItemVersion.js +0 -5
  483. package/dist/api/resources/blocks/client/requests/LinkAgentMemoryBlockRequest.d.ts +0 -15
  484. package/dist/api/resources/blocks/client/requests/LinkAgentMemoryBlockRequest.js +0 -5
  485. package/dist/api/resources/blocks/client/requests/UnlinkAgentMemoryBlockRequest.d.ts +0 -15
  486. package/dist/api/resources/blocks/client/requests/UnlinkAgentMemoryBlockRequest.js +0 -5
  487. package/dist/api/resources/runs/client/requests/GetRunMessagesRequest.js +0 -5
  488. package/dist/api/resources/sources/client/requests/SourcesAttachRequest.d.ts +0 -15
  489. package/dist/api/resources/sources/client/requests/SourcesAttachRequest.js +0 -5
  490. package/dist/api/resources/sources/client/requests/SourcesDetachRequest.d.ts +0 -15
  491. package/dist/api/resources/sources/client/requests/SourcesDetachRequest.js +0 -5
  492. package/dist/api/types/AssistantFile.d.ts +0 -12
  493. package/dist/api/types/AssistantFile.js +0 -5
  494. package/dist/api/types/AssistantMessageInput.d.ts +0 -10
  495. package/dist/api/types/AssistantMessageInput.js +0 -5
  496. package/dist/api/types/AssistantMessageOutput.js +0 -5
  497. package/dist/api/types/ChatCompletionRequest.d.ts +0 -29
  498. package/dist/api/types/ChatCompletionRequest.js +0 -5
  499. package/dist/api/types/ChatCompletionRequestFunctionCall.d.ts +0 -5
  500. package/dist/api/types/ChatCompletionRequestFunctionCall.js +0 -5
  501. package/dist/api/types/ChatCompletionRequestMessagesItem.d.ts +0 -5
  502. package/dist/api/types/ChatCompletionRequestMessagesItem.js +0 -5
  503. package/dist/api/types/ChatCompletionRequestStop.d.ts +0 -4
  504. package/dist/api/types/ChatCompletionRequestStop.js +0 -5
  505. package/dist/api/types/ChatCompletionRequestToolChoice.d.ts +0 -5
  506. package/dist/api/types/ChatCompletionRequestToolChoice.js +0 -5
  507. package/dist/api/types/ChatCompletionResponse.d.ts +0 -16
  508. package/dist/api/types/ChatCompletionResponse.js +0 -5
  509. package/dist/api/types/Choice.d.ts +0 -11
  510. package/dist/api/types/Choice.js +0 -5
  511. package/dist/api/types/CreateAssistantFileRequest.d.ts +0 -7
  512. package/dist/api/types/CreateAssistantFileRequest.js +0 -5
  513. package/dist/api/types/CreateAssistantRequest.d.ts +0 -21
  514. package/dist/api/types/CreateAssistantRequest.js +0 -5
  515. package/dist/api/types/DeleteAssistantFileResponse.d.ts +0 -10
  516. package/dist/api/types/DeleteAssistantFileResponse.js +0 -5
  517. package/dist/api/types/DeleteAssistantResponse.d.ts +0 -10
  518. package/dist/api/types/DeleteAssistantResponse.js +0 -5
  519. package/dist/api/types/FunctionCallInput.d.ts +0 -6
  520. package/dist/api/types/FunctionCallInput.js +0 -5
  521. package/dist/api/types/FunctionCallOutput.d.ts +0 -7
  522. package/dist/api/types/FunctionCallOutput.js +0 -5
  523. package/dist/api/types/FunctionSchema.js +0 -5
  524. package/dist/api/types/LettaSchemasLettaMessageToolCall.js +0 -5
  525. package/dist/api/types/LettaSchemasMessageMessage.js +0 -5
  526. package/dist/api/types/LettaSchemasOpenaiChatCompletionRequestTool.d.ts +0 -8
  527. package/dist/api/types/LettaSchemasOpenaiChatCompletionRequestTool.js +0 -5
  528. package/dist/api/types/LettaSchemasOpenaiChatCompletionRequestToolCall.d.ts +0 -9
  529. package/dist/api/types/LettaSchemasOpenaiChatCompletionRequestToolCall.js +0 -5
  530. package/dist/api/types/LettaSchemasOpenaiChatCompletionRequestToolCallFunction.d.ts +0 -7
  531. package/dist/api/types/LettaSchemasOpenaiChatCompletionRequestToolCallFunction.js +0 -5
  532. package/dist/api/types/LettaSchemasOpenaiChatCompletionResponseMessage.d.ts +0 -10
  533. package/dist/api/types/LettaSchemasOpenaiChatCompletionResponseMessage.js +0 -5
  534. package/dist/api/types/LettaSchemasOpenaiChatCompletionResponseToolCall.d.ts +0 -9
  535. package/dist/api/types/LettaSchemasOpenaiChatCompletionResponseToolCall.js +0 -5
  536. package/dist/api/types/LettaSchemasOpenaiChatCompletionsToolCallFunction.d.ts +0 -9
  537. package/dist/api/types/LettaSchemasOpenaiChatCompletionsToolCallFunction.js +0 -5
  538. package/dist/api/types/LettaSchemasOpenaiChatCompletionsToolCallInput.d.ts +0 -11
  539. package/dist/api/types/LettaSchemasOpenaiChatCompletionsToolCallInput.js +0 -5
  540. package/dist/api/types/LettaSchemasOpenaiChatCompletionsToolCallOutput.d.ts +0 -11
  541. package/dist/api/types/LettaSchemasOpenaiChatCompletionsToolCallOutput.js +0 -5
  542. package/dist/api/types/LettaSchemasToolTool.js +0 -5
  543. package/dist/api/types/LogProbToken.d.ts +0 -8
  544. package/dist/api/types/LogProbToken.js +0 -5
  545. package/dist/api/types/MessageContentLogProb.d.ts +0 -10
  546. package/dist/api/types/MessageContentLogProb.js +0 -5
  547. package/dist/api/types/OpenAiAssistant.d.ts +0 -27
  548. package/dist/api/types/OpenAiAssistant.js +0 -5
  549. package/dist/api/types/ResponseFormat.d.ts +0 -6
  550. package/dist/api/types/ResponseFormat.js +0 -5
  551. package/dist/api/types/SystemMessageInput.d.ts +0 -8
  552. package/dist/api/types/SystemMessageInput.js +0 -5
  553. package/dist/api/types/SystemMessageOutput.js +0 -5
  554. package/dist/api/types/ToolCallFunctionOutput.d.ts +0 -9
  555. package/dist/api/types/ToolCallFunctionOutput.js +0 -5
  556. package/dist/api/types/ToolFunctionChoice.d.ts +0 -8
  557. package/dist/api/types/ToolFunctionChoice.js +0 -5
  558. package/dist/api/types/ToolInput.d.ts +0 -8
  559. package/dist/api/types/ToolInput.js +0 -5
  560. package/dist/api/types/ToolMessage.d.ts +0 -8
  561. package/dist/api/types/ToolMessage.js +0 -5
  562. package/dist/api/types/UserMessageInput.d.ts +0 -9
  563. package/dist/api/types/UserMessageInput.js +0 -5
  564. package/dist/api/types/UserMessageInputContent.d.ts +0 -4
  565. package/dist/api/types/UserMessageInputContent.js +0 -5
  566. package/dist/api/types/UserMessageOutput.js +0 -5
  567. package/dist/serialization/resources/agents/resources/archivalMemory/client/create.d.ts +0 -11
  568. package/dist/serialization/resources/agents/resources/archivalMemory/client/index.d.ts +0 -3
  569. package/dist/serialization/resources/agents/resources/archivalMemory/client/index.js +0 -42
  570. package/dist/serialization/resources/agents/resources/archivalMemory/client/list.d.ts +0 -11
  571. package/dist/serialization/resources/agents/resources/archivalMemory/client/requests/CreateArchivalMemory.d.ts +0 -12
  572. package/dist/serialization/resources/agents/resources/archivalMemory/client/requests/index.d.ts +0 -1
  573. package/dist/serialization/resources/agents/resources/archivalMemory/client/requests/index.js +0 -5
  574. package/dist/serialization/resources/agents/resources/archivalMemory/index.d.ts +0 -1
  575. package/dist/serialization/resources/agents/resources/archivalMemory/index.js +0 -17
  576. package/dist/serialization/resources/agents/resources/coreMemory/client/index.d.ts +0 -1
  577. package/dist/serialization/resources/agents/resources/coreMemory/client/index.js +0 -37
  578. package/dist/serialization/resources/agents/resources/coreMemory/client/list.d.ts +0 -11
  579. package/dist/serialization/resources/agents/resources/coreMemory/index.d.ts +0 -1
  580. package/dist/serialization/resources/agents/resources/coreMemory/index.js +0 -17
  581. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemName.d.ts +0 -14
  582. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemNameOperator.d.ts +0 -10
  583. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemOrderBy.d.ts +0 -15
  584. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemOrderByDirection.d.ts +0 -10
  585. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemOrderByValue.d.ts +0 -10
  586. package/dist/serialization/resources/agents/types/AgentsSearchRequestSearchItemVersion.d.ts +0 -12
  587. package/dist/serialization/types/AssistantFile.d.ts +0 -15
  588. package/dist/serialization/types/AssistantFile.js +0 -46
  589. package/dist/serialization/types/AssistantMessageInput.d.ts +0 -16
  590. package/dist/serialization/types/AssistantMessageInput.js +0 -47
  591. package/dist/serialization/types/ChatCompletionRequest.d.ts +0 -38
  592. package/dist/serialization/types/ChatCompletionRequest.js +0 -69
  593. package/dist/serialization/types/ChatCompletionRequestFunctionCall.d.ts +0 -11
  594. package/dist/serialization/types/ChatCompletionRequestFunctionCall.js +0 -46
  595. package/dist/serialization/types/ChatCompletionRequestMessagesItem.d.ts +0 -14
  596. package/dist/serialization/types/ChatCompletionRequestMessagesItem.js +0 -45
  597. package/dist/serialization/types/ChatCompletionRequestStop.d.ts +0 -10
  598. package/dist/serialization/types/ChatCompletionRequestToolChoice.d.ts +0 -11
  599. package/dist/serialization/types/ChatCompletionRequestToolChoice.js +0 -47
  600. package/dist/serialization/types/ChatCompletionResponse.d.ts +0 -20
  601. package/dist/serialization/types/ChatCompletionResponse.js +0 -51
  602. package/dist/serialization/types/Choice.d.ts +0 -18
  603. package/dist/serialization/types/Choice.js +0 -51
  604. package/dist/serialization/types/CreateAssistantFileRequest.d.ts +0 -12
  605. package/dist/serialization/types/CreateAssistantRequest.d.ts +0 -19
  606. package/dist/serialization/types/CreateAssistantRequest.js +0 -50
  607. package/dist/serialization/types/DeleteAssistantFileResponse.d.ts +0 -14
  608. package/dist/serialization/types/DeleteAssistantResponse.d.ts +0 -14
  609. package/dist/serialization/types/FunctionCallInput.d.ts +0 -12
  610. package/dist/serialization/types/FunctionCallInput.js +0 -43
  611. package/dist/serialization/types/LettaSchemasLettaMessageToolCall.d.ts +0 -14
  612. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionRequestTool.d.ts +0 -14
  613. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionRequestTool.js +0 -45
  614. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionRequestToolCall.d.ts +0 -15
  615. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionRequestToolCall.js +0 -46
  616. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionRequestToolCallFunction.d.ts +0 -13
  617. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionRequestToolCallFunction.js +0 -44
  618. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionResponseMessage.d.ts +0 -17
  619. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionResponseMessage.js +0 -48
  620. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionResponseToolCall.d.ts +0 -15
  621. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionResponseToolCall.js +0 -46
  622. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallFunction.d.ts +0 -13
  623. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallFunction.js +0 -44
  624. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallInput.d.ts +0 -15
  625. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallInput.js +0 -46
  626. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallOutput.d.ts +0 -15
  627. package/dist/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallOutput.js +0 -46
  628. package/dist/serialization/types/LogProbToken.d.ts +0 -14
  629. package/dist/serialization/types/LogProbToken.js +0 -45
  630. package/dist/serialization/types/MessageContentLogProb.d.ts +0 -16
  631. package/dist/serialization/types/MessageContentLogProb.js +0 -47
  632. package/dist/serialization/types/OpenAiAssistant.d.ts +0 -21
  633. package/dist/serialization/types/OpenAiAssistant.js +0 -52
  634. package/dist/serialization/types/ResponseFormat.d.ts +0 -12
  635. package/dist/serialization/types/ResponseFormat.js +0 -43
  636. package/dist/serialization/types/SystemMessageInput.d.ts +0 -14
  637. package/dist/serialization/types/SystemMessageInput.js +0 -45
  638. package/dist/serialization/types/ToolCallFunctionOutput.js +0 -44
  639. package/dist/serialization/types/ToolFunctionChoice.d.ts +0 -14
  640. package/dist/serialization/types/ToolFunctionChoice.js +0 -45
  641. package/dist/serialization/types/ToolInput.d.ts +0 -14
  642. package/dist/serialization/types/ToolInput.js +0 -45
  643. package/dist/serialization/types/ToolMessage.d.ts +0 -14
  644. package/dist/serialization/types/ToolMessage.js +0 -45
  645. package/dist/serialization/types/UserMessageInput.d.ts +0 -15
  646. package/dist/serialization/types/UserMessageInput.js +0 -46
  647. package/dist/serialization/types/UserMessageInputContent.d.ts +0 -10
  648. package/dist/serialization/types/UserMessageInputContent.js +0 -44
  649. package/serialization/resources/agents/resources/archivalMemory/client/create.d.ts +0 -11
  650. package/serialization/resources/agents/resources/archivalMemory/client/index.d.ts +0 -3
  651. package/serialization/resources/agents/resources/archivalMemory/client/index.js +0 -42
  652. package/serialization/resources/agents/resources/archivalMemory/client/list.d.ts +0 -11
  653. package/serialization/resources/agents/resources/archivalMemory/client/requests/CreateArchivalMemory.d.ts +0 -12
  654. package/serialization/resources/agents/resources/archivalMemory/client/requests/index.d.ts +0 -1
  655. package/serialization/resources/agents/resources/archivalMemory/client/requests/index.js +0 -5
  656. package/serialization/resources/agents/resources/archivalMemory/index.d.ts +0 -1
  657. package/serialization/resources/agents/resources/archivalMemory/index.js +0 -17
  658. package/serialization/resources/agents/resources/coreMemory/client/index.d.ts +0 -1
  659. package/serialization/resources/agents/resources/coreMemory/client/index.js +0 -37
  660. package/serialization/resources/agents/resources/coreMemory/client/list.d.ts +0 -11
  661. package/serialization/resources/agents/resources/coreMemory/index.d.ts +0 -1
  662. package/serialization/resources/agents/resources/coreMemory/index.js +0 -17
  663. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemName.d.ts +0 -14
  664. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemNameOperator.d.ts +0 -10
  665. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemOrderBy.d.ts +0 -15
  666. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemOrderBy.js +0 -46
  667. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemOrderByDirection.d.ts +0 -10
  668. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemOrderByValue.d.ts +0 -10
  669. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemOrderByValue.js +0 -41
  670. package/serialization/resources/agents/types/AgentsSearchRequestSearchItemVersion.d.ts +0 -12
  671. package/serialization/types/AssistantFile.d.ts +0 -15
  672. package/serialization/types/AssistantFile.js +0 -46
  673. package/serialization/types/AssistantMessageInput.d.ts +0 -16
  674. package/serialization/types/AssistantMessageInput.js +0 -47
  675. package/serialization/types/ChatCompletionRequest.d.ts +0 -38
  676. package/serialization/types/ChatCompletionRequest.js +0 -69
  677. package/serialization/types/ChatCompletionRequestFunctionCall.d.ts +0 -11
  678. package/serialization/types/ChatCompletionRequestFunctionCall.js +0 -46
  679. package/serialization/types/ChatCompletionRequestMessagesItem.d.ts +0 -14
  680. package/serialization/types/ChatCompletionRequestMessagesItem.js +0 -45
  681. package/serialization/types/ChatCompletionRequestStop.d.ts +0 -10
  682. package/serialization/types/ChatCompletionRequestStop.js +0 -44
  683. package/serialization/types/ChatCompletionRequestToolChoice.d.ts +0 -11
  684. package/serialization/types/ChatCompletionRequestToolChoice.js +0 -47
  685. package/serialization/types/ChatCompletionResponse.d.ts +0 -20
  686. package/serialization/types/ChatCompletionResponse.js +0 -51
  687. package/serialization/types/Choice.d.ts +0 -18
  688. package/serialization/types/Choice.js +0 -51
  689. package/serialization/types/CreateAssistantFileRequest.d.ts +0 -12
  690. package/serialization/types/CreateAssistantFileRequest.js +0 -43
  691. package/serialization/types/CreateAssistantRequest.d.ts +0 -19
  692. package/serialization/types/CreateAssistantRequest.js +0 -50
  693. package/serialization/types/DeleteAssistantFileResponse.d.ts +0 -14
  694. package/serialization/types/DeleteAssistantFileResponse.js +0 -45
  695. package/serialization/types/DeleteAssistantResponse.d.ts +0 -14
  696. package/serialization/types/DeleteAssistantResponse.js +0 -45
  697. package/serialization/types/FunctionCallInput.d.ts +0 -12
  698. package/serialization/types/FunctionCallInput.js +0 -43
  699. package/serialization/types/LettaSchemasLettaMessageToolCall.d.ts +0 -14
  700. package/serialization/types/LettaSchemasOpenaiChatCompletionRequestTool.d.ts +0 -14
  701. package/serialization/types/LettaSchemasOpenaiChatCompletionRequestTool.js +0 -45
  702. package/serialization/types/LettaSchemasOpenaiChatCompletionRequestToolCall.d.ts +0 -15
  703. package/serialization/types/LettaSchemasOpenaiChatCompletionRequestToolCall.js +0 -46
  704. package/serialization/types/LettaSchemasOpenaiChatCompletionRequestToolCallFunction.d.ts +0 -13
  705. package/serialization/types/LettaSchemasOpenaiChatCompletionRequestToolCallFunction.js +0 -44
  706. package/serialization/types/LettaSchemasOpenaiChatCompletionResponseMessage.d.ts +0 -17
  707. package/serialization/types/LettaSchemasOpenaiChatCompletionResponseMessage.js +0 -48
  708. package/serialization/types/LettaSchemasOpenaiChatCompletionResponseToolCall.d.ts +0 -15
  709. package/serialization/types/LettaSchemasOpenaiChatCompletionResponseToolCall.js +0 -46
  710. package/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallFunction.d.ts +0 -13
  711. package/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallFunction.js +0 -44
  712. package/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallInput.d.ts +0 -15
  713. package/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallInput.js +0 -46
  714. package/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallOutput.d.ts +0 -15
  715. package/serialization/types/LettaSchemasOpenaiChatCompletionsToolCallOutput.js +0 -46
  716. package/serialization/types/LogProbToken.d.ts +0 -14
  717. package/serialization/types/LogProbToken.js +0 -45
  718. package/serialization/types/MessageContentLogProb.d.ts +0 -16
  719. package/serialization/types/MessageContentLogProb.js +0 -47
  720. package/serialization/types/OpenAiAssistant.d.ts +0 -21
  721. package/serialization/types/OpenAiAssistant.js +0 -52
  722. package/serialization/types/ResponseFormat.d.ts +0 -12
  723. package/serialization/types/ResponseFormat.js +0 -43
  724. package/serialization/types/SystemMessageInput.d.ts +0 -14
  725. package/serialization/types/SystemMessageInput.js +0 -45
  726. package/serialization/types/ToolCallFunctionOutput.js +0 -44
  727. package/serialization/types/ToolFunctionChoice.d.ts +0 -14
  728. package/serialization/types/ToolFunctionChoice.js +0 -45
  729. package/serialization/types/ToolInput.d.ts +0 -14
  730. package/serialization/types/ToolInput.js +0 -45
  731. package/serialization/types/ToolMessage.d.ts +0 -14
  732. package/serialization/types/ToolMessage.js +0 -45
  733. package/serialization/types/UserMessageInput.d.ts +0 -15
  734. package/serialization/types/UserMessageInput.js +0 -46
  735. package/serialization/types/UserMessageInputContent.d.ts +0 -10
  736. package/serialization/types/UserMessageInputContent.js +0 -44
  737. /package/api/resources/agents/{resources/archivalMemory/client → client}/requests/CreateArchivalMemory.d.ts +0 -0
  738. /package/api/resources/agents/{resources/archivalMemory/client → client}/requests/CreateArchivalMemory.js +0 -0
  739. /package/api/resources/agents/{resources/archivalMemory/client/requests/ArchivalMemoryListRequest.js → client/requests/ListArchivalMemoryRequest.js} +0 -0
  740. /package/api/resources/agents/resources/memoryVariables/types/{MemoryVariablesGetResponse.js → MemoryVariablesListResponse.js} +0 -0
  741. /package/api/resources/agents/types/{AgentsSearchRequestSearchItemName.js → AgentsSearchRequestSearchItemDirection.js} +0 -0
  742. /package/api/resources/agents/types/{AgentsSearchRequestSearchItemOrderBy.js → AgentsSearchRequestSearchItemOne.js} +0 -0
  743. /package/api/resources/agents/types/{AgentsSearchRequestSearchItemTags.js → AgentsSearchRequestSearchItemTwo.js} +0 -0
  744. /package/api/resources/agents/types/{AgentsSearchRequestSearchItemVersion.js → AgentsSearchRequestSearchItemZero.js} +0 -0
  745. /package/api/resources/{blocks/client/requests/LinkAgentMemoryBlockRequest.js → runs/client/requests/ListRunMessagesRequest.js} +0 -0
  746. /package/api/{resources/blocks/client/requests/UnlinkAgentMemoryBlockRequest.js → types/AssistantMessage.js} +0 -0
  747. /package/api/{resources/runs/client/requests/GetRunMessagesRequest.js → types/ChatCompletionMessageToolCall.js} +0 -0
  748. /package/api/{resources/sources/client/requests/SourcesAttachRequest.js → types/Function.js} +0 -0
  749. /package/api/{resources/sources/client/requests/SourcesDetachRequest.js → types/FunctionDefinition.js} +0 -0
  750. /package/api/types/{AssistantFile.js → FunctionTool.js} +0 -0
  751. /package/api/types/{AssistantMessageInput.js → Message.js} +0 -0
  752. /package/api/types/{AssistantMessageOutput.js → SystemMessage.js} +0 -0
  753. /package/api/types/{ChatCompletionRequest.js → Tool.js} +0 -0
  754. /package/api/types/{ChatCompletionRequestFunctionCall.js → ToolCall.js} +0 -0
  755. /package/api/types/{ChatCompletionRequestMessagesItem.js → UserMessage.js} +0 -0
  756. /package/dist/api/resources/agents/{resources/archivalMemory/client → client}/requests/CreateArchivalMemory.d.ts +0 -0
  757. /package/dist/api/resources/agents/{resources/archivalMemory/client → client}/requests/CreateArchivalMemory.js +0 -0
  758. /package/{api/types/ChatCompletionRequestStop.js → dist/api/resources/agents/client/requests/ListArchivalMemoryRequest.js} +0 -0
  759. /package/{api/types/ChatCompletionRequestToolChoice.js → dist/api/resources/agents/resources/memoryVariables/types/MemoryVariablesListResponse.js} +0 -0
  760. /package/{api/types/ChatCompletionResponse.js → dist/api/resources/agents/types/AgentsSearchRequestSearchItemDirection.js} +0 -0
  761. /package/{api/types/Choice.js → dist/api/resources/agents/types/AgentsSearchRequestSearchItemOne.js} +0 -0
  762. /package/{api/types/CreateAssistantFileRequest.js → dist/api/resources/agents/types/AgentsSearchRequestSearchItemTwo.js} +0 -0
  763. /package/{api/types/CreateAssistantRequest.js → dist/api/resources/agents/types/AgentsSearchRequestSearchItemZero.js} +0 -0
  764. /package/{api/types/DeleteAssistantFileResponse.js → dist/api/resources/runs/client/requests/ListRunMessagesRequest.js} +0 -0
  765. /package/{api/types/DeleteAssistantResponse.js → dist/api/types/AssistantMessage.js} +0 -0
  766. /package/{api/types/FunctionCallInput.js → dist/api/types/ChatCompletionMessageToolCall.js} +0 -0
  767. /package/{api/types/FunctionCallOutput.js → dist/api/types/Function.js} +0 -0
  768. /package/{api/types/FunctionSchema.js → dist/api/types/FunctionDefinition.js} +0 -0
  769. /package/{api/types/LettaSchemasLettaMessageToolCall.js → dist/api/types/FunctionTool.js} +0 -0
  770. /package/{api/types/LettaSchemasMessageMessage.js → dist/api/types/Message.js} +0 -0
  771. /package/{api/types/LettaSchemasOpenaiChatCompletionRequestTool.js → dist/api/types/SystemMessage.js} +0 -0
  772. /package/{api/types/LettaSchemasOpenaiChatCompletionRequestToolCall.js → dist/api/types/Tool.js} +0 -0
  773. /package/{api/types/LettaSchemasOpenaiChatCompletionRequestToolCallFunction.js → dist/api/types/ToolCall.js} +0 -0
  774. /package/{api/types/LettaSchemasOpenaiChatCompletionResponseMessage.js → dist/api/types/UserMessage.js} +0 -0
  775. /package/dist/serialization/resources/agents/resources/sources/client/{get.js → list.js} +0 -0
  776. /package/dist/serialization/resources/runs/client/{getRunMessages.js → listRunMessages.js} +0 -0
  777. /package/serialization/resources/agents/resources/sources/client/{get.js → list.js} +0 -0
  778. /package/serialization/resources/runs/client/{getRunMessages.js → listRunMessages.js} +0 -0
@@ -51,33 +51,26 @@ Object.defineProperty(exports, "__esModule", { value: true });
51
51
  exports.CoreMemory = void 0;
52
52
  const environments = __importStar(require("../../../../../../environments"));
53
53
  const core = __importStar(require("../../../../../../core"));
54
- const Letta = __importStar(require("../../../../../index"));
55
54
  const url_join_1 = __importDefault(require("url-join"));
56
- const serializers = __importStar(require("../../../../../../serialization/index"));
57
55
  const errors = __importStar(require("../../../../../../errors/index"));
58
56
  class CoreMemory {
59
57
  constructor(_options = {}) {
60
58
  this._options = _options;
61
59
  }
62
60
  /**
63
- * Retrieve the memory state of a specific agent.
64
- * This endpoint fetches the current memory state of the agent identified by the user ID and agent ID.
65
- *
66
61
  * @param {string} agentId
67
62
  * @param {CoreMemory.RequestOptions} requestOptions - Request-specific configuration.
68
63
  *
69
- * @throws {@link Letta.UnprocessableEntityError}
70
- *
71
64
  * @example
72
- * await client.agents.coreMemory.get("agent_id")
65
+ * await client.agents.coreMemory.retrieve("agent_id")
73
66
  */
74
- get(agentId, requestOptions) {
67
+ retrieve(agentId, requestOptions) {
75
68
  return __awaiter(this, void 0, void 0, function* () {
76
69
  var _a, _b, _c;
77
70
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
78
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/agents/${encodeURIComponent(agentId)}/core_memory`),
79
72
  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.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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
74
  contentType: "application/json",
82
75
  requestType: "json",
83
76
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -85,30 +78,13 @@ class CoreMemory {
85
78
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
86
79
  });
87
80
  if (_response.ok) {
88
- return serializers.Memory.parseOrThrow(_response.body, {
89
- unrecognizedObjectKeys: "passthrough",
90
- allowUnrecognizedUnionMembers: true,
91
- allowUnrecognizedEnumValues: true,
92
- skipValidation: true,
93
- breadcrumbsPrefix: ["response"],
94
- });
81
+ return;
95
82
  }
96
83
  if (_response.error.reason === "status-code") {
97
- switch (_response.error.statusCode) {
98
- case 422:
99
- throw new Letta.UnprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
100
- unrecognizedObjectKeys: "passthrough",
101
- allowUnrecognizedUnionMembers: true,
102
- allowUnrecognizedEnumValues: true,
103
- skipValidation: true,
104
- breadcrumbsPrefix: ["response"],
105
- }));
106
- default:
107
- throw new errors.LettaError({
108
- statusCode: _response.error.statusCode,
109
- body: _response.error.body,
110
- });
111
- }
84
+ throw new errors.LettaError({
85
+ statusCode: _response.error.statusCode,
86
+ body: _response.error.body,
87
+ });
112
88
  }
113
89
  switch (_response.error.reason) {
114
90
  case "non-json":
@@ -126,24 +102,19 @@ class CoreMemory {
126
102
  });
127
103
  }
128
104
  /**
129
- * Retrieve a memory block from an agent.
130
- *
131
105
  * @param {string} agentId
132
- * @param {string} blockLabel
133
106
  * @param {CoreMemory.RequestOptions} requestOptions - Request-specific configuration.
134
107
  *
135
- * @throws {@link Letta.UnprocessableEntityError}
136
- *
137
108
  * @example
138
- * await client.agents.coreMemory.getBlock("agent_id", "block_label")
109
+ * await client.agents.coreMemory.listBlocks("agent_id")
139
110
  */
140
- getBlock(agentId, blockLabel, requestOptions) {
111
+ listBlocks(agentId, requestOptions) {
141
112
  return __awaiter(this, void 0, void 0, function* () {
142
113
  var _a, _b, _c;
143
114
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
144
- 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)}`),
115
+ 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`),
145
116
  method: "GET",
146
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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),
117
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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
118
  contentType: "application/json",
148
119
  requestType: "json",
149
120
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -151,30 +122,13 @@ class CoreMemory {
151
122
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
152
123
  });
153
124
  if (_response.ok) {
154
- return serializers.Block.parseOrThrow(_response.body, {
155
- unrecognizedObjectKeys: "passthrough",
156
- allowUnrecognizedUnionMembers: true,
157
- allowUnrecognizedEnumValues: true,
158
- skipValidation: true,
159
- breadcrumbsPrefix: ["response"],
160
- });
125
+ return;
161
126
  }
162
127
  if (_response.error.reason === "status-code") {
163
- switch (_response.error.statusCode) {
164
- case 422:
165
- throw new Letta.UnprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
166
- unrecognizedObjectKeys: "passthrough",
167
- allowUnrecognizedUnionMembers: true,
168
- allowUnrecognizedEnumValues: true,
169
- skipValidation: true,
170
- breadcrumbsPrefix: ["response"],
171
- }));
172
- default:
173
- throw new errors.LettaError({
174
- statusCode: _response.error.statusCode,
175
- body: _response.error.body,
176
- });
177
- }
128
+ throw new errors.LettaError({
129
+ statusCode: _response.error.statusCode,
130
+ body: _response.error.body,
131
+ });
178
132
  }
179
133
  switch (_response.error.reason) {
180
134
  case "non-json":
@@ -183,7 +137,7 @@ class CoreMemory {
183
137
  body: _response.error.rawBody,
184
138
  });
185
139
  case "timeout":
186
- throw new errors.LettaTimeoutError("Timeout exceeded when calling GET /v1/agents/{agent_id}/core_memory/blocks/{block_label}.");
140
+ throw new errors.LettaTimeoutError("Timeout exceeded when calling GET /v1/agents/{agent_id}/core_memory/blocks.");
187
141
  case "unknown":
188
142
  throw new errors.LettaError({
189
143
  message: _response.error.errorMessage,
@@ -192,24 +146,20 @@ class CoreMemory {
192
146
  });
193
147
  }
194
148
  /**
195
- * Removes a memory block from an agent by unlnking it. If the block is not linked to any other agent, it is deleted.
196
- *
197
149
  * @param {string} agentId
198
- * @param {string} blockLabel
150
+ * @param {string} blockId
199
151
  * @param {CoreMemory.RequestOptions} requestOptions - Request-specific configuration.
200
152
  *
201
- * @throws {@link Letta.UnprocessableEntityError}
202
- *
203
153
  * @example
204
- * await client.agents.coreMemory.removeBlock("agent_id", "block_label")
154
+ * await client.agents.coreMemory.attachBlock("agent_id", "block_id")
205
155
  */
206
- removeBlock(agentId, blockLabel, requestOptions) {
156
+ attachBlock(agentId, blockId, requestOptions) {
207
157
  return __awaiter(this, void 0, void 0, function* () {
208
158
  var _a, _b, _c;
209
159
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
210
- 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)}`),
211
- method: "DELETE",
212
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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
+ 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)}`),
161
+ method: "PATCH",
162
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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
163
  contentType: "application/json",
214
164
  requestType: "json",
215
165
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -217,30 +167,13 @@ class CoreMemory {
217
167
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
218
168
  });
219
169
  if (_response.ok) {
220
- return serializers.Memory.parseOrThrow(_response.body, {
221
- unrecognizedObjectKeys: "passthrough",
222
- allowUnrecognizedUnionMembers: true,
223
- allowUnrecognizedEnumValues: true,
224
- skipValidation: true,
225
- breadcrumbsPrefix: ["response"],
226
- });
170
+ return;
227
171
  }
228
172
  if (_response.error.reason === "status-code") {
229
- switch (_response.error.statusCode) {
230
- case 422:
231
- throw new Letta.UnprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
232
- unrecognizedObjectKeys: "passthrough",
233
- allowUnrecognizedUnionMembers: true,
234
- allowUnrecognizedEnumValues: true,
235
- skipValidation: true,
236
- breadcrumbsPrefix: ["response"],
237
- }));
238
- default:
239
- throw new errors.LettaError({
240
- statusCode: _response.error.statusCode,
241
- body: _response.error.body,
242
- });
243
- }
173
+ throw new errors.LettaError({
174
+ statusCode: _response.error.statusCode,
175
+ body: _response.error.body,
176
+ });
244
177
  }
245
178
  switch (_response.error.reason) {
246
179
  case "non-json":
@@ -249,7 +182,7 @@ class CoreMemory {
249
182
  body: _response.error.rawBody,
250
183
  });
251
184
  case "timeout":
252
- throw new errors.LettaTimeoutError("Timeout exceeded when calling DELETE /v1/agents/{agent_id}/core_memory/blocks/{block_label}.");
185
+ throw new errors.LettaTimeoutError("Timeout exceeded when calling PATCH /v1/agents/{agent_id}/core_memory/blocks/attach/{block_id}.");
253
186
  case "unknown":
254
187
  throw new errors.LettaError({
255
188
  message: _response.error.errorMessage,
@@ -258,57 +191,34 @@ class CoreMemory {
258
191
  });
259
192
  }
260
193
  /**
261
- * Removes a memory block from an agent by unlnking it. If the block is not linked to any other agent, it is deleted.
262
- *
263
194
  * @param {string} agentId
264
- * @param {string} blockLabel
265
- * @param {Letta.BlockUpdate} request
195
+ * @param {string} blockId
266
196
  * @param {CoreMemory.RequestOptions} requestOptions - Request-specific configuration.
267
197
  *
268
- * @throws {@link Letta.UnprocessableEntityError}
269
- *
270
198
  * @example
271
- * await client.agents.coreMemory.updateBlock("agent_id", "block_label", {})
199
+ * await client.agents.coreMemory.detachBlock("agent_id", "block_id")
272
200
  */
273
- updateBlock(agentId, blockLabel, request, requestOptions) {
201
+ detachBlock(agentId, blockId, requestOptions) {
274
202
  return __awaiter(this, void 0, void 0, function* () {
275
203
  var _a, _b, _c;
276
204
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
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/${encodeURIComponent(blockLabel)}`),
205
+ 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)}`),
278
206
  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.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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),
207
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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
208
  contentType: "application/json",
281
209
  requestType: "json",
282
- body: serializers.BlockUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
283
210
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
284
211
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
285
212
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
286
213
  });
287
214
  if (_response.ok) {
288
- return serializers.Block.parseOrThrow(_response.body, {
289
- unrecognizedObjectKeys: "passthrough",
290
- allowUnrecognizedUnionMembers: true,
291
- allowUnrecognizedEnumValues: true,
292
- skipValidation: true,
293
- breadcrumbsPrefix: ["response"],
294
- });
215
+ return;
295
216
  }
296
217
  if (_response.error.reason === "status-code") {
297
- switch (_response.error.statusCode) {
298
- case 422:
299
- throw new Letta.UnprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
300
- unrecognizedObjectKeys: "passthrough",
301
- allowUnrecognizedUnionMembers: true,
302
- allowUnrecognizedEnumValues: true,
303
- skipValidation: true,
304
- breadcrumbsPrefix: ["response"],
305
- }));
306
- default:
307
- throw new errors.LettaError({
308
- statusCode: _response.error.statusCode,
309
- body: _response.error.body,
310
- });
311
- }
218
+ throw new errors.LettaError({
219
+ statusCode: _response.error.statusCode,
220
+ body: _response.error.body,
221
+ });
312
222
  }
313
223
  switch (_response.error.reason) {
314
224
  case "non-json":
@@ -317,7 +227,7 @@ class CoreMemory {
317
227
  body: _response.error.rawBody,
318
228
  });
319
229
  case "timeout":
320
- throw new errors.LettaTimeoutError("Timeout exceeded when calling PATCH /v1/agents/{agent_id}/core_memory/blocks/{block_label}.");
230
+ throw new errors.LettaTimeoutError("Timeout exceeded when calling PATCH /v1/agents/{agent_id}/core_memory/blocks/detach/{block_id}.");
321
231
  case "unknown":
322
232
  throw new errors.LettaError({
323
233
  message: _response.error.errorMessage,
@@ -326,23 +236,20 @@ class CoreMemory {
326
236
  });
327
237
  }
328
238
  /**
329
- * Retrieve the memory blocks of a specific agent.
330
- *
331
239
  * @param {string} agentId
240
+ * @param {string} blockLabel
332
241
  * @param {CoreMemory.RequestOptions} requestOptions - Request-specific configuration.
333
242
  *
334
- * @throws {@link Letta.UnprocessableEntityError}
335
- *
336
243
  * @example
337
- * await client.agents.coreMemory.list("agent_id")
244
+ * await client.agents.coreMemory.retrieveBlock("agent_id", "block_label")
338
245
  */
339
- list(agentId, requestOptions) {
246
+ retrieveBlock(agentId, blockLabel, requestOptions) {
340
247
  return __awaiter(this, void 0, void 0, function* () {
341
248
  var _a, _b, _c;
342
249
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
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`),
250
+ 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)}`),
344
251
  method: "GET",
345
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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),
252
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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
253
  contentType: "application/json",
347
254
  requestType: "json",
348
255
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -350,30 +257,13 @@ class CoreMemory {
350
257
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
351
258
  });
352
259
  if (_response.ok) {
353
- return serializers.agents.coreMemory.list.Response.parseOrThrow(_response.body, {
354
- unrecognizedObjectKeys: "passthrough",
355
- allowUnrecognizedUnionMembers: true,
356
- allowUnrecognizedEnumValues: true,
357
- skipValidation: true,
358
- breadcrumbsPrefix: ["response"],
359
- });
260
+ return;
360
261
  }
361
262
  if (_response.error.reason === "status-code") {
362
- switch (_response.error.statusCode) {
363
- case 422:
364
- throw new Letta.UnprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
365
- unrecognizedObjectKeys: "passthrough",
366
- allowUnrecognizedUnionMembers: true,
367
- allowUnrecognizedEnumValues: true,
368
- skipValidation: true,
369
- breadcrumbsPrefix: ["response"],
370
- }));
371
- default:
372
- throw new errors.LettaError({
373
- statusCode: _response.error.statusCode,
374
- body: _response.error.body,
375
- });
376
- }
263
+ throw new errors.LettaError({
264
+ statusCode: _response.error.statusCode,
265
+ body: _response.error.body,
266
+ });
377
267
  }
378
268
  switch (_response.error.reason) {
379
269
  case "non-json":
@@ -382,7 +272,7 @@ class CoreMemory {
382
272
  body: _response.error.rawBody,
383
273
  });
384
274
  case "timeout":
385
- throw new errors.LettaTimeoutError("Timeout exceeded when calling GET /v1/agents/{agent_id}/core_memory/blocks.");
275
+ throw new errors.LettaTimeoutError("Timeout exceeded when calling GET /v1/agents/{agent_id}/core_memory/blocks/{block_label}.");
386
276
  case "unknown":
387
277
  throw new errors.LettaError({
388
278
  message: _response.error.errorMessage,
@@ -391,59 +281,34 @@ class CoreMemory {
391
281
  });
392
282
  }
393
283
  /**
394
- * Creates a memory block and links it to the agent.
395
- *
396
284
  * @param {string} agentId
397
- * @param {Letta.CreateBlock} request
285
+ * @param {string} blockLabel
398
286
  * @param {CoreMemory.RequestOptions} requestOptions - Request-specific configuration.
399
287
  *
400
- * @throws {@link Letta.UnprocessableEntityError}
401
- *
402
288
  * @example
403
- * await client.agents.coreMemory.addBlock("agent_id", {
404
- * value: "value",
405
- * label: "label"
406
- * })
289
+ * await client.agents.coreMemory.modifyBlock("agent_id", "block_label")
407
290
  */
408
- addBlock(agentId, request, requestOptions) {
291
+ modifyBlock(agentId, blockLabel, requestOptions) {
409
292
  return __awaiter(this, void 0, void 0, function* () {
410
293
  var _a, _b, _c;
411
294
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
412
- 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`),
413
- method: "POST",
414
- headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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),
295
+ 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)}`),
296
+ method: "PATCH",
297
+ headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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),
415
298
  contentType: "application/json",
416
299
  requestType: "json",
417
- body: serializers.CreateBlock.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
418
300
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
419
301
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
420
302
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
421
303
  });
422
304
  if (_response.ok) {
423
- return serializers.Memory.parseOrThrow(_response.body, {
424
- unrecognizedObjectKeys: "passthrough",
425
- allowUnrecognizedUnionMembers: true,
426
- allowUnrecognizedEnumValues: true,
427
- skipValidation: true,
428
- breadcrumbsPrefix: ["response"],
429
- });
305
+ return;
430
306
  }
431
307
  if (_response.error.reason === "status-code") {
432
- switch (_response.error.statusCode) {
433
- case 422:
434
- throw new Letta.UnprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
435
- unrecognizedObjectKeys: "passthrough",
436
- allowUnrecognizedUnionMembers: true,
437
- allowUnrecognizedEnumValues: true,
438
- skipValidation: true,
439
- breadcrumbsPrefix: ["response"],
440
- }));
441
- default:
442
- throw new errors.LettaError({
443
- statusCode: _response.error.statusCode,
444
- body: _response.error.body,
445
- });
446
- }
308
+ throw new errors.LettaError({
309
+ statusCode: _response.error.statusCode,
310
+ body: _response.error.body,
311
+ });
447
312
  }
448
313
  switch (_response.error.reason) {
449
314
  case "non-json":
@@ -452,7 +317,7 @@ class CoreMemory {
452
317
  body: _response.error.rawBody,
453
318
  });
454
319
  case "timeout":
455
- throw new errors.LettaTimeoutError("Timeout exceeded when calling POST /v1/agents/{agent_id}/core_memory/blocks.");
320
+ throw new errors.LettaTimeoutError("Timeout exceeded when calling PATCH /v1/agents/{agent_id}/core_memory/blocks/{block_label}.");
456
321
  case "unknown":
457
322
  throw new errors.LettaError({
458
323
  message: _response.error.errorMessage,
@@ -9,6 +9,5 @@ export * as tools from "./tools";
9
9
  export * as sources from "./sources";
10
10
  export * as coreMemory from "./coreMemory";
11
11
  export * as archivalMemory from "./archivalMemory";
12
- export * from "./archivalMemory/client/requests";
13
12
  export * from "./messages/client/requests";
14
13
  export * from "./templates/client/requests";
@@ -48,6 +48,5 @@ exports.tools = __importStar(require("./tools"));
48
48
  exports.sources = __importStar(require("./sources"));
49
49
  exports.coreMemory = __importStar(require("./coreMemory"));
50
50
  exports.archivalMemory = __importStar(require("./archivalMemory"));
51
- __exportStar(require("./archivalMemory/client/requests"), exports);
52
51
  __exportStar(require("./messages/client/requests"), exports);
53
52
  __exportStar(require("./templates/client/requests"), exports);
@@ -37,9 +37,9 @@ export declare class MemoryVariables {
37
37
  * @throws {@link Letta.NotFoundError}
38
38
  *
39
39
  * @example
40
- * await client.agents.memoryVariables.get("agent_id")
40
+ * await client.agents.memoryVariables.list("agent_id")
41
41
  */
42
- get(agentId: string, requestOptions?: MemoryVariables.RequestOptions): Promise<Letta.agents.MemoryVariablesGetResponse>;
42
+ list(agentId: string, requestOptions?: MemoryVariables.RequestOptions): Promise<Letta.agents.MemoryVariablesListResponse>;
43
43
  protected _getCustomAuthorizationHeaders(): Promise<{
44
44
  Authorization: string;
45
45
  }>;
@@ -70,15 +70,15 @@ class MemoryVariables {
70
70
  * @throws {@link Letta.NotFoundError}
71
71
  *
72
72
  * @example
73
- * await client.agents.memoryVariables.get("agent_id")
73
+ * await client.agents.memoryVariables.list("agent_id")
74
74
  */
75
- get(agentId, requestOptions) {
75
+ list(agentId, requestOptions) {
76
76
  return __awaiter(this, void 0, void 0, function* () {
77
77
  var _a, _b, _c;
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.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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,
@@ -86,7 +86,7 @@ class MemoryVariables {
86
86
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
87
87
  });
88
88
  if (_response.ok) {
89
- return serializers.agents.MemoryVariablesGetResponse.parseOrThrow(_response.body, {
89
+ return serializers.agents.MemoryVariablesListResponse.parseOrThrow(_response.body, {
90
90
  unrecognizedObjectKeys: "passthrough",
91
91
  allowUnrecognizedUnionMembers: true,
92
92
  allowUnrecognizedEnumValues: true,
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
- export interface MemoryVariablesGetResponse {
4
+ export interface MemoryVariablesListResponse {
5
5
  variables: Record<string, string>;
6
6
  }
@@ -1 +1 @@
1
- export * from "./MemoryVariablesGetResponse";
1
+ export * from "./MemoryVariablesListResponse";
@@ -14,4 +14,4 @@ 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("./MemoryVariablesGetResponse"), exports);
17
+ __exportStar(require("./MemoryVariablesListResponse"), exports);
@@ -69,9 +69,9 @@ export declare class Messages {
69
69
  * @throws {@link Letta.UnprocessableEntityError}
70
70
  *
71
71
  * @example
72
- * await client.agents.messages.update("agent_id", "message_id")
72
+ * await client.agents.messages.modify("agent_id", "message_id")
73
73
  */
74
- update(agentId: string, messageId: string, request?: Letta.agents.MessageUpdate, requestOptions?: Messages.RequestOptions): Promise<Letta.LettaSchemasMessageMessage>;
74
+ modify(agentId: string, messageId: string, request?: Letta.agents.MessageUpdate, requestOptions?: Messages.RequestOptions): Promise<Letta.Message>;
75
75
  /**
76
76
  * Process a user message and return the agent's response.
77
77
  * This endpoint accepts a message from a user and processes it through the agent.
@@ -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.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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",
@@ -167,7 +167,7 @@ class Messages {
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.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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" }),
@@ -227,15 +227,15 @@ class Messages {
227
227
  * @throws {@link Letta.UnprocessableEntityError}
228
228
  *
229
229
  * @example
230
- * await client.agents.messages.update("agent_id", "message_id")
230
+ * await client.agents.messages.modify("agent_id", "message_id")
231
231
  */
232
- update(agentId_1, messageId_1) {
232
+ modify(agentId_1, messageId_1) {
233
233
  return __awaiter(this, arguments, void 0, function* (agentId, messageId, request = {}, requestOptions) {
234
234
  var _a, _b, _c;
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.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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" }),
@@ -244,7 +244,7 @@ class Messages {
244
244
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
245
245
  });
246
246
  if (_response.ok) {
247
- return serializers.LettaSchemasMessageMessage.parseOrThrow(_response.body, {
247
+ return serializers.Message.parseOrThrow(_response.body, {
248
248
  unrecognizedObjectKeys: "passthrough",
249
249
  allowUnrecognizedUnionMembers: true,
250
250
  allowUnrecognizedEnumValues: true,
@@ -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.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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" }),
@@ -379,7 +379,7 @@ class Messages {
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.12", "User-Agent": "@letta-ai/letta-client/0.1.12", "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.13", "User-Agent": "@letta-ai/letta-client/0.1.13", "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" }),