@or-sdk/idw 2.2.0-beta.1694.0 → 3.1.0-beta.1698.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.
Files changed (68) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/dist/cjs/api/channelApi.js +8 -8
  3. package/dist/cjs/api/flowApi.js +7 -7
  4. package/dist/cjs/api/idwDbApi.js +3 -3
  5. package/dist/cjs/api/idwInfoApi.js +4 -4
  6. package/dist/cjs/api/idwRwcApi.js +6 -6
  7. package/dist/cjs/api/index.js +3 -1
  8. package/dist/cjs/api/index.js.map +1 -1
  9. package/dist/cjs/api/memoryApi.js +57 -0
  10. package/dist/cjs/api/memoryApi.js.map +1 -0
  11. package/dist/cjs/api/migrationApi.js +4 -4
  12. package/dist/cjs/api/skillApi.js +7 -7
  13. package/dist/cjs/{helpres.js → helpers.js} +1 -1
  14. package/dist/cjs/helpers.js.map +1 -0
  15. package/dist/cjs/idwApi.js +1 -0
  16. package/dist/cjs/idwApi.js.map +1 -1
  17. package/dist/cjs/types/index.js +1 -0
  18. package/dist/cjs/types/index.js.map +1 -1
  19. package/dist/cjs/types/memory.js +3 -0
  20. package/dist/cjs/types/memory.js.map +1 -0
  21. package/dist/esm/api/channelApi.js +1 -1
  22. package/dist/esm/api/flowApi.js +1 -1
  23. package/dist/esm/api/idwDbApi.js +1 -1
  24. package/dist/esm/api/idwInfoApi.js +1 -1
  25. package/dist/esm/api/idwRwcApi.js +1 -1
  26. package/dist/esm/api/index.js +1 -0
  27. package/dist/esm/api/index.js.map +1 -1
  28. package/dist/esm/api/memoryApi.js +52 -0
  29. package/dist/esm/api/memoryApi.js.map +1 -0
  30. package/dist/esm/api/migrationApi.js +1 -1
  31. package/dist/esm/api/skillApi.js +1 -1
  32. package/dist/esm/{helpres.js → helpers.js} +1 -1
  33. package/dist/esm/helpers.js.map +1 -0
  34. package/dist/esm/idwApi.js +2 -1
  35. package/dist/esm/idwApi.js.map +1 -1
  36. package/dist/esm/types/index.js +1 -0
  37. package/dist/esm/types/index.js.map +1 -1
  38. package/dist/esm/types/memory.js +2 -0
  39. package/dist/esm/types/memory.js.map +1 -0
  40. package/dist/types/api/index.d.ts +1 -0
  41. package/dist/types/api/index.d.ts.map +1 -1
  42. package/dist/types/api/memoryApi.d.ts +13 -0
  43. package/dist/types/api/memoryApi.d.ts.map +1 -0
  44. package/dist/types/{helpres.d.ts → helpers.d.ts} +1 -1
  45. package/dist/types/helpers.d.ts.map +1 -0
  46. package/dist/types/idwApi.d.ts +2 -1
  47. package/dist/types/idwApi.d.ts.map +1 -1
  48. package/dist/types/types/index.d.ts +1 -0
  49. package/dist/types/types/index.d.ts.map +1 -1
  50. package/dist/types/types/memory.d.ts +6 -0
  51. package/dist/types/types/memory.d.ts.map +1 -0
  52. package/package.json +3 -3
  53. package/src/api/channelApi.ts +1 -1
  54. package/src/api/flowApi.ts +1 -1
  55. package/src/api/idwDbApi.ts +1 -1
  56. package/src/api/idwInfoApi.ts +1 -1
  57. package/src/api/idwRwcApi.ts +1 -1
  58. package/src/api/index.ts +1 -0
  59. package/src/api/memoryApi.ts +83 -0
  60. package/src/api/migrationApi.ts +1 -1
  61. package/src/api/skillApi.ts +1 -1
  62. package/src/idwApi.ts +4 -1
  63. package/src/types/index.ts +1 -0
  64. package/src/types/memory.ts +6 -0
  65. package/dist/cjs/helpres.js.map +0 -1
  66. package/dist/esm/helpres.js.map +0 -1
  67. package/dist/types/helpres.d.ts.map +0 -1
  68. /package/src/{helpres.ts → helpers.ts} +0 -0
