@letta-ai/letta-client 0.1.147 → 0.1.149

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 (188) hide show
  1. package/api/resources/agents/client/Client.js +11 -11
  2. package/api/resources/agents/resources/blocks/client/Client.js +5 -5
  3. package/api/resources/agents/resources/context/client/Client.js +1 -1
  4. package/api/resources/agents/resources/coreMemory/client/Client.js +1 -1
  5. package/api/resources/agents/resources/groups/client/Client.js +1 -1
  6. package/api/resources/agents/resources/memoryVariables/client/Client.js +1 -1
  7. package/api/resources/agents/resources/messages/client/Client.d.ts +18 -0
  8. package/api/resources/agents/resources/messages/client/Client.js +84 -6
  9. package/api/resources/agents/resources/passages/client/Client.js +4 -4
  10. package/api/resources/agents/resources/sources/client/Client.js +3 -3
  11. package/api/resources/agents/resources/templates/client/Client.js +3 -3
  12. package/api/resources/agents/resources/tools/client/Client.js +3 -3
  13. package/api/resources/batches/client/Client.js +4 -4
  14. package/api/resources/blocks/client/Client.js +6 -6
  15. package/api/resources/blocks/resources/agents/client/Client.d.ts +2 -1
  16. package/api/resources/blocks/resources/agents/client/Client.js +15 -3
  17. package/api/resources/blocks/resources/agents/client/index.d.ts +1 -1
  18. package/api/resources/blocks/resources/agents/client/index.js +15 -0
  19. package/api/resources/blocks/resources/agents/client/requests/AgentsListRequest.d.ts +13 -0
  20. package/api/resources/blocks/resources/agents/client/requests/AgentsListRequest.js +5 -0
  21. package/api/resources/blocks/resources/agents/client/requests/index.d.ts +1 -0
  22. package/api/resources/blocks/resources/agents/client/requests/index.js +2 -0
  23. package/api/resources/blocks/resources/index.d.ts +1 -0
  24. package/api/resources/blocks/resources/index.js +4 -0
  25. package/api/resources/clientSideAccessTokens/client/Client.js +2 -2
  26. package/api/resources/embeddingModels/client/Client.js +1 -1
  27. package/api/resources/groups/client/Client.js +6 -6
  28. package/api/resources/groups/resources/messages/client/Client.js +5 -5
  29. package/api/resources/health/client/Client.js +1 -1
  30. package/api/resources/identities/client/Client.js +7 -7
  31. package/api/resources/identities/resources/properties/client/Client.js +1 -1
  32. package/api/resources/jobs/client/Client.d.ts +16 -0
  33. package/api/resources/jobs/client/Client.js +101 -6
  34. package/api/resources/jobs/client/requests/JobsListActiveRequest.d.ts +16 -0
  35. package/api/resources/jobs/client/requests/JobsListRequest.d.ts +16 -0
  36. package/api/resources/messages/client/Client.js +1 -1
  37. package/api/resources/models/client/Client.js +1 -1
  38. package/api/resources/projects/client/Client.js +1 -1
  39. package/api/resources/providers/client/Client.js +5 -5
  40. package/api/resources/runs/client/Client.js +4 -4
  41. package/api/resources/runs/resources/messages/client/Client.js +1 -1
  42. package/api/resources/runs/resources/steps/client/Client.js +1 -1
  43. package/api/resources/runs/resources/usage/client/Client.js +1 -1
  44. package/api/resources/sources/client/Client.d.ts +17 -0
  45. package/api/resources/sources/client/Client.js +80 -8
  46. package/api/resources/sources/resources/files/client/Client.js +3 -3
  47. package/api/resources/sources/resources/passages/client/Client.js +1 -1
  48. package/api/resources/steps/client/Client.js +2 -2
  49. package/api/resources/steps/resources/feedback/client/Client.js +1 -1
  50. package/api/resources/tags/client/Client.js +1 -1
  51. package/api/resources/telemetry/client/Client.js +1 -1
  52. package/api/resources/templates/client/Client.js +1 -1
  53. package/api/resources/templates/resources/agents/client/Client.js +1 -1
  54. package/api/resources/tools/client/Client.js +19 -19
  55. package/api/resources/voice/client/Client.js +1 -1
  56. package/api/types/FileMetadata.d.ts +4 -0
  57. package/api/types/FileStats.d.ts +14 -0
  58. package/api/types/FileStats.js +5 -0
  59. package/api/types/LlmConfig.d.ts +2 -0
  60. package/api/types/OrganizationSourcesStats.d.ts +17 -0
  61. package/api/types/OrganizationSourcesStats.js +5 -0
  62. package/api/types/SourceStats.d.ts +19 -0
  63. package/api/types/SourceStats.js +5 -0
  64. package/api/types/StopReasonType.d.ts +2 -1
  65. package/api/types/StopReasonType.js +1 -0
  66. package/api/types/UpdateSsemcpServer.d.ts +2 -0
  67. package/api/types/UpdateStreamableHttpmcpServer.d.ts +2 -0
  68. package/api/types/index.d.ts +3 -0
  69. package/api/types/index.js +3 -0
  70. package/dist/api/resources/agents/client/Client.js +11 -11
  71. package/dist/api/resources/agents/resources/blocks/client/Client.js +5 -5
  72. package/dist/api/resources/agents/resources/context/client/Client.js +1 -1
  73. package/dist/api/resources/agents/resources/coreMemory/client/Client.js +1 -1
  74. package/dist/api/resources/agents/resources/groups/client/Client.js +1 -1
  75. package/dist/api/resources/agents/resources/memoryVariables/client/Client.js +1 -1
  76. package/dist/api/resources/agents/resources/messages/client/Client.d.ts +18 -0
  77. package/dist/api/resources/agents/resources/messages/client/Client.js +84 -6
  78. package/dist/api/resources/agents/resources/passages/client/Client.js +4 -4
  79. package/dist/api/resources/agents/resources/sources/client/Client.js +3 -3
  80. package/dist/api/resources/agents/resources/templates/client/Client.js +3 -3
  81. package/dist/api/resources/agents/resources/tools/client/Client.js +3 -3
  82. package/dist/api/resources/batches/client/Client.js +4 -4
  83. package/dist/api/resources/blocks/client/Client.js +6 -6
  84. package/dist/api/resources/blocks/resources/agents/client/Client.d.ts +2 -1
  85. package/dist/api/resources/blocks/resources/agents/client/Client.js +15 -3
  86. package/dist/api/resources/blocks/resources/agents/client/index.d.ts +1 -1
  87. package/dist/api/resources/blocks/resources/agents/client/index.js +15 -0
  88. package/dist/api/resources/blocks/resources/agents/client/requests/AgentsListRequest.d.ts +13 -0
  89. package/dist/api/resources/blocks/resources/agents/client/requests/AgentsListRequest.js +5 -0
  90. package/dist/api/resources/blocks/resources/agents/client/requests/index.d.ts +1 -0
  91. package/dist/api/resources/blocks/resources/agents/client/requests/index.js +2 -0
  92. package/dist/api/resources/blocks/resources/index.d.ts +1 -0
  93. package/dist/api/resources/blocks/resources/index.js +4 -0
  94. package/dist/api/resources/clientSideAccessTokens/client/Client.js +2 -2
  95. package/dist/api/resources/embeddingModels/client/Client.js +1 -1
  96. package/dist/api/resources/groups/client/Client.js +6 -6
  97. package/dist/api/resources/groups/resources/messages/client/Client.js +5 -5
  98. package/dist/api/resources/health/client/Client.js +1 -1
  99. package/dist/api/resources/identities/client/Client.js +7 -7
  100. package/dist/api/resources/identities/resources/properties/client/Client.js +1 -1
  101. package/dist/api/resources/jobs/client/Client.d.ts +16 -0
  102. package/dist/api/resources/jobs/client/Client.js +101 -6
  103. package/dist/api/resources/jobs/client/requests/JobsListActiveRequest.d.ts +16 -0
  104. package/dist/api/resources/jobs/client/requests/JobsListRequest.d.ts +16 -0
  105. package/dist/api/resources/messages/client/Client.js +1 -1
  106. package/dist/api/resources/models/client/Client.js +1 -1
  107. package/dist/api/resources/projects/client/Client.js +1 -1
  108. package/dist/api/resources/providers/client/Client.js +5 -5
  109. package/dist/api/resources/runs/client/Client.js +4 -4
  110. package/dist/api/resources/runs/resources/messages/client/Client.js +1 -1
  111. package/dist/api/resources/runs/resources/steps/client/Client.js +1 -1
  112. package/dist/api/resources/runs/resources/usage/client/Client.js +1 -1
  113. package/dist/api/resources/sources/client/Client.d.ts +17 -0
  114. package/dist/api/resources/sources/client/Client.js +80 -8
  115. package/dist/api/resources/sources/resources/files/client/Client.js +3 -3
  116. package/dist/api/resources/sources/resources/passages/client/Client.js +1 -1
  117. package/dist/api/resources/steps/client/Client.js +2 -2
  118. package/dist/api/resources/steps/resources/feedback/client/Client.js +1 -1
  119. package/dist/api/resources/tags/client/Client.js +1 -1
  120. package/dist/api/resources/telemetry/client/Client.js +1 -1
  121. package/dist/api/resources/templates/client/Client.js +1 -1
  122. package/dist/api/resources/templates/resources/agents/client/Client.js +1 -1
  123. package/dist/api/resources/tools/client/Client.js +19 -19
  124. package/dist/api/resources/voice/client/Client.js +1 -1
  125. package/dist/api/types/FileMetadata.d.ts +4 -0
  126. package/dist/api/types/FileStats.d.ts +14 -0
  127. package/dist/api/types/FileStats.js +5 -0
  128. package/dist/api/types/LlmConfig.d.ts +2 -0
  129. package/dist/api/types/OrganizationSourcesStats.d.ts +17 -0
  130. package/dist/api/types/OrganizationSourcesStats.js +5 -0
  131. package/dist/api/types/SourceStats.d.ts +19 -0
  132. package/dist/api/types/SourceStats.js +5 -0
  133. package/dist/api/types/StopReasonType.d.ts +2 -1
  134. package/dist/api/types/StopReasonType.js +1 -0
  135. package/dist/api/types/UpdateSsemcpServer.d.ts +2 -0
  136. package/dist/api/types/UpdateStreamableHttpmcpServer.d.ts +2 -0
  137. package/dist/api/types/index.d.ts +3 -0
  138. package/dist/api/types/index.js +3 -0
  139. package/dist/serialization/resources/agents/resources/messages/client/cancel.d.ts +13 -0
  140. package/dist/serialization/resources/agents/resources/messages/client/cancel.js +42 -0
  141. package/dist/serialization/resources/agents/resources/messages/client/index.d.ts +1 -0
  142. package/dist/serialization/resources/agents/resources/messages/client/index.js +2 -1
  143. package/dist/serialization/types/FileMetadata.d.ts +2 -0
  144. package/dist/serialization/types/FileMetadata.js +2 -0
  145. package/dist/serialization/types/FileStats.d.ts +14 -0
  146. package/dist/serialization/types/FileStats.js +45 -0
  147. package/dist/serialization/types/LlmConfig.d.ts +1 -0
  148. package/dist/serialization/types/LlmConfig.js +1 -0
  149. package/dist/serialization/types/OrganizationSourcesStats.d.ts +16 -0
  150. package/dist/serialization/types/OrganizationSourcesStats.js +47 -0
  151. package/dist/serialization/types/SourceStats.d.ts +17 -0
  152. package/dist/serialization/types/SourceStats.js +48 -0
  153. package/dist/serialization/types/StopReasonType.d.ts +1 -1
  154. package/dist/serialization/types/StopReasonType.js +9 -1
  155. package/dist/serialization/types/UpdateSsemcpServer.d.ts +1 -0
  156. package/dist/serialization/types/UpdateSsemcpServer.js +1 -0
  157. package/dist/serialization/types/UpdateStreamableHttpmcpServer.d.ts +1 -0
  158. package/dist/serialization/types/UpdateStreamableHttpmcpServer.js +1 -0
  159. package/dist/serialization/types/index.d.ts +3 -0
  160. package/dist/serialization/types/index.js +3 -0
  161. package/dist/version.d.ts +1 -1
  162. package/dist/version.js +1 -1
  163. package/package.json +1 -1
  164. package/reference.md +213 -1
  165. package/serialization/resources/agents/resources/messages/client/cancel.d.ts +13 -0
  166. package/serialization/resources/agents/resources/messages/client/cancel.js +42 -0
  167. package/serialization/resources/agents/resources/messages/client/index.d.ts +1 -0
  168. package/serialization/resources/agents/resources/messages/client/index.js +2 -1
  169. package/serialization/types/FileMetadata.d.ts +2 -0
  170. package/serialization/types/FileMetadata.js +2 -0
  171. package/serialization/types/FileStats.d.ts +14 -0
  172. package/serialization/types/FileStats.js +45 -0
  173. package/serialization/types/LlmConfig.d.ts +1 -0
  174. package/serialization/types/LlmConfig.js +1 -0
  175. package/serialization/types/OrganizationSourcesStats.d.ts +16 -0
  176. package/serialization/types/OrganizationSourcesStats.js +47 -0
  177. package/serialization/types/SourceStats.d.ts +17 -0
  178. package/serialization/types/SourceStats.js +48 -0
  179. package/serialization/types/StopReasonType.d.ts +1 -1
  180. package/serialization/types/StopReasonType.js +9 -1
  181. package/serialization/types/UpdateSsemcpServer.d.ts +1 -0
  182. package/serialization/types/UpdateSsemcpServer.js +1 -0
  183. package/serialization/types/UpdateStreamableHttpmcpServer.d.ts +1 -0
  184. package/serialization/types/UpdateStreamableHttpmcpServer.js +1 -0
  185. package/serialization/types/index.d.ts +3 -0
  186. package/serialization/types/index.js +3 -0
  187. package/version.d.ts +1 -1
  188. package/version.js +1 -1
