@iblai/iblai-api 4.23.2-test-core → 4.24.0-core
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +37 -1
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +37 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/index.umd.js +37 -1
- package/dist/index.umd.js.map +1 -1
- package/dist/types/index.d.ts +8 -0
- package/dist/types/models/ActivityInfo.d.ts +7 -0
- package/dist/types/models/LearnerAnalyticsResponse.d.ts +12 -0
- package/dist/types/models/LearnerAnalyticsResult.d.ts +16 -0
- package/dist/types/models/MetricDetail.d.ts +7 -0
- package/dist/types/models/Pagination.d.ts +11 -16
- package/dist/types/models/PlatformMetrics.d.ts +15 -0
- package/dist/types/models/PlatformSummary.d.ts +17 -0
- package/dist/types/models/PointsMetric.d.ts +7 -0
- package/dist/types/models/SkillsMetric.d.ts +10 -0
- package/dist/types/models/UserInfo.d.ts +8 -11
- package/dist/types/services/AiAnalyticsService.d.ts +38 -0
- package/package.json +1 -1
- package/sdk_schema.yml +277 -22
- package/src/core/OpenAPI.ts +1 -1
- package/src/index.ts +8 -0
- package/src/models/ActivityInfo.ts +12 -0
- package/src/models/LearnerAnalyticsResponse.ts +17 -0
- package/src/models/LearnerAnalyticsResult.ts +21 -0
- package/src/models/MetricDetail.ts +12 -0
- package/src/models/Pagination.ts +11 -16
- package/src/models/PlatformMetrics.ts +20 -0
- package/src/models/PlatformSummary.ts +22 -0
- package/src/models/PointsMetric.ts +12 -0
- package/src/models/SkillsMetric.ts +15 -0
- package/src/models/UserInfo.ts +8 -11
- package/src/services/AiAnalyticsService.ts +54 -0
package/src/models/UserInfo.ts
CHANGED
|
@@ -2,17 +2,14 @@
|
|
|
2
2
|
/* istanbul ignore file */
|
|
3
3
|
/* tslint:disable */
|
|
4
4
|
/* eslint-disable */
|
|
5
|
+
/**
|
|
6
|
+
* Serializer for user information.
|
|
7
|
+
*/
|
|
5
8
|
export type UserInfo = {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
* edX username
|
|
12
|
-
*/
|
|
13
|
-
username?: string | null;
|
|
14
|
-
email: string;
|
|
15
|
-
active: boolean;
|
|
16
|
-
edx_data: any;
|
|
9
|
+
user_id: number;
|
|
10
|
+
username: string | null;
|
|
11
|
+
email: string | null;
|
|
12
|
+
name: string;
|
|
13
|
+
is_active: boolean;
|
|
17
14
|
};
|
|
18
15
|
|
|
@@ -18,6 +18,7 @@ import type { EngagementPerCourse } from '../models/EngagementPerCourse';
|
|
|
18
18
|
import type { Enrollments } from '../models/Enrollments';
|
|
19
19
|
import type { EnrollmentsPerUser } from '../models/EnrollmentsPerUser';
|
|
20
20
|
import type { GradingPerUser } from '../models/GradingPerUser';
|
|
21
|
+
import type { LearnerAnalyticsResponse } from '../models/LearnerAnalyticsResponse';
|
|
21
22
|
import type { LearnerInformationAPI } from '../models/LearnerInformationAPI';
|
|
22
23
|
import type { NewPerLearnerList } from '../models/NewPerLearnerList';
|
|
23
24
|
import type { OvertimeWithChangeInfo } from '../models/OvertimeWithChangeInfo';
|
|
@@ -49,6 +50,59 @@ import type { CancelablePromise } from '../core/CancelablePromise';
|
|
|
49
50
|
import { OpenAPI } from '../core/OpenAPI';
|
|
50
51
|
import { request as __request } from '../core/request';
|
|
51
52
|
export class AiAnalyticsService {
|
|
53
|
+
/**
|
|
54
|
+
* Unified API endpoint for learner analytics.
|
|
55
|
+
*
|
|
56
|
+
* This endpoint provides either:
|
|
57
|
+
* 1. Cross-platform summary (when only username is provided)
|
|
58
|
+
* 2. Platform-specific detailed data (when username + platform_key are provided)
|
|
59
|
+
*
|
|
60
|
+
* Query params:
|
|
61
|
+
* - username (required): Username of the learner
|
|
62
|
+
* - platform_key (optional): Platform key for platform-specific data
|
|
63
|
+
* - page (optional): Page number (default: 1)
|
|
64
|
+
* - limit (optional): Records per page (default: 20, max: 100)
|
|
65
|
+
*
|
|
66
|
+
* Returns:
|
|
67
|
+
* - If platform_key provided: Detailed platform metrics
|
|
68
|
+
* - If no platform_key: Cross-platform summary with pagination
|
|
69
|
+
* @returns LearnerAnalyticsResponse
|
|
70
|
+
* @throws ApiError
|
|
71
|
+
*/
|
|
72
|
+
public static analyticsLearnersRetrieve({
|
|
73
|
+
limit = 20,
|
|
74
|
+
page = 1,
|
|
75
|
+
platformKey,
|
|
76
|
+
username,
|
|
77
|
+
}: {
|
|
78
|
+
/**
|
|
79
|
+
* Number of records per page (default: 20, max: 100)
|
|
80
|
+
*/
|
|
81
|
+
limit?: number,
|
|
82
|
+
/**
|
|
83
|
+
* Page number (default: 1)
|
|
84
|
+
*/
|
|
85
|
+
page?: number,
|
|
86
|
+
/**
|
|
87
|
+
* Optional platform key - if provided, returns platform-specific detailed data
|
|
88
|
+
*/
|
|
89
|
+
platformKey?: string,
|
|
90
|
+
/**
|
|
91
|
+
* Username of the learner to get analytics for. Defaults to self if not provided.
|
|
92
|
+
*/
|
|
93
|
+
username?: string,
|
|
94
|
+
}): CancelablePromise<LearnerAnalyticsResponse> {
|
|
95
|
+
return __request(OpenAPI, {
|
|
96
|
+
method: 'GET',
|
|
97
|
+
url: '/api/analytics/learners/',
|
|
98
|
+
query: {
|
|
99
|
+
'limit': limit,
|
|
100
|
+
'page': page,
|
|
101
|
+
'platform_key': platformKey,
|
|
102
|
+
'username': username,
|
|
103
|
+
},
|
|
104
|
+
});
|
|
105
|
+
}
|
|
52
106
|
/**
|
|
53
107
|
* Update time spent tracking data from client-side events.
|
|
54
108
|
*
|