@easyedu/js-lsm-api 1.103.0 → 1.104.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 (98) hide show
  1. package/.openapi-generator/FILES +28 -0
  2. package/README.md +22 -2
  3. package/dist/apis/ChatApi.d.ts +98 -0
  4. package/dist/apis/ChatApi.js +255 -0
  5. package/dist/esm/apis/ChatApi.d.ts +98 -0
  6. package/dist/esm/apis/ChatApi.js +255 -0
  7. package/dist/esm/models/AdminChatMessage.d.ts +51 -0
  8. package/dist/esm/models/AdminChatMessage.js +54 -0
  9. package/dist/esm/models/AdminConversationDetail.d.ts +90 -0
  10. package/dist/esm/models/AdminConversationDetail.js +81 -0
  11. package/dist/esm/models/AdminConversationList.d.ts +57 -0
  12. package/dist/esm/models/AdminConversationList.js +60 -0
  13. package/dist/esm/models/AdminConversationSummary.d.ts +83 -0
  14. package/dist/esm/models/AdminConversationSummary.js +76 -0
  15. package/dist/esm/models/ChatDailyUsage.d.ts +39 -0
  16. package/dist/esm/models/ChatDailyUsage.js +48 -0
  17. package/dist/esm/models/ChatModelUsage.d.ts +68 -0
  18. package/dist/esm/models/ChatModelUsage.js +67 -0
  19. package/dist/esm/models/ChatQuota.d.ts +56 -0
  20. package/dist/esm/models/ChatQuota.js +59 -0
  21. package/dist/esm/models/ChatQuotaExceeded.d.ts +56 -0
  22. package/dist/esm/models/ChatQuotaExceeded.js +59 -0
  23. package/dist/esm/models/ChatTurnUsage.d.ts +82 -0
  24. package/dist/esm/models/ChatTurnUsage.js +78 -0
  25. package/dist/esm/models/ChatUsageTotals.d.ts +68 -0
  26. package/dist/esm/models/ChatUsageTotals.js +67 -0
  27. package/dist/esm/models/ChatUserIdentity.d.ts +50 -0
  28. package/dist/esm/models/ChatUserIdentity.js +55 -0
  29. package/dist/esm/models/GetChatSettings.d.ts +51 -0
  30. package/dist/esm/models/GetChatSettings.js +57 -0
  31. package/dist/esm/models/GetChatUsage.d.ts +59 -0
  32. package/dist/esm/models/GetChatUsage.js +62 -0
  33. package/dist/esm/models/PutChatSettings.d.ts +32 -0
  34. package/dist/esm/models/PutChatSettings.js +43 -0
  35. package/dist/esm/models/index.d.ts +14 -0
  36. package/dist/esm/models/index.js +14 -0
  37. package/dist/models/AdminChatMessage.d.ts +51 -0
  38. package/dist/models/AdminChatMessage.js +61 -0
  39. package/dist/models/AdminConversationDetail.d.ts +90 -0
  40. package/dist/models/AdminConversationDetail.js +88 -0
  41. package/dist/models/AdminConversationList.d.ts +57 -0
  42. package/dist/models/AdminConversationList.js +67 -0
  43. package/dist/models/AdminConversationSummary.d.ts +83 -0
  44. package/dist/models/AdminConversationSummary.js +83 -0
  45. package/dist/models/ChatDailyUsage.d.ts +39 -0
  46. package/dist/models/ChatDailyUsage.js +55 -0
  47. package/dist/models/ChatModelUsage.d.ts +68 -0
  48. package/dist/models/ChatModelUsage.js +74 -0
  49. package/dist/models/ChatQuota.d.ts +56 -0
  50. package/dist/models/ChatQuota.js +66 -0
  51. package/dist/models/ChatQuotaExceeded.d.ts +56 -0
  52. package/dist/models/ChatQuotaExceeded.js +66 -0
  53. package/dist/models/ChatTurnUsage.d.ts +82 -0
  54. package/dist/models/ChatTurnUsage.js +86 -0
  55. package/dist/models/ChatUsageTotals.d.ts +68 -0
  56. package/dist/models/ChatUsageTotals.js +74 -0
  57. package/dist/models/ChatUserIdentity.d.ts +50 -0
  58. package/dist/models/ChatUserIdentity.js +62 -0
  59. package/dist/models/GetChatSettings.d.ts +51 -0
  60. package/dist/models/GetChatSettings.js +65 -0
  61. package/dist/models/GetChatUsage.d.ts +59 -0
  62. package/dist/models/GetChatUsage.js +69 -0
  63. package/dist/models/PutChatSettings.d.ts +32 -0
  64. package/dist/models/PutChatSettings.js +50 -0
  65. package/dist/models/index.d.ts +14 -0
  66. package/dist/models/index.js +14 -0
  67. package/docs/AdminChatMessage.md +40 -0
  68. package/docs/AdminConversationDetail.md +52 -0
  69. package/docs/AdminConversationList.md +42 -0
  70. package/docs/AdminConversationSummary.md +50 -0
  71. package/docs/ChatApi.md +422 -0
  72. package/docs/ChatDailyUsage.md +36 -0
  73. package/docs/ChatModelUsage.md +46 -0
  74. package/docs/ChatQuota.md +42 -0
  75. package/docs/ChatQuotaExceeded.md +42 -0
  76. package/docs/ChatTurnUsage.md +48 -0
  77. package/docs/ChatUsageTotals.md +46 -0
  78. package/docs/ChatUserIdentity.md +40 -0
  79. package/docs/GetChatSettings.md +38 -0
  80. package/docs/GetChatUsage.md +42 -0
  81. package/docs/PutChatSettings.md +34 -0
  82. package/package.json +1 -1
  83. package/src/apis/ChatApi.ts +339 -0
  84. package/src/models/AdminChatMessage.ts +100 -0
  85. package/src/models/AdminConversationDetail.ts +175 -0
  86. package/src/models/AdminConversationList.ts +110 -0
  87. package/src/models/AdminConversationSummary.ts +159 -0
  88. package/src/models/ChatDailyUsage.ts +83 -0
  89. package/src/models/ChatModelUsage.ts +120 -0
  90. package/src/models/ChatQuota.ts +102 -0
  91. package/src/models/ChatQuotaExceeded.ts +102 -0
  92. package/src/models/ChatTurnUsage.ts +140 -0
  93. package/src/models/ChatUsageTotals.ts +120 -0
  94. package/src/models/ChatUserIdentity.ts +93 -0
  95. package/src/models/GetChatSettings.ts +94 -0
  96. package/src/models/GetChatUsage.ts +124 -0
  97. package/src/models/PutChatSettings.ts +66 -0
  98. package/src/models/index.ts +14 -0
