hume 0.8.5 → 0.8.6

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 (185) hide show
  1. package/.mock/definition/empathic-voice/__package__.yml +35 -34
  2. package/.mock/definition/empathic-voice/chatGroups.yml +338 -27
  3. package/.mock/definition/empathic-voice/chats.yml +353 -36
  4. package/.mock/definition/empathic-voice/configs.yml +282 -210
  5. package/.mock/definition/empathic-voice/prompts.yml +140 -64
  6. package/.mock/definition/empathic-voice/tools.yml +11 -8
  7. package/.mock/definition/expression-measurement/__package__.yml +203 -59
  8. package/.mock/definition/expression-measurement/batch.yml +64 -35
  9. package/.mock/fern.config.json +1 -1
  10. package/api/resources/empathicVoice/resources/chatGroups/client/Client.d.ts +11 -2
  11. package/api/resources/empathicVoice/resources/chatGroups/client/Client.js +13 -4
  12. package/api/resources/empathicVoice/resources/chatGroups/client/requests/ChatGroupsListChatGroupEventsRequest.d.ts +7 -3
  13. package/api/resources/empathicVoice/resources/chatGroups/client/requests/ChatGroupsListChatGroupsRequest.d.ts +8 -3
  14. package/api/resources/empathicVoice/resources/chats/client/Client.d.ts +12 -4
  15. package/api/resources/empathicVoice/resources/chats/client/Client.js +128 -96
  16. package/api/resources/empathicVoice/resources/chats/client/requests/ChatsListChatEventsRequest.d.ts +7 -3
  17. package/api/resources/empathicVoice/resources/chats/client/requests/ChatsListChatsRequest.d.ts +7 -3
  18. package/api/resources/empathicVoice/resources/configs/client/Client.d.ts +74 -10
  19. package/api/resources/empathicVoice/resources/configs/client/Client.js +83 -19
  20. package/api/resources/empathicVoice/resources/configs/client/requests/ConfigsListConfigVersionsRequest.d.ts +2 -2
  21. package/api/resources/empathicVoice/resources/configs/client/requests/ConfigsListConfigsRequest.d.ts +6 -3
  22. package/api/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +28 -1
  23. package/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigName.d.ts +1 -1
  24. package/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +33 -1
  25. package/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersionDescription.d.ts +3 -1
  26. package/api/resources/empathicVoice/resources/prompts/client/Client.d.ts +19 -13
  27. package/api/resources/empathicVoice/resources/prompts/client/Client.js +89 -70
  28. package/api/resources/empathicVoice/resources/prompts/client/requests/PostedPrompt.d.ts +2 -2
  29. package/api/resources/empathicVoice/resources/prompts/client/requests/PostedPromptName.d.ts +1 -1
  30. package/api/resources/empathicVoice/resources/prompts/client/requests/PostedPromptVersion.d.ts +2 -1
  31. package/api/resources/empathicVoice/resources/prompts/client/requests/PostedPromptVersionDescription.d.ts +3 -1
  32. package/api/resources/empathicVoice/resources/prompts/client/requests/PromptsListPromptVersionsRequest.d.ts +2 -2
  33. package/api/resources/empathicVoice/resources/prompts/client/requests/PromptsListPromptsRequest.d.ts +6 -3
  34. package/api/resources/empathicVoice/resources/tools/client/Client.d.ts +1 -1
  35. package/api/resources/empathicVoice/resources/tools/client/Client.js +71 -58
  36. package/api/resources/empathicVoice/resources/tools/client/requests/ToolsListToolVersionsRequest.d.ts +2 -2
  37. package/api/resources/empathicVoice/resources/tools/client/requests/ToolsListToolsRequest.d.ts +2 -2
  38. package/api/resources/empathicVoice/types/AudioInput.d.ts +4 -2
  39. package/api/resources/empathicVoice/types/JsonMessage.d.ts +1 -1
  40. package/api/resources/expressionMeasurement/resources/batch/client/Client.d.ts +4 -4
  41. package/api/resources/expressionMeasurement/resources/batch/client/Client.js +11 -19
  42. package/api/resources/expressionMeasurement/resources/batch/client/requests/BatchListJobsRequest.d.ts +25 -9
  43. package/api/resources/expressionMeasurement/resources/batch/client/requests/BatchStartInferenceJobFromLocalFileRequest.d.ts +1 -0
  44. package/api/resources/expressionMeasurement/types/{UnionJobJobInference.d.ts → CustomModelsInferenceJob.d.ts} +2 -1
  45. package/api/resources/expressionMeasurement/types/{UnionJobJobEmbeddingGeneration.d.ts → CustomModelsTrainingJob.d.ts} +2 -1
  46. package/api/resources/expressionMeasurement/types/EmbeddingGenerationJob.d.ts +7 -0
  47. package/api/resources/expressionMeasurement/types/Face.d.ts +5 -0
  48. package/api/resources/expressionMeasurement/types/File_.d.ts +3 -0
  49. package/api/resources/expressionMeasurement/types/Granularity.d.ts +9 -1
  50. package/api/resources/expressionMeasurement/types/InferenceBaseRequest.d.ts +6 -1
  51. package/api/resources/expressionMeasurement/types/InferenceJob.d.ts +12 -0
  52. package/api/resources/expressionMeasurement/types/JobInference.d.ts +3 -0
  53. package/api/resources/expressionMeasurement/types/Language.d.ts +5 -0
  54. package/api/resources/expressionMeasurement/types/Models.d.ts +3 -0
  55. package/api/resources/expressionMeasurement/types/Ner.d.ts +5 -0
  56. package/api/resources/expressionMeasurement/types/Prosody.d.ts +5 -0
  57. package/api/resources/expressionMeasurement/types/Transcription.d.ts +40 -0
  58. package/api/resources/expressionMeasurement/types/UnionJob.d.ts +1 -15
  59. package/api/resources/expressionMeasurement/types/UnionPredictResult.d.ts +1 -1
  60. package/api/resources/expressionMeasurement/types/Window.d.ts +5 -0
  61. package/api/resources/expressionMeasurement/types/index.d.ts +4 -4
  62. package/api/resources/expressionMeasurement/types/index.js +4 -4
  63. package/api/resources/index.d.ts +1 -1
  64. package/api/resources/index.js +2 -2
  65. package/core/index.d.ts +1 -0
  66. package/core/index.js +1 -0
  67. package/core/pagination/Page.d.ts +29 -0
  68. package/core/pagination/Page.js +94 -0
  69. package/core/pagination/Pageable.d.ts +12 -0
  70. package/core/pagination/Pageable.js +10 -0
  71. package/core/pagination/index.d.ts +2 -0
  72. package/core/pagination/index.js +7 -0
  73. package/dist/api/resources/empathicVoice/resources/chatGroups/client/Client.d.ts +11 -2
  74. package/dist/api/resources/empathicVoice/resources/chatGroups/client/Client.js +13 -4
  75. package/dist/api/resources/empathicVoice/resources/chatGroups/client/requests/ChatGroupsListChatGroupEventsRequest.d.ts +7 -3
  76. package/dist/api/resources/empathicVoice/resources/chatGroups/client/requests/ChatGroupsListChatGroupsRequest.d.ts +8 -3
  77. package/dist/api/resources/empathicVoice/resources/chats/client/Client.d.ts +12 -4
  78. package/dist/api/resources/empathicVoice/resources/chats/client/Client.js +128 -96
  79. package/dist/api/resources/empathicVoice/resources/chats/client/requests/ChatsListChatEventsRequest.d.ts +7 -3
  80. package/dist/api/resources/empathicVoice/resources/chats/client/requests/ChatsListChatsRequest.d.ts +7 -3
  81. package/dist/api/resources/empathicVoice/resources/configs/client/Client.d.ts +74 -10
  82. package/dist/api/resources/empathicVoice/resources/configs/client/Client.js +83 -19
  83. package/dist/api/resources/empathicVoice/resources/configs/client/requests/ConfigsListConfigVersionsRequest.d.ts +2 -2
  84. package/dist/api/resources/empathicVoice/resources/configs/client/requests/ConfigsListConfigsRequest.d.ts +6 -3
  85. package/dist/api/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +28 -1
  86. package/dist/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigName.d.ts +1 -1
  87. package/dist/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +33 -1
  88. package/dist/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersionDescription.d.ts +3 -1
  89. package/dist/api/resources/empathicVoice/resources/prompts/client/Client.d.ts +19 -13
  90. package/dist/api/resources/empathicVoice/resources/prompts/client/Client.js +89 -70
  91. package/dist/api/resources/empathicVoice/resources/prompts/client/requests/PostedPrompt.d.ts +2 -2
  92. package/dist/api/resources/empathicVoice/resources/prompts/client/requests/PostedPromptName.d.ts +1 -1
  93. package/dist/api/resources/empathicVoice/resources/prompts/client/requests/PostedPromptVersion.d.ts +2 -1
  94. package/dist/api/resources/empathicVoice/resources/prompts/client/requests/PostedPromptVersionDescription.d.ts +3 -1
  95. package/dist/api/resources/empathicVoice/resources/prompts/client/requests/PromptsListPromptVersionsRequest.d.ts +2 -2
  96. package/dist/api/resources/empathicVoice/resources/prompts/client/requests/PromptsListPromptsRequest.d.ts +6 -3
  97. package/dist/api/resources/empathicVoice/resources/tools/client/Client.d.ts +1 -1
  98. package/dist/api/resources/empathicVoice/resources/tools/client/Client.js +71 -58
  99. package/dist/api/resources/empathicVoice/resources/tools/client/requests/ToolsListToolVersionsRequest.d.ts +2 -2
  100. package/dist/api/resources/empathicVoice/resources/tools/client/requests/ToolsListToolsRequest.d.ts +2 -2
  101. package/dist/api/resources/empathicVoice/types/AudioInput.d.ts +4 -2
  102. package/dist/api/resources/empathicVoice/types/JsonMessage.d.ts +1 -1
  103. package/dist/api/resources/expressionMeasurement/resources/batch/client/Client.d.ts +4 -4
  104. package/dist/api/resources/expressionMeasurement/resources/batch/client/Client.js +11 -19
  105. package/dist/api/resources/expressionMeasurement/resources/batch/client/requests/BatchListJobsRequest.d.ts +25 -9
  106. package/dist/api/resources/expressionMeasurement/resources/batch/client/requests/BatchStartInferenceJobFromLocalFileRequest.d.ts +1 -0
  107. package/{api/resources/expressionMeasurement/types/UnionJobJobTraining.d.ts → dist/api/resources/expressionMeasurement/types/CustomModelsInferenceJob.d.ts} +2 -1
  108. package/{api/resources/expressionMeasurement/types/UnionJobJobTlInference.d.ts → dist/api/resources/expressionMeasurement/types/CustomModelsTrainingJob.d.ts} +2 -1
  109. package/dist/api/resources/expressionMeasurement/types/EmbeddingGenerationJob.d.ts +7 -0
  110. package/dist/api/resources/expressionMeasurement/types/Face.d.ts +5 -0
  111. package/dist/api/resources/expressionMeasurement/types/File_.d.ts +3 -0
  112. package/dist/api/resources/expressionMeasurement/types/Granularity.d.ts +9 -1
  113. package/dist/api/resources/expressionMeasurement/types/InferenceBaseRequest.d.ts +6 -1
  114. package/dist/api/resources/expressionMeasurement/types/InferenceJob.d.ts +12 -0
  115. package/dist/api/resources/expressionMeasurement/types/JobInference.d.ts +3 -0
  116. package/dist/api/resources/expressionMeasurement/types/Language.d.ts +5 -0
  117. package/dist/api/resources/expressionMeasurement/types/Models.d.ts +3 -0
  118. package/dist/api/resources/expressionMeasurement/types/Ner.d.ts +5 -0
  119. package/dist/api/resources/expressionMeasurement/types/Prosody.d.ts +5 -0
  120. package/dist/api/resources/expressionMeasurement/types/Transcription.d.ts +40 -0
  121. package/dist/api/resources/expressionMeasurement/types/UnionJob.d.ts +1 -15
  122. package/dist/api/resources/expressionMeasurement/types/UnionPredictResult.d.ts +1 -1
  123. package/dist/api/resources/expressionMeasurement/types/Window.d.ts +5 -0
  124. package/dist/api/resources/expressionMeasurement/types/index.d.ts +4 -4
  125. package/dist/api/resources/expressionMeasurement/types/index.js +4 -4
  126. package/dist/api/resources/index.d.ts +1 -1
  127. package/dist/api/resources/index.js +2 -2
  128. package/dist/core/index.d.ts +1 -0
  129. package/dist/core/index.js +1 -0
  130. package/dist/core/pagination/Page.d.ts +29 -0
  131. package/dist/core/pagination/Page.js +94 -0
  132. package/dist/core/pagination/Pageable.d.ts +12 -0
  133. package/dist/core/pagination/Pageable.js +10 -0
  134. package/dist/core/pagination/index.d.ts +2 -0
  135. package/dist/core/pagination/index.js +7 -0
  136. package/dist/serialization/resources/empathicVoice/types/JsonMessage.d.ts +2 -1
  137. package/dist/serialization/resources/empathicVoice/types/JsonMessage.js +2 -0
  138. package/{serialization/resources/expressionMeasurement/types/UnionJobJobTlInference.d.ts → dist/serialization/resources/expressionMeasurement/types/CustomModelsInferenceJob.d.ts} +3 -2
  139. package/{serialization/resources/expressionMeasurement/types/UnionJobJobTlInference.js → dist/serialization/resources/expressionMeasurement/types/CustomModelsInferenceJob.js} +6 -2
  140. package/{serialization/resources/expressionMeasurement/types/UnionJobJobTraining.d.ts → dist/serialization/resources/expressionMeasurement/types/CustomModelsTrainingJob.d.ts} +3 -2
  141. package/{serialization/resources/expressionMeasurement/types/UnionJobJobTraining.js → dist/serialization/resources/expressionMeasurement/types/CustomModelsTrainingJob.js} +6 -2
  142. package/dist/serialization/resources/expressionMeasurement/types/{UnionJobJobEmbeddingGeneration.d.ts → EmbeddingGenerationJob.d.ts} +3 -2
  143. package/dist/serialization/resources/expressionMeasurement/types/{UnionJobJobEmbeddingGeneration.js → EmbeddingGenerationJob.js} +6 -2
  144. package/{serialization/resources/expressionMeasurement/types/UnionJobJobInference.d.ts → dist/serialization/resources/expressionMeasurement/types/InferenceJob.d.ts} +3 -2
  145. package/{serialization/resources/expressionMeasurement/types/UnionJobJobInference.js → dist/serialization/resources/expressionMeasurement/types/InferenceJob.js} +6 -2
  146. package/dist/serialization/resources/expressionMeasurement/types/UnionJob.d.ts +3 -18
  147. package/dist/serialization/resources/expressionMeasurement/types/UnionJob.js +2 -39
  148. package/dist/serialization/resources/expressionMeasurement/types/UnionPredictResult.d.ts +2 -3
  149. package/dist/serialization/resources/expressionMeasurement/types/UnionPredictResult.js +1 -29
  150. package/dist/serialization/resources/expressionMeasurement/types/index.d.ts +4 -4
  151. package/dist/serialization/resources/expressionMeasurement/types/index.js +4 -4
  152. package/dist/serialization/resources/index.d.ts +1 -1
  153. package/dist/serialization/resources/index.js +2 -2
  154. package/package.json +1 -1
  155. package/reference.md +596 -544
  156. package/serialization/resources/empathicVoice/types/JsonMessage.d.ts +2 -1
  157. package/serialization/resources/empathicVoice/types/JsonMessage.js +2 -0
  158. package/{dist/serialization/resources/expressionMeasurement/types/UnionJobJobTlInference.d.ts → serialization/resources/expressionMeasurement/types/CustomModelsInferenceJob.d.ts} +3 -2
  159. package/{dist/serialization/resources/expressionMeasurement/types/UnionJobJobTlInference.js → serialization/resources/expressionMeasurement/types/CustomModelsInferenceJob.js} +6 -2
  160. package/{dist/serialization/resources/expressionMeasurement/types/UnionJobJobTraining.d.ts → serialization/resources/expressionMeasurement/types/CustomModelsTrainingJob.d.ts} +3 -2
  161. package/{dist/serialization/resources/expressionMeasurement/types/UnionJobJobTraining.js → serialization/resources/expressionMeasurement/types/CustomModelsTrainingJob.js} +6 -2
  162. package/serialization/resources/expressionMeasurement/types/{UnionJobJobEmbeddingGeneration.d.ts → EmbeddingGenerationJob.d.ts} +3 -2
  163. package/serialization/resources/expressionMeasurement/types/{UnionJobJobEmbeddingGeneration.js → EmbeddingGenerationJob.js} +6 -2
  164. package/{dist/serialization/resources/expressionMeasurement/types/UnionJobJobInference.d.ts → serialization/resources/expressionMeasurement/types/InferenceJob.d.ts} +3 -2
  165. package/{dist/serialization/resources/expressionMeasurement/types/UnionJobJobInference.js → serialization/resources/expressionMeasurement/types/InferenceJob.js} +6 -2
  166. package/serialization/resources/expressionMeasurement/types/UnionJob.d.ts +3 -18
  167. package/serialization/resources/expressionMeasurement/types/UnionJob.js +2 -39
  168. package/serialization/resources/expressionMeasurement/types/UnionPredictResult.d.ts +2 -3
  169. package/serialization/resources/expressionMeasurement/types/UnionPredictResult.js +1 -29
  170. package/serialization/resources/expressionMeasurement/types/index.d.ts +4 -4
  171. package/serialization/resources/expressionMeasurement/types/index.js +4 -4
  172. package/serialization/resources/index.d.ts +1 -1
  173. package/serialization/resources/index.js +2 -2
  174. package/dist/api/resources/expressionMeasurement/types/UnionJobJobEmbeddingGeneration.d.ts +0 -6
  175. package/dist/api/resources/expressionMeasurement/types/UnionJobJobInference.d.ts +0 -6
  176. package/dist/api/resources/expressionMeasurement/types/UnionJobJobTlInference.d.ts +0 -6
  177. package/dist/api/resources/expressionMeasurement/types/UnionJobJobTraining.d.ts +0 -6
  178. /package/api/resources/expressionMeasurement/types/{UnionJobJobEmbeddingGeneration.js → CustomModelsInferenceJob.js} +0 -0
  179. /package/api/resources/expressionMeasurement/types/{UnionJobJobInference.js → CustomModelsTrainingJob.js} +0 -0
  180. /package/api/resources/expressionMeasurement/types/{UnionJobJobTlInference.js → EmbeddingGenerationJob.js} +0 -0
  181. /package/api/resources/expressionMeasurement/types/{UnionJobJobTraining.js → InferenceJob.js} +0 -0
  182. /package/dist/api/resources/expressionMeasurement/types/{UnionJobJobEmbeddingGeneration.js → CustomModelsInferenceJob.js} +0 -0
  183. /package/dist/api/resources/expressionMeasurement/types/{UnionJobJobInference.js → CustomModelsTrainingJob.js} +0 -0
  184. /package/dist/api/resources/expressionMeasurement/types/{UnionJobJobTlInference.js → EmbeddingGenerationJob.js} +0 -0
  185. /package/dist/api/resources/expressionMeasurement/types/{UnionJobJobTraining.js → InferenceJob.js} +0 -0
