@letta-ai/letta-client 0.0.68657 → 0.0.68658

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 (226) hide show
  1. package/api/resources/agents/client/Client.js +9 -9
  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/files/client/Client.js +4 -4
  6. package/api/resources/agents/resources/folders/client/Client.js +3 -3
  7. package/api/resources/agents/resources/groups/client/Client.js +1 -1
  8. package/api/resources/agents/resources/memoryVariables/client/Client.js +1 -1
  9. package/api/resources/agents/resources/messages/client/Client.js +10 -10
  10. package/api/resources/agents/resources/passages/client/Client.js +5 -5
  11. package/api/resources/agents/resources/sources/client/Client.js +3 -3
  12. package/api/resources/agents/resources/templates/client/Client.js +3 -3
  13. package/api/resources/agents/resources/tools/client/Client.js +4 -4
  14. package/api/resources/archives/client/Client.js +3 -3
  15. package/api/resources/batches/client/Client.js +4 -4
  16. package/api/resources/batches/resources/messages/client/Client.js +1 -1
  17. package/api/resources/blocks/client/Client.js +6 -6
  18. package/api/resources/blocks/resources/agents/client/Client.js +1 -1
  19. package/api/resources/clientSideAccessTokens/client/Client.js +3 -3
  20. package/api/resources/folders/client/Client.js +8 -8
  21. package/api/resources/folders/resources/agents/client/Client.js +1 -1
  22. package/api/resources/folders/resources/files/client/Client.js +3 -3
  23. package/api/resources/folders/resources/passages/client/Client.js +1 -1
  24. package/api/resources/groups/client/Client.js +6 -6
  25. package/api/resources/groups/resources/messages/client/Client.js +5 -5
  26. package/api/resources/health/client/Client.js +1 -1
  27. package/api/resources/identities/client/Client.js +7 -7
  28. package/api/resources/identities/resources/agents/client/Client.js +1 -1
  29. package/api/resources/identities/resources/blocks/client/Client.js +1 -1
  30. package/api/resources/identities/resources/properties/client/Client.js +1 -1
  31. package/api/resources/jobs/client/Client.js +5 -5
  32. package/api/resources/models/client/Client.js +2 -2
  33. package/api/resources/models/resources/embeddings/client/Client.js +1 -1
  34. package/api/resources/projects/client/Client.js +1 -1
  35. package/api/resources/providers/client/Client.js +6 -6
  36. package/api/resources/runs/client/Client.js +5 -5
  37. package/api/resources/runs/resources/messages/client/Client.js +1 -1
  38. package/api/resources/runs/resources/steps/client/Client.js +1 -1
  39. package/api/resources/runs/resources/usage/client/Client.js +1 -1
  40. package/api/resources/sources/client/Client.js +10 -10
  41. package/api/resources/sources/resources/files/client/Client.js +3 -3
  42. package/api/resources/sources/resources/passages/client/Client.js +1 -1
  43. package/api/resources/steps/client/Client.d.ts +3 -0
  44. package/api/resources/steps/client/Client.js +7 -2
  45. package/api/resources/steps/index.d.ts +1 -1
  46. package/api/resources/steps/index.js +1 -1
  47. package/api/resources/steps/resources/feedback/client/Client.js +1 -1
  48. package/api/resources/steps/resources/index.d.ts +3 -0
  49. package/api/resources/steps/resources/index.js +4 -1
  50. package/api/resources/steps/resources/messages/client/Client.d.ts +50 -0
  51. package/api/resources/steps/resources/messages/client/Client.js +166 -0
  52. package/api/resources/steps/resources/messages/client/index.d.ts +1 -0
  53. package/api/resources/steps/resources/messages/client/index.js +17 -0
  54. package/api/resources/steps/resources/messages/client/requests/MessagesListRequest.d.ts +30 -0
  55. package/api/resources/steps/resources/messages/client/requests/MessagesListRequest.js +5 -0
  56. package/api/resources/steps/resources/messages/client/requests/index.d.ts +1 -0
  57. package/api/resources/steps/resources/messages/client/requests/index.js +2 -0
  58. package/api/resources/steps/resources/messages/index.d.ts +2 -0
  59. package/api/resources/steps/resources/messages/index.js +18 -0
  60. package/api/resources/steps/resources/messages/types/MessagesListRequestOrder.d.ts +11 -0
  61. package/api/resources/steps/resources/messages/types/MessagesListRequestOrder.js +10 -0
  62. package/api/resources/steps/resources/messages/types/MessagesListResponseItem.d.ts +5 -0
  63. package/api/resources/steps/resources/messages/types/MessagesListResponseItem.js +5 -0
  64. package/api/resources/steps/resources/messages/types/index.d.ts +2 -0
  65. package/api/resources/steps/resources/messages/types/index.js +18 -0
  66. package/api/resources/steps/resources/metrics/client/Client.js +1 -1
  67. package/api/resources/steps/resources/trace/client/Client.js +1 -1
  68. package/api/resources/tags/client/Client.js +1 -1
  69. package/api/resources/telemetry/client/Client.js +1 -1
  70. package/api/resources/templates/client/Client.js +9 -9
  71. package/api/resources/templates/resources/agents/client/Client.js +1 -1
  72. package/api/resources/tools/client/Client.js +20 -20
  73. package/api/resources/voice/client/Client.js +1 -1
  74. package/api/types/ChildToolRule.d.ts +1 -1
  75. package/api/types/ConditionalToolRule.d.ts +1 -1
  76. package/api/types/ContinueToolRule.d.ts +1 -1
  77. package/api/types/InitToolRule.d.ts +1 -1
  78. package/api/types/MaxCountPerStepToolRule.d.ts +1 -1
  79. package/api/types/Memory.d.ts +3 -1
  80. package/api/types/MemoryAgentType.d.ts +8 -0
  81. package/api/types/MemoryAgentType.js +5 -0
  82. package/api/types/ParentToolRule.d.ts +1 -1
  83. package/api/types/RequiredBeforeExitToolRule.d.ts +1 -1
  84. package/api/types/RequiresApprovalToolRule.d.ts +1 -1
  85. package/api/types/Step.d.ts +1 -1
  86. package/api/types/TerminalToolRule.d.ts +1 -1
  87. package/api/types/index.d.ts +1 -0
  88. package/api/types/index.js +1 -0
  89. package/dist/api/resources/agents/client/Client.js +9 -9
  90. package/dist/api/resources/agents/resources/blocks/client/Client.js +5 -5
  91. package/dist/api/resources/agents/resources/context/client/Client.js +1 -1
  92. package/dist/api/resources/agents/resources/coreMemory/client/Client.js +1 -1
  93. package/dist/api/resources/agents/resources/files/client/Client.js +4 -4
  94. package/dist/api/resources/agents/resources/folders/client/Client.js +3 -3
  95. package/dist/api/resources/agents/resources/groups/client/Client.js +1 -1
  96. package/dist/api/resources/agents/resources/memoryVariables/client/Client.js +1 -1
  97. package/dist/api/resources/agents/resources/messages/client/Client.js +10 -10
  98. package/dist/api/resources/agents/resources/passages/client/Client.js +5 -5
  99. package/dist/api/resources/agents/resources/sources/client/Client.js +3 -3
  100. package/dist/api/resources/agents/resources/templates/client/Client.js +3 -3
  101. package/dist/api/resources/agents/resources/tools/client/Client.js +4 -4
  102. package/dist/api/resources/archives/client/Client.js +3 -3
  103. package/dist/api/resources/batches/client/Client.js +4 -4
  104. package/dist/api/resources/batches/resources/messages/client/Client.js +1 -1
  105. package/dist/api/resources/blocks/client/Client.js +6 -6
  106. package/dist/api/resources/blocks/resources/agents/client/Client.js +1 -1
  107. package/dist/api/resources/clientSideAccessTokens/client/Client.js +3 -3
  108. package/dist/api/resources/folders/client/Client.js +8 -8
  109. package/dist/api/resources/folders/resources/agents/client/Client.js +1 -1
  110. package/dist/api/resources/folders/resources/files/client/Client.js +3 -3
  111. package/dist/api/resources/folders/resources/passages/client/Client.js +1 -1
  112. package/dist/api/resources/groups/client/Client.js +6 -6
  113. package/dist/api/resources/groups/resources/messages/client/Client.js +5 -5
  114. package/dist/api/resources/health/client/Client.js +1 -1
  115. package/dist/api/resources/identities/client/Client.js +7 -7
  116. package/dist/api/resources/identities/resources/agents/client/Client.js +1 -1
  117. package/dist/api/resources/identities/resources/blocks/client/Client.js +1 -1
  118. package/dist/api/resources/identities/resources/properties/client/Client.js +1 -1
  119. package/dist/api/resources/jobs/client/Client.js +5 -5
  120. package/dist/api/resources/models/client/Client.js +2 -2
  121. package/dist/api/resources/models/resources/embeddings/client/Client.js +1 -1
  122. package/dist/api/resources/projects/client/Client.js +1 -1
  123. package/dist/api/resources/providers/client/Client.js +6 -6
  124. package/dist/api/resources/runs/client/Client.js +5 -5
  125. package/dist/api/resources/runs/resources/messages/client/Client.js +1 -1
  126. package/dist/api/resources/runs/resources/steps/client/Client.js +1 -1
  127. package/dist/api/resources/runs/resources/usage/client/Client.js +1 -1
  128. package/dist/api/resources/sources/client/Client.js +10 -10
  129. package/dist/api/resources/sources/resources/files/client/Client.js +3 -3
  130. package/dist/api/resources/sources/resources/passages/client/Client.js +1 -1
  131. package/dist/api/resources/steps/client/Client.d.ts +3 -0
  132. package/dist/api/resources/steps/client/Client.js +7 -2
  133. package/dist/api/resources/steps/index.d.ts +1 -1
  134. package/dist/api/resources/steps/index.js +1 -1
  135. package/dist/api/resources/steps/resources/feedback/client/Client.js +1 -1
  136. package/dist/api/resources/steps/resources/index.d.ts +3 -0
  137. package/dist/api/resources/steps/resources/index.js +4 -1
  138. package/dist/api/resources/steps/resources/messages/client/Client.d.ts +50 -0
  139. package/dist/api/resources/steps/resources/messages/client/Client.js +166 -0
  140. package/dist/api/resources/steps/resources/messages/client/index.d.ts +1 -0
  141. package/dist/api/resources/steps/resources/messages/client/index.js +17 -0
  142. package/dist/api/resources/steps/resources/messages/client/requests/MessagesListRequest.d.ts +30 -0
  143. package/dist/api/resources/steps/resources/messages/client/requests/MessagesListRequest.js +5 -0
  144. package/dist/api/resources/steps/resources/messages/client/requests/index.d.ts +1 -0
  145. package/dist/api/resources/steps/resources/messages/client/requests/index.js +2 -0
  146. package/dist/api/resources/steps/resources/messages/index.d.ts +2 -0
  147. package/dist/api/resources/steps/resources/messages/index.js +18 -0
  148. package/dist/api/resources/steps/resources/messages/types/MessagesListRequestOrder.d.ts +11 -0
  149. package/dist/api/resources/steps/resources/messages/types/MessagesListRequestOrder.js +10 -0
  150. package/dist/api/resources/steps/resources/messages/types/MessagesListResponseItem.d.ts +5 -0
  151. package/dist/api/resources/steps/resources/messages/types/MessagesListResponseItem.js +5 -0
  152. package/dist/api/resources/steps/resources/messages/types/index.d.ts +2 -0
  153. package/dist/api/resources/steps/resources/messages/types/index.js +18 -0
  154. package/dist/api/resources/steps/resources/metrics/client/Client.js +1 -1
  155. package/dist/api/resources/steps/resources/trace/client/Client.js +1 -1
  156. package/dist/api/resources/tags/client/Client.js +1 -1
  157. package/dist/api/resources/telemetry/client/Client.js +1 -1
  158. package/dist/api/resources/templates/client/Client.js +9 -9
  159. package/dist/api/resources/templates/resources/agents/client/Client.js +1 -1
  160. package/dist/api/resources/tools/client/Client.js +20 -20
  161. package/dist/api/resources/voice/client/Client.js +1 -1
  162. package/dist/api/types/ChildToolRule.d.ts +1 -1
  163. package/dist/api/types/ConditionalToolRule.d.ts +1 -1
  164. package/dist/api/types/ContinueToolRule.d.ts +1 -1
  165. package/dist/api/types/InitToolRule.d.ts +1 -1
  166. package/dist/api/types/MaxCountPerStepToolRule.d.ts +1 -1
  167. package/dist/api/types/Memory.d.ts +3 -1
  168. package/dist/api/types/MemoryAgentType.d.ts +8 -0
  169. package/dist/api/types/MemoryAgentType.js +5 -0
  170. package/dist/api/types/ParentToolRule.d.ts +1 -1
  171. package/dist/api/types/RequiredBeforeExitToolRule.d.ts +1 -1
  172. package/dist/api/types/RequiresApprovalToolRule.d.ts +1 -1
  173. package/dist/api/types/Step.d.ts +1 -1
  174. package/dist/api/types/TerminalToolRule.d.ts +1 -1
  175. package/dist/api/types/index.d.ts +1 -0
  176. package/dist/api/types/index.js +1 -0
  177. package/dist/serialization/resources/steps/index.d.ts +1 -1
  178. package/dist/serialization/resources/steps/index.js +1 -1
  179. package/dist/serialization/resources/steps/resources/index.d.ts +2 -0
  180. package/dist/serialization/resources/steps/resources/index.js +3 -1
  181. package/dist/serialization/resources/steps/resources/messages/client/index.d.ts +1 -0
  182. package/dist/serialization/resources/steps/resources/messages/client/index.js +37 -0
  183. package/dist/serialization/resources/steps/resources/messages/client/list.d.ts +11 -0
  184. package/dist/serialization/resources/steps/resources/messages/client/list.js +42 -0
  185. package/dist/serialization/resources/steps/resources/messages/index.d.ts +2 -0
  186. package/dist/serialization/resources/steps/resources/messages/index.js +18 -0
  187. package/dist/serialization/resources/steps/resources/messages/types/MessagesListRequestOrder.d.ts +10 -0
  188. package/dist/serialization/resources/steps/resources/messages/types/MessagesListRequestOrder.js +41 -0
  189. package/dist/serialization/resources/steps/resources/messages/types/MessagesListResponseItem.d.ts +19 -0
  190. package/dist/serialization/resources/steps/resources/messages/types/MessagesListResponseItem.js +60 -0
  191. package/dist/serialization/resources/steps/resources/messages/types/index.d.ts +2 -0
  192. package/dist/serialization/resources/steps/resources/messages/types/index.js +18 -0
  193. package/dist/serialization/types/Memory.d.ts +2 -0
  194. package/dist/serialization/types/Memory.js +2 -0
  195. package/dist/serialization/types/MemoryAgentType.d.ts +11 -0
  196. package/dist/serialization/types/MemoryAgentType.js +42 -0
  197. package/dist/serialization/types/index.d.ts +1 -0
  198. package/dist/serialization/types/index.js +1 -0
  199. package/dist/version.d.ts +1 -1
  200. package/dist/version.js +1 -1
  201. package/package.json +1 -1
  202. package/reference.md +73 -0
  203. package/serialization/resources/steps/index.d.ts +1 -1
  204. package/serialization/resources/steps/index.js +1 -1
  205. package/serialization/resources/steps/resources/index.d.ts +2 -0
  206. package/serialization/resources/steps/resources/index.js +3 -1
  207. package/serialization/resources/steps/resources/messages/client/index.d.ts +1 -0
  208. package/serialization/resources/steps/resources/messages/client/index.js +37 -0
  209. package/serialization/resources/steps/resources/messages/client/list.d.ts +11 -0
  210. package/serialization/resources/steps/resources/messages/client/list.js +42 -0
  211. package/serialization/resources/steps/resources/messages/index.d.ts +2 -0
  212. package/serialization/resources/steps/resources/messages/index.js +18 -0
  213. package/serialization/resources/steps/resources/messages/types/MessagesListRequestOrder.d.ts +10 -0
  214. package/serialization/resources/steps/resources/messages/types/MessagesListRequestOrder.js +41 -0
  215. package/serialization/resources/steps/resources/messages/types/MessagesListResponseItem.d.ts +19 -0
  216. package/serialization/resources/steps/resources/messages/types/MessagesListResponseItem.js +60 -0
  217. package/serialization/resources/steps/resources/messages/types/index.d.ts +2 -0
  218. package/serialization/resources/steps/resources/messages/types/index.js +18 -0
  219. package/serialization/types/Memory.d.ts +2 -0
  220. package/serialization/types/Memory.js +2 -0
  221. package/serialization/types/MemoryAgentType.d.ts +11 -0
  222. package/serialization/types/MemoryAgentType.js +42 -0
  223. package/serialization/types/index.d.ts +1 -0
  224. package/serialization/types/index.js +1 -0
  225. package/version.d.ts +1 -1
  226. package/version.js +1 -1
