@memori.ai/memori-api-client 6.5.7 → 6.5.9
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/CHANGELOG.md +14 -0
- package/dist/backend/trustedApplication.d.ts +17 -0
- package/dist/backend/trustedApplication.js +26 -0
- package/dist/backend/trustedApplication.js.map +1 -0
- package/dist/backend/trustedApplication.test.d.ts +1 -0
- package/dist/backend/trustedApplication.test.js +14 -0
- package/dist/backend/trustedApplication.test.js.map +1 -0
- package/dist/backend.d.ts +28 -0
- package/dist/backend.js +3 -0
- package/dist/backend.js.map +1 -1
- package/dist/engine/chatLogs.d.ts +3 -0
- package/dist/engine/chatLogs.js +4 -0
- package/dist/engine/chatLogs.js.map +1 -1
- package/dist/engine.d.ts +6 -0
- package/dist/index.d.ts +34 -0
- package/dist/types.d.ts +13 -0
- package/esm/backend/trustedApplication.d.ts +17 -0
- package/esm/backend/trustedApplication.js +24 -0
- package/esm/backend/trustedApplication.js.map +1 -0
- package/esm/backend/trustedApplication.test.d.ts +1 -0
- package/esm/backend/trustedApplication.test.js +11 -0
- package/esm/backend/trustedApplication.test.js.map +1 -0
- package/esm/backend.d.ts +28 -0
- package/esm/backend.js +3 -0
- package/esm/backend.js.map +1 -1
- package/esm/engine/chatLogs.d.ts +3 -0
- package/esm/engine/chatLogs.js +4 -0
- package/esm/engine/chatLogs.js.map +1 -1
- package/esm/engine.d.ts +6 -0
- package/esm/index.d.ts +34 -0
- package/esm/types.d.ts +13 -0
- package/package.json +1 -1
- package/src/backend/trustedApplication.test.ts +21 -0
- package/src/backend/trustedApplication.ts +64 -0
- package/src/backend.ts +3 -0
- package/src/engine/chatLogs.ts +27 -0
- package/src/types.ts +14 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
|
+
## [6.5.9](https://github.com/memori-ai/memori-api-client/compare/v6.5.8...v6.5.9) (2025-06-26)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* add getChatLogsPaged API function for retrieving paginated chat logs within a date range ([ec60c57](https://github.com/memori-ai/memori-api-client/commit/ec60c575c71fa065fb8247a833d94b8b38aa9fd0))
|
|
9
|
+
|
|
10
|
+
## [6.5.8](https://github.com/memori-ai/memori-api-client/compare/v6.5.7...v6.5.8) (2025-06-25)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Features
|
|
14
|
+
|
|
15
|
+
* implement trustedApplication API for managing trusted applications ([7115f9f](https://github.com/memori-ai/memori-api-client/commit/7115f9ff576153144ee5ed4ef17900f4844dbce7))
|
|
16
|
+
|
|
3
17
|
## [6.5.7](https://github.com/memori-ai/memori-api-client/compare/v6.5.6...v6.5.7) (2025-06-23)
|
|
4
18
|
|
|
5
19
|
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ResponseSpec, TrustedApplication } from '../types';
|
|
2
|
+
declare const _default: (apiUrl: string) => {
|
|
3
|
+
createTrustedApplication: (authToken: string, trustedApplication: TrustedApplication) => Promise<ResponseSpec & {
|
|
4
|
+
trustedApplication: TrustedApplication;
|
|
5
|
+
}>;
|
|
6
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<ResponseSpec & {
|
|
7
|
+
trustedApplication: TrustedApplication;
|
|
8
|
+
}>;
|
|
9
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: TrustedApplication) => Promise<ResponseSpec & {
|
|
10
|
+
trustedApplication: TrustedApplication;
|
|
11
|
+
}>;
|
|
12
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<ResponseSpec>;
|
|
13
|
+
getTrustedApplicationsList: (authToken: string) => Promise<ResponseSpec & {
|
|
14
|
+
trustedApplications: TrustedApplication[];
|
|
15
|
+
}>;
|
|
16
|
+
};
|
|
17
|
+
export default _default;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const apiFetcher_1 = require("../apiFetcher");
|
|
4
|
+
exports.default = (apiUrl) => ({
|
|
5
|
+
createTrustedApplication: (authToken, trustedApplication) => (0, apiFetcher_1.apiFetcher)(`/TrustedApplication/${authToken}`, {
|
|
6
|
+
apiUrl,
|
|
7
|
+
body: trustedApplication,
|
|
8
|
+
method: 'POST',
|
|
9
|
+
}),
|
|
10
|
+
getTrustedApplication: (authToken, trustedApplicationID) => (0, apiFetcher_1.apiFetcher)(`/TrustedApplication/${authToken}/${trustedApplicationID}`, {
|
|
11
|
+
apiUrl,
|
|
12
|
+
}),
|
|
13
|
+
updateTrustedApplication: (authToken, trustedApplicationID, trustedApplication) => (0, apiFetcher_1.apiFetcher)(`/TrustedApplication/${authToken}/${trustedApplicationID}`, {
|
|
14
|
+
apiUrl,
|
|
15
|
+
method: 'PUT',
|
|
16
|
+
body: trustedApplication,
|
|
17
|
+
}),
|
|
18
|
+
deleteTrustedApplication: (authToken, trustedApplicationID) => (0, apiFetcher_1.apiFetcher)(`/TrustedApplication/${authToken}/${trustedApplicationID}`, {
|
|
19
|
+
apiUrl,
|
|
20
|
+
method: 'DELETE',
|
|
21
|
+
}),
|
|
22
|
+
getTrustedApplicationsList: (authToken) => (0, apiFetcher_1.apiFetcher)(`/TrustedApplications/${authToken}`, {
|
|
23
|
+
apiUrl,
|
|
24
|
+
}),
|
|
25
|
+
});
|
|
26
|
+
//# sourceMappingURL=trustedApplication.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"trustedApplication.js","sourceRoot":"","sources":["../../src/backend/trustedApplication.ts"],"names":[],"mappings":";;AACA,8CAA2C;AAE3C,kBAAe,CAAC,MAAc,EAAE,EAAE,CAAC,CAAC;IAQlC,wBAAwB,EAAE,CAAC,SAAiB,EAAE,kBAAsC,EAAE,EAAE,CACtF,IAAA,uBAAU,EAAC,uBAAuB,SAAS,EAAE,EAAE;QAC7C,MAAM;QACN,IAAI,EAAE,kBAAkB;QACxB,MAAM,EAAE,MAAM;KACf,CAAuE;IAQ1E,qBAAqB,EAAE,CAAC,SAAiB,EAAE,oBAA4B,EAAE,EAAE,CACzE,IAAA,uBAAU,EAAC,uBAAuB,SAAS,IAAI,oBAAoB,EAAE,EAAE;QACrE,MAAM;KACP,CAAuE;IAS1E,wBAAwB,EAAE,CAAC,SAAiB,EAAE,oBAA4B,EAAE,kBAAsC,EAAE,EAAE,CACpH,IAAA,uBAAU,EAAC,uBAAuB,SAAS,IAAI,oBAAoB,EAAE,EAAE;QACrE,MAAM;QACN,MAAM,EAAE,KAAK;QACb,IAAI,EAAE,kBAAkB;KACzB,CAAuE;IAO1E,wBAAwB,EAAE,CAAC,SAAiB,EAAE,oBAA4B,EAAE,EAAE,CAC5E,IAAA,uBAAU,EAAC,uBAAuB,SAAS,IAAI,oBAAoB,EAAE,EAAE;QACrE,MAAM;QACN,MAAM,EAAE,QAAQ;KACjB,CAA0B;IAO7B,0BAA0B,EAAE,CAAC,SAAiB,EAAE,EAAE,CAChD,IAAA,uBAAU,EAAC,wBAAwB,SAAS,EAAE,EAAE;QAC9C,MAAM;KACP,CAA0E;CAC9E,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const index_1 = tslib_1.__importDefault(require("../index"));
|
|
5
|
+
const client = (0, index_1.default)('https://backend.memori.ai');
|
|
6
|
+
describe('backend/trustedApplication api', () => {
|
|
7
|
+
it('works on trustedApplication apis', async () => {
|
|
8
|
+
expect(await client.backend.trustedApplication.getTrustedApplicationsList('768b9654-e781-4c3c-81fa-ae1529d1bfbe')).not.toBeNull();
|
|
9
|
+
});
|
|
10
|
+
it('works on trustedApplication apis with shorthand version', async () => {
|
|
11
|
+
expect(await client.backend.getTrustedApplicationsList('768b9654-e781-4c3c-81fa-ae1529d1bfbe')).not.toBeNull();
|
|
12
|
+
});
|
|
13
|
+
});
|
|
14
|
+
//# sourceMappingURL=trustedApplication.test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"trustedApplication.test.js","sourceRoot":"","sources":["../../src/backend/trustedApplication.test.ts"],"names":[],"mappings":";;;AAAA,6DAA8B;AAE9B,MAAM,MAAM,GAAG,IAAA,eAAM,EAAC,2BAA2B,CAAC,CAAC;AAEnD,QAAQ,CAAC,gCAAgC,EAAE,GAAG,EAAE;IAC9C,EAAE,CAAC,kCAAkC,EAAE,KAAK,IAAI,EAAE;QAChD,MAAM,CACJ,MAAM,MAAM,CAAC,OAAO,CAAC,kBAAkB,CAAC,0BAA0B,CAChE,sCAAsC,CACvC,CACF,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC;IACnB,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,yDAAyD,EAAE,KAAK,IAAI,EAAE;QACvE,MAAM,CACJ,MAAM,MAAM,CAAC,OAAO,CAAC,0BAA0B,CAC7C,sCAAsC,CACvC,CACF,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC;IACnB,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
package/dist/backend.d.ts
CHANGED
|
@@ -1,4 +1,17 @@
|
|
|
1
1
|
declare const backendAPI: (apiUrl: string) => {
|
|
2
|
+
createTrustedApplication: (authToken: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
3
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
4
|
+
}>;
|
|
5
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec & {
|
|
6
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
7
|
+
}>;
|
|
8
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
9
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
10
|
+
}>;
|
|
11
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec>;
|
|
12
|
+
getTrustedApplicationsList: (authToken: string) => Promise<import("./types").ResponseSpec & {
|
|
13
|
+
trustedApplications: import("./types").TrustedApplication[];
|
|
14
|
+
}>;
|
|
2
15
|
healthCheck: () => Promise<import("./types").ResponseSpec>;
|
|
3
16
|
getTenantConfig: (tenantName: string) => Promise<import("./types").ResponseSpec & {
|
|
4
17
|
tenant: import("./types").Tenant;
|
|
@@ -613,5 +626,20 @@ declare const backendAPI: (apiUrl: string) => {
|
|
|
613
626
|
tenant: import("./types").Tenant;
|
|
614
627
|
}>;
|
|
615
628
|
};
|
|
629
|
+
trustedApplication: {
|
|
630
|
+
createTrustedApplication: (authToken: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
631
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
632
|
+
}>;
|
|
633
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec & {
|
|
634
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
635
|
+
}>;
|
|
636
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
637
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
638
|
+
}>;
|
|
639
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec>;
|
|
640
|
+
getTrustedApplicationsList: (authToken: string) => Promise<import("./types").ResponseSpec & {
|
|
641
|
+
trustedApplications: import("./types").TrustedApplication[];
|
|
642
|
+
}>;
|
|
643
|
+
};
|
|
616
644
|
};
|
|
617
645
|
export default backendAPI;
|
package/dist/backend.js
CHANGED
|
@@ -15,6 +15,7 @@ const analysis_1 = tslib_1.__importDefault(require("./backend/analysis"));
|
|
|
15
15
|
const completionConfig_1 = tslib_1.__importDefault(require("./backend/completionConfig"));
|
|
16
16
|
const badge_1 = tslib_1.__importDefault(require("./backend/badge"));
|
|
17
17
|
const tenant_1 = tslib_1.__importDefault(require("./backend/tenant"));
|
|
18
|
+
const trustedApplication_1 = tslib_1.__importDefault(require("./backend/trustedApplication"));
|
|
18
19
|
const backendAPI = (apiUrl) => ({
|
|
19
20
|
asset: (0, asset_1.default)(apiUrl),
|
|
20
21
|
memori: (0, memori_1.default)(apiUrl),
|
|
@@ -30,6 +31,7 @@ const backendAPI = (apiUrl) => ({
|
|
|
30
31
|
completionConfig: (0, completionConfig_1.default)(apiUrl),
|
|
31
32
|
badge: (0, badge_1.default)(apiUrl),
|
|
32
33
|
tenant: (0, tenant_1.default)(apiUrl),
|
|
34
|
+
trustedApplication: (0, trustedApplication_1.default)(apiUrl),
|
|
33
35
|
...(0, asset_1.default)(apiUrl),
|
|
34
36
|
...(0, memori_1.default)(apiUrl),
|
|
35
37
|
...(0, user_1.default)(apiUrl),
|
|
@@ -44,6 +46,7 @@ const backendAPI = (apiUrl) => ({
|
|
|
44
46
|
...(0, completionConfig_1.default)(apiUrl),
|
|
45
47
|
...(0, badge_1.default)(apiUrl),
|
|
46
48
|
...(0, tenant_1.default)(apiUrl),
|
|
49
|
+
...(0, trustedApplication_1.default)(apiUrl),
|
|
47
50
|
});
|
|
48
51
|
exports.default = backendAPI;
|
|
49
52
|
//# sourceMappingURL=backend.js.map
|
package/dist/backend.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"backend.js","sourceRoot":"","sources":["../src/backend.ts"],"names":[],"mappings":";;;AAAA,sEAAsC;AACtC,kEAAkC;AAClC,wEAAwC;AACxC,gFAAgD;AAChD,oEAAoC;AACpC,8EAA8C;AAC9C,wFAAwD;AACxD,oFAAoD;AACpD,kFAAkD;AAClD,wEAAwC;AACxC,0EAA0C;AAC1C,0FAA0D;AAC1D,oEAAoC;AACpC,s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AM,CAAC;IACf,GAAG,IAAA,iBAAO,EAAC,MAAM,CAAC;IAClB,GAAG,IAAA,qBAAW,EAAC,MAAM,CAAC;IACtB,GAAG,IAAA,oBAAU,EAAC,MAAM,CAAC;IACrB,GAAG,IAAA,yBAAe,EAAC,MAAM,CAAC;IAC1B,GAAG,IAAA,uBAAa,EAAC,MAAM,CAAC;IACxB,GAAG,IAAA,sBAAY,EAAC,MAAM,CAAC;IACvB,GAAG,IAAA,iBAAO,EAAC,MAAM,CAAC;IAClB,GAAG,IAAA,kBAAQ,EAAC,MAAM,CAAC;IACnB,GAAG,IAAA,0BAAgB,EAAC,MAAM,CAAC;IAC3B,GAAG,IAAA,eAAK,EAAC,MAAM,CAAC;IAChB,GAAG,IAAA,gBAAM,EAAC,MAAM,CAAC;IACjB,GAAG,IAAA,4BAAkB,EAAC,MAAM,CAAC;CAC9B,CAAC,CAAC;AAEH,kBAAe,UAAU,CAAC"}
|
|
@@ -3,6 +3,9 @@ declare const _default: (apiUrl: string) => {
|
|
|
3
3
|
getChatLogs: (sessionId: string, dateFrom?: string, dateTo?: string) => Promise<ResponseSpec & {
|
|
4
4
|
chatLogs: ChatLog[];
|
|
5
5
|
}>;
|
|
6
|
+
getChatLogsPaged: (sessionId: string, dateFrom: string, dateTo: string, from: number, howMany: number) => Promise<ResponseSpec & {
|
|
7
|
+
chatLogs: ChatLog[];
|
|
8
|
+
}>;
|
|
6
9
|
getChatLogsByUser: (sessionId: string, dateFrom?: string, dateTo?: string) => Promise<ResponseSpec & {
|
|
7
10
|
chatLogs: ChatLog[];
|
|
8
11
|
}>;
|
package/dist/engine/chatLogs.js
CHANGED
|
@@ -6,6 +6,10 @@ exports.default = (apiUrl) => ({
|
|
|
6
6
|
method: 'GET',
|
|
7
7
|
apiUrl,
|
|
8
8
|
}),
|
|
9
|
+
getChatLogsPaged: async (sessionId, dateFrom, dateTo, from, howMany) => (0, apiFetcher_1.apiFetcher)(`/ChatLogsPaged/${sessionId}/${dateFrom}/${dateTo}/${from}/${howMany}`, {
|
|
10
|
+
method: 'GET',
|
|
11
|
+
apiUrl,
|
|
12
|
+
}),
|
|
9
13
|
getChatLogsByUser: async (sessionId, dateFrom, dateTo) => (0, apiFetcher_1.apiFetcher)(`/CurrentUserChatLogs/${sessionId}${dateFrom ? `/${dateFrom}` : ''}${dateFrom && dateTo ? `/${dateTo}` : ''}`, {
|
|
10
14
|
method: 'GET',
|
|
11
15
|
apiUrl,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"chatLogs.js","sourceRoot":"","sources":["../../src/engine/chatLogs.ts"],"names":[],"mappings":";;AACA,8CAA2C;AAQ3C,kBAAe,CAAC,MAAc,EAAE,EAAE,CAAC,CAAC;IAOlC,WAAW,EAAE,KAAK,EAAE,SAAiB,EAAE,QAAiB,EAAE,MAAe,EAAE,EAAE,CAC3E,IAAA,uBAAU,EACR,aAAa,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,IAAI,QAAQ,EAAE,CAAC,CAAC,CAAC,EAAE,GACrD,QAAQ,IAAI,MAAM,CAAC,CAAC,CAAC,IAAI,MAAM,EAAE,CAAC,CAAC,CAAC,EACtC,EAAE,EACF;QACE,MAAM,EAAE,KAAK;QACb,MAAM;KACP,CAKF;IAQH,iBAAiB,EAAE,KAAK,EAAE,SAAiB,EAAE,QAAiB,EAAE,MAAe,EAAE,EAAE,CACjF,IAAA,uBAAU,EACR,wBAAwB,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,IAAI,QAAQ,EAAE,CAAC,CAAC,CAAC,EAAE,GAChE,QAAQ,IAAI,MAAM,CAAC,CAAC,CAAC,IAAI,MAAM,EAAE,CAAC,CAAC,CAAC,EACtC,EAAE,EACF;QACE,MAAM,EAAE,KAAK;QACb,MAAM;KACP,CAKF;IAOH,kBAAkB,EAAE,KAAK,EAAE,SAAiB,EAAE,gBAAwB,EAAE,EAAE,CACxE,IAAA,uBAAU,EAAC,oBAAoB,SAAS,IAAI,gBAAgB,EAA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,MAAM,EAAE,KAAK;QACb,MAAM;KACP,CAKF;IAQH,cAAc,EAAE,KAAK,EACnB,SAAiB,EACjB,QAAiB,EACjB,MAAe,EACf,EAAE,CACF,IAAA,uBAAU,EACR,aAAa,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,IAAI,QAAQ,EAAE,CAAC,CAAC,CAAC,EAAE,GACrD,QAAQ,IAAI,MAAM,CAAC,CAAC,CAAC,IAAI,MAAM,EAAE,CAAC,CAAC,CAAC,EACtC,EAAE,EACF;QACE,MAAM,EAAE,QAAQ;QAChB,MAAM;KACP,CACuB;IAO5B,aAAa,EAAE,KAAK,EAAE,SAAiB,EAAE,SAAiB,EAAE,EAAE,CAC5D,IAAA,uBAAU,EAAC,YAAY,SAAS,IAAI,SAAS,EAAE,EAAE;QAC/C,MAAM,EAAE,QAAQ;QAChB,MAAM;KACP,CAA0B;CAC9B,CAAC,CAAC"}
|
package/dist/engine.d.ts
CHANGED
|
@@ -192,6 +192,9 @@ declare const _default: (apiUrl: string) => {
|
|
|
192
192
|
getChatLogs: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
193
193
|
chatLogs: import("./types").ChatLog[];
|
|
194
194
|
}>;
|
|
195
|
+
getChatLogsPaged: (sessionId: string, dateFrom: string, dateTo: string, from: number, howMany: number) => Promise<import("./types").ResponseSpec & {
|
|
196
|
+
chatLogs: import("./types").ChatLog[];
|
|
197
|
+
}>;
|
|
195
198
|
getChatLogsByUser: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
196
199
|
chatLogs: import("./types").ChatLog[];
|
|
197
200
|
}>;
|
|
@@ -207,6 +210,9 @@ declare const _default: (apiUrl: string) => {
|
|
|
207
210
|
getChatLogs: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
208
211
|
chatLogs: import("./types").ChatLog[];
|
|
209
212
|
}>;
|
|
213
|
+
getChatLogsPaged: (sessionId: string, dateFrom: string, dateTo: string, from: number, howMany: number) => Promise<import("./types").ResponseSpec & {
|
|
214
|
+
chatLogs: import("./types").ChatLog[];
|
|
215
|
+
}>;
|
|
210
216
|
getChatLogsByUser: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
211
217
|
chatLogs: import("./types").ChatLog[];
|
|
212
218
|
}>;
|
package/dist/index.d.ts
CHANGED
|
@@ -201,6 +201,9 @@ declare const api: (backendEndpoint?: string, engineEndpoint?: string) => {
|
|
|
201
201
|
getChatLogs: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
202
202
|
chatLogs: import("./types").ChatLog[];
|
|
203
203
|
}>;
|
|
204
|
+
getChatLogsPaged: (sessionId: string, dateFrom: string, dateTo: string, from: number, howMany: number) => Promise<import("./types").ResponseSpec & {
|
|
205
|
+
chatLogs: import("./types").ChatLog[];
|
|
206
|
+
}>;
|
|
204
207
|
getChatLogsByUser: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
205
208
|
chatLogs: import("./types").ChatLog[];
|
|
206
209
|
}>;
|
|
@@ -216,6 +219,9 @@ declare const api: (backendEndpoint?: string, engineEndpoint?: string) => {
|
|
|
216
219
|
getChatLogs: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
217
220
|
chatLogs: import("./types").ChatLog[];
|
|
218
221
|
}>;
|
|
222
|
+
getChatLogsPaged: (sessionId: string, dateFrom: string, dateTo: string, from: number, howMany: number) => Promise<import("./types").ResponseSpec & {
|
|
223
|
+
chatLogs: import("./types").ChatLog[];
|
|
224
|
+
}>;
|
|
219
225
|
getChatLogsByUser: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
220
226
|
chatLogs: import("./types").ChatLog[];
|
|
221
227
|
}>;
|
|
@@ -745,6 +751,19 @@ declare const api: (backendEndpoint?: string, engineEndpoint?: string) => {
|
|
|
745
751
|
deleteCorrelationPair: (sessionId: string, pairId: string) => Promise<import("./types").ResponseSpec>;
|
|
746
752
|
};
|
|
747
753
|
backend: {
|
|
754
|
+
createTrustedApplication: (authToken: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
755
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
756
|
+
}>;
|
|
757
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec & {
|
|
758
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
759
|
+
}>;
|
|
760
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
761
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
762
|
+
}>;
|
|
763
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec>;
|
|
764
|
+
getTrustedApplicationsList: (authToken: string) => Promise<import("./types").ResponseSpec & {
|
|
765
|
+
trustedApplications: import("./types").TrustedApplication[];
|
|
766
|
+
}>;
|
|
748
767
|
healthCheck: () => Promise<import("./types").ResponseSpec>;
|
|
749
768
|
getTenantConfig: (tenantName: string) => Promise<import("./types").ResponseSpec & {
|
|
750
769
|
tenant: import("./types").Tenant;
|
|
@@ -1359,6 +1378,21 @@ declare const api: (backendEndpoint?: string, engineEndpoint?: string) => {
|
|
|
1359
1378
|
tenant: import("./types").Tenant;
|
|
1360
1379
|
}>;
|
|
1361
1380
|
};
|
|
1381
|
+
trustedApplication: {
|
|
1382
|
+
createTrustedApplication: (authToken: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
1383
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
1384
|
+
}>;
|
|
1385
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec & {
|
|
1386
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
1387
|
+
}>;
|
|
1388
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
1389
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
1390
|
+
}>;
|
|
1391
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec>;
|
|
1392
|
+
getTrustedApplicationsList: (authToken: string) => Promise<import("./types").ResponseSpec & {
|
|
1393
|
+
trustedApplications: import("./types").TrustedApplication[];
|
|
1394
|
+
}>;
|
|
1395
|
+
};
|
|
1362
1396
|
};
|
|
1363
1397
|
};
|
|
1364
1398
|
export default api;
|
package/dist/types.d.ts
CHANGED
|
@@ -985,3 +985,16 @@ export declare type MacroFunction = {
|
|
|
985
985
|
obfuscated?: boolean;
|
|
986
986
|
}[];
|
|
987
987
|
};
|
|
988
|
+
export declare type TrustedApplication = {
|
|
989
|
+
trustedApplicationID: string;
|
|
990
|
+
tenantID: string;
|
|
991
|
+
name: string;
|
|
992
|
+
description: string;
|
|
993
|
+
baseUrl: string;
|
|
994
|
+
authorizationToken: string;
|
|
995
|
+
isEnabled: boolean;
|
|
996
|
+
createdByUserID: string;
|
|
997
|
+
lastModifiedByUserID: string;
|
|
998
|
+
creationTimestamp: string;
|
|
999
|
+
lastChangeTimestamp: string;
|
|
1000
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ResponseSpec, TrustedApplication } from '../types';
|
|
2
|
+
declare const _default: (apiUrl: string) => {
|
|
3
|
+
createTrustedApplication: (authToken: string, trustedApplication: TrustedApplication) => Promise<ResponseSpec & {
|
|
4
|
+
trustedApplication: TrustedApplication;
|
|
5
|
+
}>;
|
|
6
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<ResponseSpec & {
|
|
7
|
+
trustedApplication: TrustedApplication;
|
|
8
|
+
}>;
|
|
9
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: TrustedApplication) => Promise<ResponseSpec & {
|
|
10
|
+
trustedApplication: TrustedApplication;
|
|
11
|
+
}>;
|
|
12
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<ResponseSpec>;
|
|
13
|
+
getTrustedApplicationsList: (authToken: string) => Promise<ResponseSpec & {
|
|
14
|
+
trustedApplications: TrustedApplication[];
|
|
15
|
+
}>;
|
|
16
|
+
};
|
|
17
|
+
export default _default;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { apiFetcher } from '../apiFetcher';
|
|
2
|
+
export default (apiUrl) => ({
|
|
3
|
+
createTrustedApplication: (authToken, trustedApplication) => apiFetcher(`/TrustedApplication/${authToken}`, {
|
|
4
|
+
apiUrl,
|
|
5
|
+
body: trustedApplication,
|
|
6
|
+
method: 'POST',
|
|
7
|
+
}),
|
|
8
|
+
getTrustedApplication: (authToken, trustedApplicationID) => apiFetcher(`/TrustedApplication/${authToken}/${trustedApplicationID}`, {
|
|
9
|
+
apiUrl,
|
|
10
|
+
}),
|
|
11
|
+
updateTrustedApplication: (authToken, trustedApplicationID, trustedApplication) => apiFetcher(`/TrustedApplication/${authToken}/${trustedApplicationID}`, {
|
|
12
|
+
apiUrl,
|
|
13
|
+
method: 'PUT',
|
|
14
|
+
body: trustedApplication,
|
|
15
|
+
}),
|
|
16
|
+
deleteTrustedApplication: (authToken, trustedApplicationID) => apiFetcher(`/TrustedApplication/${authToken}/${trustedApplicationID}`, {
|
|
17
|
+
apiUrl,
|
|
18
|
+
method: 'DELETE',
|
|
19
|
+
}),
|
|
20
|
+
getTrustedApplicationsList: (authToken) => apiFetcher(`/TrustedApplications/${authToken}`, {
|
|
21
|
+
apiUrl,
|
|
22
|
+
}),
|
|
23
|
+
});
|
|
24
|
+
//# sourceMappingURL=trustedApplication.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"trustedApplication.js","sourceRoot":"","sources":["../../src/backend/trustedApplication.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,eAAe,CAAC,MAAc,EAAE,EAAE,CAAC,CAAC;IAQlC,wBAAwB,EAAE,CAAC,SAAiB,EAAE,kBAAsC,EAAE,EAAE,CACtF,UAAU,CAAC,uBAAuB,SAAS,EAAE,EAAE;QAC7C,MAAM;QACN,IAAI,EAAE,kBAAkB;QACxB,MAAM,EAAE,MAAM;KACf,CAAuE;IAQ1E,qBAAqB,EAAE,CAAC,SAAiB,EAAE,oBAA4B,EAAE,EAAE,CACzE,UAAU,CAAC,uBAAuB,SAAS,IAAI,oBAAoB,EAAE,EAAE;QACrE,MAAM;KACP,CAAuE;IAS1E,wBAAwB,EAAE,CAAC,SAAiB,EAAE,oBAA4B,EAAE,kBAAsC,EAAE,EAAE,CACpH,UAAU,CAAC,uBAAuB,SAAS,IAAI,oBAAoB,EAAE,EAAE;QACrE,MAAM;QACN,MAAM,EAAE,KAAK;QACb,IAAI,EAAE,kBAAkB;KACzB,CAAuE;IAO1E,wBAAwB,EAAE,CAAC,SAAiB,EAAE,oBAA4B,EAAE,EAAE,CAC5E,UAAU,CAAC,uBAAuB,SAAS,IAAI,oBAAoB,EAAE,EAAE;QACrE,MAAM;QACN,MAAM,EAAE,QAAQ;KACjB,CAA0B;IAO7B,0BAA0B,EAAE,CAAC,SAAiB,EAAE,EAAE,CAChD,UAAU,CAAC,wBAAwB,SAAS,EAAE,EAAE;QAC9C,MAAM;KACP,CAA0E;CAC9E,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import memori from '../index';
|
|
2
|
+
const client = memori('https://backend.memori.ai');
|
|
3
|
+
describe('backend/trustedApplication api', () => {
|
|
4
|
+
it('works on trustedApplication apis', async () => {
|
|
5
|
+
expect(await client.backend.trustedApplication.getTrustedApplicationsList('768b9654-e781-4c3c-81fa-ae1529d1bfbe')).not.toBeNull();
|
|
6
|
+
});
|
|
7
|
+
it('works on trustedApplication apis with shorthand version', async () => {
|
|
8
|
+
expect(await client.backend.getTrustedApplicationsList('768b9654-e781-4c3c-81fa-ae1529d1bfbe')).not.toBeNull();
|
|
9
|
+
});
|
|
10
|
+
});
|
|
11
|
+
//# sourceMappingURL=trustedApplication.test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"trustedApplication.test.js","sourceRoot":"","sources":["../../src/backend/trustedApplication.test.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,UAAU,CAAC;AAE9B,MAAM,MAAM,GAAG,MAAM,CAAC,2BAA2B,CAAC,CAAC;AAEnD,QAAQ,CAAC,gCAAgC,EAAE,GAAG,EAAE;IAC9C,EAAE,CAAC,kCAAkC,EAAE,KAAK,IAAI,EAAE;QAChD,MAAM,CACJ,MAAM,MAAM,CAAC,OAAO,CAAC,kBAAkB,CAAC,0BAA0B,CAChE,sCAAsC,CACvC,CACF,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC;IACnB,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,yDAAyD,EAAE,KAAK,IAAI,EAAE;QACvE,MAAM,CACJ,MAAM,MAAM,CAAC,OAAO,CAAC,0BAA0B,CAC7C,sCAAsC,CACvC,CACF,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC;IACnB,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
package/esm/backend.d.ts
CHANGED
|
@@ -1,4 +1,17 @@
|
|
|
1
1
|
declare const backendAPI: (apiUrl: string) => {
|
|
2
|
+
createTrustedApplication: (authToken: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
3
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
4
|
+
}>;
|
|
5
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec & {
|
|
6
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
7
|
+
}>;
|
|
8
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
9
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
10
|
+
}>;
|
|
11
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec>;
|
|
12
|
+
getTrustedApplicationsList: (authToken: string) => Promise<import("./types").ResponseSpec & {
|
|
13
|
+
trustedApplications: import("./types").TrustedApplication[];
|
|
14
|
+
}>;
|
|
2
15
|
healthCheck: () => Promise<import("./types").ResponseSpec>;
|
|
3
16
|
getTenantConfig: (tenantName: string) => Promise<import("./types").ResponseSpec & {
|
|
4
17
|
tenant: import("./types").Tenant;
|
|
@@ -613,5 +626,20 @@ declare const backendAPI: (apiUrl: string) => {
|
|
|
613
626
|
tenant: import("./types").Tenant;
|
|
614
627
|
}>;
|
|
615
628
|
};
|
|
629
|
+
trustedApplication: {
|
|
630
|
+
createTrustedApplication: (authToken: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
631
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
632
|
+
}>;
|
|
633
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec & {
|
|
634
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
635
|
+
}>;
|
|
636
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
637
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
638
|
+
}>;
|
|
639
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec>;
|
|
640
|
+
getTrustedApplicationsList: (authToken: string) => Promise<import("./types").ResponseSpec & {
|
|
641
|
+
trustedApplications: import("./types").TrustedApplication[];
|
|
642
|
+
}>;
|
|
643
|
+
};
|
|
616
644
|
};
|
|
617
645
|
export default backendAPI;
|
package/esm/backend.js
CHANGED
|
@@ -12,6 +12,7 @@ import analysis from './backend/analysis';
|
|
|
12
12
|
import completionConfig from './backend/completionConfig';
|
|
13
13
|
import badge from './backend/badge';
|
|
14
14
|
import tenant from './backend/tenant';
|
|
15
|
+
import trustedApplication from './backend/trustedApplication';
|
|
15
16
|
const backendAPI = (apiUrl) => ({
|
|
16
17
|
asset: asset(apiUrl),
|
|
17
18
|
memori: memori(apiUrl),
|
|
@@ -27,6 +28,7 @@ const backendAPI = (apiUrl) => ({
|
|
|
27
28
|
completionConfig: completionConfig(apiUrl),
|
|
28
29
|
badge: badge(apiUrl),
|
|
29
30
|
tenant: tenant(apiUrl),
|
|
31
|
+
trustedApplication: trustedApplication(apiUrl),
|
|
30
32
|
...asset(apiUrl),
|
|
31
33
|
...memori(apiUrl),
|
|
32
34
|
...user(apiUrl),
|
|
@@ -41,6 +43,7 @@ const backendAPI = (apiUrl) => ({
|
|
|
41
43
|
...completionConfig(apiUrl),
|
|
42
44
|
...badge(apiUrl),
|
|
43
45
|
...tenant(apiUrl),
|
|
46
|
+
...trustedApplication(apiUrl),
|
|
44
47
|
});
|
|
45
48
|
export default backendAPI;
|
|
46
49
|
//# sourceMappingURL=backend.js.map
|
package/esm/backend.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"backend.js","sourceRoot":"","sources":["../src/backend.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,kBAAkB,CAAC;AACtC,OAAO,IAAI,MAAM,gBAAgB,CAAC;AAClC,OAAO,OAAO,MAAM,mBAAmB,CAAC;AACxC,OAAO,WAAW,MAAM,uBAAuB,CAAC;AAChD,OAAO,KAAK,MAAM,iBAAiB,CAAC;AACpC,OAAO,UAAU,MAAM,sBAAsB,CAAC;AAC9C,OAAO,eAAe,MAAM,2BAA2B,C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AU,CAAC,MAAM,CAAC;IAC9B,eAAe,EAAE,eAAe,CAAC,MAAM,CAAC;IACxC,aAAa,EAAE,aAAa,CAAC,MAAM,CAAC;IACpC,YAAY,EAAE,YAAY,CAAC,MAAM,CAAC;IAClC,OAAO,EAAE,OAAO,CAAC,MAAM,CAAC;IACxB,QAAQ,EAAE,QAAQ,CAAC,MAAM,CAAC;IAC1B,gBAAgB,EAAE,gBAAgB,CAAC,MAAM,CAAC;IAC1C,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC,MAAM,CAAC;IACtB,kBAAkB,EAAE,kBAAkB,CAAC,MAAM,CAAC;IAC9C,GAAG,KAAK,CAAC,MAAM,CAAC;IAChB,GAAG,MAAM,CAAC,MAAM,CAAC;IACjB,GAAG,IAAI,CAAC,MAAM,CAAC;IACf,GAAG,OAAO,CAAC,MAAM,CAAC;IAClB,GAAG,WAAW,CAAC,MAAM,CAAC;IACtB,GAAG,UAAU,CAAC,MAAM,CAAC;IACrB,GAAG,eAAe,CAAC,MAAM,CAAC;IAC1B,GAAG,aAAa,CAAC,MAAM,CAAC;IACxB,GAAG,YAAY,CAAC,MAAM,CAAC;IACvB,GAAG,OAAO,CAAC,MAAM,CAAC;IAClB,GAAG,QAAQ,CAAC,MAAM,CAAC;IACnB,GAAG,gBAAgB,CAAC,MAAM,CAAC;IAC3B,GAAG,KAAK,CAAC,MAAM,CAAC;IAChB,GAAG,MAAM,CAAC,MAAM,CAAC;IACjB,GAAG,kBAAkB,CAAC,MAAM,CAAC;CAC9B,CAAC,CAAC;AAEH,eAAe,UAAU,CAAC"}
|
package/esm/engine/chatLogs.d.ts
CHANGED
|
@@ -3,6 +3,9 @@ declare const _default: (apiUrl: string) => {
|
|
|
3
3
|
getChatLogs: (sessionId: string, dateFrom?: string, dateTo?: string) => Promise<ResponseSpec & {
|
|
4
4
|
chatLogs: ChatLog[];
|
|
5
5
|
}>;
|
|
6
|
+
getChatLogsPaged: (sessionId: string, dateFrom: string, dateTo: string, from: number, howMany: number) => Promise<ResponseSpec & {
|
|
7
|
+
chatLogs: ChatLog[];
|
|
8
|
+
}>;
|
|
6
9
|
getChatLogsByUser: (sessionId: string, dateFrom?: string, dateTo?: string) => Promise<ResponseSpec & {
|
|
7
10
|
chatLogs: ChatLog[];
|
|
8
11
|
}>;
|
package/esm/engine/chatLogs.js
CHANGED
|
@@ -4,6 +4,10 @@ export default (apiUrl) => ({
|
|
|
4
4
|
method: 'GET',
|
|
5
5
|
apiUrl,
|
|
6
6
|
}),
|
|
7
|
+
getChatLogsPaged: async (sessionId, dateFrom, dateTo, from, howMany) => apiFetcher(`/ChatLogsPaged/${sessionId}/${dateFrom}/${dateTo}/${from}/${howMany}`, {
|
|
8
|
+
method: 'GET',
|
|
9
|
+
apiUrl,
|
|
10
|
+
}),
|
|
7
11
|
getChatLogsByUser: async (sessionId, dateFrom, dateTo) => apiFetcher(`/CurrentUserChatLogs/${sessionId}${dateFrom ? `/${dateFrom}` : ''}${dateFrom && dateTo ? `/${dateTo}` : ''}`, {
|
|
8
12
|
method: 'GET',
|
|
9
13
|
apiUrl,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"chatLogs.js","sourceRoot":"","sources":["../../src/engine/chatLogs.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAQ3C,eAAe,CAAC,MAAc,EAAE,EAAE,CAAC,CAAC;IAOlC,WAAW,EAAE,KAAK,EAAE,SAAiB,EAAE,QAAiB,EAAE,MAAe,EAAE,EAAE,CAC3E,UAAU,CACR,aAAa,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,IAAI,QAAQ,EAAE,CAAC,CAAC,CAAC,EAAE,GACrD,QAAQ,IAAI,MAAM,CAAC,CAAC,CAAC,IAAI,MAAM,EAAE,CAAC,CAAC,CAAC,EACtC,EAAE,EACF;QACE,MAAM,EAAE,KAAK;QACb,MAAM;KACP,CAKF;IAQ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AAE,CACxE,UAAU,CAAC,oBAAoB,SAAS,IAAI,gBAAgB,EAAE,EAAE;QAC9D,MAAM,EAAE,KAAK;QACb,MAAM;KACP,CAIA;IASH,eAAe,EAAE,KAAK,EACpB,SAAiB,EACjB,MAAc,EACd,QAAiB,EACjB,MAAe,EACf,EAAE,CACF,UAAU,CACR,iBAAiB,SAAS,IAAI,MAAM,GAAG,QAAQ,CAAC,CAAC,CAAC,IAAI,QAAQ,EAAE,CAAC,CAAC,CAAC,EAAE,GACnE,QAAQ,IAAI,MAAM,CAAC,CAAC,CAAC,IAAI,MAAM,EAAE,CAAC,CAAC,CAAC,EACtC,EAAE,EACF;QACE,MAAM,EAAE,KAAK;QACb,MAAM;KACP,CAKF;IAQH,cAAc,EAAE,KAAK,EACnB,SAAiB,EACjB,QAAiB,EACjB,MAAe,EACf,EAAE,CACF,UAAU,CACR,aAAa,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,IAAI,QAAQ,EAAE,CAAC,CAAC,CAAC,EAAE,GACrD,QAAQ,IAAI,MAAM,CAAC,CAAC,CAAC,IAAI,MAAM,EAAE,CAAC,CAAC,CAAC,EACtC,EAAE,EACF;QACE,MAAM,EAAE,QAAQ;QAChB,MAAM;KACP,CACuB;IAO5B,aAAa,EAAE,KAAK,EAAE,SAAiB,EAAE,SAAiB,EAAE,EAAE,CAC5D,UAAU,CAAC,YAAY,SAAS,IAAI,SAAS,EAAE,EAAE;QAC/C,MAAM,EAAE,QAAQ;QAChB,MAAM;KACP,CAA0B;CAC9B,CAAC,CAAC"}
|
package/esm/engine.d.ts
CHANGED
|
@@ -192,6 +192,9 @@ declare const _default: (apiUrl: string) => {
|
|
|
192
192
|
getChatLogs: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
193
193
|
chatLogs: import("./types").ChatLog[];
|
|
194
194
|
}>;
|
|
195
|
+
getChatLogsPaged: (sessionId: string, dateFrom: string, dateTo: string, from: number, howMany: number) => Promise<import("./types").ResponseSpec & {
|
|
196
|
+
chatLogs: import("./types").ChatLog[];
|
|
197
|
+
}>;
|
|
195
198
|
getChatLogsByUser: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
196
199
|
chatLogs: import("./types").ChatLog[];
|
|
197
200
|
}>;
|
|
@@ -207,6 +210,9 @@ declare const _default: (apiUrl: string) => {
|
|
|
207
210
|
getChatLogs: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
208
211
|
chatLogs: import("./types").ChatLog[];
|
|
209
212
|
}>;
|
|
213
|
+
getChatLogsPaged: (sessionId: string, dateFrom: string, dateTo: string, from: number, howMany: number) => Promise<import("./types").ResponseSpec & {
|
|
214
|
+
chatLogs: import("./types").ChatLog[];
|
|
215
|
+
}>;
|
|
210
216
|
getChatLogsByUser: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
211
217
|
chatLogs: import("./types").ChatLog[];
|
|
212
218
|
}>;
|
package/esm/index.d.ts
CHANGED
|
@@ -201,6 +201,9 @@ declare const api: (backendEndpoint?: string, engineEndpoint?: string) => {
|
|
|
201
201
|
getChatLogs: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
202
202
|
chatLogs: import("./types").ChatLog[];
|
|
203
203
|
}>;
|
|
204
|
+
getChatLogsPaged: (sessionId: string, dateFrom: string, dateTo: string, from: number, howMany: number) => Promise<import("./types").ResponseSpec & {
|
|
205
|
+
chatLogs: import("./types").ChatLog[];
|
|
206
|
+
}>;
|
|
204
207
|
getChatLogsByUser: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
205
208
|
chatLogs: import("./types").ChatLog[];
|
|
206
209
|
}>;
|
|
@@ -216,6 +219,9 @@ declare const api: (backendEndpoint?: string, engineEndpoint?: string) => {
|
|
|
216
219
|
getChatLogs: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
217
220
|
chatLogs: import("./types").ChatLog[];
|
|
218
221
|
}>;
|
|
222
|
+
getChatLogsPaged: (sessionId: string, dateFrom: string, dateTo: string, from: number, howMany: number) => Promise<import("./types").ResponseSpec & {
|
|
223
|
+
chatLogs: import("./types").ChatLog[];
|
|
224
|
+
}>;
|
|
219
225
|
getChatLogsByUser: (sessionId: string, dateFrom?: string | undefined, dateTo?: string | undefined) => Promise<import("./types").ResponseSpec & {
|
|
220
226
|
chatLogs: import("./types").ChatLog[];
|
|
221
227
|
}>;
|
|
@@ -745,6 +751,19 @@ declare const api: (backendEndpoint?: string, engineEndpoint?: string) => {
|
|
|
745
751
|
deleteCorrelationPair: (sessionId: string, pairId: string) => Promise<import("./types").ResponseSpec>;
|
|
746
752
|
};
|
|
747
753
|
backend: {
|
|
754
|
+
createTrustedApplication: (authToken: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
755
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
756
|
+
}>;
|
|
757
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec & {
|
|
758
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
759
|
+
}>;
|
|
760
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
761
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
762
|
+
}>;
|
|
763
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec>;
|
|
764
|
+
getTrustedApplicationsList: (authToken: string) => Promise<import("./types").ResponseSpec & {
|
|
765
|
+
trustedApplications: import("./types").TrustedApplication[];
|
|
766
|
+
}>;
|
|
748
767
|
healthCheck: () => Promise<import("./types").ResponseSpec>;
|
|
749
768
|
getTenantConfig: (tenantName: string) => Promise<import("./types").ResponseSpec & {
|
|
750
769
|
tenant: import("./types").Tenant;
|
|
@@ -1359,6 +1378,21 @@ declare const api: (backendEndpoint?: string, engineEndpoint?: string) => {
|
|
|
1359
1378
|
tenant: import("./types").Tenant;
|
|
1360
1379
|
}>;
|
|
1361
1380
|
};
|
|
1381
|
+
trustedApplication: {
|
|
1382
|
+
createTrustedApplication: (authToken: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
1383
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
1384
|
+
}>;
|
|
1385
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec & {
|
|
1386
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
1387
|
+
}>;
|
|
1388
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: import("./types").TrustedApplication) => Promise<import("./types").ResponseSpec & {
|
|
1389
|
+
trustedApplication: import("./types").TrustedApplication;
|
|
1390
|
+
}>;
|
|
1391
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) => Promise<import("./types").ResponseSpec>;
|
|
1392
|
+
getTrustedApplicationsList: (authToken: string) => Promise<import("./types").ResponseSpec & {
|
|
1393
|
+
trustedApplications: import("./types").TrustedApplication[];
|
|
1394
|
+
}>;
|
|
1395
|
+
};
|
|
1362
1396
|
};
|
|
1363
1397
|
};
|
|
1364
1398
|
export default api;
|
package/esm/types.d.ts
CHANGED
|
@@ -985,3 +985,16 @@ export declare type MacroFunction = {
|
|
|
985
985
|
obfuscated?: boolean;
|
|
986
986
|
}[];
|
|
987
987
|
};
|
|
988
|
+
export declare type TrustedApplication = {
|
|
989
|
+
trustedApplicationID: string;
|
|
990
|
+
tenantID: string;
|
|
991
|
+
name: string;
|
|
992
|
+
description: string;
|
|
993
|
+
baseUrl: string;
|
|
994
|
+
authorizationToken: string;
|
|
995
|
+
isEnabled: boolean;
|
|
996
|
+
createdByUserID: string;
|
|
997
|
+
lastModifiedByUserID: string;
|
|
998
|
+
creationTimestamp: string;
|
|
999
|
+
lastChangeTimestamp: string;
|
|
1000
|
+
};
|
package/package.json
CHANGED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import memori from '../index';
|
|
2
|
+
|
|
3
|
+
const client = memori('https://backend.memori.ai');
|
|
4
|
+
|
|
5
|
+
describe('backend/trustedApplication api', () => {
|
|
6
|
+
it('works on trustedApplication apis', async () => {
|
|
7
|
+
expect(
|
|
8
|
+
await client.backend.trustedApplication.getTrustedApplicationsList(
|
|
9
|
+
'768b9654-e781-4c3c-81fa-ae1529d1bfbe'
|
|
10
|
+
)
|
|
11
|
+
).not.toBeNull();
|
|
12
|
+
});
|
|
13
|
+
|
|
14
|
+
it('works on trustedApplication apis with shorthand version', async () => {
|
|
15
|
+
expect(
|
|
16
|
+
await client.backend.getTrustedApplicationsList(
|
|
17
|
+
'768b9654-e781-4c3c-81fa-ae1529d1bfbe'
|
|
18
|
+
)
|
|
19
|
+
).not.toBeNull();
|
|
20
|
+
});
|
|
21
|
+
});
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { ResponseSpec, TrustedApplication } from '../types';
|
|
2
|
+
import { apiFetcher } from '../apiFetcher';
|
|
3
|
+
|
|
4
|
+
export default (apiUrl: string) => ({
|
|
5
|
+
/**
|
|
6
|
+
* Creates a new TrustedApplication.
|
|
7
|
+
* Only administrators can create TrustedApplications.
|
|
8
|
+
* @param authToken - The login token
|
|
9
|
+
* @param trustedApplication - The TrustedApplication specifications
|
|
10
|
+
* @returns The created TrustedApplication object
|
|
11
|
+
*/
|
|
12
|
+
createTrustedApplication: (authToken: string, trustedApplication: TrustedApplication) =>
|
|
13
|
+
apiFetcher(`/TrustedApplication/${authToken}`, {
|
|
14
|
+
apiUrl,
|
|
15
|
+
body: trustedApplication,
|
|
16
|
+
method: 'POST',
|
|
17
|
+
}) as Promise<ResponseSpec & { trustedApplication: TrustedApplication }>,
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Gets a TrustedApplication by ID.
|
|
21
|
+
* @param authToken - The login token
|
|
22
|
+
* @param trustedApplicationID - The TrustedApplication ID
|
|
23
|
+
* @returns The TrustedApplication object
|
|
24
|
+
*/
|
|
25
|
+
getTrustedApplication: (authToken: string, trustedApplicationID: string) =>
|
|
26
|
+
apiFetcher(`/TrustedApplication/${authToken}/${trustedApplicationID}`, {
|
|
27
|
+
apiUrl,
|
|
28
|
+
}) as Promise<ResponseSpec & { trustedApplication: TrustedApplication }>,
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Updates an existing TrustedApplication.
|
|
32
|
+
* @param authToken - The login token
|
|
33
|
+
* @param trustedApplicationID - The TrustedApplication ID
|
|
34
|
+
* @param trustedApplication - The TrustedApplication specifications
|
|
35
|
+
* @returns The updated TrustedApplication object
|
|
36
|
+
*/
|
|
37
|
+
updateTrustedApplication: (authToken: string, trustedApplicationID: string, trustedApplication: TrustedApplication) =>
|
|
38
|
+
apiFetcher(`/TrustedApplication/${authToken}/${trustedApplicationID}`, {
|
|
39
|
+
apiUrl,
|
|
40
|
+
method: 'PUT',
|
|
41
|
+
body: trustedApplication,
|
|
42
|
+
}) as Promise<ResponseSpec & { trustedApplication: TrustedApplication }>,
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* Deletes a TrustedApplication.
|
|
46
|
+
* @param authToken - The login token
|
|
47
|
+
* @param trustedApplicationID - The TrustedApplication ID
|
|
48
|
+
*/
|
|
49
|
+
deleteTrustedApplication: (authToken: string, trustedApplicationID: string) =>
|
|
50
|
+
apiFetcher(`/TrustedApplication/${authToken}/${trustedApplicationID}`, {
|
|
51
|
+
apiUrl,
|
|
52
|
+
method: 'DELETE',
|
|
53
|
+
}) as Promise<ResponseSpec>,
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* Lists all TrustedApplications for the current tenant.
|
|
57
|
+
* @param authToken - The login token
|
|
58
|
+
* @returns A list of TrustedApplication objects
|
|
59
|
+
*/
|
|
60
|
+
getTrustedApplicationsList: (authToken: string) =>
|
|
61
|
+
apiFetcher(`/TrustedApplications/${authToken}`, {
|
|
62
|
+
apiUrl,
|
|
63
|
+
}) as Promise<ResponseSpec & { trustedApplications: TrustedApplication[] }>,
|
|
64
|
+
});
|
package/src/backend.ts
CHANGED
|
@@ -12,6 +12,7 @@ import analysis from './backend/analysis';
|
|
|
12
12
|
import completionConfig from './backend/completionConfig';
|
|
13
13
|
import badge from './backend/badge';
|
|
14
14
|
import tenant from './backend/tenant';
|
|
15
|
+
import trustedApplication from './backend/trustedApplication';
|
|
15
16
|
|
|
16
17
|
const backendAPI = (apiUrl: string) => ({
|
|
17
18
|
asset: asset(apiUrl),
|
|
@@ -28,6 +29,7 @@ const backendAPI = (apiUrl: string) => ({
|
|
|
28
29
|
completionConfig: completionConfig(apiUrl),
|
|
29
30
|
badge: badge(apiUrl),
|
|
30
31
|
tenant: tenant(apiUrl),
|
|
32
|
+
trustedApplication: trustedApplication(apiUrl),
|
|
31
33
|
...asset(apiUrl),
|
|
32
34
|
...memori(apiUrl),
|
|
33
35
|
...user(apiUrl),
|
|
@@ -42,6 +44,7 @@ const backendAPI = (apiUrl: string) => ({
|
|
|
42
44
|
...completionConfig(apiUrl),
|
|
43
45
|
...badge(apiUrl),
|
|
44
46
|
...tenant(apiUrl),
|
|
47
|
+
...trustedApplication(apiUrl),
|
|
45
48
|
});
|
|
46
49
|
|
|
47
50
|
export default backendAPI;
|
package/src/engine/chatLogs.ts
CHANGED
|
@@ -29,6 +29,33 @@ export default (apiUrl: string) => ({
|
|
|
29
29
|
}
|
|
30
30
|
>,
|
|
31
31
|
|
|
32
|
+
/**
|
|
33
|
+
* Gets paginated Chat Log objects for the Memori of the current session in a specific date interval.
|
|
34
|
+
* @param {string} sessionId The session ID
|
|
35
|
+
* @param {string} dateFrom The begin of the date interval, in UTC time, in the format yyyyMMddHHmmssfff
|
|
36
|
+
* @param {string} dateTo The end of the date interval, in UTC time, in the format yyyyMMddHHmmssfff
|
|
37
|
+
* @param {number} from The starting index for pagination
|
|
38
|
+
* @param {number} howMany The number of items to retrieve
|
|
39
|
+
*/
|
|
40
|
+
getChatLogsPaged: async (
|
|
41
|
+
sessionId: string,
|
|
42
|
+
dateFrom: string,
|
|
43
|
+
dateTo: string,
|
|
44
|
+
from: number,
|
|
45
|
+
howMany: number
|
|
46
|
+
) =>
|
|
47
|
+
apiFetcher(
|
|
48
|
+
`/ChatLogsPaged/${sessionId}/${dateFrom}/${dateTo}/${from}/${howMany}`,
|
|
49
|
+
{
|
|
50
|
+
method: 'GET',
|
|
51
|
+
apiUrl,
|
|
52
|
+
}
|
|
53
|
+
) as Promise<
|
|
54
|
+
ResponseSpec & {
|
|
55
|
+
chatLogs: ChatLog[];
|
|
56
|
+
}
|
|
57
|
+
>,
|
|
58
|
+
|
|
32
59
|
/**
|
|
33
60
|
* Gets the Chat Log objects for the Memori of the current session created by the current User.
|
|
34
61
|
* @param {string} sessionId The session ID
|
package/src/types.ts
CHANGED
|
@@ -1934,3 +1934,17 @@ export declare type MacroFunction = {
|
|
|
1934
1934
|
obfuscated?: boolean;
|
|
1935
1935
|
}[];
|
|
1936
1936
|
};
|
|
1937
|
+
|
|
1938
|
+
export declare type TrustedApplication = {
|
|
1939
|
+
trustedApplicationID: string;
|
|
1940
|
+
tenantID: string;
|
|
1941
|
+
name: string;
|
|
1942
|
+
description: string;
|
|
1943
|
+
baseUrl: string;
|
|
1944
|
+
authorizationToken: string;
|
|
1945
|
+
isEnabled: boolean;
|
|
1946
|
+
createdByUserID: string;
|
|
1947
|
+
lastModifiedByUserID: string;
|
|
1948
|
+
creationTimestamp: string;
|
|
1949
|
+
lastChangeTimestamp: string;
|
|
1950
|
+
};
|