@@ -79,7 +79,7 @@ class Blocks {
79
79
  method: "GET",
80
80
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
81
81
  ? yield core.Supplier.get(this._options.project)
82
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
83
83
  contentType: "application/json",
84
84
  requestType: "json",
85
85
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -148,7 +148,7 @@ class Blocks {
148
148
  method: "PATCH",
149
149
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
150
150
  ? yield core.Supplier.get(this._options.project)
151
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
151
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
152
152
  contentType: "application/json",
153
153
  requestType: "json",
154
154
  body: serializers.BlockUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -216,7 +216,7 @@ class Blocks {
216
216
  method: "GET",
217
217
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
218
218
  ? yield core.Supplier.get(this._options.project)
219
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
219
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
220
220
  contentType: "application/json",
221
221
  requestType: "json",
222
222
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -284,7 +284,7 @@ class Blocks {
284
284
  method: "PATCH",
285
285
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
286
286
  ? yield core.Supplier.get(this._options.project)
287
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
287
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
288
288
  contentType: "application/json",
289
289
  requestType: "json",
290
290
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -352,7 +352,7 @@ class Blocks {
352
352
  method: "PATCH",
353
353
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
354
354
  ? yield core.Supplier.get(this._options.project)
355
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
355
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
356
356
  contentType: "application/json",
357
357
  requestType: "json",
358
358
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -78,7 +78,7 @@ class Context {
78
78
  method: "GET",
79
79
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
80
80
  ? yield core.Supplier.get(this._options.project)
81
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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,
@@ -79,7 +79,7 @@ class CoreMemory {
79
79
  method: "GET",
80
80
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
81
81
  ? yield core.Supplier.get(this._options.project)
82
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
83
83
  contentType: "application/json",
84
84
  requestType: "json",
85
85
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -84,7 +84,7 @@ class Groups {
84
84
  method: "GET",
85
85
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
86
86
  ? yield core.Supplier.get(this._options.project)
87
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
87
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
88
88
  contentType: "application/json",
89
89
  queryParameters: _queryParams,
90
90
  requestType: "json",
@@ -80,7 +80,7 @@ class MemoryVariables {
80
80
  method: "GET",
81
81
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
82
82
  ? yield core.Supplier.get(this._options.project)
83
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
83
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
84
84
  contentType: "application/json",
85
85
  requestType: "json",
86
86
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -87,10 +87,28 @@ export declare class Messages {
87
87
  * It will stream the steps of the response always, and stream the tokens if 'stream_tokens' is set to True.
88
88
  */
89
89
  createStream(agentId: string, request: Letta.LettaStreamingRequest, requestOptions?: Messages.RequestOptions): Promise<core.Stream<Letta.agents.LettaStreamingResponse>>;
90
+ /**
91
+ * Cancel runs associated with an agent. If run_ids are passed in, cancel those in particular.
92
+ *
93
+ * Note to cancel active runs associated with an agent, redis is required.
94
+ *
95
+ * @param {string} agentId
96
+ * @param {string[]} request
97
+ * @param {Messages.RequestOptions} requestOptions - Request-specific configuration.
98
+ *
99
+ * @throws {@link Letta.UnprocessableEntityError}
100
+ *
101
+ * @example
102
+ * await client.agents.messages.cancel("agent_id", undefined)
103
+ */
104
+ cancel(agentId: string, request?: string[], requestOptions?: Messages.RequestOptions): Promise<Record<string, unknown>>;
90
105
  /**
91
106
  * Asynchronously process a user message and return a run object.
92
107
  * The actual processing happens in the background, and the status can be checked using the run ID.
93
108
  *
109
+ * This is "asynchronous" in the sense that it's a background job and explicitly must be fetched by the run ID.
110
+ * This is more like `send_message_job`
111
+ *
94
112
  * @param {string} agentId
95
113
  * @param {Letta.agents.LettaAsyncRequest} request
96
114
  * @param {Messages.RequestOptions} requestOptions - Request-specific configuration.
@@ -102,7 +102,7 @@ class Messages {
102
102
  method: "GET",
103
103
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
104
104
  ? yield core.Supplier.get(this._options.project)
105
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
105
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
106
106
  contentType: "application/json",
107
107
  queryParameters: _queryParams,
108
108
  requestType: "json",
@@ -180,7 +180,7 @@ class Messages {
180
180
  method: "POST",
181
181
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
182
182
  ? yield core.Supplier.get(this._options.project)
183
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
183
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
184
184
  contentType: "application/json",
185
185
  requestType: "json",
186
186
  body: serializers.LettaRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -252,7 +252,7 @@ class Messages {
252
252
  method: "PATCH",
253
253
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
254
254
  ? yield core.Supplier.get(this._options.project)
255
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
255
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
256
256
  contentType: "application/json",
257
257
  requestType: "json",
258
258
  body: serializers.agents.MessagesModifyRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -314,7 +314,7 @@ class Messages {
314
314
  method: "POST",
315
315
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
316
316
  ? yield core.Supplier.get(this._options.project)
317
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
317
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
318
318
  contentType: "application/json",
319
319
  requestType: "json",
320
320
  body: serializers.LettaStreamingRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -374,10 +374,88 @@ class Messages {
374
374
  }
375
375
  });
376
376
  }
377
+ /**
378
+ * Cancel runs associated with an agent. If run_ids are passed in, cancel those in particular.
379
+ *
380
+ * Note to cancel active runs associated with an agent, redis is required.
381
+ *
382
+ * @param {string} agentId
383
+ * @param {string[]} request
384
+ * @param {Messages.RequestOptions} requestOptions - Request-specific configuration.
385
+ *
386
+ * @throws {@link Letta.UnprocessableEntityError}
387
+ *
388
+ * @example
389
+ * await client.agents.messages.cancel("agent_id", undefined)
390
+ */
391
+ cancel(agentId, request, requestOptions) {
392
+ return __awaiter(this, void 0, void 0, function* () {
393
+ var _a, _b, _c;
394
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
395
+ 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/cancel`),
396
+ method: "POST",
397
+ headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
398
+ ? yield core.Supplier.get(this._options.project)
399
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
400
+ contentType: "application/json",
401
+ requestType: "json",
402
+ body: request != null
403
+ ? serializers.agents.messages.cancel.Request.jsonOrThrow(request, {
404
+ unrecognizedObjectKeys: "strip",
405
+ })
406
+ : undefined,
407
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
408
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
409
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
410
+ });
411
+ if (_response.ok) {
412
+ return serializers.agents.messages.cancel.Response.parseOrThrow(_response.body, {
413
+ unrecognizedObjectKeys: "passthrough",
414
+ allowUnrecognizedUnionMembers: true,
415
+ allowUnrecognizedEnumValues: true,
416
+ skipValidation: true,
417
+ breadcrumbsPrefix: ["response"],
418
+ });
419
+ }
420
+ if (_response.error.reason === "status-code") {
421
+ switch (_response.error.statusCode) {
422
+ case 422:
423
+ throw new Letta.UnprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
424
+ unrecognizedObjectKeys: "passthrough",
425
+ allowUnrecognizedUnionMembers: true,
426
+ allowUnrecognizedEnumValues: true,
427
+ skipValidation: true,
428
+ breadcrumbsPrefix: ["response"],
429
+ }));
430
+ default:
431
+ throw new errors.LettaError({
432
+ statusCode: _response.error.statusCode,
433
+ body: _response.error.body,
434
+ });
435
+ }
436
+ }
437
+ switch (_response.error.reason) {
438
+ case "non-json":
439
+ throw new errors.LettaError({
440
+ statusCode: _response.error.statusCode,
441
+ body: _response.error.rawBody,
442
+ });
443
+ case "timeout":
444
+ throw new errors.LettaTimeoutError("Timeout exceeded when calling POST /v1/agents/{agent_id}/messages/cancel.");
445
+ case "unknown":
446
+ throw new errors.LettaError({
447
+ message: _response.error.errorMessage,
448
+ });
449
+ }
450
+ });
451
+ }
377
452
  /**
378
453
  * Asynchronously process a user message and return a run object.
379
454
  * The actual processing happens in the background, and the status can be checked using the run ID.
380
455
  *
456
+ * This is "asynchronous" in the sense that it's a background job and explicitly must be fetched by the run ID.
457
+ * This is more like `send_message_job`
458
+ *
381
459
  * @param {string} agentId
382
460
  * @param {Letta.agents.LettaAsyncRequest} request
383
461
  * @param {Messages.RequestOptions} requestOptions - Request-specific configuration.
@@ -403,7 +481,7 @@ class Messages {
403
481
  method: "POST",
404
482
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
405
483
  ? yield core.Supplier.get(this._options.project)
406
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
484
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
407
485
  contentType: "application/json",
408
486
  requestType: "json",
409
487
  body: serializers.agents.LettaAsyncRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -477,7 +555,7 @@ class Messages {
477
555
  method: "PATCH",
478
556
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
479
557
  ? yield core.Supplier.get(this._options.project)
480
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
558
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
481
559
  contentType: "application/json",
482
560
  queryParameters: _queryParams,
483
561
  requestType: "json",
@@ -96,7 +96,7 @@ class Passages {
96
96
  method: "GET",
97
97
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
98
98
  ? yield core.Supplier.get(this._options.project)
99
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
99
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
100
100
  contentType: "application/json",
101
101
  queryParameters: _queryParams,
102
102
  requestType: "json",
@@ -167,7 +167,7 @@ class Passages {
167
167
  method: "POST",
168
168
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
169
169
  ? yield core.Supplier.get(this._options.project)
170
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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.agents.CreateArchivalMemory.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -236,7 +236,7 @@ class Passages {
236
236
  method: "DELETE",
237
237
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
238
238
  ? yield core.Supplier.get(this._options.project)
239
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
240
240
  contentType: "application/json",
241
241
  requestType: "json",
242
242
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -301,7 +301,7 @@ class Passages {
301
301
  method: "PATCH",
302
302
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
303
303
  ? yield core.Supplier.get(this._options.project)
304
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
304
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
305
305
  contentType: "application/json",
306
306
  requestType: "json",
307
307
  body: serializers.agents.PassageUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -79,7 +79,7 @@ class Sources {
79
79
  method: "PATCH",
80
80
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
81
81
  ? yield core.Supplier.get(this._options.project)
82
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
83
83
  contentType: "application/json",
84
84
  requestType: "json",
85
85
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -147,7 +147,7 @@ class Sources {
147
147
  method: "PATCH",
148
148
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
149
149
  ? yield core.Supplier.get(this._options.project)
150
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
150
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
151
151
  contentType: "application/json",
152
152
  requestType: "json",
153
153
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -214,7 +214,7 @@ class Sources {
214
214
  method: "GET",
215
215
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
216
216
  ? yield core.Supplier.get(this._options.project)
217
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
217
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
218
218
  contentType: "application/json",
219
219
  requestType: "json",
220
220
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -98,7 +98,7 @@ class Templates {
98
98
  method: "POST",
99
99
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
100
100
  ? yield core.Supplier.get(this._options.project)
101
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
101
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
102
102
  contentType: "application/json",
103
103
  queryParameters: _queryParams,
104
104
  requestType: "json",
@@ -167,7 +167,7 @@ class Templates {
167
167
  method: "POST",
168
168
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
169
169
  ? yield core.Supplier.get(this._options.project)
170
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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.agents.TemplatesMigrateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -242,7 +242,7 @@ class Templates {
242
242
  method: "POST",
243
243
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
244
244
  ? yield core.Supplier.get(this._options.project)
245
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
245
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
246
246
  contentType: "application/json",
247
247
  requestType: "json",
248
248
  body: serializers.agents.TemplatesCreateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -78,7 +78,7 @@ class Tools {
78
78
  method: "GET",
79
79
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
80
80
  ? yield core.Supplier.get(this._options.project)
81
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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,
@@ -146,7 +146,7 @@ class Tools {
146
146
  method: "PATCH",
147
147
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
148
148
  ? yield core.Supplier.get(this._options.project)
149
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
149
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
150
150
  contentType: "application/json",
151
151
  requestType: "json",
152
152
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -214,7 +214,7 @@ class Tools {
214
214
  method: "PATCH",
215
215
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
216
216
  ? yield core.Supplier.get(this._options.project)
217
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
217
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
218
218
  contentType: "application/json",
219
219
  requestType: "json",
220
220
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -77,7 +77,7 @@ class Batches {
77
77
  method: "GET",
78
78
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
79
79
  ? yield core.Supplier.get(this._options.project)
80
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
80
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
81
81
  contentType: "application/json",
82
82
  requestType: "json",
83
83
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -156,7 +156,7 @@ class Batches {
156
156
  method: "POST",
157
157
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
158
158
  ? yield core.Supplier.get(this._options.project)
159
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
159
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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
160
  contentType: "application/json",
161
161
  requestType: "json",
162
162
  body: serializers.CreateBatch.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -224,7 +224,7 @@ class Batches {
224
224
  method: "GET",
225
225
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
226
226
  ? yield core.Supplier.get(this._options.project)
227
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
227
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
228
228
  contentType: "application/json",
229
229
  requestType: "json",
230
230
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -291,7 +291,7 @@ class Batches {
291
291
  method: "PATCH",
292
292
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
293
293
  ? yield core.Supplier.get(this._options.project)
294
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
294
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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
295
  contentType: "application/json",
296
296
  requestType: "json",
297
297
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -106,7 +106,7 @@ class Blocks {
106
106
  method: "GET",
107
107
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
108
108
  ? yield core.Supplier.get(this._options.project)
109
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
109
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
110
110
  contentType: "application/json",
111
111
  queryParameters: _queryParams,
112
112
  requestType: "json",
@@ -175,7 +175,7 @@ class Blocks {
175
175
  method: "POST",
176
176
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
177
177
  ? yield core.Supplier.get(this._options.project)
178
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
178
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
179
179
  contentType: "application/json",
180
180
  requestType: "json",
181
181
  body: serializers.CreateBlock.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -242,7 +242,7 @@ class Blocks {
242
242
  method: "GET",
243
243
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
244
244
  ? yield core.Supplier.get(this._options.project)
245
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
245
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
246
246
  contentType: "application/json",
247
247
  requestType: "json",
248
248
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -307,7 +307,7 @@ class Blocks {
307
307
  method: "GET",
308
308
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
309
309
  ? yield core.Supplier.get(this._options.project)
310
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
310
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
311
311
  contentType: "application/json",
312
312
  requestType: "json",
313
313
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -372,7 +372,7 @@ class Blocks {
372
372
  method: "DELETE",
373
373
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
374
374
  ? yield core.Supplier.get(this._options.project)
375
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
375
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
376
376
  contentType: "application/json",
377
377
  requestType: "json",
378
378
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -438,7 +438,7 @@ class Blocks {
438
438
  method: "PATCH",
439
439
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
440
440
  ? yield core.Supplier.get(this._options.project)
441
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
441
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
442
442
  contentType: "application/json",
443
443
  requestType: "json",
444
444
  body: serializers.BlockUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -35,6 +35,7 @@ export declare class Agents {
35
35
  * Raises a 404 if the block does not exist.
36
36
  *
37
37
  * @param {string} blockId
38
+ * @param {Letta.blocks.AgentsListRequest} request
38
39
  * @param {Agents.RequestOptions} requestOptions - Request-specific configuration.
39
40
  *
40
41
  * @throws {@link Letta.UnprocessableEntityError}
@@ -42,7 +43,7 @@ export declare class Agents {
42
43
  * @example
43
44
  * await client.blocks.agents.list("block_id")
44
45
  */
45
- list(blockId: string, requestOptions?: Agents.RequestOptions): Promise<Letta.AgentState[]>;
46
+ list(blockId: string, request?: Letta.blocks.AgentsListRequest, requestOptions?: Agents.RequestOptions): Promise<Letta.AgentState[]>;
46
47
  protected _getCustomAuthorizationHeaders(): Promise<{
47
48
  Authorization: string;
48
49
  }>;
@@ -64,6 +64,7 @@ class Agents {
64
64
  * Raises a 404 if the block does not exist.
65
65
  *
66
66
  * @param {string} blockId
67
+ * @param {Letta.blocks.AgentsListRequest} request
67
68
  * @param {Agents.RequestOptions} requestOptions - Request-specific configuration.
68
69
  *
69
70
  * @throws {@link Letta.UnprocessableEntityError}
@@ -71,16 +72,27 @@ class Agents {
71
72
  * @example
72
73
  * await client.blocks.agents.list("block_id")
73
74
  */
74
- list(blockId, requestOptions) {
75
- return __awaiter(this, void 0, void 0, function* () {
75
+ list(blockId_1) {
76
+ return __awaiter(this, arguments, void 0, function* (blockId, request = {}, requestOptions) {
76
77
  var _a, _b, _c;
78
+ const { includeRelationships } = request;
79
+ const _queryParams = {};
80
+ if (includeRelationships != null) {
81
+ if (Array.isArray(includeRelationships)) {
82
+ _queryParams["include_relationships"] = includeRelationships.map((item) => item);
83
+ }
84
+ else {
85
+ _queryParams["include_relationships"] = includeRelationships;
86
+ }
87
+ }
77
88
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
78
89
  url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.LettaEnvironment.LettaCloud, `v1/blocks/${encodeURIComponent(blockId)}/agents`),
79
90
  method: "GET",
80
91
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
81
92
  ? yield core.Supplier.get(this._options.project)
82
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.147", "User-Agent": "@letta-ai/letta-client/0.1.147", "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),
93
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.149", "User-Agent": "@letta-ai/letta-client/0.1.149", "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),
83
94
  contentType: "application/json",
95
+ queryParameters: _queryParams,
84
96
  requestType: "json",
85
97
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
86
98
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -1 +1 @@
1
- export {};
1
+ export * from "./requests";