package/CHANGELOG.md CHANGED
@@ -3,6 +3,19 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [3.0.0](https://gitlab.internal.onereach.io/onereach/platform/or-sdk-next/compare/@or-sdk/idw@2.1.0...@or-sdk/idw@3.0.0) (2023-08-01)
7
+
8
+
9
+ ### ⚠ BREAKING CHANGES
10
+
11
+ * **@or-sdk/idw:** implement-channels-api
12
+
13
+ ### Features
14
+
15
+ * **@or-sdk/idw:** implement-channels-api ([73c7129](https://gitlab.internal.onereach.io/onereach/platform/or-sdk-next/commit/73c71298cd0bac62f318a49bfaa14f6593a66991))
16
+
17
+
18
+
6
19
  ## [2.1.0](https://gitlab.internal.onereach.io/onereach/platform/or-sdk-next/compare/@or-sdk/idw@2.0.12...@or-sdk/idw@2.1.0) (2023-08-01)
7
20
 
8
21
 
@@ -1,14 +1,14 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ChannelApi = void 0;
4
- var helpres_1 = require("../helpres");
4
+ var helpers_1 = require("../helpers");
5
5
  var ChannelApi = (function () {
6
6
  function ChannelApi(providers) {
7
7
  this.providers = providers;
8
8
  }
9
9
  ChannelApi.prototype.getChannel = function (id) {
10
10
  return this.providers.makeRequest({
11
- route: (0, helpres_1.buildRoute)('channel'),
11
+ route: (0, helpers_1.buildRoute)('channel'),
12
12
  params: {
13
13
  id: id,
14
14
  },
@@ -16,12 +16,12 @@ var ChannelApi = (function () {
16
16
  };
17
17
  ChannelApi.prototype.getAllChannels = function () {
18
18
  return this.providers.makeRequest({
19
- route: (0, helpres_1.buildRoute)('channels'),
19
+ route: (0, helpers_1.buildRoute)('channels'),
20
20
  });
21
21
  };
22
22
  ChannelApi.prototype.deleteChannel = function (id) {
23
23
  return this.providers.makeRequest({
24
- route: (0, helpres_1.buildRoute)('channel'),
24
+ route: (0, helpers_1.buildRoute)('channel'),
25
25
  method: 'DELETE',
26
26
  params: {
27
27
  id: id,
@@ -30,13 +30,13 @@ var ChannelApi = (function () {
30
30
  };
31
31
  ChannelApi.prototype.deleteAllChannels = function () {
32
32
  return this.providers.makeRequest({
33
- route: (0, helpres_1.buildRoute)('channels'),
33
+ route: (0, helpers_1.buildRoute)('channels'),
34
34
  method: 'DELETE',
35
35
  });
36
36
  };
37
37
  ChannelApi.prototype.updateChannel = function (id, data) {
38
38
  return this.providers.makeRequest({
39
- route: (0, helpres_1.buildRoute)('channel'),
39
+ route: (0, helpers_1.buildRoute)('channel'),
40
40
  method: 'PATCH',
41
41
  data: data,
42
42
  params: {
@@ -46,14 +46,14 @@ var ChannelApi = (function () {
46
46
  };
47
47
  ChannelApi.prototype.createChannel = function (data) {
48
48
  return this.providers.makeRequest({
49
- route: (0, helpres_1.buildRoute)('channel'),
49
+ route: (0, helpers_1.buildRoute)('channel'),
50
50
  method: 'POST',
51
51
  data: data,
52
52
  });
53
53
  };
54
54
  ChannelApi.prototype.getSuggestedChannels = function () {
55
55
  return this.providers.makeRequest({
56
- route: (0, helpres_1.buildRoute)('channels/suggested'),
56
+ route: (0, helpers_1.buildRoute)('channels/suggested'),
57
57
  });
58
58
  };
59
59
  return ChannelApi;
@@ -1,14 +1,14 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.FlowApi = void 0;
4
- var helpres_1 = require("../helpres");
4
+ var helpers_1 = require("../helpers");
5
5
  var FlowApi = (function () {
6
6
  function FlowApi(providers) {
7
7
  this.providers = providers;
8
8
  }
9
9
  FlowApi.prototype.getFlow = function (id) {
10
10
  return this.providers.makeRequest({
11
- route: (0, helpres_1.buildRoute)('flow'),
11
+ route: (0, helpers_1.buildRoute)('flow'),
12
12
  params: {
13
13
  id: id,
14
14
  },
@@ -16,7 +16,7 @@ var FlowApi = (function () {
16
16
  };
17
17
  FlowApi.prototype.deleteFlow = function (id) {
18
18
  return this.providers.makeRequest({
19
- route: (0, helpres_1.buildRoute)('flow'),
19
+ route: (0, helpers_1.buildRoute)('flow'),
20
20
  method: 'DELETE',
21
21
  params: {
22
22
  id: id,
@@ -25,7 +25,7 @@ var FlowApi = (function () {
25
25
  };
26
26
  FlowApi.prototype.deleteFlows = function (ids) {
27
27
  return this.providers.makeRequest({
28
- route: (0, helpres_1.buildRoute)('flows'),
28
+ route: (0, helpers_1.buildRoute)('flows'),
29
29
  method: 'DELETE',
30
30
  params: {
31
31
  ids: ids.join(),
@@ -34,21 +34,21 @@ var FlowApi = (function () {
34
34
  };
35
35
  FlowApi.prototype.upsert = function (data) {
36
36
  return this.providers.makeRequest({
37
- route: (0, helpres_1.buildRoute)('flow'),
37
+ route: (0, helpers_1.buildRoute)('flow'),
38
38
  method: 'POST',
39
39
  data: data,
40
40
  });
41
41
  };
42
42
  FlowApi.prototype.activateFlow = function (data) {
43
43
  return this.providers.makeRequest({
44
- route: (0, helpres_1.buildRoute)('flow/activate'),
44
+ route: (0, helpers_1.buildRoute)('flow/activate'),
45
45
  method: 'PUT',
46
46
  data: data,
47
47
  });
48
48
  };
49
49
  FlowApi.prototype.deactivateFlow = function (id) {
50
50
  return this.providers.makeRequest({
51
- route: (0, helpres_1.buildRoute)('flow/deactivate'),
51
+ route: (0, helpers_1.buildRoute)('flow/deactivate'),
52
52
  method: 'PUT',
53
53
  params: {
54
54
  id: id,
@@ -1,20 +1,20 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.IdwDbApi = void 0;
4
- var helpres_1 = require("../helpres");
4
+ var helpers_1 = require("../helpers");
5
5
  var IdwDbApi = (function () {
6
6
  function IdwDbApi(providers) {
7
7
  this.providers = providers;
8
8
  }
9
9
  IdwDbApi.prototype.isDbExist = function () {
10
10
  return this.providers.makeRequest({
11
- route: (0, helpres_1.buildRoute)('db'),
11
+ route: (0, helpers_1.buildRoute)('db'),
12
12
  method: 'GET',
13
13
  });
14
14
  };
15
15
  IdwDbApi.prototype.prepareDb = function () {
16
16
  return this.providers.makeRequest({
17
- route: (0, helpres_1.buildRoute)('db'),
17
+ route: (0, helpers_1.buildRoute)('db'),
18
18
  method: 'POST',
19
19
  });
20
20
  };
@@ -1,26 +1,26 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.IdwInfoApi = void 0;
4
- var helpres_1 = require("../helpres");
4
+ var helpers_1 = require("../helpers");
5
5
  var IdwInfoApi = (function () {
6
6
  function IdwInfoApi(providers) {
7
7
  this.providers = providers;
8
8
  }
9
9
  IdwInfoApi.prototype.getBaseInfo = function () {
10
10
  return this.providers.makeRequest({
11
- route: (0, helpres_1.buildRoute)('idw-info'),
11
+ route: (0, helpers_1.buildRoute)('idw-info'),
12
12
  method: 'GET',
13
13
  });
14
14
  };
15
15
  IdwInfoApi.prototype.getIdwInfoWithStatistic = function () {
16
16
  return this.providers.makeRequest({
17
- route: (0, helpres_1.buildRoute)('idw-info/statistic'),
17
+ route: (0, helpers_1.buildRoute)('idw-info/statistic'),
18
18
  method: 'GET',
19
19
  });
20
20
  };
21
21
  IdwInfoApi.prototype.updateIdwInfo = function (data) {
22
22
  return this.providers.makeRequest({
23
- route: (0, helpres_1.buildRoute)('idw-info'),
23
+ route: (0, helpers_1.buildRoute)('idw-info'),
24
24
  method: 'POST',
25
25
  data: data,
26
26
  });
@@ -37,7 +37,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
37
37
  };
38
38
  Object.defineProperty(exports, "__esModule", { value: true });
39
39
  exports.IdwRwcApi = void 0;
40
- var helpres_1 = require("../helpres");
40
+ var helpers_1 = require("../helpers");
41
41
  var noop = function () { };
42
42
  var IdwRwcApi = (function () {
43
43
  function IdwRwcApi(providers) {
@@ -45,32 +45,32 @@ var IdwRwcApi = (function () {
45
45
  }
46
46
  IdwRwcApi.prototype.getIdwRwcData = function () {
47
47
  return this.providers.makeRequest({
48
- route: (0, helpres_1.buildRoute)('idw-rwc'),
48
+ route: (0, helpers_1.buildRoute)('idw-rwc'),
49
49
  method: 'GET',
50
50
  });
51
51
  };
52
52
  IdwRwcApi.prototype.upsertIdwRwcData = function (data) {
53
53
  return this.providers.makeRequest({
54
- route: (0, helpres_1.buildRoute)('idw-rwc'),
54
+ route: (0, helpers_1.buildRoute)('idw-rwc'),
55
55
  method: 'GET',
56
56
  data: data,
57
57
  });
58
58
  };
59
59
  IdwRwcApi.prototype.deleteIdwRwcData = function () {
60
60
  return this.providers.makeRequest({
61
- route: (0, helpres_1.buildRoute)('idw-rwc'),
61
+ route: (0, helpers_1.buildRoute)('idw-rwc'),
62
62
  method: 'DELETE',
63
63
  });
64
64
  };
65
65
  IdwRwcApi.prototype.installRwcChat = function () {
66
66
  return this.providers.makeRequest({
67
- route: (0, helpres_1.buildRoute)('idw-rwc/install'),
67
+ route: (0, helpers_1.buildRoute)('idw-rwc/install'),
68
68
  method: 'POST',
69
69
  });
70
70
  };
71
71
  IdwRwcApi.prototype.getChatStatus = function () {
72
72
  return this.providers.makeRequest({
73
- route: (0, helpres_1.buildRoute)('idw-rwc/install'),
73
+ route: (0, helpers_1.buildRoute)('idw-rwc/install'),
74
74
  method: 'GET',
75
75
  });
76
76
  };
@@ -1,8 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.FlowApi = exports.IdwRwcApi = exports.IdwDbApi = exports.IdwInfoApi = exports.MigrationApi = exports.ChannelApi = exports.SkillApi = void 0;
3
+ exports.FlowApi = exports.IdwRwcApi = exports.IdwDbApi = exports.IdwInfoApi = exports.MigrationApi = exports.ChannelApi = exports.MemoryApi = exports.SkillApi = void 0;
4
4
  var skillApi_1 = require("./skillApi");
5
5
  Object.defineProperty(exports, "SkillApi", { enumerable: true, get: function () { return skillApi_1.SkillApi; } });
6
+ var memoryApi_1 = require("./memoryApi");
7
+ Object.defineProperty(exports, "MemoryApi", { enumerable: true, get: function () { return memoryApi_1.MemoryApi; } });
6
8
  var channelApi_1 = require("./channelApi");
7
9
  Object.defineProperty(exports, "ChannelApi", { enumerable: true, get: function () { return channelApi_1.ChannelApi; } });
8
10
  var migrationApi_1 = require("./migrationApi");
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/api/index.ts"],"names":[],"mappings":";;;AAAA,uCAAsC;AAA7B,oGAAA,QAAQ,OAAA;AACjB,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,+CAA8C;AAArC,4GAAA,YAAY,OAAA;AACrB,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,uCAAsC;AAA7B,oGAAA,QAAQ,OAAA;AACjB,yCAAwC;AAA/B,sGAAA,SAAS,OAAA;AAClB,qCAAoC;AAA3B,kGAAA,OAAO,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/api/index.ts"],"names":[],"mappings":";;;AAAA,uCAAsC;AAA7B,oGAAA,QAAQ,OAAA;AACjB,yCAAwC;AAA/B,sGAAA,SAAS,OAAA;AAClB,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,+CAA8C;AAArC,4GAAA,YAAY,OAAA;AACrB,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,uCAAsC;AAA7B,oGAAA,QAAQ,OAAA;AACjB,yCAAwC;AAA/B,sGAAA,SAAS,OAAA;AAClB,qCAAoC;AAA3B,kGAAA,OAAO,OAAA"}
@@ -0,0 +1,57 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.MemoryApi = void 0;
4
+ var helpers_1 = require("../helpers");
5
+ var MemoryApi = (function () {
6
+ function MemoryApi(providers) {
7
+ this.providers = providers;
8
+ }
9
+ MemoryApi.prototype.getMemory = function (id) {
10
+ return this.providers.makeRequest({
11
+ route: (0, helpers_1.buildRoute)('memory'),
12
+ params: {
13
+ id: id,
14
+ },
15
+ });
16
+ };
17
+ MemoryApi.prototype.getAllMemories = function () {
18
+ return this.providers.makeRequest({
19
+ route: (0, helpers_1.buildRoute)('memories'),
20
+ });
21
+ };
22
+ MemoryApi.prototype.deleteMemory = function (id) {
23
+ return this.providers.makeRequest({
24
+ route: (0, helpers_1.buildRoute)('memory'),
25
+ method: 'DELETE',
26
+ params: {
27
+ id: id,
28
+ },
29
+ });
30
+ };
31
+ MemoryApi.prototype.deleteAllMemories = function () {
32
+ return this.providers.makeRequest({
33
+ route: (0, helpers_1.buildRoute)('memories'),
34
+ method: 'DELETE',
35
+ });
36
+ };
37
+ MemoryApi.prototype.updateMemory = function (id, data) {
38
+ return this.providers.makeRequest({
39
+ route: (0, helpers_1.buildRoute)('memory'),
40
+ method: 'PATCH',
41
+ data: data,
42
+ params: {
43
+ id: id,
44
+ },
45
+ });
46
+ };
47
+ MemoryApi.prototype.createMemory = function (data) {
48
+ return this.providers.makeRequest({
49
+ route: (0, helpers_1.buildRoute)('memory'),
50
+ method: 'POST',
51
+ data: data,
52
+ });
53
+ };
54
+ return MemoryApi;
55
+ }());
56
+ exports.MemoryApi = MemoryApi;
57
+ //# sourceMappingURL=memoryApi.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"memoryApi.js","sourceRoot":"","sources":["../../../src/api/memoryApi.ts"],"names":[],"mappings":";;;AAEA,sCAAwC;AAExC;IACE,mBACmB,SAAoB;QAApB,cAAS,GAAT,SAAS,CAAW;IACpC,CAAC;IAMJ,6BAAS,GAAT,UAAU,EAAU;QAClB,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,IAAA,oBAAU,EAAC,QAAQ,CAAC;YAC3B,MAAM,EAAE;gBACN,EAAE,IAAA;aACH;SACF,CAAC,CAAC;IACL,CAAC;IAKD,kCAAc,GAAd;QACE,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,IAAA,oBAAU,EAAC,UAAU,CAAC;SAC9B,CAAC,CAAC;IACL,CAAC;IAMD,gCAAY,GAAZ,UAAa,EAAU;QACrB,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,IAAA,oBAAU,EAAC,QAAQ,CAAC;YAC3B,MAAM,EAAE,QAAQ;YAChB,MAAM,EAAE;gBACN,EAAE,IAAA;aACH;SACF,CAAC,CAAC;IACL,CAAC;IAKD,qCAAiB,GAAjB;QACE,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,IAAA,oBAAU,EAAC,UAAU,CAAC;YAC7B,MAAM,EAAE,QAAQ;SACjB,CAAC,CAAC;IACL,CAAC;IAOD,gCAAY,GAAZ,UAAa,EAAU,EAAE,IAAsB;QAC7C,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,IAAA,oBAAU,EAAC,QAAQ,CAAC;YAC3B,MAAM,EAAE,OAAO;YACf,IAAI,MAAA;YACJ,MAAM,EAAE;gBACN,EAAE,IAAA;aACH;SACF,CAAC,CAAC;IACL,CAAC;IAMD,gCAAY,GAAZ,UAAa,IAAsB;QACjC,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,IAAA,oBAAU,EAAC,QAAQ,CAAC;YAC3B,MAAM,EAAE,MAAM;YACd,IAAI,MAAA;SACL,CAAC,CAAC;IACL,CAAC;IACH,gBAAC;AAAD,CAAC,AA9ED,IA8EC;AA9EY,8BAAS"}
@@ -1,26 +1,26 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.MigrationApi = void 0;
4
- var helpres_1 = require("../helpres");
4
+ var helpers_1 = require("../helpers");
5
5
  var MigrationApi = (function () {
6
6
  function MigrationApi(providers) {
7
7
  this.providers = providers;
8
8
  }
9
9
  MigrationApi.prototype.migrationsStatus = function () {
10
10
  return this.providers.makeRequest({
11
- route: (0, helpres_1.buildRoute)('migration'),
11
+ route: (0, helpers_1.buildRoute)('migration'),
12
12
  method: 'GET',
13
13
  });
14
14
  };
15
15
  MigrationApi.prototype.migrationsRun = function () {
16
16
  return this.providers.makeRequest({
17
- route: (0, helpres_1.buildRoute)('migration'),
17
+ route: (0, helpers_1.buildRoute)('migration'),
18
18
  method: 'POST',
19
19
  });
20
20
  };
21
21
  MigrationApi.prototype.revertLatest = function () {
22
22
  return this.providers.makeRequest({
23
- route: (0, helpres_1.buildRoute)('migration'),
23
+ route: (0, helpers_1.buildRoute)('migration'),
24
24
  method: 'DELETE',
25
25
  });
26
26
  };
@@ -1,14 +1,14 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SkillApi = void 0;
4
- var helpres_1 = require("../helpres");
4
+ var helpers_1 = require("../helpers");
5
5
  var SkillApi = (function () {
6
6
  function SkillApi(providers) {
7
7
  this.providers = providers;
8
8
  }
9
9
  SkillApi.prototype.getSkill = function (id) {
10
10
  return this.providers.makeRequest({
11
- route: (0, helpres_1.buildRoute)('skill'),
11
+ route: (0, helpers_1.buildRoute)('skill'),
12
12
  params: {
13
13
  id: id,
14
14
  },
@@ -16,12 +16,12 @@ var SkillApi = (function () {
16
16
  };
17
17
  SkillApi.prototype.getAllSkills = function () {
18
18
  return this.providers.makeRequest({
19
- route: (0, helpres_1.buildRoute)('skills'),
19
+ route: (0, helpers_1.buildRoute)('skills'),
20
20
  });
21
21
  };
22
22
  SkillApi.prototype.deleteSkill = function (id) {
23
23
  return this.providers.makeRequest({
24
- route: (0, helpres_1.buildRoute)('skill'),
24
+ route: (0, helpers_1.buildRoute)('skill'),
25
25
  method: 'DELETE',
26
26
  params: {
27
27
  id: id,
@@ -30,13 +30,13 @@ var SkillApi = (function () {
30
30
  };
31
31
  SkillApi.prototype.deleteAllSkills = function () {
32
32
  return this.providers.makeRequest({
33
- route: (0, helpres_1.buildRoute)('skills'),
33
+ route: (0, helpers_1.buildRoute)('skills'),
34
34
  method: 'DELETE',
35
35
  });
36
36
  };
37
37
  SkillApi.prototype.updateSkill = function (id, data) {
38
38
  return this.providers.makeRequest({
39
- route: (0, helpres_1.buildRoute)('skill'),
39
+ route: (0, helpers_1.buildRoute)('skill'),
40
40
  method: 'PATCH',
41
41
  data: data,
42
42
  params: {
@@ -46,7 +46,7 @@ var SkillApi = (function () {
46
46
  };
47
47
  SkillApi.prototype.createSkill = function (data) {
48
48
  return this.providers.makeRequest({
49
- route: (0, helpres_1.buildRoute)('skill'),
49
+ route: (0, helpers_1.buildRoute)('skill'),
50
50
  method: 'POST',
51
51
  data: data,
52
52
  });
@@ -4,4 +4,4 @@ exports.buildRoute = void 0;
4
4
  var constants_1 = require("./constants");
5
5
  var buildRoute = function (route) { return "".concat(constants_1.IDW_PROVIDER_NAME_SPACE, "/").concat(route); };
6
6
  exports.buildRoute = buildRoute;
7
- //# sourceMappingURL=helpres.js.map
7
+ //# sourceMappingURL=helpers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../src/helpers.ts"],"names":[],"mappings":";;;AAAA,yCAAsD;AAE/C,IAAM,UAAU,GAAG,UAAC,KAAa,IAAa,OAAA,UAAG,mCAAuB,cAAI,KAAK,CAAE,EAArC,CAAqC,CAAC;AAA9E,QAAA,UAAU,cAAoE"}
@@ -13,6 +13,7 @@ var IdwApi = (function () {
13
13
  providersAccountId: providerAccountId,
14
14
  });
15
15
  this.skillApi = new api_1.SkillApi(provider);
16
+ this.memoryApi = new api_1.MemoryApi(provider);
16
17
  this.channelApi = new api_1.ChannelApi(provider);
17
18
  this.migrationApi = new api_1.MigrationApi(provider);
18
19
  this.idwInfoApi = new api_1.IdwInfoApi(provider);
@@ -1 +1 @@
1
- {"version":3,"file":"idwApi.js","sourceRoot":"","sources":["../../src/idwApi.ts"],"names":[],"mappings":";;;AACA,6BAA4F;AAC5F,+CAA8C;AAC9C,yCAAwC;AAExC;IAQE,gBAAY,EAAkD;YAAhD,iBAAiB,uBAAA,EAAE,KAAK,WAAA,EAAE,KAAK,WAAA;QAC3C,IAAM,QAAQ,GAAG,IAAI,qBAAS,CAAC;YAC7B,KAAK,OAAA;YACL,eAAe,EAAE,KAAK;YACtB,kBAAkB,EAAE,iBAAiB;SACtC,CAAC,CAAC;QAEH,IAAI,CAAC,QAAQ,GAAG,IAAI,cAAQ,CAAC,QAAQ,CAAC,CAAC;QACvC,IAAI,CAAC,UAAU,GAAG,IAAI,gBAAU,CAAC,QAAQ,CAAC,CAAC;QAC3C,IAAI,CAAC,YAAY,GAAG,IAAI,kBAAY,CAAC,QAAQ,CAAC,CAAC;QAC/C,IAAI,CAAC,UAAU,GAAG,IAAI,gBAAU,CAAC,QAAQ,CAAC,CAAC;QAC3C,IAAI,CAAC,QAAQ,GAAG,IAAI,cAAQ,CAAC,QAAQ,CAAC,CAAC;QACvC,IAAI,CAAC,SAAS,GAAG,IAAI,eAAS,CAAC,QAAQ,CAAC,CAAC;QACzC,IAAI,CAAC,OAAO,GAAG,IAAI,iBAAO,CAAC,QAAQ,CAAC,CAAC;IACvC,CAAC;IACH,aAAC;AAAD,CAAC,AAvBD,IAuBC;AAvBY,wBAAM"}
1
+ {"version":3,"file":"idwApi.js","sourceRoot":"","sources":["../../src/idwApi.ts"],"names":[],"mappings":";;;AAEA,6BAAuG;AACvG,+CAA8C;AAC9C,yCAAwC;AAExC;IASE,gBAAY,EAAkD;YAAhD,iBAAiB,uBAAA,EAAE,KAAK,WAAA,EAAE,KAAK,WAAA;QAC3C,IAAM,QAAQ,GAAG,IAAI,qBAAS,CAAC;YAC7B,KAAK,OAAA;YACL,eAAe,EAAE,KAAK;YACtB,kBAAkB,EAAE,iBAAiB;SACtC,CAAC,CAAC;QAEH,IAAI,CAAC,QAAQ,GAAG,IAAI,cAAQ,CAAC,QAAQ,CAAC,CAAC;QACvC,IAAI,CAAC,SAAS,GAAG,IAAI,eAAS,CAAC,QAAQ,CAAC,CAAC;QACzC,IAAI,CAAC,UAAU,GAAG,IAAI,gBAAU,CAAC,QAAQ,CAAC,CAAC;QAC3C,IAAI,CAAC,YAAY,GAAG,IAAI,kBAAY,CAAC,QAAQ,CAAC,CAAC;QAC/C,IAAI,CAAC,UAAU,GAAG,IAAI,gBAAU,CAAC,QAAQ,CAAC,CAAC;QAC3C,IAAI,CAAC,QAAQ,GAAG,IAAI,cAAQ,CAAC,QAAQ,CAAC,CAAC;QACvC,IAAI,CAAC,SAAS,GAAG,IAAI,eAAS,CAAC,QAAQ,CAAC,CAAC;QACzC,IAAI,CAAC,OAAO,GAAG,IAAI,iBAAO,CAAC,QAAQ,CAAC,CAAC;IACvC,CAAC;IACH,aAAC;AAAD,CAAC,AAzBD,IAyBC;AAzBY,wBAAM"}
@@ -19,6 +19,7 @@ __exportStar(require("./channel"), exports);
19
19
  __exportStar(require("./config"), exports);
20
20
  __exportStar(require("./common"), exports);
21
21
  __exportStar(require("./flow"), exports);
22
+ __exportStar(require("./memory"), exports);
22
23
  __exportStar(require("./idwInfo"), exports);
23
24
  __exportStar(require("./idwRwc"), exports);
24
25
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0CAAwB;AACxB,4CAA0B;AAC1B,2CAAyB;AACzB,2CAAyB;AACzB,yCAAuB;AACvB,4CAA0B;AAC1B,2CAAyB"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0CAAwB;AACxB,4CAA0B;AAC1B,2CAAyB;AACzB,2CAAyB;AACzB,yCAAuB;AACvB,2CAAyB;AACzB,4CAA0B;AAC1B,2CAAyB"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=memory.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"memory.js","sourceRoot":"","sources":["../../../src/types/memory.ts"],"names":[],"mappings":""}
@@ -1,4 +1,4 @@
1
- import { buildRoute } from '../helpres';
1
+ import { buildRoute } from '../helpers';
2
2
  export class ChannelApi {
3
3
  constructor(providers) {
4
4
  this.providers = providers;
@@ -1,4 +1,4 @@
1
- import { buildRoute } from '../helpres';
1
+ import { buildRoute } from '../helpers';
2
2
  export class FlowApi {
3
3
  constructor(providers) {
4
4
  this.providers = providers;
@@ -1,4 +1,4 @@
1
- import { buildRoute } from '../helpres';
1
+ import { buildRoute } from '../helpers';
2
2
  export class IdwDbApi {
3
3
  constructor(providers) {
4
4
  this.providers = providers;
@@ -1,4 +1,4 @@
1
- import { buildRoute } from '../helpres';
1
+ import { buildRoute } from '../helpers';
2
2
  export class IdwInfoApi {
3
3
  constructor(providers) {
4
4
  this.providers = providers;
@@ -7,7 +7,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
7
7
  step((generator = generator.apply(thisArg, _arguments || [])).next());
8
8
  });
9
9
  };
10
- import { buildRoute } from '../helpres';
10
+ import { buildRoute } from '../helpers';
11
11
  const noop = () => { };
12
12
  export class IdwRwcApi {
13
13
  constructor(providers) {
@@ -1,4 +1,5 @@
1
1
  export { SkillApi } from './skillApi';
2
+ export { MemoryApi } from './memoryApi';
2
3
  export { ChannelApi } from './channelApi';
3
4
  export { MigrationApi } from './migrationApi';
4
5
  export { IdwInfoApi } from './idwInfoApi';
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/api/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/api/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC"}
@@ -0,0 +1,52 @@
1
+ import { buildRoute } from '../helpers';
2
+ export class MemoryApi {
3
+ constructor(providers) {
4
+ this.providers = providers;
5
+ }
6
+ getMemory(id) {
7
+ return this.providers.makeRequest({
8
+ route: buildRoute('memory'),
9
+ params: {
10
+ id,
11
+ },
12
+ });
13
+ }
14
+ getAllMemories() {
15
+ return this.providers.makeRequest({
16
+ route: buildRoute('memories'),
17
+ });
18
+ }
19
+ deleteMemory(id) {
20
+ return this.providers.makeRequest({
21
+ route: buildRoute('memory'),
22
+ method: 'DELETE',
23
+ params: {
24
+ id,
25
+ },
26
+ });
27
+ }
28
+ deleteAllMemories() {
29
+ return this.providers.makeRequest({
30
+ route: buildRoute('memories'),
31
+ method: 'DELETE',
32
+ });
33
+ }
34
+ updateMemory(id, data) {
35
+ return this.providers.makeRequest({
36
+ route: buildRoute('memory'),
37
+ method: 'PATCH',
38
+ data,
39
+ params: {
40
+ id,
41
+ },
42
+ });
43
+ }
44
+ createMemory(data) {
45
+ return this.providers.makeRequest({
46
+ route: buildRoute('memory'),
47
+ method: 'POST',
48
+ data,
49
+ });
50
+ }
51
+ }
52
+ //# sourceMappingURL=memoryApi.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"memoryApi.js","sourceRoot":"","sources":["../../../src/api/memoryApi.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAExC,MAAM,OAAO,SAAS;IACpB,YACmB,SAAoB;QAApB,cAAS,GAAT,SAAS,CAAW;IACpC,CAAC;IAMJ,SAAS,CAAC,EAAU;QAClB,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,UAAU,CAAC,QAAQ,CAAC;YAC3B,MAAM,EAAE;gBACN,EAAE;aACH;SACF,CAAC,CAAC;IACL,CAAC;IAKD,cAAc;QACZ,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,UAAU,CAAC,UAAU,CAAC;SAC9B,CAAC,CAAC;IACL,CAAC;IAMD,YAAY,CAAC,EAAU;QACrB,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,UAAU,CAAC,QAAQ,CAAC;YAC3B,MAAM,EAAE,QAAQ;YAChB,MAAM,EAAE;gBACN,EAAE;aACH;SACF,CAAC,CAAC;IACL,CAAC;IAKD,iBAAiB;QACf,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,UAAU,CAAC,UAAU,CAAC;YAC7B,MAAM,EAAE,QAAQ;SACjB,CAAC,CAAC;IACL,CAAC;IAOD,YAAY,CAAC,EAAU,EAAE,IAAsB;QAC7C,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,UAAU,CAAC,QAAQ,CAAC;YAC3B,MAAM,EAAE,OAAO;YACf,IAAI;YACJ,MAAM,EAAE;gBACN,EAAE;aACH;SACF,CAAC,CAAC;IACL,CAAC;IAMD,YAAY,CAAC,IAAsB;QACjC,OAAO,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;YAChC,KAAK,EAAE,UAAU,CAAC,QAAQ,CAAC;YAC3B,MAAM,EAAE,MAAM;YACd,IAAI;SACL,CAAC,CAAC;IACL,CAAC;CACF"}
@@ -1,4 +1,4 @@
1
- import { buildRoute } from '../helpres';
1
+ import { buildRoute } from '../helpers';
2
2
  export class MigrationApi {
3
3
  constructor(providers) {
4
4
  this.providers = providers;
@@ -1,4 +1,4 @@
1
- import { buildRoute } from '../helpres';
1
+ import { buildRoute } from '../helpers';
2
2
  export class SkillApi {
3
3
  constructor(providers) {
4
4
  this.providers = providers;
@@ -1,3 +1,3 @@
1
1
  import { IDW_PROVIDER_NAME_SPACE } from './constants';
2
2
  export const buildRoute = (route) => `${IDW_PROVIDER_NAME_SPACE}/${route}`;
3
- //# sourceMappingURL=helpres.js.map
3
+ //# sourceMappingURL=helpers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../src/helpers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,aAAa,CAAC;AAEtD,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,KAAa,EAAU,EAAE,CAAC,GAAG,uBAAuB,IAAI,KAAK,EAAE,CAAC"}
@@ -1,4 +1,4 @@
1
- import { IdwDbApi, IdwInfoApi, IdwRwcApi, MigrationApi, SkillApi, ChannelApi } from './api';
1
+ import { IdwDbApi, IdwInfoApi, IdwRwcApi, MigrationApi, SkillApi, MemoryApi, ChannelApi } from './api';
2
2
  import { Providers } from '@or-sdk/providers';
3
3
  import { FlowApi } from './api/flowApi';
4
4
  export class IdwApi {
@@ -9,6 +9,7 @@ export class IdwApi {
9
9
  providersAccountId: providerAccountId,
10
10
  });
11
11
  this.skillApi = new SkillApi(provider);
12
+ this.memoryApi = new MemoryApi(provider);
12
13
  this.channelApi = new ChannelApi(provider);
13
14
  this.migrationApi = new MigrationApi(provider);
14
15
  this.idwInfoApi = new IdwInfoApi(provider);
@@ -1 +1 @@
1
- {"version":3,"file":"idwApi.js","sourceRoot":"","sources":["../../src/idwApi.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAC5F,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAExC,MAAM,OAAO,MAAM;IAQjB,YAAY,EAAE,iBAAiB,EAAE,KAAK,EAAE,KAAK,EAAiB;QAC5D,MAAM,QAAQ,GAAG,IAAI,SAAS,CAAC;YAC7B,KAAK;YACL,eAAe,EAAE,KAAK;YACtB,kBAAkB,EAAE,iBAAiB;SACtC,CAAC,CAAC;QAEH,IAAI,CAAC,QAAQ,GAAG,IAAI,QAAQ,CAAC,QAAQ,CAAC,CAAC;QACvC,IAAI,CAAC,UAAU,GAAG,IAAI,UAAU,CAAC,QAAQ,CAAC,CAAC;QAC3C,IAAI,CAAC,YAAY,GAAG,IAAI,YAAY,CAAC,QAAQ,CAAC,CAAC;QAC/C,IAAI,CAAC,UAAU,GAAG,IAAI,UAAU,CAAC,QAAQ,CAAC,CAAC;QAC3C,IAAI,CAAC,QAAQ,GAAG,IAAI,QAAQ,CAAC,QAAQ,CAAC,CAAC;QACvC,IAAI,CAAC,SAAS,GAAG,IAAI,SAAS,CAAC,QAAQ,CAAC,CAAC;QACzC,IAAI,CAAC,OAAO,GAAG,IAAI,OAAO,CAAC,QAAQ,CAAC,CAAC;IACvC,CAAC;CACF"}
1
+ {"version":3,"file":"idwApi.js","sourceRoot":"","sources":["../../src/idwApi.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,QAAQ,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AACvG,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAExC,MAAM,OAAO,MAAM;IASjB,YAAY,EAAE,iBAAiB,EAAE,KAAK,EAAE,KAAK,EAAiB;QAC5D,MAAM,QAAQ,GAAG,IAAI,SAAS,CAAC;YAC7B,KAAK;YACL,eAAe,EAAE,KAAK;YACtB,kBAAkB,EAAE,iBAAiB;SACtC,CAAC,CAAC;QAEH,IAAI,CAAC,QAAQ,GAAG,IAAI,QAAQ,CAAC,QAAQ,CAAC,CAAC;QACvC,IAAI,CAAC,SAAS,GAAG,IAAI,SAAS,CAAC,QAAQ,CAAC,CAAC;QACzC,IAAI,CAAC,UAAU,GAAG,IAAI,UAAU,CAAC,QAAQ,CAAC,CAAC;QAC3C,IAAI,CAAC,YAAY,GAAG,IAAI,YAAY,CAAC,QAAQ,CAAC,CAAC;QAC/C,IAAI,CAAC,UAAU,GAAG,IAAI,UAAU,CAAC,QAAQ,CAAC,CAAC;QAC3C,IAAI,CAAC,QAAQ,GAAG,IAAI,QAAQ,CAAC,QAAQ,CAAC,CAAC;QACvC,IAAI,CAAC,SAAS,GAAG,IAAI,SAAS,CAAC,QAAQ,CAAC,CAAC;QACzC,IAAI,CAAC,OAAO,GAAG,IAAI,OAAO,CAAC,QAAQ,CAAC,CAAC;IACvC,CAAC;CACF"}
@@ -3,6 +3,7 @@ export * from './channel';
3
3
  export * from './config';
4
4
  export * from './common';
5
5
  export * from './flow';
6
+ export * from './memory';
6
7
  export * from './idwInfo';
7
8
  export * from './idwRwc';
8
9
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=memory.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"memory.js","sourceRoot":"","sources":["../../../src/types/memory.ts"],"names":[],"mappings":""}
@@ -1,4 +1,5 @@
1
1
  export { SkillApi } from './skillApi';
2
+ export { MemoryApi } from './memoryApi';
2
3
  export { ChannelApi } from './channelApi';
3
4
  export { MigrationApi } from './migrationApi';
4
5
  export { IdwInfoApi } from './idwInfoApi';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { Providers } from '@or-sdk/providers';
2
+ import { ListMemories, Memory, MemoryCreateData, MemoryUpdateData } from '../types/memory';
3
+ export declare class MemoryApi {
4
+ private readonly providers;
5
+ constructor(providers: Providers);
6
+ getMemory(id: string): Promise<Memory>;
7
+ getAllMemories(): Promise<ListMemories>;
8
+ deleteMemory(id: string): Promise<void>;
9
+ deleteAllMemories(): Promise<void>;
10
+ updateMemory(id: string, data: MemoryUpdateData): Promise<Memory>;
11
+ createMemory(data: MemoryCreateData): Promise<Memory>;
12
+ }
13
+ //# sourceMappingURL=memoryApi.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"memoryApi.d.ts","sourceRoot":"","sources":["../../../src/api/memoryApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAG3F,qBAAa,SAAS;IAElB,OAAO,CAAC,QAAQ,CAAC,SAAS;gBAAT,SAAS,EAAE,SAAS;IAOvC,SAAS,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAYtC,cAAc,IAAI,OAAO,CAAC,YAAY,CAAC;IAUvC,YAAY,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAavC,iBAAiB,IAAI,OAAO,CAAC,IAAI,CAAC;IAYlC,YAAY,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,gBAAgB,GAAG,OAAO,CAAC,MAAM,CAAC;IAejE,YAAY,CAAC,IAAI,EAAE,gBAAgB,GAAG,OAAO,CAAC,MAAM,CAAC;CAOtD"}
@@ -1,2 +1,2 @@
1
1
  export declare const buildRoute: (route: string) => string;
2
- //# sourceMappingURL=helpres.d.ts.map
2
+ //# sourceMappingURL=helpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../src/helpers.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,UAAU,UAAW,MAAM,KAAG,MAA+C,CAAC"}
@@ -1,8 +1,9 @@
1
1
  import { IDWBaseConfig } from './types';
2
- import { IdwDbApi, IdwInfoApi, IdwRwcApi, MigrationApi, SkillApi, ChannelApi } from './api';
2
+ import { IdwDbApi, IdwInfoApi, IdwRwcApi, MigrationApi, SkillApi, MemoryApi, ChannelApi } from './api';
3
3
  import { FlowApi } from './api/flowApi';
4
4
  export declare class IdwApi {
5
5
  readonly skillApi: SkillApi;
6
+ readonly memoryApi: MemoryApi;
6
7
  readonly channelApi: ChannelApi;
7
8
  readonly migrationApi: MigrationApi;
8
9
  readonly idwInfoApi: IdwInfoApi;
@@ -1 +1 @@
1
- {"version":3,"file":"idwApi.d.ts","sourceRoot":"","sources":["../../src/idwApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACxC,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAE5F,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAExC,qBAAa,MAAM;IACjB,QAAQ,CAAC,QAAQ,EAAE,QAAQ,CAAC;IAC5B,QAAQ,CAAC,UAAU,EAAE,UAAU,CAAC;IAChC,QAAQ,CAAC,YAAY,EAAE,YAAY,CAAC;IACpC,QAAQ,CAAC,UAAU,EAAE,UAAU,CAAC;IAChC,QAAQ,CAAC,QAAQ,EAAE,QAAQ,CAAC;IAC5B,QAAQ,CAAC,SAAS,EAAE,SAAS,CAAC;IAC9B,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;gBACd,EAAE,iBAAiB,EAAE,KAAK,EAAE,KAAK,EAAE,EAAE,aAAa;CAe/D"}
1
+ {"version":3,"file":"idwApi.d.ts","sourceRoot":"","sources":["../../src/idwApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAExC,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,QAAQ,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAEvG,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAExC,qBAAa,MAAM;IACjB,QAAQ,CAAC,QAAQ,EAAE,QAAQ,CAAC;IAC5B,QAAQ,CAAC,SAAS,EAAE,SAAS,CAAC;IAC9B,QAAQ,CAAC,UAAU,EAAE,UAAU,CAAC;IAChC,QAAQ,CAAC,YAAY,EAAE,YAAY,CAAC;IACpC,QAAQ,CAAC,UAAU,EAAE,UAAU,CAAC;IAChC,QAAQ,CAAC,QAAQ,EAAE,QAAQ,CAAC;IAC5B,QAAQ,CAAC,SAAS,EAAE,SAAS,CAAC;IAC9B,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;gBACd,EAAE,iBAAiB,EAAE,KAAK,EAAE,KAAK,EAAE,EAAE,aAAa;CAgB/D"}
@@ -3,6 +3,7 @@ export * from './channel';
3
3
  export * from './config';
4
4
  export * from './common';
5
5
  export * from './flow';
6
+ export * from './memory';
6
7
  export * from './idwInfo';
7
8
  export * from './idwRwc';
8
9
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC"}
@@ -0,0 +1,6 @@
1
+ import { SimpleNode } from './common';
2
+ export type Memory = Omit<SimpleNode, 'icon'>;
3
+ export type ListMemories = Memory[];
4
+ export type MemoryCreateData = Pick<Memory, 'id' | 'name'>;
5
+ export type MemoryUpdateData = Partial<MemoryCreateData>;
6
+ //# sourceMappingURL=memory.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"memory.d.ts","sourceRoot":"","sources":["../../../src/types/memory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAEtC,MAAM,MAAM,MAAM,GAAG,IAAI,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC;AAC9C,MAAM,MAAM,YAAY,GAAG,MAAM,EAAE,CAAC;AACpC,MAAM,MAAM,gBAAgB,GAAG,IAAI,CAAC,MAAM,EAAE,IAAI,GAAG,MAAM,CAAC,CAAC;AAC3D,MAAM,MAAM,gBAAgB,GAAG,OAAO,CAAC,gBAAgB,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "2.2.0-beta.1694.0",
2
+ "version": "3.1.0-beta.1698.0",
3
3
  "name": "@or-sdk/idw",
4
4
  "main": "dist/cjs/index.js",
5
5
  "module": "dist/esm/index.js",
@@ -27,8 +27,8 @@
27
27
  "@or-sdk/accounts": "^1.2.13",
28
28
  "@or-sdk/base": "^0.28.3",
29
29
  "@or-sdk/deployer": "^1.1.5",
30
- "@or-sdk/flows": "^2.1.3",
31
- "@or-sdk/graph": "^1.6.0",
30
+ "@or-sdk/flows": "^2.1.4-beta.1698.0",
31
+ "@or-sdk/graph": "^1.6.1-beta.1698.0",
32
32
  "@or-sdk/providers": "^0.2.4",
33
33
  "@or-sdk/settings": "^0.24.11",
34
34
  "@or-sdk/users": "^0.30.2",
@@ -1,4 +1,4 @@
1
- import { buildRoute } from '../helpres';
1
+ import { buildRoute } from '../helpers';
2
2
  import { Channel, ListChannels, ChannelWithFlow, ChannelUpdateData, ChannelCreateData } from '../types';
3
3
  import { Providers } from '@or-sdk/providers';
4
4
 
@@ -1,6 +1,6 @@
1
1
  import { Flow, FlowUpdateData } from '../types';
2
2
  import { Providers } from '@or-sdk/providers';
3
- import { buildRoute } from '../helpres';
3
+ import { buildRoute } from '../helpers';
4
4
 
5
5
  export class FlowApi {
6
6
  constructor(
@@ -1,5 +1,5 @@
1
1
  import { Providers } from '@or-sdk/providers';
2
- import { buildRoute } from '../helpres';
2
+ import { buildRoute } from '../helpers';
3
3
 
4
4
  export class IdwDbApi {
5
5
  constructor(
@@ -1,6 +1,6 @@
1
1
  import { Providers } from '@or-sdk/providers';
2
2
  import { IdwBaseInfo, IdwInfoWithStatistic } from '../types';
3
- import { buildRoute } from '../helpres';
3
+ import { buildRoute } from '../helpers';
4
4
 
5
5
  export class IdwInfoApi {
6
6
  constructor(
@@ -1,6 +1,6 @@
1
1
  import { Providers } from '@or-sdk/providers';
2
2
  import { ChatCheckResponse, IdwRwcData, UpsertIdwRwcData } from '../types';
3
- import { buildRoute } from '../helpres';
3
+ import { buildRoute } from '../helpers';
4
4
 
5
5
  const noop: (...args: []) => void = () => {};
6
6
 
package/src/api/index.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  export { SkillApi } from './skillApi';
2
+ export { MemoryApi } from './memoryApi';
2
3
  export { ChannelApi } from './channelApi';
3
4
  export { MigrationApi } from './migrationApi';
4
5
  export { IdwInfoApi } from './idwInfoApi';
@@ -0,0 +1,83 @@
1
+ import { Providers } from '@or-sdk/providers';
2
+ import { ListMemories, Memory, MemoryCreateData, MemoryUpdateData } from '../types/memory';
3
+ import { buildRoute } from '../helpers';
4
+
5
+ export class MemoryApi {
6
+ constructor(
7
+ private readonly providers: Providers
8
+ ) {}
9
+
10
+ /**
11
+ * @description Get specific memory by id
12
+ * @param id
13
+ */
14
+ getMemory(id: string): Promise<Memory> {
15
+ return this.providers.makeRequest({
16
+ route: buildRoute('memory'),
17
+ params: {
18
+ id,
19
+ },
20
+ });
21
+ }
22
+
23
+ /**
24
+ * @description Get all memories
25
+ */
26
+ getAllMemories(): Promise<ListMemories> {
27
+ return this.providers.makeRequest({
28
+ route: buildRoute('memories'),
29
+ });
30
+ }
31
+
32
+ /**
33
+ * @description Delete specific memory by id
34
+ * @param id
35
+ */
36
+ deleteMemory(id: string): Promise<void> {
37
+ return this.providers.makeRequest({
38
+ route: buildRoute('memory'),
39
+ method: 'DELETE',
40
+ params: {
41
+ id,
42
+ },
43
+ });
44
+ }
45
+
46
+ /**
47
+ * @description Delete all memories
48
+ */
49
+ deleteAllMemories(): Promise<void> {
50
+ return this.providers.makeRequest({
51
+ route: buildRoute('memories'),
52
+ method: 'DELETE',
53
+ });
54
+ }
55
+
56
+ /**
57
+ * @description update specific memory by id
58
+ * @param id
59
+ * @param data
60
+ */
61
+ updateMemory(id: string, data: MemoryUpdateData): Promise<Memory> {
62
+ return this.providers.makeRequest({
63
+ route: buildRoute('memory'),
64
+ method: 'PATCH',
65
+ data,
66
+ params: {
67
+ id,
68
+ },
69
+ });
70
+ }
71
+
72
+ /**
73
+ * @description create memory
74
+ * @param data
75
+ */
76
+ createMemory(data: MemoryCreateData): Promise<Memory> {
77
+ return this.providers.makeRequest({
78
+ route: buildRoute('memory'),
79
+ method: 'POST',
80
+ data,
81
+ });
82
+ }
83
+ }
@@ -1,5 +1,5 @@
1
1
  import { Providers } from '@or-sdk/providers';
2
- import { buildRoute } from '../helpres';
2
+ import { buildRoute } from '../helpers';
3
3
 
4
4
  export class MigrationApi {
5
5
  constructor(
@@ -1,6 +1,6 @@
1
1
  import { Skill, ListSkills, SkillWithFlow, SkillUpdateData, SkillCreateData } from '../types';
2
2
  import { Providers } from '@or-sdk/providers';
3
- import { buildRoute } from '../helpres';
3
+ import { buildRoute } from '../helpers';
4
4
 
5
5
  export class SkillApi {
6
6
  constructor(
package/src/idwApi.ts CHANGED
@@ -1,10 +1,12 @@
1
1
  import { IDWBaseConfig } from './types';
2
- import { IdwDbApi, IdwInfoApi, IdwRwcApi, MigrationApi, SkillApi, ChannelApi } from './api';
2
+
3
+ import { IdwDbApi, IdwInfoApi, IdwRwcApi, MigrationApi, SkillApi, MemoryApi, ChannelApi } from './api';
3
4
  import { Providers } from '@or-sdk/providers';
4
5
  import { FlowApi } from './api/flowApi';
5
6
 
6
7
  export class IdwApi {
7
8
  readonly skillApi: SkillApi;
9
+ readonly memoryApi: MemoryApi;
8
10
  readonly channelApi: ChannelApi;
9
11
  readonly migrationApi: MigrationApi;
10
12
  readonly idwInfoApi: IdwInfoApi;
@@ -19,6 +21,7 @@ export class IdwApi {
19
21
  });
20
22
 
21
23
  this.skillApi = new SkillApi(provider);
24
+ this.memoryApi = new MemoryApi(provider);
22
25
  this.channelApi = new ChannelApi(provider);
23
26
  this.migrationApi = new MigrationApi(provider);
24
27
  this.idwInfoApi = new IdwInfoApi(provider);
@@ -3,6 +3,7 @@ export * from './channel';
3
3
  export * from './config';
4
4
  export * from './common';
5
5
  export * from './flow';
6
+ export * from './memory';
6
7
  export * from './idwInfo';
7
8
  export * from './idwRwc';
8
9
 
@@ -0,0 +1,6 @@
1
+ import { SimpleNode } from './common';
2
+
3
+ export type Memory = Omit<SimpleNode, 'icon'>;
4
+ export type ListMemories = Memory[];
5
+ export type MemoryCreateData = Pick<Memory, 'id' | 'name'>;
6
+ export type MemoryUpdateData = Partial<MemoryCreateData>;
@@ -1 +0,0 @@
1
- {"version":3,"file":"helpres.js","sourceRoot":"","sources":["../../src/helpres.ts"],"names":[],"mappings":";;;AAAA,yCAAsD;AAE/C,IAAM,UAAU,GAAG,UAAC,KAAa,IAAa,OAAA,UAAG,mCAAuB,cAAI,KAAK,CAAE,EAArC,CAAqC,CAAC;AAA9E,QAAA,UAAU,cAAoE"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"helpres.js","sourceRoot":"","sources":["../../src/helpres.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,aAAa,CAAC;AAEtD,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,KAAa,EAAU,EAAE,CAAC,GAAG,uBAAuB,IAAI,KAAK,EAAE,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"helpres.d.ts","sourceRoot":"","sources":["../../src/helpres.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,UAAU,UAAW,MAAM,KAAG,MAA+C,CAAC"}
File without changes