@getzep/zep-cloud 2.3.0 → 2.4.0
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/document/client/Client.js +13 -13
- package/api/resources/graph/client/Client.js +2 -2
- package/api/resources/graph/resources/edge/client/Client.js +4 -4
- package/api/resources/graph/resources/episode/client/Client.d.ts +14 -0
- package/api/resources/graph/resources/episode/client/Client.js +86 -3
- package/api/resources/graph/resources/node/client/Client.js +3 -3
- package/api/resources/group/client/Client.d.ts +39 -0
- package/api/resources/group/client/Client.js +233 -2
- package/api/resources/group/client/requests/CreateGroupRequest.d.ts +1 -1
- package/api/resources/group/client/requests/GetGroupsOrderedRequest.d.ts +17 -0
- package/api/resources/group/client/requests/index.d.ts +1 -0
- package/api/resources/memory/client/Client.js +22 -22
- package/api/resources/user/client/Client.d.ts +13 -0
- package/api/resources/user/client/Client.js +81 -7
- package/api/types/Group.d.ts +3 -0
- package/api/types/GroupListResponse.d.ts +9 -0
- package/api/types/Memory.d.ts +4 -1
- package/api/types/Session.d.ts +1 -1
- package/api/types/UserNodeResponse.d.ts +7 -0
- package/api/types/index.d.ts +3 -3
- package/api/types/index.js +3 -3
- package/dist/api/resources/document/client/Client.js +13 -13
- package/dist/api/resources/graph/client/Client.js +2 -2
- package/dist/api/resources/graph/resources/edge/client/Client.js +4 -4
- package/dist/api/resources/graph/resources/episode/client/Client.d.ts +14 -0
- package/dist/api/resources/graph/resources/episode/client/Client.js +86 -3
- package/dist/api/resources/graph/resources/node/client/Client.js +3 -3
- package/dist/api/resources/group/client/Client.d.ts +39 -0
- package/dist/api/resources/group/client/Client.js +233 -2
- package/dist/api/resources/group/client/requests/CreateGroupRequest.d.ts +1 -1
- package/dist/api/resources/group/client/requests/GetGroupsOrderedRequest.d.ts +17 -0
- package/dist/api/resources/group/client/requests/index.d.ts +1 -0
- package/dist/api/resources/memory/client/Client.js +22 -22
- package/dist/api/resources/user/client/Client.d.ts +13 -0
- package/dist/api/resources/user/client/Client.js +81 -7
- package/dist/api/types/Group.d.ts +3 -0
- package/dist/api/types/GroupListResponse.d.ts +9 -0
- package/dist/api/types/GroupListResponse.js +5 -0
- package/dist/api/types/Memory.d.ts +4 -1
- package/dist/api/types/Session.d.ts +1 -1
- package/dist/api/types/UserNodeResponse.d.ts +7 -0
- package/dist/api/types/UserNodeResponse.js +5 -0
- package/dist/api/types/index.d.ts +3 -3
- package/dist/api/types/index.js +3 -3
- package/dist/serialization/resources/group/client/requests/CreateGroupRequest.d.ts +2 -2
- package/dist/serialization/resources/group/client/requests/CreateGroupRequest.js +2 -2
- package/dist/serialization/types/Group.d.ts +3 -0
- package/dist/serialization/types/Group.js +3 -0
- package/dist/serialization/types/GroupListResponse.d.ts +15 -0
- package/{serialization/types/ApidataFactRatingInstruction.js → dist/serialization/types/GroupListResponse.js} +6 -5
- package/dist/serialization/types/Session.d.ts +2 -2
- package/dist/serialization/types/Session.js +2 -2
- package/dist/serialization/types/UserNodeResponse.d.ts +13 -0
- package/{serialization/types/ApidataFactRatingExamples.js → dist/serialization/types/UserNodeResponse.js} +4 -5
- package/dist/serialization/types/index.d.ts +3 -3
- package/dist/serialization/types/index.js +3 -3
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/examples/graph/user_graph_example.ts +13 -0
- package/jest.config.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +315 -0
- package/serialization/resources/group/client/requests/CreateGroupRequest.d.ts +2 -2
- package/serialization/resources/group/client/requests/CreateGroupRequest.js +2 -2
- package/serialization/types/Group.d.ts +3 -0
- package/serialization/types/Group.js +3 -0
- package/serialization/types/GroupListResponse.d.ts +15 -0
- package/{dist/serialization/types/ApidataFactRatingInstruction.js → serialization/types/GroupListResponse.js} +6 -5
- package/serialization/types/Session.d.ts +2 -2
- package/serialization/types/Session.js +2 -2
- package/serialization/types/UserNodeResponse.d.ts +13 -0
- package/{dist/serialization/types/ApidataFactRatingExamples.js → serialization/types/UserNodeResponse.js} +4 -5
- package/serialization/types/index.d.ts +3 -3
- package/serialization/types/index.js +3 -3
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/api/types/ApidataFactRatingExamples.d.ts +0 -8
- package/api/types/ApidataFactRatingInstruction.d.ts +0 -21
- package/dist/api/types/ApidataFactRatingExamples.d.ts +0 -8
- package/dist/api/types/ApidataFactRatingInstruction.d.ts +0 -21
- package/dist/serialization/types/ApidataFactRatingExamples.d.ts +0 -14
- package/dist/serialization/types/ApidataFactRatingInstruction.d.ts +0 -14
- package/serialization/types/ApidataFactRatingExamples.d.ts +0 -14
- package/serialization/types/ApidataFactRatingInstruction.d.ts +0 -14
- /package/api/{types/ApidataFactRatingExamples.js → resources/group/client/requests/GetGroupsOrderedRequest.js} +0 -0
- /package/api/types/{ApidataFactRatingInstruction.js → GroupListResponse.js} +0 -0
- /package/{dist/api/types/ApidataFactRatingExamples.js → api/types/UserNodeResponse.js} +0 -0
- /package/dist/api/{types/ApidataFactRatingInstruction.js → resources/group/client/requests/GetGroupsOrderedRequest.js} +0 -0
|
@@ -79,7 +79,7 @@ class Group {
|
|
|
79
79
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
80
80
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, "groups"),
|
|
81
81
|
method: "POST",
|
|
82
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
82
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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
|
body: serializers.CreateGroupRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -136,6 +136,163 @@ class Group {
|
|
|
136
136
|
}
|
|
137
137
|
});
|
|
138
138
|
}
|
|
139
|
+
/**
|
|
140
|
+
* List all groups with pagination.
|
|
141
|
+
*
|
|
142
|
+
* @param {Zep.GetGroupsOrderedRequest} request
|
|
143
|
+
* @param {Group.RequestOptions} requestOptions - Request-specific configuration.
|
|
144
|
+
*
|
|
145
|
+
* @throws {@link Zep.BadRequestError}
|
|
146
|
+
* @throws {@link Zep.InternalServerError}
|
|
147
|
+
*
|
|
148
|
+
* @example
|
|
149
|
+
* await client.group.listAllGroups()
|
|
150
|
+
*/
|
|
151
|
+
listAllGroups() {
|
|
152
|
+
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
153
|
+
var _a, _b;
|
|
154
|
+
const { pageNumber, pageSize } = request;
|
|
155
|
+
const _queryParams = {};
|
|
156
|
+
if (pageNumber != null) {
|
|
157
|
+
_queryParams["pageNumber"] = pageNumber.toString();
|
|
158
|
+
}
|
|
159
|
+
if (pageSize != null) {
|
|
160
|
+
_queryParams["pageSize"] = pageSize.toString();
|
|
161
|
+
}
|
|
162
|
+
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
163
|
+
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, "groups-ordered"),
|
|
164
|
+
method: "GET",
|
|
165
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
166
|
+
contentType: "application/json",
|
|
167
|
+
queryParameters: _queryParams,
|
|
168
|
+
requestType: "json",
|
|
169
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
170
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
171
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
172
|
+
});
|
|
173
|
+
if (_response.ok) {
|
|
174
|
+
return serializers.GroupListResponse.parseOrThrow(_response.body, {
|
|
175
|
+
unrecognizedObjectKeys: "passthrough",
|
|
176
|
+
allowUnrecognizedUnionMembers: true,
|
|
177
|
+
allowUnrecognizedEnumValues: true,
|
|
178
|
+
skipValidation: true,
|
|
179
|
+
breadcrumbsPrefix: ["response"],
|
|
180
|
+
});
|
|
181
|
+
}
|
|
182
|
+
if (_response.error.reason === "status-code") {
|
|
183
|
+
switch (_response.error.statusCode) {
|
|
184
|
+
case 400:
|
|
185
|
+
throw new Zep.BadRequestError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
186
|
+
unrecognizedObjectKeys: "passthrough",
|
|
187
|
+
allowUnrecognizedUnionMembers: true,
|
|
188
|
+
allowUnrecognizedEnumValues: true,
|
|
189
|
+
skipValidation: true,
|
|
190
|
+
breadcrumbsPrefix: ["response"],
|
|
191
|
+
}));
|
|
192
|
+
case 500:
|
|
193
|
+
throw new Zep.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
194
|
+
unrecognizedObjectKeys: "passthrough",
|
|
195
|
+
allowUnrecognizedUnionMembers: true,
|
|
196
|
+
allowUnrecognizedEnumValues: true,
|
|
197
|
+
skipValidation: true,
|
|
198
|
+
breadcrumbsPrefix: ["response"],
|
|
199
|
+
}));
|
|
200
|
+
default:
|
|
201
|
+
throw new errors.ZepError({
|
|
202
|
+
statusCode: _response.error.statusCode,
|
|
203
|
+
body: _response.error.body,
|
|
204
|
+
});
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
switch (_response.error.reason) {
|
|
208
|
+
case "non-json":
|
|
209
|
+
throw new errors.ZepError({
|
|
210
|
+
statusCode: _response.error.statusCode,
|
|
211
|
+
body: _response.error.rawBody,
|
|
212
|
+
});
|
|
213
|
+
case "timeout":
|
|
214
|
+
throw new errors.ZepTimeoutError("Timeout exceeded when calling GET /groups-ordered.");
|
|
215
|
+
case "unknown":
|
|
216
|
+
throw new errors.ZepError({
|
|
217
|
+
message: _response.error.errorMessage,
|
|
218
|
+
});
|
|
219
|
+
}
|
|
220
|
+
});
|
|
221
|
+
}
|
|
222
|
+
/**
|
|
223
|
+
* Get a group.
|
|
224
|
+
*
|
|
225
|
+
* @param {string} groupId - The group_id of the group to get.
|
|
226
|
+
* @param {Group.RequestOptions} requestOptions - Request-specific configuration.
|
|
227
|
+
*
|
|
228
|
+
* @throws {@link Zep.NotFoundError}
|
|
229
|
+
* @throws {@link Zep.InternalServerError}
|
|
230
|
+
*
|
|
231
|
+
* @example
|
|
232
|
+
* await client.group.getAGroup("groupId")
|
|
233
|
+
*/
|
|
234
|
+
getAGroup(groupId, requestOptions) {
|
|
235
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
236
|
+
var _a, _b;
|
|
237
|
+
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
238
|
+
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `groups/${encodeURIComponent(groupId)}`),
|
|
239
|
+
method: "GET",
|
|
240
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
241
|
+
contentType: "application/json",
|
|
242
|
+
requestType: "json",
|
|
243
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
244
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
245
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
246
|
+
});
|
|
247
|
+
if (_response.ok) {
|
|
248
|
+
return serializers.Group.parseOrThrow(_response.body, {
|
|
249
|
+
unrecognizedObjectKeys: "passthrough",
|
|
250
|
+
allowUnrecognizedUnionMembers: true,
|
|
251
|
+
allowUnrecognizedEnumValues: true,
|
|
252
|
+
skipValidation: true,
|
|
253
|
+
breadcrumbsPrefix: ["response"],
|
|
254
|
+
});
|
|
255
|
+
}
|
|
256
|
+
if (_response.error.reason === "status-code") {
|
|
257
|
+
switch (_response.error.statusCode) {
|
|
258
|
+
case 404:
|
|
259
|
+
throw new Zep.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
260
|
+
unrecognizedObjectKeys: "passthrough",
|
|
261
|
+
allowUnrecognizedUnionMembers: true,
|
|
262
|
+
allowUnrecognizedEnumValues: true,
|
|
263
|
+
skipValidation: true,
|
|
264
|
+
breadcrumbsPrefix: ["response"],
|
|
265
|
+
}));
|
|
266
|
+
case 500:
|
|
267
|
+
throw new Zep.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
268
|
+
unrecognizedObjectKeys: "passthrough",
|
|
269
|
+
allowUnrecognizedUnionMembers: true,
|
|
270
|
+
allowUnrecognizedEnumValues: true,
|
|
271
|
+
skipValidation: true,
|
|
272
|
+
breadcrumbsPrefix: ["response"],
|
|
273
|
+
}));
|
|
274
|
+
default:
|
|
275
|
+
throw new errors.ZepError({
|
|
276
|
+
statusCode: _response.error.statusCode,
|
|
277
|
+
body: _response.error.body,
|
|
278
|
+
});
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
switch (_response.error.reason) {
|
|
282
|
+
case "non-json":
|
|
283
|
+
throw new errors.ZepError({
|
|
284
|
+
statusCode: _response.error.statusCode,
|
|
285
|
+
body: _response.error.rawBody,
|
|
286
|
+
});
|
|
287
|
+
case "timeout":
|
|
288
|
+
throw new errors.ZepTimeoutError("Timeout exceeded when calling GET /groups/{groupId}.");
|
|
289
|
+
case "unknown":
|
|
290
|
+
throw new errors.ZepError({
|
|
291
|
+
message: _response.error.errorMessage,
|
|
292
|
+
});
|
|
293
|
+
}
|
|
294
|
+
});
|
|
295
|
+
}
|
|
139
296
|
/**
|
|
140
297
|
* Delete group
|
|
141
298
|
*
|
|
@@ -155,7 +312,7 @@ class Group {
|
|
|
155
312
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
156
313
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `groups/${encodeURIComponent(groupId)}`),
|
|
157
314
|
method: "DELETE",
|
|
158
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
315
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
159
316
|
contentType: "application/json",
|
|
160
317
|
requestType: "json",
|
|
161
318
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -219,6 +376,80 @@ class Group {
|
|
|
219
376
|
}
|
|
220
377
|
});
|
|
221
378
|
}
|
|
379
|
+
/**
|
|
380
|
+
* Get group facts.
|
|
381
|
+
*
|
|
382
|
+
* @param {string} groupId - The group_id of the group to get.
|
|
383
|
+
* @param {Group.RequestOptions} requestOptions - Request-specific configuration.
|
|
384
|
+
*
|
|
385
|
+
* @throws {@link Zep.NotFoundError}
|
|
386
|
+
* @throws {@link Zep.InternalServerError}
|
|
387
|
+
*
|
|
388
|
+
* @example
|
|
389
|
+
* await client.group.getFacts("groupId")
|
|
390
|
+
*/
|
|
391
|
+
getFacts(groupId, requestOptions) {
|
|
392
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
393
|
+
var _a, _b;
|
|
394
|
+
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
395
|
+
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `groups/${encodeURIComponent(groupId)}/facts`),
|
|
396
|
+
method: "GET",
|
|
397
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
398
|
+
contentType: "application/json",
|
|
399
|
+
requestType: "json",
|
|
400
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
401
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
402
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
403
|
+
});
|
|
404
|
+
if (_response.ok) {
|
|
405
|
+
return serializers.FactsResponse.parseOrThrow(_response.body, {
|
|
406
|
+
unrecognizedObjectKeys: "passthrough",
|
|
407
|
+
allowUnrecognizedUnionMembers: true,
|
|
408
|
+
allowUnrecognizedEnumValues: true,
|
|
409
|
+
skipValidation: true,
|
|
410
|
+
breadcrumbsPrefix: ["response"],
|
|
411
|
+
});
|
|
412
|
+
}
|
|
413
|
+
if (_response.error.reason === "status-code") {
|
|
414
|
+
switch (_response.error.statusCode) {
|
|
415
|
+
case 404:
|
|
416
|
+
throw new Zep.NotFoundError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
417
|
+
unrecognizedObjectKeys: "passthrough",
|
|
418
|
+
allowUnrecognizedUnionMembers: true,
|
|
419
|
+
allowUnrecognizedEnumValues: true,
|
|
420
|
+
skipValidation: true,
|
|
421
|
+
breadcrumbsPrefix: ["response"],
|
|
422
|
+
}));
|
|
423
|
+
case 500:
|
|
424
|
+
throw new Zep.InternalServerError(serializers.ApiError.parseOrThrow(_response.error.body, {
|
|
425
|
+
unrecognizedObjectKeys: "passthrough",
|
|
426
|
+
allowUnrecognizedUnionMembers: true,
|
|
427
|
+
allowUnrecognizedEnumValues: true,
|
|
428
|
+
skipValidation: true,
|
|
429
|
+
breadcrumbsPrefix: ["response"],
|
|
430
|
+
}));
|
|
431
|
+
default:
|
|
432
|
+
throw new errors.ZepError({
|
|
433
|
+
statusCode: _response.error.statusCode,
|
|
434
|
+
body: _response.error.body,
|
|
435
|
+
});
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
switch (_response.error.reason) {
|
|
439
|
+
case "non-json":
|
|
440
|
+
throw new errors.ZepError({
|
|
441
|
+
statusCode: _response.error.statusCode,
|
|
442
|
+
body: _response.error.rawBody,
|
|
443
|
+
});
|
|
444
|
+
case "timeout":
|
|
445
|
+
throw new errors.ZepTimeoutError("Timeout exceeded when calling GET /groups/{groupId}/facts.");
|
|
446
|
+
case "unknown":
|
|
447
|
+
throw new errors.ZepError({
|
|
448
|
+
message: _response.error.errorMessage,
|
|
449
|
+
});
|
|
450
|
+
}
|
|
451
|
+
});
|
|
452
|
+
}
|
|
222
453
|
_getCustomAuthorizationHeaders() {
|
|
223
454
|
return __awaiter(this, void 0, void 0, function* () {
|
|
224
455
|
var _a;
|
|
@@ -11,7 +11,7 @@ import * as Zep from "../../../../index";
|
|
|
11
11
|
export interface CreateGroupRequest {
|
|
12
12
|
description?: string;
|
|
13
13
|
/** UserIDs []string `json:"user_ids"` */
|
|
14
|
-
factRatingInstruction?: Zep.
|
|
14
|
+
factRatingInstruction?: Zep.FactRatingInstruction;
|
|
15
15
|
groupId: string;
|
|
16
16
|
name?: string;
|
|
17
17
|
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* @example
|
|
6
|
+
* {}
|
|
7
|
+
*/
|
|
8
|
+
export interface GetGroupsOrderedRequest {
|
|
9
|
+
/**
|
|
10
|
+
* Page number for pagination, starting from 1
|
|
11
|
+
*/
|
|
12
|
+
pageNumber?: number;
|
|
13
|
+
/**
|
|
14
|
+
* Number of groups to retrieve per page
|
|
15
|
+
*/
|
|
16
|
+
pageSize?: number;
|
|
17
|
+
}
|
|
@@ -88,7 +88,7 @@ class Memory {
|
|
|
88
88
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
89
89
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `facts/${encodeURIComponent(factUuid)}`),
|
|
90
90
|
method: "GET",
|
|
91
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
91
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
92
92
|
contentType: "application/json",
|
|
93
93
|
requestType: "json",
|
|
94
94
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -162,7 +162,7 @@ class Memory {
|
|
|
162
162
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
163
163
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `facts/${encodeURIComponent(factUuid)}`),
|
|
164
164
|
method: "DELETE",
|
|
165
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
165
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
166
166
|
contentType: "application/json",
|
|
167
167
|
requestType: "json",
|
|
168
168
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -239,7 +239,7 @@ class Memory {
|
|
|
239
239
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
240
240
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, "sessions"),
|
|
241
241
|
method: "POST",
|
|
242
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
242
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
243
243
|
contentType: "application/json",
|
|
244
244
|
requestType: "json",
|
|
245
245
|
body: serializers.CreateSessionRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -328,7 +328,7 @@ class Memory {
|
|
|
328
328
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
329
329
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, "sessions-ordered"),
|
|
330
330
|
method: "GET",
|
|
331
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
331
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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
|
queryParameters: _queryParams,
|
|
334
334
|
requestType: "json",
|
|
@@ -406,7 +406,7 @@ class Memory {
|
|
|
406
406
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
407
407
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, "sessions/end"),
|
|
408
408
|
method: "POST",
|
|
409
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
409
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
410
410
|
contentType: "application/json",
|
|
411
411
|
requestType: "json",
|
|
412
412
|
body: serializers.EndSessionsRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -495,7 +495,7 @@ class Memory {
|
|
|
495
495
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
496
496
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, "sessions/search"),
|
|
497
497
|
method: "POST",
|
|
498
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
498
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
499
499
|
contentType: "application/json",
|
|
500
500
|
queryParameters: _queryParams,
|
|
501
501
|
requestType: "json",
|
|
@@ -563,7 +563,7 @@ class Memory {
|
|
|
563
563
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
564
564
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}`),
|
|
565
565
|
method: "GET",
|
|
566
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
566
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
567
567
|
contentType: "application/json",
|
|
568
568
|
requestType: "json",
|
|
569
569
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -644,7 +644,7 @@ class Memory {
|
|
|
644
644
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
645
645
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}`),
|
|
646
646
|
method: "PATCH",
|
|
647
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
647
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
648
648
|
contentType: "application/json",
|
|
649
649
|
requestType: "json",
|
|
650
650
|
body: serializers.UpdateSessionRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -739,7 +739,7 @@ class Memory {
|
|
|
739
739
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
740
740
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/classify`),
|
|
741
741
|
method: "POST",
|
|
742
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
742
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
743
743
|
contentType: "application/json",
|
|
744
744
|
requestType: "json",
|
|
745
745
|
body: serializers.ClassifySessionRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -816,7 +816,7 @@ class Memory {
|
|
|
816
816
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
817
817
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/end`),
|
|
818
818
|
method: "POST",
|
|
819
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
819
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
820
820
|
contentType: "application/json",
|
|
821
821
|
requestType: "json",
|
|
822
822
|
body: serializers.EndSessionRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -904,7 +904,7 @@ class Memory {
|
|
|
904
904
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
905
905
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/extract`),
|
|
906
906
|
method: "POST",
|
|
907
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
907
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
908
908
|
contentType: "application/json",
|
|
909
909
|
requestType: "json",
|
|
910
910
|
body: serializers.ExtractDataRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -993,7 +993,7 @@ class Memory {
|
|
|
993
993
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
994
994
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/facts`),
|
|
995
995
|
method: "GET",
|
|
996
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
996
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
997
997
|
contentType: "application/json",
|
|
998
998
|
queryParameters: _queryParams,
|
|
999
999
|
requestType: "json",
|
|
@@ -1069,7 +1069,7 @@ class Memory {
|
|
|
1069
1069
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1070
1070
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/facts`),
|
|
1071
1071
|
method: "POST",
|
|
1072
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
1072
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
1073
1073
|
contentType: "application/json",
|
|
1074
1074
|
requestType: "json",
|
|
1075
1075
|
body: serializers.AddFactsRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -1153,7 +1153,7 @@ class Memory {
|
|
|
1153
1153
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1154
1154
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/memory`),
|
|
1155
1155
|
method: "GET",
|
|
1156
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
1156
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
1157
1157
|
contentType: "application/json",
|
|
1158
1158
|
queryParameters: _queryParams,
|
|
1159
1159
|
requestType: "json",
|
|
@@ -1233,7 +1233,7 @@ class Memory {
|
|
|
1233
1233
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1234
1234
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/memory`),
|
|
1235
1235
|
method: "POST",
|
|
1236
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
1236
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
1237
1237
|
contentType: "application/json",
|
|
1238
1238
|
requestType: "json",
|
|
1239
1239
|
body: serializers.AddMemoryRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -1300,7 +1300,7 @@ class Memory {
|
|
|
1300
1300
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1301
1301
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/memory`),
|
|
1302
1302
|
method: "DELETE",
|
|
1303
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
1303
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
1304
1304
|
contentType: "application/json",
|
|
1305
1305
|
requestType: "json",
|
|
1306
1306
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -1383,7 +1383,7 @@ class Memory {
|
|
|
1383
1383
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1384
1384
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/messages`),
|
|
1385
1385
|
method: "GET",
|
|
1386
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
1386
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
1387
1387
|
contentType: "application/json",
|
|
1388
1388
|
queryParameters: _queryParams,
|
|
1389
1389
|
requestType: "json",
|
|
@@ -1459,7 +1459,7 @@ class Memory {
|
|
|
1459
1459
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1460
1460
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/messages/${encodeURIComponent(messageUuid)}`),
|
|
1461
1461
|
method: "GET",
|
|
1462
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
1462
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
1463
1463
|
contentType: "application/json",
|
|
1464
1464
|
requestType: "json",
|
|
1465
1465
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -1539,7 +1539,7 @@ class Memory {
|
|
|
1539
1539
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1540
1540
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/messages/${encodeURIComponent(messageUuid)}`),
|
|
1541
1541
|
method: "PATCH",
|
|
1542
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
1542
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
1543
1543
|
contentType: "application/json",
|
|
1544
1544
|
requestType: "json",
|
|
1545
1545
|
body: serializers.ModelsMessageMetadataUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -1620,7 +1620,7 @@ class Memory {
|
|
|
1620
1620
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1621
1621
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/search`),
|
|
1622
1622
|
method: "POST",
|
|
1623
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
1623
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
1624
1624
|
contentType: "application/json",
|
|
1625
1625
|
queryParameters: _queryParams,
|
|
1626
1626
|
requestType: "json",
|
|
@@ -1696,7 +1696,7 @@ class Memory {
|
|
|
1696
1696
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1697
1697
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/summary`),
|
|
1698
1698
|
method: "GET",
|
|
1699
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
1699
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
1700
1700
|
contentType: "application/json",
|
|
1701
1701
|
requestType: "json",
|
|
1702
1702
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -1776,7 +1776,7 @@ class Memory {
|
|
|
1776
1776
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1777
1777
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.ZepEnvironment.Default, `sessions/${encodeURIComponent(sessionId)}/synthesize_question`),
|
|
1778
1778
|
method: "GET",
|
|
1779
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.
|
|
1779
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "zep-cloud", "X-Fern-SDK-Version": "2.4.0", "User-Agent": "zep-cloud/2.4.0", "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),
|
|
1780
1780
|
contentType: "application/json",
|
|
1781
1781
|
queryParameters: _queryParams,
|
|
1782
1782
|
requestType: "json",
|
|
@@ -104,6 +104,19 @@ export declare class User {
|
|
|
104
104
|
* await client.user.getFacts("userId")
|
|
105
105
|
*/
|
|
106
106
|
getFacts(userId: string, requestOptions?: User.RequestOptions): Promise<Zep.FactsResponse>;
|
|
107
|
+
/**
|
|
108
|
+
* Get user node.
|
|
109
|
+
*
|
|
110
|
+
* @param {string} userId - The user_id of the user to get the node for.
|
|
111
|
+
* @param {User.RequestOptions} requestOptions - Request-specific configuration.
|
|
112
|
+
*
|
|
113
|
+
* @throws {@link Zep.NotFoundError}
|
|
114
|
+
* @throws {@link Zep.InternalServerError}
|
|
115
|
+
*
|
|
116
|
+
* @example
|
|
117
|
+
* await client.user.getNode("userId")
|
|
118
|
+
*/
|
|
119
|
+
getNode(userId: string, requestOptions?: User.RequestOptions): Promise<Zep.UserNodeResponse>;
|
|
107
120
|
/**
|
|
108
121
|
* list all sessions for a user by user id
|
|
109
122
|
*
|