package/docs/ChatApi.md CHANGED
@@ -5,10 +5,16 @@ All URIs are relative to *https://sbzw93t49b.execute-api.us-east-2.amazonaws.com
5
5
  | Method | HTTP request | Description |
6
6
  |------------- | ------------- | -------------|
7
7
  | [**deleteConversation**](ChatApi.md#deleteconversation) | **DELETE** /chat/conversations/{conversationId} | Delete a conversation |
8
+ | [**getChatAdminConversation**](ChatApi.md#getchatadminconversation) | **GET** /chat/admin/conversations/{conversationId} | Get a conversation transcript from the selected portal |
9
+ | [**getChatAdminConversations**](ChatApi.md#getchatadminconversations) | **GET** /chat/admin/conversations | List conversations in the selected portal |
10
+ | [**getChatAdminSettings**](ChatApi.md#getchatadminsettings) | **GET** /chat/admin/settings | Get chatbot settings for the selected portal |
11
+ | [**getChatAdminUsage**](ChatApi.md#getchatadminusage) | **GET** /chat/admin/usage | Get chatbot usage analytics for the selected portal |
12
+ | [**getChatQuota**](ChatApi.md#getchatquota) | **GET** /chat/quota | Get the current user\'s chat quota |
8
13
  | [**getConversationMessages**](ChatApi.md#getconversationmessages) | **GET** /chat/conversations/{conversationId}/messages | Get all messages in a conversation |
9
14
  | [**getConversations**](ChatApi.md#getconversations) | **GET** /chat/conversations | List conversations for the current user |
10
15
  | [**postConversation**](ChatApi.md#postconversation) | **POST** /chat/conversations | Create a new conversation |
11
16
  | [**postMessage**](ChatApi.md#postmessage) | **POST** /chat/conversations/{conversationId}/messages | Send a message to a conversation |
17
+ | [**putChatAdminSettings**](ChatApi.md#putchatadminsettings) | **PUT** /chat/admin/settings | Update chatbot settings for the selected portal |
12
18
 
13
19
 
14
20
 
@@ -80,6 +86,352 @@ No authorization required
80
86
  [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
81
87
 
82
88
 
89
+ ## getChatAdminConversation
90
+
91
+ > AdminConversationDetail getChatAdminConversation(conversationId)
92
+
93
+ Get a conversation transcript from the selected portal
94
+
95
+ ### Example
96
+
97
+ ```ts
98
+ import {
99
+ Configuration,
100
+ ChatApi,
101
+ } from '@easyedu/js-lsm-api';
102
+ import type { GetChatAdminConversationRequest } from '@easyedu/js-lsm-api';
103
+
104
+ async function example() {
105
+ console.log("🚀 Testing @easyedu/js-lsm-api SDK...");
106
+ const api = new ChatApi();
107
+
108
+ const body = {
109
+ // string
110
+ conversationId: conversationId_example,
111
+ } satisfies GetChatAdminConversationRequest;
112
+
113
+ try {
114
+ const data = await api.getChatAdminConversation(body);
115
+ console.log(data);
116
+ } catch (error) {
117
+ console.error(error);
118
+ }
119
+ }
120
+
121
+ // Run the test
122
+ example().catch(console.error);
123
+ ```
124
+
125
+ ### Parameters
126
+
127
+
128
+ | Name | Type | Description | Notes |
129
+ |------------- | ------------- | ------------- | -------------|
130
+ | **conversationId** | `string` | | [Defaults to `undefined`] |
131
+
132
+ ### Return type
133
+
134
+ [**AdminConversationDetail**](AdminConversationDetail.md)
135
+
136
+ ### Authorization
137
+
138
+ No authorization required
139
+
140
+ ### HTTP request headers
141
+
142
+ - **Content-Type**: Not defined
143
+ - **Accept**: `application/json`
144
+
145
+
146
+ ### HTTP response details
147
+ | Status code | Description | Response headers |
148
+ |-------------|-------------|------------------|
149
+ | **200** | Portal-scoped conversation transcript and usage | - |
150
+ | **401** | Unauthorized | - |
151
+ | **403** | Forbidden | - |
152
+ | **404** | Conversation not found | - |
153
+
154
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
155
+
156
+
157
+ ## getChatAdminConversations
158
+
159
+ > AdminConversationList getChatAdminConversations(page, pageSize, userId, model, createdFrom, createdTo)
160
+
161
+ List conversations in the selected portal
162
+
163
+ ### Example
164
+
165
+ ```ts
166
+ import {
167
+ Configuration,
168
+ ChatApi,
169
+ } from '@easyedu/js-lsm-api';
170
+ import type { GetChatAdminConversationsRequest } from '@easyedu/js-lsm-api';
171
+
172
+ async function example() {
173
+ console.log("🚀 Testing @easyedu/js-lsm-api SDK...");
174
+ const api = new ChatApi();
175
+
176
+ const body = {
177
+ // number (optional)
178
+ page: 56,
179
+ // number (optional)
180
+ pageSize: 56,
181
+ // string | User external ID (optional)
182
+ userId: userId_example,
183
+ // string (optional)
184
+ model: model_example,
185
+ // number | Inclusive Unix timestamp (optional)
186
+ createdFrom: 789,
187
+ // number | Exclusive Unix timestamp (optional)
188
+ createdTo: 789,
189
+ } satisfies GetChatAdminConversationsRequest;
190
+
191
+ try {
192
+ const data = await api.getChatAdminConversations(body);
193
+ console.log(data);
194
+ } catch (error) {
195
+ console.error(error);
196
+ }
197
+ }
198
+
199
+ // Run the test
200
+ example().catch(console.error);
201
+ ```
202
+
203
+ ### Parameters
204
+
205
+
206
+ | Name | Type | Description | Notes |
207
+ |------------- | ------------- | ------------- | -------------|
208
+ | **page** | `number` | | [Optional] [Defaults to `1`] |
209
+ | **pageSize** | `number` | | [Optional] [Defaults to `20`] |
210
+ | **userId** | `string` | User external ID | [Optional] [Defaults to `undefined`] |
211
+ | **model** | `string` | | [Optional] [Defaults to `undefined`] |
212
+ | **createdFrom** | `number` | Inclusive Unix timestamp | [Optional] [Defaults to `undefined`] |
213
+ | **createdTo** | `number` | Exclusive Unix timestamp | [Optional] [Defaults to `undefined`] |
214
+
215
+ ### Return type
216
+
217
+ [**AdminConversationList**](AdminConversationList.md)
218
+
219
+ ### Authorization
220
+
221
+ No authorization required
222
+
223
+ ### HTTP request headers
224
+
225
+ - **Content-Type**: Not defined
226
+ - **Accept**: `application/json`
227
+
228
+
229
+ ### HTTP response details
230
+ | Status code | Description | Response headers |
231
+ |-------------|-------------|------------------|
232
+ | **200** | Portal-scoped conversation summaries | - |
233
+ | **400** | Invalid filters | - |
234
+ | **401** | Unauthorized | - |
235
+ | **403** | Forbidden | - |
236
+
237
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
238
+
239
+
240
+ ## getChatAdminSettings
241
+
242
+ > GetChatSettings getChatAdminSettings()
243
+
244
+ Get chatbot settings for the selected portal
245
+
246
+ ### Example
247
+
248
+ ```ts
249
+ import {
250
+ Configuration,
251
+ ChatApi,
252
+ } from '@easyedu/js-lsm-api';
253
+ import type { GetChatAdminSettingsRequest } from '@easyedu/js-lsm-api';
254
+
255
+ async function example() {
256
+ console.log("🚀 Testing @easyedu/js-lsm-api SDK...");
257
+ const api = new ChatApi();
258
+
259
+ try {
260
+ const data = await api.getChatAdminSettings();
261
+ console.log(data);
262
+ } catch (error) {
263
+ console.error(error);
264
+ }
265
+ }
266
+
267
+ // Run the test
268
+ example().catch(console.error);
269
+ ```
270
+
271
+ ### Parameters
272
+
273
+ This endpoint does not need any parameter.
274
+
275
+ ### Return type
276
+
277
+ [**GetChatSettings**](GetChatSettings.md)
278
+
279
+ ### Authorization
280
+
281
+ No authorization required
282
+
283
+ ### HTTP request headers
284
+
285
+ - **Content-Type**: Not defined
286
+ - **Accept**: `application/json`
287
+
288
+
289
+ ### HTTP response details
290
+ | Status code | Description | Response headers |
291
+ |-------------|-------------|------------------|
292
+ | **200** | Selected portal chatbot settings | - |
293
+ | **401** | Unauthorized | - |
294
+ | **403** | Forbidden | - |
295
+
296
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
297
+
298
+
299
+ ## getChatAdminUsage
300
+
301
+ > GetChatUsage getChatAdminUsage(userId, model, from, to)
302
+
303
+ Get chatbot usage analytics for the selected portal
304
+
305
+ ### Example
306
+
307
+ ```ts
308
+ import {
309
+ Configuration,
310
+ ChatApi,
311
+ } from '@easyedu/js-lsm-api';
312
+ import type { GetChatAdminUsageRequest } from '@easyedu/js-lsm-api';
313
+
314
+ async function example() {
315
+ console.log("🚀 Testing @easyedu/js-lsm-api SDK...");
316
+ const api = new ChatApi();
317
+
318
+ const body = {
319
+ // string | User external ID (optional)
320
+ userId: userId_example,
321
+ // string (optional)
322
+ model: model_example,
323
+ // number | Inclusive Unix timestamp; defaults to 30 UTC days before to (optional)
324
+ from: 789,
325
+ // number | Exclusive Unix timestamp; defaults to now (optional)
326
+ to: 789,
327
+ } satisfies GetChatAdminUsageRequest;
328
+
329
+ try {
330
+ const data = await api.getChatAdminUsage(body);
331
+ console.log(data);
332
+ } catch (error) {
333
+ console.error(error);
334
+ }
335
+ }
336
+
337
+ // Run the test
338
+ example().catch(console.error);
339
+ ```
340
+
341
+ ### Parameters
342
+
343
+
344
+ | Name | Type | Description | Notes |
345
+ |------------- | ------------- | ------------- | -------------|
346
+ | **userId** | `string` | User external ID | [Optional] [Defaults to `undefined`] |
347
+ | **model** | `string` | | [Optional] [Defaults to `undefined`] |
348
+ | **from** | `number` | Inclusive Unix timestamp; defaults to 30 UTC days before to | [Optional] [Defaults to `undefined`] |
349
+ | **to** | `number` | Exclusive Unix timestamp; defaults to now | [Optional] [Defaults to `undefined`] |
350
+
351
+ ### Return type
352
+
353
+ [**GetChatUsage**](GetChatUsage.md)
354
+
355
+ ### Authorization
356
+
357
+ No authorization required
358
+
359
+ ### HTTP request headers
360
+
361
+ - **Content-Type**: Not defined
362
+ - **Accept**: `application/json`
363
+
364
+
365
+ ### HTTP response details
366
+ | Status code | Description | Response headers |
367
+ |-------------|-------------|------------------|
368
+ | **200** | Portal-scoped chatbot usage analytics | - |
369
+ | **400** | Invalid timestamp range or range exceeds 366 days | - |
370
+ | **401** | Unauthorized | - |
371
+ | **403** | Forbidden | - |
372
+
373
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
374
+
375
+
376
+ ## getChatQuota
377
+
378
+ > ChatQuota getChatQuota()
379
+
380
+ Get the current user\'s chat quota
381
+
382
+ ### Example
383
+
384
+ ```ts
385
+ import {
386
+ Configuration,
387
+ ChatApi,
388
+ } from '@easyedu/js-lsm-api';
389
+ import type { GetChatQuotaRequest } from '@easyedu/js-lsm-api';
390
+
391
+ async function example() {
392
+ console.log("🚀 Testing @easyedu/js-lsm-api SDK...");
393
+ const api = new ChatApi();
394
+
395
+ try {
396
+ const data = await api.getChatQuota();
397
+ console.log(data);
398
+ } catch (error) {
399
+ console.error(error);
400
+ }
401
+ }
402
+
403
+ // Run the test
404
+ example().catch(console.error);
405
+ ```
406
+
407
+ ### Parameters
408
+
409
+ This endpoint does not need any parameter.
410
+
411
+ ### Return type
412
+
413
+ [**ChatQuota**](ChatQuota.md)
414
+
415
+ ### Authorization
416
+
417
+ No authorization required
418
+
419
+ ### HTTP request headers
420
+
421
+ - **Content-Type**: Not defined
422
+ - **Accept**: `application/json`
423
+
424
+
425
+ ### HTTP response details
426
+ | Status code | Description | Response headers |
427
+ |-------------|-------------|------------------|
428
+ | **200** | Chat quota and next UTC reset | - |
429
+ | **401** | Unauthorized | - |
430
+ | **403** | Forbidden | - |
431
+
432
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
433
+
434
+
83
435
  ## getConversationMessages
84
436
 
85
437
  > Array<GetChatMessage> getConversationMessages(conversationId)
@@ -281,6 +633,7 @@ No authorization required
281
633
  | **201** | Conversation created with LLM response | - |
282
634
  | **401** | Unauthorized | - |
283
635
  | **403** | Forbidden | - |
636
+ | **429** | Learner daily message quota exceeded | - |
284
637
 
285
638
  [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
286
639
 
@@ -352,6 +705,75 @@ No authorization required
352
705
  | **401** | Unauthorized | - |
353
706
  | **403** | Forbidden | - |
354
707
  | **404** | Conversation not found | - |
708
+ | **429** | Learner daily message quota exceeded | - |
709
+
710
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
711
+
712
+
713
+ ## putChatAdminSettings
714
+
715
+ > GetChatSettings putChatAdminSettings(putChatSettings)
716
+
717
+ Update chatbot settings for the selected portal
718
+
719
+ ### Example
720
+
721
+ ```ts
722
+ import {
723
+ Configuration,
724
+ ChatApi,
725
+ } from '@easyedu/js-lsm-api';
726
+ import type { PutChatAdminSettingsRequest } from '@easyedu/js-lsm-api';
727
+
728
+ async function example() {
729
+ console.log("🚀 Testing @easyedu/js-lsm-api SDK...");
730
+ const api = new ChatApi();
731
+
732
+ const body = {
733
+ // PutChatSettings
734
+ putChatSettings: ...,
735
+ } satisfies PutChatAdminSettingsRequest;
736
+
737
+ try {
738
+ const data = await api.putChatAdminSettings(body);
739
+ console.log(data);
740
+ } catch (error) {
741
+ console.error(error);
742
+ }
743
+ }
744
+
745
+ // Run the test
746
+ example().catch(console.error);
747
+ ```
748
+
749
+ ### Parameters
750
+
751
+
752
+ | Name | Type | Description | Notes |
753
+ |------------- | ------------- | ------------- | -------------|
754
+ | **putChatSettings** | [PutChatSettings](PutChatSettings.md) | | |
755
+
756
+ ### Return type
757
+
758
+ [**GetChatSettings**](GetChatSettings.md)
759
+
760
+ ### Authorization
761
+
762
+ No authorization required
763
+
764
+ ### HTTP request headers
765
+
766
+ - **Content-Type**: `application/json`
767
+ - **Accept**: `application/json`
768
+
769
+
770
+ ### HTTP response details
771
+ | Status code | Description | Response headers |
772
+ |-------------|-------------|------------------|
773
+ | **200** | Updated selected portal chatbot settings | - |
774
+ | **400** | Invalid learner daily message limit | - |
775
+ | **401** | Unauthorized | - |
776
+ | **403** | Forbidden | - |
355
777
 
356
778
  [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
357
779
 
@@ -0,0 +1,36 @@
1
+
2
+ # ChatDailyUsage
3
+
4
+
5
+ ## Properties
6
+
7
+ Name | Type
8
+ ------------ | -------------
9
+ `date` | Date
10
+ `usage` | [ChatUsageTotals](ChatUsageTotals.md)
11
+
12
+ ## Example
13
+
14
+ ```typescript
15
+ import type { ChatDailyUsage } from '@easyedu/js-lsm-api'
16
+
17
+ // TODO: Update the object below with actual values
18
+ const example = {
19
+ "date": null,
20
+ "usage": null,
21
+ } satisfies ChatDailyUsage
22
+
23
+ console.log(example)
24
+
25
+ // Convert the instance to a JSON string
26
+ const exampleJSON: string = JSON.stringify(example)
27
+ console.log(exampleJSON)
28
+
29
+ // Parse the JSON string back to an object
30
+ const exampleParsed = JSON.parse(exampleJSON) as ChatDailyUsage
31
+ console.log(exampleParsed)
32
+ ```
33
+
34
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
35
+
36
+
@@ -0,0 +1,46 @@
1
+
2
+ # ChatModelUsage
3
+
4
+
5
+ ## Properties
6
+
7
+ Name | Type
8
+ ------------ | -------------
9
+ `provider` | string
10
+ `model` | string
11
+ `acceptedRequests` | number
12
+ `providerRequestCount` | number
13
+ `inputTokens` | number
14
+ `outputTokens` | number
15
+ `totalTokens` | number
16
+
17
+ ## Example
18
+
19
+ ```typescript
20
+ import type { ChatModelUsage } from '@easyedu/js-lsm-api'
21
+
22
+ // TODO: Update the object below with actual values
23
+ const example = {
24
+ "provider": null,
25
+ "model": null,
26
+ "acceptedRequests": null,
27
+ "providerRequestCount": null,
28
+ "inputTokens": null,
29
+ "outputTokens": null,
30
+ "totalTokens": null,
31
+ } satisfies ChatModelUsage
32
+
33
+ console.log(example)
34
+
35
+ // Convert the instance to a JSON string
36
+ const exampleJSON: string = JSON.stringify(example)
37
+ console.log(exampleJSON)
38
+
39
+ // Parse the JSON string back to an object
40
+ const exampleParsed = JSON.parse(exampleJSON) as ChatModelUsage
41
+ console.log(exampleParsed)
42
+ ```
43
+
44
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
45
+
46
+
@@ -0,0 +1,42 @@
1
+
2
+ # ChatQuota
3
+
4
+
5
+ ## Properties
6
+
7
+ Name | Type
8
+ ------------ | -------------
9
+ `applies` | boolean
10
+ `limit` | number
11
+ `used` | number
12
+ `remaining` | number
13
+ `resetsAt` | number
14
+
15
+ ## Example
16
+
17
+ ```typescript
18
+ import type { ChatQuota } from '@easyedu/js-lsm-api'
19
+
20
+ // TODO: Update the object below with actual values
21
+ const example = {
22
+ "applies": null,
23
+ "limit": null,
24
+ "used": null,
25
+ "remaining": null,
26
+ "resetsAt": null,
27
+ } satisfies ChatQuota
28
+
29
+ console.log(example)
30
+
31
+ // Convert the instance to a JSON string
32
+ const exampleJSON: string = JSON.stringify(example)
33
+ console.log(exampleJSON)
34
+
35
+ // Parse the JSON string back to an object
36
+ const exampleParsed = JSON.parse(exampleJSON) as ChatQuota
37
+ console.log(exampleParsed)
38
+ ```
39
+
40
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
41
+
42
+
@@ -0,0 +1,42 @@
1
+
2
+ # ChatQuotaExceeded
3
+
4
+
5
+ ## Properties
6
+
7
+ Name | Type
8
+ ------------ | -------------
9
+ `error` | string
10
+ `limit` | number
11
+ `used` | number
12
+ `remaining` | number
13
+ `resetsAt` | number
14
+
15
+ ## Example
16
+
17
+ ```typescript
18
+ import type { ChatQuotaExceeded } from '@easyedu/js-lsm-api'
19
+
20
+ // TODO: Update the object below with actual values
21
+ const example = {
22
+ "error": null,
23
+ "limit": null,
24
+ "used": null,
25
+ "remaining": null,
26
+ "resetsAt": null,
27
+ } satisfies ChatQuotaExceeded
28
+
29
+ console.log(example)
30
+
31
+ // Convert the instance to a JSON string
32
+ const exampleJSON: string = JSON.stringify(example)
33
+ console.log(exampleJSON)
34
+
35
+ // Parse the JSON string back to an object
36
+ const exampleParsed = JSON.parse(exampleJSON) as ChatQuotaExceeded
37
+ console.log(exampleParsed)
38
+ ```
39
+
40
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
41
+
42
+
@@ -0,0 +1,48 @@
1
+
2
+ # ChatTurnUsage
3
+
4
+
5
+ ## Properties
6
+
7
+ Name | Type
8
+ ------------ | -------------
9
+ `status` | string
10
+ `provider` | string
11
+ `model` | string
12
+ `providerRequestCount` | number
13
+ `inputTokens` | number
14
+ `outputTokens` | number
15
+ `totalTokens` | number
16
+ `createdAt` | number
17
+
18
+ ## Example
19
+
20
+ ```typescript
21
+ import type { ChatTurnUsage } from '@easyedu/js-lsm-api'
22
+
23
+ // TODO: Update the object below with actual values
24
+ const example = {
25
+ "status": null,
26
+ "provider": null,
27
+ "model": null,
28
+ "providerRequestCount": null,
29
+ "inputTokens": null,
30
+ "outputTokens": null,
31
+ "totalTokens": null,
32
+ "createdAt": null,
33
+ } satisfies ChatTurnUsage
34
+
35
+ console.log(example)
36
+
37
+ // Convert the instance to a JSON string
38
+ const exampleJSON: string = JSON.stringify(example)
39
+ console.log(exampleJSON)
40
+
41
+ // Parse the JSON string back to an object
42
+ const exampleParsed = JSON.parse(exampleJSON) as ChatTurnUsage
43
+ console.log(exampleParsed)
44
+ ```
45
+
46
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
47
+
48
+
@@ -0,0 +1,46 @@
1
+
2
+ # ChatUsageTotals
3
+
4
+
5
+ ## Properties
6
+
7
+ Name | Type
8
+ ------------ | -------------
9
+ `acceptedRequests` | number
10
+ `successfulRequests` | number
11
+ `failedRequests` | number
12
+ `providerRequestCount` | number
13
+ `inputTokens` | number
14
+ `outputTokens` | number
15
+ `totalTokens` | number
16
+
17
+ ## Example
18
+
19
+ ```typescript
20
+ import type { ChatUsageTotals } from '@easyedu/js-lsm-api'
21
+
22
+ // TODO: Update the object below with actual values
23
+ const example = {
24
+ "acceptedRequests": null,
25
+ "successfulRequests": null,
26
+ "failedRequests": null,
27
+ "providerRequestCount": null,
28
+ "inputTokens": null,
29
+ "outputTokens": null,
30
+ "totalTokens": null,
31
+ } satisfies ChatUsageTotals
32
+
33
+ console.log(example)
34
+
35
+ // Convert the instance to a JSON string
36
+ const exampleJSON: string = JSON.stringify(example)
37
+ console.log(exampleJSON)
38
+
39
+ // Parse the JSON string back to an object
40
+ const exampleParsed = JSON.parse(exampleJSON) as ChatUsageTotals
41
+ console.log(exampleParsed)
42
+ ```
43
+
44
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
45
+
46
+