@letta-ai/letta-client 0.1.148 → 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.
- package/api/resources/agents/client/Client.d.ts +0 -15
- package/api/resources/agents/client/Client.js +11 -86
- package/api/resources/agents/resources/blocks/client/Client.js +5 -5
- package/api/resources/agents/resources/context/client/Client.js +1 -1
- package/api/resources/agents/resources/coreMemory/client/Client.js +1 -1
- package/api/resources/agents/resources/groups/client/Client.js +1 -1
- package/api/resources/agents/resources/memoryVariables/client/Client.js +1 -1
- package/api/resources/agents/resources/messages/client/Client.d.ts +15 -0
- package/api/resources/agents/resources/messages/client/Client.js +81 -6
- package/api/resources/agents/resources/passages/client/Client.js +4 -4
- package/api/resources/agents/resources/sources/client/Client.js +3 -3
- package/api/resources/agents/resources/templates/client/Client.js +3 -3
- package/api/resources/agents/resources/tools/client/Client.js +3 -3
- package/api/resources/batches/client/Client.js +4 -4
- package/api/resources/blocks/client/Client.js +6 -6
- package/api/resources/blocks/resources/agents/client/Client.d.ts +2 -1
- package/api/resources/blocks/resources/agents/client/Client.js +15 -3
- package/api/resources/blocks/resources/agents/client/index.d.ts +1 -1
- package/api/resources/blocks/resources/agents/client/index.js +15 -0
- package/api/resources/blocks/resources/agents/client/requests/AgentsListRequest.d.ts +13 -0
- package/api/resources/blocks/resources/agents/client/requests/AgentsListRequest.js +5 -0
- package/api/resources/blocks/resources/agents/client/requests/index.d.ts +1 -0
- package/api/resources/blocks/resources/agents/client/requests/index.js +2 -0
- package/api/resources/blocks/resources/index.d.ts +1 -0
- package/api/resources/blocks/resources/index.js +4 -0
- package/api/resources/clientSideAccessTokens/client/Client.js +2 -2
- package/api/resources/embeddingModels/client/Client.js +1 -1
- package/api/resources/groups/client/Client.js +6 -6
- package/api/resources/groups/resources/messages/client/Client.js +5 -5
- package/api/resources/health/client/Client.js +1 -1
- package/api/resources/identities/client/Client.js +7 -7
- package/api/resources/identities/resources/properties/client/Client.js +1 -1
- package/api/resources/jobs/client/Client.js +5 -5
- package/api/resources/messages/client/Client.js +1 -1
- package/api/resources/models/client/Client.js +1 -1
- package/api/resources/projects/client/Client.js +1 -1
- package/api/resources/providers/client/Client.js +5 -5
- package/api/resources/runs/client/Client.js +4 -4
- package/api/resources/runs/resources/messages/client/Client.js +1 -1
- package/api/resources/runs/resources/steps/client/Client.js +1 -1
- package/api/resources/runs/resources/usage/client/Client.js +1 -1
- package/api/resources/sources/client/Client.d.ts +17 -0
- package/api/resources/sources/client/Client.js +80 -8
- package/api/resources/sources/resources/files/client/Client.js +3 -3
- package/api/resources/sources/resources/passages/client/Client.js +1 -1
- package/api/resources/steps/client/Client.js +2 -2
- package/api/resources/steps/resources/feedback/client/Client.js +1 -1
- package/api/resources/tags/client/Client.js +1 -1
- package/api/resources/telemetry/client/Client.js +1 -1
- package/api/resources/templates/client/Client.js +1 -1
- package/api/resources/templates/resources/agents/client/Client.js +1 -1
- package/api/resources/tools/client/Client.js +19 -19
- package/api/resources/voice/client/Client.js +1 -1
- package/api/types/FileMetadata.d.ts +4 -0
- package/api/types/FileStats.d.ts +14 -0
- package/api/types/FileStats.js +5 -0
- package/api/types/LlmConfig.d.ts +2 -0
- package/api/types/OrganizationSourcesStats.d.ts +17 -0
- package/api/types/OrganizationSourcesStats.js +5 -0
- package/api/types/SourceStats.d.ts +19 -0
- package/api/types/SourceStats.js +5 -0
- package/api/types/index.d.ts +3 -0
- package/api/types/index.js +3 -0
- package/dist/api/resources/agents/client/Client.d.ts +0 -15
- package/dist/api/resources/agents/client/Client.js +11 -86
- package/dist/api/resources/agents/resources/blocks/client/Client.js +5 -5
- package/dist/api/resources/agents/resources/context/client/Client.js +1 -1
- package/dist/api/resources/agents/resources/coreMemory/client/Client.js +1 -1
- package/dist/api/resources/agents/resources/groups/client/Client.js +1 -1
- package/dist/api/resources/agents/resources/memoryVariables/client/Client.js +1 -1
- package/dist/api/resources/agents/resources/messages/client/Client.d.ts +15 -0
- package/dist/api/resources/agents/resources/messages/client/Client.js +81 -6
- package/dist/api/resources/agents/resources/passages/client/Client.js +4 -4
- package/dist/api/resources/agents/resources/sources/client/Client.js +3 -3
- package/dist/api/resources/agents/resources/templates/client/Client.js +3 -3
- package/dist/api/resources/agents/resources/tools/client/Client.js +3 -3
- package/dist/api/resources/batches/client/Client.js +4 -4
- package/dist/api/resources/blocks/client/Client.js +6 -6
- package/dist/api/resources/blocks/resources/agents/client/Client.d.ts +2 -1
- package/dist/api/resources/blocks/resources/agents/client/Client.js +15 -3
- package/dist/api/resources/blocks/resources/agents/client/index.d.ts +1 -1
- package/dist/api/resources/blocks/resources/agents/client/index.js +15 -0
- package/dist/api/resources/blocks/resources/agents/client/requests/AgentsListRequest.d.ts +13 -0
- package/dist/api/resources/blocks/resources/agents/client/requests/AgentsListRequest.js +5 -0
- package/dist/api/resources/blocks/resources/agents/client/requests/index.d.ts +1 -0
- package/dist/api/resources/blocks/resources/agents/client/requests/index.js +2 -0
- package/dist/api/resources/blocks/resources/index.d.ts +1 -0
- package/dist/api/resources/blocks/resources/index.js +4 -0
- package/dist/api/resources/clientSideAccessTokens/client/Client.js +2 -2
- package/dist/api/resources/embeddingModels/client/Client.js +1 -1
- package/dist/api/resources/groups/client/Client.js +6 -6
- package/dist/api/resources/groups/resources/messages/client/Client.js +5 -5
- package/dist/api/resources/health/client/Client.js +1 -1
- package/dist/api/resources/identities/client/Client.js +7 -7
- package/dist/api/resources/identities/resources/properties/client/Client.js +1 -1
- package/dist/api/resources/jobs/client/Client.js +5 -5
- package/dist/api/resources/messages/client/Client.js +1 -1
- package/dist/api/resources/models/client/Client.js +1 -1
- package/dist/api/resources/projects/client/Client.js +1 -1
- package/dist/api/resources/providers/client/Client.js +5 -5
- package/dist/api/resources/runs/client/Client.js +4 -4
- package/dist/api/resources/runs/resources/messages/client/Client.js +1 -1
- package/dist/api/resources/runs/resources/steps/client/Client.js +1 -1
- package/dist/api/resources/runs/resources/usage/client/Client.js +1 -1
- package/dist/api/resources/sources/client/Client.d.ts +17 -0
- package/dist/api/resources/sources/client/Client.js +80 -8
- package/dist/api/resources/sources/resources/files/client/Client.js +3 -3
- package/dist/api/resources/sources/resources/passages/client/Client.js +1 -1
- package/dist/api/resources/steps/client/Client.js +2 -2
- package/dist/api/resources/steps/resources/feedback/client/Client.js +1 -1
- package/dist/api/resources/tags/client/Client.js +1 -1
- package/dist/api/resources/telemetry/client/Client.js +1 -1
- package/dist/api/resources/templates/client/Client.js +1 -1
- package/dist/api/resources/templates/resources/agents/client/Client.js +1 -1
- package/dist/api/resources/tools/client/Client.js +19 -19
- package/dist/api/resources/voice/client/Client.js +1 -1
- package/dist/api/types/FileMetadata.d.ts +4 -0
- package/dist/api/types/FileStats.d.ts +14 -0
- package/dist/api/types/FileStats.js +5 -0
- package/dist/api/types/LlmConfig.d.ts +2 -0
- package/dist/api/types/OrganizationSourcesStats.d.ts +17 -0
- package/dist/api/types/OrganizationSourcesStats.js +5 -0
- package/dist/api/types/SourceStats.d.ts +19 -0
- package/dist/api/types/SourceStats.js +5 -0
- package/dist/api/types/index.d.ts +3 -0
- package/dist/api/types/index.js +3 -0
- package/dist/serialization/resources/agents/client/index.d.ts +0 -1
- package/dist/serialization/resources/agents/client/index.js +1 -2
- package/dist/serialization/resources/agents/{client/cancelAgentRun.d.ts → resources/messages/client/cancel.d.ts} +4 -4
- package/dist/serialization/resources/agents/{client/cancelAgentRun.js → resources/messages/client/cancel.js} +1 -1
- package/dist/serialization/resources/agents/resources/messages/client/index.d.ts +1 -0
- package/dist/serialization/resources/agents/resources/messages/client/index.js +2 -1
- package/dist/serialization/types/FileMetadata.d.ts +2 -0
- package/dist/serialization/types/FileMetadata.js +2 -0
- package/dist/serialization/types/FileStats.d.ts +14 -0
- package/dist/serialization/types/FileStats.js +45 -0
- package/dist/serialization/types/LlmConfig.d.ts +1 -0
- package/dist/serialization/types/LlmConfig.js +1 -0
- package/dist/serialization/types/OrganizationSourcesStats.d.ts +16 -0
- package/dist/serialization/types/OrganizationSourcesStats.js +47 -0
- package/dist/serialization/types/SourceStats.d.ts +17 -0
- package/dist/serialization/types/SourceStats.js +48 -0
- package/dist/serialization/types/index.d.ts +3 -0
- package/dist/serialization/types/index.js +3 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
- package/reference.md +143 -74
- package/serialization/resources/agents/client/index.d.ts +0 -1
- package/serialization/resources/agents/client/index.js +1 -2
- package/serialization/resources/agents/{client/cancelAgentRun.d.ts → resources/messages/client/cancel.d.ts} +4 -4
- package/serialization/resources/agents/{client/cancelAgentRun.js → resources/messages/client/cancel.js} +1 -1
- package/serialization/resources/agents/resources/messages/client/index.d.ts +1 -0
- package/serialization/resources/agents/resources/messages/client/index.js +2 -1
- package/serialization/types/FileMetadata.d.ts +2 -0
- package/serialization/types/FileMetadata.js +2 -0
- package/serialization/types/FileStats.d.ts +14 -0
- package/serialization/types/FileStats.js +45 -0
- package/serialization/types/LlmConfig.d.ts +1 -0
- package/serialization/types/LlmConfig.js +1 -0
- package/serialization/types/OrganizationSourcesStats.d.ts +16 -0
- package/serialization/types/OrganizationSourcesStats.js +47 -0
- package/serialization/types/SourceStats.d.ts +17 -0
- package/serialization/types/SourceStats.js +48 -0
- package/serialization/types/index.d.ts +3 -0
- package/serialization/types/index.js +3 -0
- package/version.d.ts +1 -1
- package/version.js +1 -1
|
@@ -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.
|
|
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,
|
|
@@ -145,7 +145,7 @@ class Tools {
|
|
|
145
145
|
method: "DELETE",
|
|
146
146
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
147
147
|
? yield core.Supplier.get(this._options.project)
|
|
148
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
148
|
+
: 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),
|
|
149
149
|
contentType: "application/json",
|
|
150
150
|
requestType: "json",
|
|
151
151
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -207,7 +207,7 @@ class Tools {
|
|
|
207
207
|
method: "PATCH",
|
|
208
208
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
209
209
|
? yield core.Supplier.get(this._options.project)
|
|
210
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
210
|
+
: 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),
|
|
211
211
|
contentType: "application/json",
|
|
212
212
|
requestType: "json",
|
|
213
213
|
body: serializers.ToolUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -280,7 +280,7 @@ class Tools {
|
|
|
280
280
|
method: "GET",
|
|
281
281
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
282
282
|
? yield core.Supplier.get(this._options.project)
|
|
283
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
283
|
+
: 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),
|
|
284
284
|
contentType: "application/json",
|
|
285
285
|
queryParameters: _queryParams,
|
|
286
286
|
requestType: "json",
|
|
@@ -359,7 +359,7 @@ class Tools {
|
|
|
359
359
|
method: "GET",
|
|
360
360
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
361
361
|
? yield core.Supplier.get(this._options.project)
|
|
362
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
362
|
+
: 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),
|
|
363
363
|
contentType: "application/json",
|
|
364
364
|
queryParameters: _queryParams,
|
|
365
365
|
requestType: "json",
|
|
@@ -429,7 +429,7 @@ class Tools {
|
|
|
429
429
|
method: "POST",
|
|
430
430
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
431
431
|
? yield core.Supplier.get(this._options.project)
|
|
432
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
432
|
+
: 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),
|
|
433
433
|
contentType: "application/json",
|
|
434
434
|
requestType: "json",
|
|
435
435
|
body: serializers.ToolCreate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -499,7 +499,7 @@ class Tools {
|
|
|
499
499
|
method: "PUT",
|
|
500
500
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
501
501
|
? yield core.Supplier.get(this._options.project)
|
|
502
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
502
|
+
: 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),
|
|
503
503
|
contentType: "application/json",
|
|
504
504
|
requestType: "json",
|
|
505
505
|
body: serializers.ToolCreate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -566,7 +566,7 @@ class Tools {
|
|
|
566
566
|
method: "POST",
|
|
567
567
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
568
568
|
? yield core.Supplier.get(this._options.project)
|
|
569
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
569
|
+
: 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),
|
|
570
570
|
contentType: "application/json",
|
|
571
571
|
requestType: "json",
|
|
572
572
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -638,7 +638,7 @@ class Tools {
|
|
|
638
638
|
method: "POST",
|
|
639
639
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
640
640
|
? yield core.Supplier.get(this._options.project)
|
|
641
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
641
|
+
: 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),
|
|
642
642
|
contentType: "application/json",
|
|
643
643
|
requestType: "json",
|
|
644
644
|
body: serializers.ToolRunFromSource.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -707,7 +707,7 @@ class Tools {
|
|
|
707
707
|
method: "GET",
|
|
708
708
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
709
709
|
? yield core.Supplier.get(this._options.project)
|
|
710
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
710
|
+
: 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, "user-id": userId != null ? userId : undefined }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
711
711
|
contentType: "application/json",
|
|
712
712
|
requestType: "json",
|
|
713
713
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -774,7 +774,7 @@ class Tools {
|
|
|
774
774
|
method: "GET",
|
|
775
775
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
776
776
|
? yield core.Supplier.get(this._options.project)
|
|
777
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
777
|
+
: 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),
|
|
778
778
|
contentType: "application/json",
|
|
779
779
|
requestType: "json",
|
|
780
780
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -841,7 +841,7 @@ class Tools {
|
|
|
841
841
|
method: "POST",
|
|
842
842
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
843
843
|
? yield core.Supplier.get(this._options.project)
|
|
844
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
844
|
+
: 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),
|
|
845
845
|
contentType: "application/json",
|
|
846
846
|
requestType: "json",
|
|
847
847
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -909,7 +909,7 @@ class Tools {
|
|
|
909
909
|
method: "GET",
|
|
910
910
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
911
911
|
? yield core.Supplier.get(this._options.project)
|
|
912
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
912
|
+
: 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, "user-id": userId != null ? userId : undefined }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
913
913
|
contentType: "application/json",
|
|
914
914
|
requestType: "json",
|
|
915
915
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -980,7 +980,7 @@ class Tools {
|
|
|
980
980
|
method: "PUT",
|
|
981
981
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
982
982
|
? yield core.Supplier.get(this._options.project)
|
|
983
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
983
|
+
: 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),
|
|
984
984
|
contentType: "application/json",
|
|
985
985
|
requestType: "json",
|
|
986
986
|
body: serializers.AddMcpServerRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -1048,7 +1048,7 @@ class Tools {
|
|
|
1048
1048
|
method: "GET",
|
|
1049
1049
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
1050
1050
|
? yield core.Supplier.get(this._options.project)
|
|
1051
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
1051
|
+
: 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),
|
|
1052
1052
|
contentType: "application/json",
|
|
1053
1053
|
requestType: "json",
|
|
1054
1054
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -1116,7 +1116,7 @@ class Tools {
|
|
|
1116
1116
|
method: "POST",
|
|
1117
1117
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
1118
1118
|
? yield core.Supplier.get(this._options.project)
|
|
1119
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
1119
|
+
: 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),
|
|
1120
1120
|
contentType: "application/json",
|
|
1121
1121
|
requestType: "json",
|
|
1122
1122
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -1183,7 +1183,7 @@ class Tools {
|
|
|
1183
1183
|
method: "DELETE",
|
|
1184
1184
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
1185
1185
|
? yield core.Supplier.get(this._options.project)
|
|
1186
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
1186
|
+
: 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),
|
|
1187
1187
|
contentType: "application/json",
|
|
1188
1188
|
requestType: "json",
|
|
1189
1189
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -1251,7 +1251,7 @@ class Tools {
|
|
|
1251
1251
|
method: "PATCH",
|
|
1252
1252
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
1253
1253
|
? yield core.Supplier.get(this._options.project)
|
|
1254
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
1254
|
+
: 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),
|
|
1255
1255
|
contentType: "application/json",
|
|
1256
1256
|
requestType: "json",
|
|
1257
1257
|
body: serializers.UpdateMcpServerRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -1324,7 +1324,7 @@ class Tools {
|
|
|
1324
1324
|
method: "POST",
|
|
1325
1325
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
1326
1326
|
? yield core.Supplier.get(this._options.project)
|
|
1327
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
1327
|
+
: 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),
|
|
1328
1328
|
contentType: "application/json",
|
|
1329
1329
|
requestType: "json",
|
|
1330
1330
|
body: serializers.TestMcpServerRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -82,7 +82,7 @@ class Voice {
|
|
|
82
82
|
method: "POST",
|
|
83
83
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
84
84
|
? yield core.Supplier.get(this._options.project)
|
|
85
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
85
|
+
: 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, "user-id": userId != null ? userId : undefined }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
86
86
|
contentType: "application/json",
|
|
87
87
|
requestType: "json",
|
|
88
88
|
body: serializers.voice.createVoiceChatCompletions.Request.jsonOrThrow(_body, {
|
|
@@ -28,6 +28,10 @@ export interface FileMetadata {
|
|
|
28
28
|
processingStatus?: Letta.FileProcessingStatus;
|
|
29
29
|
/** Optional error message if the file failed processing. */
|
|
30
30
|
errorMessage?: string;
|
|
31
|
+
/** Total number of chunks for the file. */
|
|
32
|
+
totalChunks?: number;
|
|
33
|
+
/** Number of chunks that have been embedded. */
|
|
34
|
+
chunksEmbedded?: number;
|
|
31
35
|
/** The creation date of the file. */
|
|
32
36
|
createdAt?: Date;
|
|
33
37
|
/** The update date of the file. */
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* File statistics for metadata endpoint
|
|
6
|
+
*/
|
|
7
|
+
export interface FileStats {
|
|
8
|
+
/** Unique identifier of the file */
|
|
9
|
+
fileId: string;
|
|
10
|
+
/** Name of the file */
|
|
11
|
+
fileName: string;
|
|
12
|
+
/** Size of the file in bytes */
|
|
13
|
+
fileSize?: number;
|
|
14
|
+
}
|
package/api/types/LlmConfig.d.ts
CHANGED
|
@@ -44,4 +44,6 @@ export interface LlmConfig {
|
|
|
44
44
|
reasoningEffort?: Letta.LlmConfigReasoningEffort;
|
|
45
45
|
/** Configurable thinking budget for extended thinking, only used if enable_reasoner is True. Minimum value is 1024. */
|
|
46
46
|
maxReasoningTokens?: number;
|
|
47
|
+
/** Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim. From OpenAI: Number between -2.0 and 2.0. */
|
|
48
|
+
frequencyPenalty?: number;
|
|
47
49
|
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as Letta from "../index";
|
|
5
|
+
/**
|
|
6
|
+
* Complete metadata response for organization sources
|
|
7
|
+
*/
|
|
8
|
+
export interface OrganizationSourcesStats {
|
|
9
|
+
/** Total number of sources */
|
|
10
|
+
totalSources?: number;
|
|
11
|
+
/** Total number of files across all sources */
|
|
12
|
+
totalFiles?: number;
|
|
13
|
+
/** Total size of all files in bytes */
|
|
14
|
+
totalSize?: number;
|
|
15
|
+
/** List of source metadata */
|
|
16
|
+
sources?: Letta.SourceStats[];
|
|
17
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as Letta from "../index";
|
|
5
|
+
/**
|
|
6
|
+
* Aggregated metadata for a source
|
|
7
|
+
*/
|
|
8
|
+
export interface SourceStats {
|
|
9
|
+
/** Unique identifier of the source */
|
|
10
|
+
sourceId: string;
|
|
11
|
+
/** Name of the source */
|
|
12
|
+
sourceName: string;
|
|
13
|
+
/** Number of files in the source */
|
|
14
|
+
fileCount?: number;
|
|
15
|
+
/** Total size of all files in bytes */
|
|
16
|
+
totalSize?: number;
|
|
17
|
+
/** List of file statistics */
|
|
18
|
+
files?: Letta.FileStats[];
|
|
19
|
+
}
|
package/api/types/index.d.ts
CHANGED
|
@@ -95,6 +95,7 @@ export * from "./File_";
|
|
|
95
95
|
export * from "./FileFile";
|
|
96
96
|
export * from "./FileMetadata";
|
|
97
97
|
export * from "./FileProcessingStatus";
|
|
98
|
+
export * from "./FileStats";
|
|
98
99
|
export * from "./FunctionOutput";
|
|
99
100
|
export * from "./FunctionCall";
|
|
100
101
|
export * from "./FunctionDefinitionInput";
|
|
@@ -153,6 +154,7 @@ export * from "./MessageType";
|
|
|
153
154
|
export * from "./OmittedReasoningContent";
|
|
154
155
|
export * from "./Organization";
|
|
155
156
|
export * from "./OrganizationCreate";
|
|
157
|
+
export * from "./OrganizationSourcesStats";
|
|
156
158
|
export * from "./OrganizationUpdate";
|
|
157
159
|
export * from "./ParameterProperties";
|
|
158
160
|
export * from "./ParametersSchema";
|
|
@@ -188,6 +190,7 @@ export * from "./SandboxType";
|
|
|
188
190
|
export * from "./SleeptimeManager";
|
|
189
191
|
export * from "./SleeptimeManagerUpdate";
|
|
190
192
|
export * from "./Source";
|
|
193
|
+
export * from "./SourceStats";
|
|
191
194
|
export * from "./StdioServerConfig";
|
|
192
195
|
export * from "./StepFeedback";
|
|
193
196
|
export * from "./Step";
|
package/api/types/index.js
CHANGED
|
@@ -111,6 +111,7 @@ __exportStar(require("./File_"), exports);
|
|
|
111
111
|
__exportStar(require("./FileFile"), exports);
|
|
112
112
|
__exportStar(require("./FileMetadata"), exports);
|
|
113
113
|
__exportStar(require("./FileProcessingStatus"), exports);
|
|
114
|
+
__exportStar(require("./FileStats"), exports);
|
|
114
115
|
__exportStar(require("./FunctionOutput"), exports);
|
|
115
116
|
__exportStar(require("./FunctionCall"), exports);
|
|
116
117
|
__exportStar(require("./FunctionDefinitionInput"), exports);
|
|
@@ -169,6 +170,7 @@ __exportStar(require("./MessageType"), exports);
|
|
|
169
170
|
__exportStar(require("./OmittedReasoningContent"), exports);
|
|
170
171
|
__exportStar(require("./Organization"), exports);
|
|
171
172
|
__exportStar(require("./OrganizationCreate"), exports);
|
|
173
|
+
__exportStar(require("./OrganizationSourcesStats"), exports);
|
|
172
174
|
__exportStar(require("./OrganizationUpdate"), exports);
|
|
173
175
|
__exportStar(require("./ParameterProperties"), exports);
|
|
174
176
|
__exportStar(require("./ParametersSchema"), exports);
|
|
@@ -204,6 +206,7 @@ __exportStar(require("./SandboxType"), exports);
|
|
|
204
206
|
__exportStar(require("./SleeptimeManager"), exports);
|
|
205
207
|
__exportStar(require("./SleeptimeManagerUpdate"), exports);
|
|
206
208
|
__exportStar(require("./Source"), exports);
|
|
209
|
+
__exportStar(require("./SourceStats"), exports);
|
|
207
210
|
__exportStar(require("./StdioServerConfig"), exports);
|
|
208
211
|
__exportStar(require("./StepFeedback"), exports);
|
|
209
212
|
__exportStar(require("./Step"), exports);
|
|
@@ -178,21 +178,6 @@ export declare class Agents {
|
|
|
178
178
|
* await client.agents.closeAllOpenFiles("agent_id")
|
|
179
179
|
*/
|
|
180
180
|
closeAllOpenFiles(agentId: string, requestOptions?: Agents.RequestOptions): Promise<string[]>;
|
|
181
|
-
/**
|
|
182
|
-
* Cancel runs associated with an agent. If run_ids are passed in, cancel those in particular.
|
|
183
|
-
*
|
|
184
|
-
* Note to cancel active runs associated with an agent, redis is required.
|
|
185
|
-
*
|
|
186
|
-
* @param {string} agentId
|
|
187
|
-
* @param {string[]} request
|
|
188
|
-
* @param {Agents.RequestOptions} requestOptions - Request-specific configuration.
|
|
189
|
-
*
|
|
190
|
-
* @throws {@link Letta.UnprocessableEntityError}
|
|
191
|
-
*
|
|
192
|
-
* @example
|
|
193
|
-
* await client.agents.cancelAgentRun("agent_id", undefined)
|
|
194
|
-
*/
|
|
195
|
-
cancelAgentRun(agentId: string, request?: string[], requestOptions?: Agents.RequestOptions): Promise<Record<string, unknown>>;
|
|
196
181
|
/**
|
|
197
182
|
* Summarize an agent's conversation history to a target message length.
|
|
198
183
|
*
|
|
@@ -193,7 +193,7 @@ class Agents {
|
|
|
193
193
|
method: "GET",
|
|
194
194
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
195
195
|
? yield core.Supplier.get(this._options.project)
|
|
196
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
196
|
+
: 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),
|
|
197
197
|
contentType: "application/json",
|
|
198
198
|
queryParameters: _queryParams,
|
|
199
199
|
requestType: "json",
|
|
@@ -261,7 +261,7 @@ class Agents {
|
|
|
261
261
|
method: "POST",
|
|
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.1.
|
|
264
|
+
: 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),
|
|
265
265
|
contentType: "application/json",
|
|
266
266
|
requestType: "json",
|
|
267
267
|
body: serializers.CreateAgentRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -328,7 +328,7 @@ class Agents {
|
|
|
328
328
|
method: "GET",
|
|
329
329
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
330
330
|
? yield core.Supplier.get(this._options.project)
|
|
331
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
331
|
+
: 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),
|
|
332
332
|
contentType: "application/json",
|
|
333
333
|
requestType: "json",
|
|
334
334
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -395,7 +395,7 @@ class Agents {
|
|
|
395
395
|
method: "GET",
|
|
396
396
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
397
397
|
? yield core.Supplier.get(this._options.project)
|
|
398
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
398
|
+
: 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),
|
|
399
399
|
contentType: "application/json",
|
|
400
400
|
requestType: "json",
|
|
401
401
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -479,7 +479,7 @@ class Agents {
|
|
|
479
479
|
method: "POST",
|
|
480
480
|
headers: Object.assign(Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
481
481
|
? yield core.Supplier.get(this._options.project)
|
|
482
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
482
|
+
: 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())), _maybeEncodedRequest.headers), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
483
483
|
queryParameters: _queryParams,
|
|
484
484
|
requestType: "file",
|
|
485
485
|
duplex: _maybeEncodedRequest.duplex,
|
|
@@ -559,7 +559,7 @@ class Agents {
|
|
|
559
559
|
method: "GET",
|
|
560
560
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
561
561
|
? yield core.Supplier.get(this._options.project)
|
|
562
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
562
|
+
: 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),
|
|
563
563
|
contentType: "application/json",
|
|
564
564
|
queryParameters: _queryParams,
|
|
565
565
|
requestType: "json",
|
|
@@ -627,7 +627,7 @@ class Agents {
|
|
|
627
627
|
method: "DELETE",
|
|
628
628
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
629
629
|
? yield core.Supplier.get(this._options.project)
|
|
630
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
630
|
+
: 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),
|
|
631
631
|
contentType: "application/json",
|
|
632
632
|
requestType: "json",
|
|
633
633
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -689,7 +689,7 @@ class Agents {
|
|
|
689
689
|
method: "PATCH",
|
|
690
690
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
691
691
|
? yield core.Supplier.get(this._options.project)
|
|
692
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
692
|
+
: 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),
|
|
693
693
|
contentType: "application/json",
|
|
694
694
|
requestType: "json",
|
|
695
695
|
body: serializers.UpdateAgent.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -760,7 +760,7 @@ class Agents {
|
|
|
760
760
|
method: "PATCH",
|
|
761
761
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
762
762
|
? yield core.Supplier.get(this._options.project)
|
|
763
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
763
|
+
: 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),
|
|
764
764
|
contentType: "application/json",
|
|
765
765
|
requestType: "json",
|
|
766
766
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -808,81 +808,6 @@ class Agents {
|
|
|
808
808
|
}
|
|
809
809
|
});
|
|
810
810
|
}
|
|
811
|
-
/**
|
|
812
|
-
* Cancel runs associated with an agent. If run_ids are passed in, cancel those in particular.
|
|
813
|
-
*
|
|
814
|
-
* Note to cancel active runs associated with an agent, redis is required.
|
|
815
|
-
*
|
|
816
|
-
* @param {string} agentId
|
|
817
|
-
* @param {string[]} request
|
|
818
|
-
* @param {Agents.RequestOptions} requestOptions - Request-specific configuration.
|
|
819
|
-
*
|
|
820
|
-
* @throws {@link Letta.UnprocessableEntityError}
|
|
821
|
-
*
|
|
822
|
-
* @example
|
|
823
|
-
* await client.agents.cancelAgentRun("agent_id", undefined)
|
|
824
|
-
*/
|
|
825
|
-
cancelAgentRun(agentId, request, requestOptions) {
|
|
826
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
827
|
-
var _a, _b, _c;
|
|
828
|
-
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
829
|
-
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`),
|
|
830
|
-
method: "POST",
|
|
831
|
-
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
832
|
-
? yield core.Supplier.get(this._options.project)
|
|
833
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.148", "User-Agent": "@letta-ai/letta-client/0.1.148", "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),
|
|
834
|
-
contentType: "application/json",
|
|
835
|
-
requestType: "json",
|
|
836
|
-
body: request != null
|
|
837
|
-
? serializers.agents.cancelAgentRun.Request.jsonOrThrow(request, {
|
|
838
|
-
unrecognizedObjectKeys: "strip",
|
|
839
|
-
})
|
|
840
|
-
: undefined,
|
|
841
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
842
|
-
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
843
|
-
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
844
|
-
});
|
|
845
|
-
if (_response.ok) {
|
|
846
|
-
return serializers.agents.cancelAgentRun.Response.parseOrThrow(_response.body, {
|
|
847
|
-
unrecognizedObjectKeys: "passthrough",
|
|
848
|
-
allowUnrecognizedUnionMembers: true,
|
|
849
|
-
allowUnrecognizedEnumValues: true,
|
|
850
|
-
skipValidation: true,
|
|
851
|
-
breadcrumbsPrefix: ["response"],
|
|
852
|
-
});
|
|
853
|
-
}
|
|
854
|
-
if (_response.error.reason === "status-code") {
|
|
855
|
-
switch (_response.error.statusCode) {
|
|
856
|
-
case 422:
|
|
857
|
-
throw new Letta.UnprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
|
|
858
|
-
unrecognizedObjectKeys: "passthrough",
|
|
859
|
-
allowUnrecognizedUnionMembers: true,
|
|
860
|
-
allowUnrecognizedEnumValues: true,
|
|
861
|
-
skipValidation: true,
|
|
862
|
-
breadcrumbsPrefix: ["response"],
|
|
863
|
-
}));
|
|
864
|
-
default:
|
|
865
|
-
throw new errors.LettaError({
|
|
866
|
-
statusCode: _response.error.statusCode,
|
|
867
|
-
body: _response.error.body,
|
|
868
|
-
});
|
|
869
|
-
}
|
|
870
|
-
}
|
|
871
|
-
switch (_response.error.reason) {
|
|
872
|
-
case "non-json":
|
|
873
|
-
throw new errors.LettaError({
|
|
874
|
-
statusCode: _response.error.statusCode,
|
|
875
|
-
body: _response.error.rawBody,
|
|
876
|
-
});
|
|
877
|
-
case "timeout":
|
|
878
|
-
throw new errors.LettaTimeoutError("Timeout exceeded when calling POST /v1/agents/{agent_id}/messages/cancel.");
|
|
879
|
-
case "unknown":
|
|
880
|
-
throw new errors.LettaError({
|
|
881
|
-
message: _response.error.errorMessage,
|
|
882
|
-
});
|
|
883
|
-
}
|
|
884
|
-
});
|
|
885
|
-
}
|
|
886
811
|
/**
|
|
887
812
|
* Summarize an agent's conversation history to a target message length.
|
|
888
813
|
*
|
|
@@ -911,7 +836,7 @@ class Agents {
|
|
|
911
836
|
method: "POST",
|
|
912
837
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
913
838
|
? yield core.Supplier.get(this._options.project)
|
|
914
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
839
|
+
: 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),
|
|
915
840
|
contentType: "application/json",
|
|
916
841
|
queryParameters: _queryParams,
|
|
917
842
|
requestType: "json",
|
|
@@ -979,7 +904,7 @@ class Agents {
|
|
|
979
904
|
method: "POST",
|
|
980
905
|
headers: Object.assign(Object.assign({ "X-Project": (yield core.Supplier.get(this._options.project)) != null
|
|
981
906
|
? yield core.Supplier.get(this._options.project)
|
|
982
|
-
: undefined, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", "X-Fern-SDK-Version": "0.1.
|
|
907
|
+
: 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),
|
|
983
908
|
contentType: "application/json",
|
|
984
909
|
requestType: "json",
|
|
985
910
|
body: serializers.AgentsSearchRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|