@@ -0,0 +1,166 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || (function () {
22
+ var ownKeys = function(o) {
23
+ ownKeys = Object.getOwnPropertyNames || function (o) {
24
+ var ar = [];
25
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
26
+ return ar;
27
+ };
28
+ return ownKeys(o);
29
+ };
30
+ return function (mod) {
31
+ if (mod && mod.__esModule) return mod;
32
+ var result = {};
33
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
34
+ __setModuleDefault(result, mod);
35
+ return result;
36
+ };
37
+ })();
38
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
39
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
40
+ return new (P || (P = Promise))(function (resolve, reject) {
41
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
42
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
43
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
44
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
45
+ });
46
+ };
47
+ var __importDefault = (this && this.__importDefault) || function (mod) {
48
+ return (mod && mod.__esModule) ? mod : { "default": mod };
49
+ };
50
+ Object.defineProperty(exports, "__esModule", { value: true });
51
+ exports.Messages = void 0;
52
+ const environments = __importStar(require("../../../../../../environments"));
53
+ const core = __importStar(require("../../../../../../core"));
54
+ const Letta = __importStar(require("../../../../../index"));
55
+ const serializers = __importStar(require("../../../../../../serialization/index"));
56
+ const url_join_1 = __importDefault(require("url-join"));
57
+ const errors = __importStar(require("../../../../../../errors/index"));
58
+ class Messages {
59
+ constructor(_options = {}) {
60
+ this._options = _options;
61
+ }
62
+ /**
63
+ * List messages for a given step.
64
+ *
65
+ * @param {string} stepId
66
+ * @param {Letta.steps.MessagesListRequest} request
67
+ * @param {Messages.RequestOptions} requestOptions - Request-specific configuration.
68
+ *
69
+ * @throws {@link Letta.UnprocessableEntityError}
70
+ *
71
+ * @example
72
+ * await client.steps.messages.list("step_id")
73
+ */
74
+ list(stepId, request = {}, requestOptions) {
75
+ return core.HttpResponsePromise.fromPromise(this.__list(stepId, request, requestOptions));
76
+ }
77
+ __list(stepId_1) {
78
+ return __awaiter(this, arguments, void 0, function* (stepId, request = {}, requestOptions) {
79
+ var _a, _b, _c;
80
+ const { before, after, limit, order, orderBy } = request;
81
+ const _queryParams = {};
82
+ if (before != null) {
83
+ _queryParams["before"] = before;
84
+ }
85
+ if (after != null) {
86
+ _queryParams["after"] = after;
87
+ }
88
+ if (limit != null) {
89
+ _queryParams["limit"] = limit.toString();
90
+ }
91
+ if (order != null) {
92
+ _queryParams["order"] = serializers.steps.MessagesListRequestOrder.jsonOrThrow(order, {
93
+ unrecognizedObjectKeys: "strip",
94
+ });
95
+ }
96
+ if (orderBy != null) {
97
+ _queryParams["order_by"] = orderBy;
98
+ }
99
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
100
+ 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/steps/${encodeURIComponent(stepId)}/messages`),
101
+ method: "GET",
102
+ headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
103
+ ? yield core.Supplier.get(this._options.project)
104
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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
+ contentType: "application/json",
106
+ queryParameters: _queryParams,
107
+ requestType: "json",
108
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
109
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
110
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
111
+ });
112
+ if (_response.ok) {
113
+ return {
114
+ data: serializers.steps.messages.list.Response.parseOrThrow(_response.body, {
115
+ unrecognizedObjectKeys: "passthrough",
116
+ allowUnrecognizedUnionMembers: true,
117
+ allowUnrecognizedEnumValues: true,
118
+ skipValidation: true,
119
+ breadcrumbsPrefix: ["response"],
120
+ }),
121
+ rawResponse: _response.rawResponse,
122
+ };
123
+ }
124
+ if (_response.error.reason === "status-code") {
125
+ switch (_response.error.statusCode) {
126
+ case 422:
127
+ throw new Letta.UnprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
128
+ unrecognizedObjectKeys: "passthrough",
129
+ allowUnrecognizedUnionMembers: true,
130
+ allowUnrecognizedEnumValues: true,
131
+ skipValidation: true,
132
+ breadcrumbsPrefix: ["response"],
133
+ }), _response.rawResponse);
134
+ default:
135
+ throw new errors.LettaError({
136
+ statusCode: _response.error.statusCode,
137
+ body: _response.error.body,
138
+ rawResponse: _response.rawResponse,
139
+ });
140
+ }
141
+ }
142
+ switch (_response.error.reason) {
143
+ case "non-json":
144
+ throw new errors.LettaError({
145
+ statusCode: _response.error.statusCode,
146
+ body: _response.error.rawBody,
147
+ rawResponse: _response.rawResponse,
148
+ });
149
+ case "timeout":
150
+ throw new errors.LettaTimeoutError("Timeout exceeded when calling GET /v1/steps/{step_id}/messages.");
151
+ case "unknown":
152
+ throw new errors.LettaError({
153
+ message: _response.error.errorMessage,
154
+ rawResponse: _response.rawResponse,
155
+ });
156
+ }
157
+ });
158
+ }
159
+ _getCustomAuthorizationHeaders() {
160
+ return __awaiter(this, void 0, void 0, function* () {
161
+ const tokenValue = yield core.Supplier.get(this._options.token);
162
+ return { Authorization: `Bearer ${tokenValue}` };
163
+ });
164
+ }
165
+ }
166
+ exports.Messages = Messages;
@@ -0,0 +1 @@
1
+ export * from "./requests";
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./requests"), exports);
@@ -0,0 +1,30 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../../../../../../index";
5
+ /**
6
+ * @example
7
+ * {}
8
+ */
9
+ export interface MessagesListRequest {
10
+ /**
11
+ * Message ID cursor for pagination. Returns messages that come before this message ID in the specified sort order
12
+ */
13
+ before?: string;
14
+ /**
15
+ * Message ID cursor for pagination. Returns messages that come after this message ID in the specified sort order
16
+ */
17
+ after?: string;
18
+ /**
19
+ * Maximum number of messages to return
20
+ */
21
+ limit?: number;
22
+ /**
23
+ * Sort order for messages by creation time. 'asc' for oldest first, 'desc' for newest first
24
+ */
25
+ order?: Letta.steps.MessagesListRequestOrder;
26
+ /**
27
+ * Sort by field
28
+ */
29
+ orderBy?: "created_at";
30
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1 @@
1
+ export { type MessagesListRequest } from "./MessagesListRequest";
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,2 @@
1
+ export * from "./types";
2
+ export * from "./client";
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./types"), exports);
18
+ __exportStar(require("./client"), exports);
@@ -0,0 +1,11 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ /**
5
+ * Sort order for messages by creation time. 'asc' for oldest first, 'desc' for newest first
6
+ */
7
+ export type MessagesListRequestOrder = "asc" | "desc";
8
+ export declare const MessagesListRequestOrder: {
9
+ readonly Asc: "asc";
10
+ readonly Desc: "desc";
11
+ };
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.MessagesListRequestOrder = void 0;
7
+ exports.MessagesListRequestOrder = {
8
+ Asc: "asc",
9
+ Desc: "desc",
10
+ };
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Letta from "../../../../../index";
5
+ export type MessagesListResponseItem = Letta.SystemMessage | Letta.UserMessage | Letta.ReasoningMessage | Letta.HiddenReasoningMessage | Letta.ToolCallMessage | Letta.ToolReturnMessage | Letta.AssistantMessage | Letta.ApprovalRequestMessage | Letta.ApprovalResponseMessage;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,2 @@
1
+ export * from "./MessagesListRequestOrder";
2
+ export * from "./MessagesListResponseItem";
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./MessagesListRequestOrder"), exports);
18
+ __exportStar(require("./MessagesListResponseItem"), exports);
@@ -81,7 +81,7 @@ class Metrics {
81
81
  method: "GET",
82
82
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
83
83
  ? yield core.Supplier.get(this._options.project)
84
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
85
85
  contentType: "application/json",
86
86
  requestType: "json",
87
87
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -79,7 +79,7 @@ class Trace {
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.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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,
@@ -106,7 +106,7 @@ class Tags {
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.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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",
@@ -83,7 +83,7 @@ class Telemetry {
83
83
  method: "GET",
84
84
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
85
85
  ? yield core.Supplier.get(this._options.project)
86
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
86
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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
87
  contentType: "application/json",
88
88
  requestType: "json",
89
89
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -118,7 +118,7 @@ class Templates {
118
118
  method: "GET",
119
119
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
120
120
  ? yield core.Supplier.get(this._options.project)
121
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
121
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
122
122
  contentType: "application/json",
123
123
  queryParameters: _queryParams,
124
124
  requestType: "json",
@@ -186,7 +186,7 @@ class Templates {
186
186
  method: "POST",
187
187
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
188
188
  ? yield core.Supplier.get(this._options.project)
189
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
189
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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),
190
190
  contentType: "application/json",
191
191
  requestType: "json",
192
192
  body: serializers.TemplatesSaveTemplateVersionRequest.jsonOrThrow(request, {
@@ -261,7 +261,7 @@ class Templates {
261
261
  method: "DELETE",
262
262
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
263
263
  ? yield core.Supplier.get(this._options.project)
264
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
264
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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),
265
265
  contentType: "application/json",
266
266
  requestType: "json",
267
267
  body: serializers.TemplatesDeleteTemplateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -331,7 +331,7 @@ class Templates {
331
331
  method: "GET",
332
332
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
333
333
  ? yield core.Supplier.get(this._options.project)
334
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
334
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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),
335
335
  contentType: "application/json",
336
336
  requestType: "json",
337
337
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -398,7 +398,7 @@ class Templates {
398
398
  method: "POST",
399
399
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
400
400
  ? yield core.Supplier.get(this._options.project)
401
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
401
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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),
402
402
  contentType: "application/json",
403
403
  requestType: "json",
404
404
  body: serializers.TemplatesForkTemplateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -473,7 +473,7 @@ class Templates {
473
473
  method: "POST",
474
474
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
475
475
  ? yield core.Supplier.get(this._options.project)
476
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
476
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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),
477
477
  contentType: "application/json",
478
478
  requestType: "json",
479
479
  body: serializers.TemplatesCreateTemplateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -550,7 +550,7 @@ class Templates {
550
550
  method: "PATCH",
551
551
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
552
552
  ? yield core.Supplier.get(this._options.project)
553
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
553
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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),
554
554
  contentType: "application/json",
555
555
  requestType: "json",
556
556
  body: serializers.TemplatesRenameTemplateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -634,7 +634,7 @@ class Templates {
634
634
  method: "PATCH",
635
635
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
636
636
  ? yield core.Supplier.get(this._options.project)
637
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
637
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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),
638
638
  contentType: "application/json",
639
639
  requestType: "json",
640
640
  body: serializers.TemplatesUpdateTemplateDescriptionRequest.jsonOrThrow(request, {
@@ -719,7 +719,7 @@ class Templates {
719
719
  method: "GET",
720
720
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
721
721
  ? yield core.Supplier.get(this._options.project)
722
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
722
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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),
723
723
  contentType: "application/json",
724
724
  queryParameters: _queryParams,
725
725
  requestType: "json",
@@ -83,7 +83,7 @@ class Agents {
83
83
  method: "POST",
84
84
  headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
85
85
  ? yield core.Supplier.get(this._options.project)
86
- : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68657", "User-Agent": "@letta-ai/letta-client/0.0.68657", "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),
86
+ : undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.0.68658", "User-Agent": "@letta-ai/letta-client/0.0.68658", "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
87
  contentType: "application/json",
88
88
  requestType: "json",
89
89
  body: serializers.templates.AgentsCreateRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),