@@ -0,0 +1,94 @@
1
+ "use strict";
2
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
+ return new (P || (P = Promise))(function (resolve, reject) {
5
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
9
+ });
10
+ };
11
+ var __await = (this && this.__await) || function (v) { return this instanceof __await ? (this.v = v, this) : new __await(v); }
12
+ var __asyncGenerator = (this && this.__asyncGenerator) || function (thisArg, _arguments, generator) {
13
+ if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
14
+ var g = generator.apply(thisArg, _arguments || []), i, q = [];
15
+ return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
16
+ function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
17
+ function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }
18
+ function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
19
+ function fulfill(value) { resume("next", value); }
20
+ function reject(value) { resume("throw", value); }
21
+ function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }
22
+ };
23
+ var __asyncValues = (this && this.__asyncValues) || function (o) {
24
+ if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
25
+ var m = o[Symbol.asyncIterator], i;
26
+ return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
27
+ function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
28
+ function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }
29
+ };
30
+ Object.defineProperty(exports, "__esModule", { value: true });
31
+ exports.Page = void 0;
32
+ /**
33
+ * A page of results from a paginated API.
34
+ *
35
+ * @template T The type of the items in the page.
36
+ */
37
+ class Page {
38
+ constructor({ response, hasNextPage, getItems, loadPage, }) {
39
+ this.response = response;
40
+ this.data = getItems(response);
41
+ this._hasNextPage = hasNextPage;
42
+ this.getItems = getItems;
43
+ this.loadNextPage = loadPage;
44
+ }
45
+ /**
46
+ * Retrieves the next page
47
+ * @returns this
48
+ */
49
+ getNextPage() {
50
+ return __awaiter(this, void 0, void 0, function* () {
51
+ this.response = yield this.loadNextPage(this.response);
52
+ this.data = this.getItems(this.response);
53
+ return this;
54
+ });
55
+ }
56
+ /**
57
+ * @returns whether there is a next page to load
58
+ */
59
+ hasNextPage() {
60
+ return this._hasNextPage(this.response);
61
+ }
62
+ iterMessages() {
63
+ return __asyncGenerator(this, arguments, function* iterMessages_1() {
64
+ for (const item of this.data) {
65
+ yield yield __await(item);
66
+ }
67
+ while (this.hasNextPage()) {
68
+ yield __await(this.getNextPage());
69
+ for (const item of this.data) {
70
+ yield yield __await(item);
71
+ }
72
+ }
73
+ });
74
+ }
75
+ [Symbol.asyncIterator]() {
76
+ return __asyncGenerator(this, arguments, function* _a() {
77
+ var e_1, _b;
78
+ try {
79
+ for (var _c = __asyncValues(this.iterMessages()), _d; _d = yield __await(_c.next()), !_d.done;) {
80
+ const message = _d.value;
81
+ yield yield __await(message);
82
+ }
83
+ }
84
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
85
+ finally {
86
+ try {
87
+ if (_d && !_d.done && (_b = _c.return)) yield __await(_b.call(_c));
88
+ }
89
+ finally { if (e_1) throw e_1.error; }
90
+ }
91
+ });
92
+ }
93
+ }
94
+ exports.Page = Page;
@@ -0,0 +1,12 @@
1
+ import { Page } from './Page';
2
+ export declare namespace Pageable {
3
+ interface Args<Response, Item> {
4
+ response: Response;
5
+ hasNextPage: (response: Response) => boolean;
6
+ getItems: (response: Response) => Item[];
7
+ loadPage: (response: Response) => Promise<Response>;
8
+ }
9
+ }
10
+ export declare class Pageable<R, T> extends Page<T> {
11
+ constructor(args: Pageable.Args<R, T>);
12
+ }
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Pageable = void 0;
4
+ const Page_1 = require("./Page");
5
+ class Pageable extends Page_1.Page {
6
+ constructor(args) {
7
+ super(args);
8
+ }
9
+ }
10
+ exports.Pageable = Pageable;
@@ -0,0 +1,2 @@
1
+ export { Page } from './Page';
2
+ export { Pageable } from './Pageable';
@@ -0,0 +1,7 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Pageable = exports.Page = void 0;
4
+ var Page_1 = require("./Page");
5
+ Object.defineProperty(exports, "Page", { enumerable: true, get: function () { return Page_1.Page; } });
6
+ var Pageable_1 = require("./Pageable");
7
+ Object.defineProperty(exports, "Pageable", { enumerable: true, get: function () { return Pageable_1.Pageable; } });
@@ -27,7 +27,12 @@ export declare class ChatGroups {
27
27
  * @param {ChatGroups.RequestOptions} requestOptions - Request-specific configuration.
28
28
  *
29
29
  * @example
30
- * await client.empathicVoice.chatGroups.listChatGroups()
30
+ * await client.empathicVoice.chatGroups.listChatGroups({
31
+ * pageNumber: 0,
32
+ * pageSize: 1,
33
+ * ascendingOrder: true,
34
+ * configId: "1b60e1a0-cc59-424a-8d2c-189d354db3f3"
35
+ * })
31
36
  */
32
37
  listChatGroups(request?: Hume.empathicVoice.ChatGroupsListChatGroupsRequest, requestOptions?: ChatGroups.RequestOptions): Promise<Hume.empathicVoice.ReturnPagedChatGroups>;
33
38
  /**
@@ -36,7 +41,11 @@ export declare class ChatGroups {
36
41
  * @param {ChatGroups.RequestOptions} requestOptions - Request-specific configuration.
37
42
  *
38
43
  * @example
39
- * await client.empathicVoice.chatGroups.listChatGroupEvents("id")
44
+ * await client.empathicVoice.chatGroups.listChatGroupEvents("697056f0-6c7e-487d-9bd8-9c19df79f05f", {
45
+ * pageNumber: 0,
46
+ * pageSize: 3,
47
+ * ascendingOrder: true
48
+ * })
40
49
  */
41
50
  listChatGroupEvents(id: string, request?: Hume.empathicVoice.ChatGroupsListChatGroupEventsRequest, requestOptions?: ChatGroups.RequestOptions): Promise<Hume.empathicVoice.ReturnChatGroupPagedEvents>;
42
51
  protected _getCustomAuthorizationHeaders(): Promise<{
@@ -53,7 +53,12 @@ class ChatGroups {
53
53
  * @param {ChatGroups.RequestOptions} requestOptions - Request-specific configuration.
54
54
  *
55
55
  * @example
56
- * await client.empathicVoice.chatGroups.listChatGroups()
56
+ * await client.empathicVoice.chatGroups.listChatGroups({
57
+ * pageNumber: 0,
58
+ * pageSize: 1,
59
+ * ascendingOrder: true,
60
+ * configId: "1b60e1a0-cc59-424a-8d2c-189d354db3f3"
61
+ * })
57
62
  */
58
63
  listChatGroups(request = {}, requestOptions) {
59
64
  var _a, _b;
@@ -75,7 +80,7 @@ class ChatGroups {
75
80
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
76
81
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, 'v0/evi/chat_groups'),
77
82
  method: 'GET',
78
- headers: Object.assign({ 'X-Fern-Language': 'JavaScript', 'X-Fern-SDK-Name': 'hume', 'X-Fern-SDK-Version': '0.8.5', 'X-Fern-Runtime': core.RUNTIME.type, 'X-Fern-Runtime-Version': core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
83
+ headers: Object.assign({ 'X-Fern-Language': 'JavaScript', 'X-Fern-SDK-Name': 'hume', 'X-Fern-SDK-Version': '0.8.6', 'X-Fern-Runtime': core.RUNTIME.type, 'X-Fern-Runtime-Version': core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
79
84
  contentType: 'application/json',
80
85
  queryParameters: _queryParams,
81
86
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null
@@ -119,7 +124,11 @@ class ChatGroups {
119
124
  * @param {ChatGroups.RequestOptions} requestOptions - Request-specific configuration.
120
125
  *
121
126
  * @example
122
- * await client.empathicVoice.chatGroups.listChatGroupEvents("id")
127
+ * await client.empathicVoice.chatGroups.listChatGroupEvents("697056f0-6c7e-487d-9bd8-9c19df79f05f", {
128
+ * pageNumber: 0,
129
+ * pageSize: 3,
130
+ * ascendingOrder: true
131
+ * })
123
132
  */
124
133
  listChatGroupEvents(id, request = {}, requestOptions) {
125
134
  var _a, _b;
@@ -138,7 +147,7 @@ class ChatGroups {
138
147
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
139
148
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, `v0/evi/chat_groups/${encodeURIComponent(id)}/events`),
140
149
  method: 'GET',
141
- headers: Object.assign({ 'X-Fern-Language': 'JavaScript', 'X-Fern-SDK-Name': 'hume', 'X-Fern-SDK-Version': '0.8.5', 'X-Fern-Runtime': core.RUNTIME.type, 'X-Fern-Runtime-Version': core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
150
+ headers: Object.assign({ 'X-Fern-Language': 'JavaScript', 'X-Fern-SDK-Name': 'hume', 'X-Fern-SDK-Version': '0.8.6', 'X-Fern-Runtime': core.RUNTIME.type, 'X-Fern-Runtime-Version': core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
142
151
  contentType: 'application/json',
143
152
  queryParameters: _queryParams,
144
153
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null
@@ -3,13 +3,17 @@
3
3
  */
4
4
  /**
5
5
  * @example
6
- * {}
6
+ * {
7
+ * pageNumber: 0,
8
+ * pageSize: 3,
9
+ * ascendingOrder: true
10
+ * }
7
11
  */
8
12
  export interface ChatGroupsListChatGroupEventsRequest {
9
13
  /**
10
- * Specifies the maximum number of results to include per page, enabling pagination.
14
+ * Specifies the maximum number of results to include per page, enabling pagination. The value must be between 1 and 100, inclusive.
11
15
  *
12
- * The value must be greater than or equal to 1. For example, if `page_size` is set to 10, each page will include up to 10 items. Defaults to 10.
16
+ * For example, if `page_size` is set to 10, each page will include up to 10 items. Defaults to 10.
13
17
  */
14
18
  pageSize?: number;
15
19
  /**
@@ -3,7 +3,12 @@
3
3
  */
4
4
  /**
5
5
  * @example
6
- * {}
6
+ * {
7
+ * pageNumber: 0,
8
+ * pageSize: 1,
9
+ * ascendingOrder: true,
10
+ * configId: "1b60e1a0-cc59-424a-8d2c-189d354db3f3"
11
+ * }
7
12
  */
8
13
  export interface ChatGroupsListChatGroupsRequest {
9
14
  /**
@@ -13,9 +18,9 @@ export interface ChatGroupsListChatGroupsRequest {
13
18
  */
14
19
  pageNumber?: number;
15
20
  /**
16
- * Specifies the maximum number of results to include per page, enabling pagination.
21
+ * Specifies the maximum number of results to include per page, enabling pagination. The value must be between 1 and 100, inclusive.
17
22
  *
18
- * The value must be greater than or equal to 1. For example, if `page_size` is set to 10, each page will include up to 10 items. Defaults to 10.
23
+ * For example, if `page_size` is set to 10, each page will include up to 10 items. Defaults to 10.
19
24
  */
20
25
  pageSize?: number;
21
26
  /**
@@ -27,18 +27,26 @@ export declare class Chats {
27
27
  * @param {Chats.RequestOptions} requestOptions - Request-specific configuration.
28
28
  *
29
29
  * @example
30
- * await client.empathicVoice.chats.listChats()
30
+ * await client.empathicVoice.chats.listChats({
31
+ * pageNumber: 0,
32
+ * pageSize: 1,
33
+ * ascendingOrder: true
34
+ * })
31
35
  */
32
- listChats(request?: Hume.empathicVoice.ChatsListChatsRequest, requestOptions?: Chats.RequestOptions): Promise<Hume.empathicVoice.ReturnPagedChats>;
36
+ listChats(request?: Hume.empathicVoice.ChatsListChatsRequest, requestOptions?: Chats.RequestOptions): Promise<core.Page<Hume.empathicVoice.ReturnChat>>;
33
37
  /**
34
38
  * @param {string} id - Identifier for a Chat. Formatted as a UUID.
35
39
  * @param {Hume.empathicVoice.ChatsListChatEventsRequest} request
36
40
  * @param {Chats.RequestOptions} requestOptions - Request-specific configuration.
37
41
  *
38
42
  * @example
39
- * await client.empathicVoice.chats.listChatEvents("id")
43
+ * await client.empathicVoice.chats.listChatEvents("470a49f6-1dec-4afe-8b61-035d3b2d63b0", {
44
+ * pageNumber: 0,
45
+ * pageSize: 3,
46
+ * ascendingOrder: true
47
+ * })
40
48
  */
41
- listChatEvents(id: string, request?: Hume.empathicVoice.ChatsListChatEventsRequest, requestOptions?: Chats.RequestOptions): Promise<Hume.empathicVoice.ReturnChatPagedEvents>;
49
+ listChatEvents(id: string, request?: Hume.empathicVoice.ChatsListChatEventsRequest, requestOptions?: Chats.RequestOptions): Promise<core.Page<Hume.empathicVoice.ReturnChatEvent>>;
42
50
  protected _getCustomAuthorizationHeaders(): Promise<{
43
51
  'X-Hume-Api-Key': string | undefined;
44
52
  }>;
@@ -53,61 +53,77 @@ class Chats {
53
53
  * @param {Chats.RequestOptions} requestOptions - Request-specific configuration.
54
54
  *
55
55
  * @example
56
- * await client.empathicVoice.chats.listChats()
56
+ * await client.empathicVoice.chats.listChats({
57
+ * pageNumber: 0,
58
+ * pageSize: 1,
59
+ * ascendingOrder: true
60
+ * })
57
61
  */
58
62
  listChats(request = {}, requestOptions) {
59
- var _a, _b;
60
63
  return __awaiter(this, void 0, void 0, function* () {
61
- const { pageNumber, pageSize, ascendingOrder } = request;
62
- const _queryParams = {};
63
- if (pageNumber != null) {
64
- _queryParams['page_number'] = pageNumber.toString();
65
- }
66
- if (pageSize != null) {
67
- _queryParams['page_size'] = pageSize.toString();
68
- }
69
- if (ascendingOrder != null) {
70
- _queryParams['ascending_order'] = ascendingOrder.toString();
71
- }
72
- const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
73
- url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, 'v0/evi/chats'),
74
- method: 'GET',
75
- headers: Object.assign({ 'X-Fern-Language': 'JavaScript', 'X-Fern-SDK-Name': 'hume', 'X-Fern-SDK-Version': '0.8.5', 'X-Fern-Runtime': core.RUNTIME.type, 'X-Fern-Runtime-Version': core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
76
- contentType: 'application/json',
77
- queryParameters: _queryParams,
78
- timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null
79
- ? requestOptions.timeoutInSeconds * 1000
80
- : 60000,
81
- maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
82
- abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
83
- });
84
- if (_response.ok) {
85
- return serializers.empathicVoice.ReturnPagedChats.parseOrThrow(_response.body, {
86
- unrecognizedObjectKeys: 'passthrough',
87
- allowUnrecognizedUnionMembers: true,
88
- allowUnrecognizedEnumValues: true,
89
- breadcrumbsPrefix: ['response'],
90
- });
91
- }
92
- if (_response.error.reason === 'status-code') {
93
- throw new errors.HumeError({
94
- statusCode: _response.error.statusCode,
95
- body: _response.error.body,
64
+ const list = (request) => __awaiter(this, void 0, void 0, function* () {
65
+ var _a, _b;
66
+ const { pageNumber, pageSize, ascendingOrder } = request;
67
+ const _queryParams = {};
68
+ if (pageNumber != null) {
69
+ _queryParams['page_number'] = pageNumber.toString();
70
+ }
71
+ if (pageSize != null) {
72
+ _queryParams['page_size'] = pageSize.toString();
73
+ }
74
+ if (ascendingOrder != null) {
75
+ _queryParams['ascending_order'] = ascendingOrder.toString();
76
+ }
77
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
78
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, 'v0/evi/chats'),
79
+ method: 'GET',
80
+ headers: Object.assign({ 'X-Fern-Language': 'JavaScript', 'X-Fern-SDK-Name': 'hume', 'X-Fern-SDK-Version': '0.8.6', 'X-Fern-Runtime': core.RUNTIME.type, 'X-Fern-Runtime-Version': core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
81
+ contentType: 'application/json',
82
+ queryParameters: _queryParams,
83
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null
84
+ ? requestOptions.timeoutInSeconds * 1000
85
+ : 60000,
86
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
87
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
96
88
  });
97
- }
98
- switch (_response.error.reason) {
99
- case 'non-json':
100
- throw new errors.HumeError({
101
- statusCode: _response.error.statusCode,
102
- body: _response.error.rawBody,
89
+ if (_response.ok) {
90
+ return serializers.empathicVoice.ReturnPagedChats.parseOrThrow(_response.body, {
91
+ unrecognizedObjectKeys: 'passthrough',
92
+ allowUnrecognizedUnionMembers: true,
93
+ allowUnrecognizedEnumValues: true,
94
+ breadcrumbsPrefix: ['response'],
103
95
  });
104
- case 'timeout':
105
- throw new errors.HumeTimeoutError();
106
- case 'unknown':
96
+ }
97
+ if (_response.error.reason === 'status-code') {
107
98
  throw new errors.HumeError({
108
- message: _response.error.errorMessage,
99
+ statusCode: _response.error.statusCode,
100
+ body: _response.error.body,
109
101
  });
110
- }
102
+ }
103
+ switch (_response.error.reason) {
104
+ case 'non-json':
105
+ throw new errors.HumeError({
106
+ statusCode: _response.error.statusCode,
107
+ body: _response.error.rawBody,
108
+ });
109
+ case 'timeout':
110
+ throw new errors.HumeTimeoutError();
111
+ case 'unknown':
112
+ throw new errors.HumeError({
113
+ message: _response.error.errorMessage,
114
+ });
115
+ }
116
+ });
117
+ let _offset = request.pageNumber != null ? request.pageNumber : 1;
118
+ return new core.Pageable({
119
+ response: yield list(request),
120
+ hasNextPage: (response) => { var _a; return ((_a = response === null || response === void 0 ? void 0 : response.chatsPage) !== null && _a !== void 0 ? _a : []).length > 0; },
121
+ getItems: (response) => { var _a; return (_a = response === null || response === void 0 ? void 0 : response.chatsPage) !== null && _a !== void 0 ? _a : []; },
122
+ loadPage: (_response) => {
123
+ _offset += 1;
124
+ return list(Object.assign(Object.assign({}, request), { pageNumber: _offset }));
125
+ },
126
+ });
111
127
  });
112
128
  }
113
129
  /**
@@ -116,61 +132,77 @@ class Chats {
116
132
  * @param {Chats.RequestOptions} requestOptions - Request-specific configuration.
117
133
  *
118
134
  * @example
119
- * await client.empathicVoice.chats.listChatEvents("id")
135
+ * await client.empathicVoice.chats.listChatEvents("470a49f6-1dec-4afe-8b61-035d3b2d63b0", {
136
+ * pageNumber: 0,
137
+ * pageSize: 3,
138
+ * ascendingOrder: true
139
+ * })
120
140
  */
121
141
  listChatEvents(id, request = {}, requestOptions) {
122
- var _a, _b;
123
142
  return __awaiter(this, void 0, void 0, function* () {
124
- const { pageSize, pageNumber, ascendingOrder } = request;
125
- const _queryParams = {};
126
- if (pageSize != null) {
127
- _queryParams['page_size'] = pageSize.toString();
128
- }
129
- if (pageNumber != null) {
130
- _queryParams['page_number'] = pageNumber.toString();
131
- }
132
- if (ascendingOrder != null) {
133
- _queryParams['ascending_order'] = ascendingOrder.toString();
134
- }
135
- const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
136
- url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, `v0/evi/chats/${encodeURIComponent(id)}`),
137
- method: 'GET',
138
- headers: Object.assign({ 'X-Fern-Language': 'JavaScript', 'X-Fern-SDK-Name': 'hume', 'X-Fern-SDK-Version': '0.8.5', 'X-Fern-Runtime': core.RUNTIME.type, 'X-Fern-Runtime-Version': core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
139
- contentType: 'application/json',
140
- queryParameters: _queryParams,
141
- timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null
142
- ? requestOptions.timeoutInSeconds * 1000
143
- : 60000,
144
- maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
145
- abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
146
- });
147
- if (_response.ok) {
148
- return serializers.empathicVoice.ReturnChatPagedEvents.parseOrThrow(_response.body, {
149
- unrecognizedObjectKeys: 'passthrough',
150
- allowUnrecognizedUnionMembers: true,
151
- allowUnrecognizedEnumValues: true,
152
- breadcrumbsPrefix: ['response'],
153
- });
154
- }
155
- if (_response.error.reason === 'status-code') {
156
- throw new errors.HumeError({
157
- statusCode: _response.error.statusCode,
158
- body: _response.error.body,
143
+ const list = (request) => __awaiter(this, void 0, void 0, function* () {
144
+ var _a, _b;
145
+ const { pageSize, pageNumber, ascendingOrder } = request;
146
+ const _queryParams = {};
147
+ if (pageSize != null) {
148
+ _queryParams['page_size'] = pageSize.toString();
149
+ }
150
+ if (pageNumber != null) {
151
+ _queryParams['page_number'] = pageNumber.toString();
152
+ }
153
+ if (ascendingOrder != null) {
154
+ _queryParams['ascending_order'] = ascendingOrder.toString();
155
+ }
156
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
157
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, `v0/evi/chats/${encodeURIComponent(id)}`),
158
+ method: 'GET',
159
+ headers: Object.assign({ 'X-Fern-Language': 'JavaScript', 'X-Fern-SDK-Name': 'hume', 'X-Fern-SDK-Version': '0.8.6', 'X-Fern-Runtime': core.RUNTIME.type, 'X-Fern-Runtime-Version': core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
160
+ contentType: 'application/json',
161
+ queryParameters: _queryParams,
162
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null
163
+ ? requestOptions.timeoutInSeconds * 1000
164
+ : 60000,
165
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
166
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
159
167
  });
160
- }
161
- switch (_response.error.reason) {
162
- case 'non-json':
163
- throw new errors.HumeError({
164
- statusCode: _response.error.statusCode,
165
- body: _response.error.rawBody,
168
+ if (_response.ok) {
169
+ return serializers.empathicVoice.ReturnChatPagedEvents.parseOrThrow(_response.body, {
170
+ unrecognizedObjectKeys: 'passthrough',
171
+ allowUnrecognizedUnionMembers: true,
172
+ allowUnrecognizedEnumValues: true,
173
+ breadcrumbsPrefix: ['response'],
166
174
  });
167
- case 'timeout':
168
- throw new errors.HumeTimeoutError();
169
- case 'unknown':
175
+ }
176
+ if (_response.error.reason === 'status-code') {
170
177
  throw new errors.HumeError({
171
- message: _response.error.errorMessage,
178
+ statusCode: _response.error.statusCode,
179
+ body: _response.error.body,
172
180
  });
173
- }
181
+ }
182
+ switch (_response.error.reason) {
183
+ case 'non-json':
184
+ throw new errors.HumeError({
185
+ statusCode: _response.error.statusCode,
186
+ body: _response.error.rawBody,
187
+ });
188
+ case 'timeout':
189
+ throw new errors.HumeTimeoutError();
190
+ case 'unknown':
191
+ throw new errors.HumeError({
192
+ message: _response.error.errorMessage,
193
+ });
194
+ }
195
+ });
196
+ let _offset = request.pageNumber != null ? request.pageNumber : 1;
197
+ return new core.Pageable({
198
+ response: yield list(request),
199
+ hasNextPage: (response) => { var _a; return ((_a = response === null || response === void 0 ? void 0 : response.eventsPage) !== null && _a !== void 0 ? _a : []).length > 0; },
200
+ getItems: (response) => { var _a; return (_a = response === null || response === void 0 ? void 0 : response.eventsPage) !== null && _a !== void 0 ? _a : []; },
201
+ loadPage: (_response) => {
202
+ _offset += 1;
203
+ return list(Object.assign(Object.assign({}, request), { pageNumber: _offset }));
204
+ },
205
+ });
174
206
  });
175
207
  }
176
208
  _getCustomAuthorizationHeaders() {
@@ -3,13 +3,17 @@
3
3
  */
4
4
  /**
5
5
  * @example
6
- * {}
6
+ * {
7
+ * pageNumber: 0,
8
+ * pageSize: 3,
9
+ * ascendingOrder: true
10
+ * }
7
11
  */
8
12
  export interface ChatsListChatEventsRequest {
9
13
  /**
10
- * Specifies the maximum number of results to include per page, enabling pagination.
14
+ * Specifies the maximum number of results to include per page, enabling pagination. The value must be between 1 and 100, inclusive.
11
15
  *
12
- * The value must be greater than or equal to 1. For example, if `page_size` is set to 10, each page will include up to 10 items. Defaults to 10.
16
+ * For example, if `page_size` is set to 10, each page will include up to 10 items. Defaults to 10.
13
17
  */
14
18
  pageSize?: number;
15
19
  /**
@@ -3,7 +3,11 @@
3
3
  */
4
4
  /**
5
5
  * @example
6
- * {}
6
+ * {
7
+ * pageNumber: 0,
8
+ * pageSize: 1,
9
+ * ascendingOrder: true
10
+ * }
7
11
  */
8
12
  export interface ChatsListChatsRequest {
9
13
  /**
@@ -13,9 +17,9 @@ export interface ChatsListChatsRequest {
13
17
  */
14
18
  pageNumber?: number;
15
19
  /**
16
- * Specifies the maximum number of results to include per page, enabling pagination.
20
+ * Specifies the maximum number of results to include per page, enabling pagination. The value must be between 1 and 100, inclusive.
17
21
  *
18
- * The value must be greater than or equal to 1. For example, if `page_size` is set to 10, each page will include up to 10 items. Defaults to 10.
22
+ * For example, if `page_size` is set to 10, each page will include up to 10 items. Defaults to 10.
19
23
  */
20
24
  pageSize?: number;
21
25
  /**