@instructure/athena-api-client 2.12.0 → 2.13.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.
- package/README.md +4 -0
- package/dist/apis/QuizSessionsApi.d.ts +35 -1
- package/dist/apis/QuizSessionsApi.js +65 -1
- package/dist/esm/apis/QuizSessionsApi.d.ts +35 -1
- package/dist/esm/apis/QuizSessionsApi.js +65 -1
- package/dist/esm/models/PaginatedQuizSessions.d.ts +39 -0
- package/dist/esm/models/PaginatedQuizSessions.js +48 -0
- package/dist/esm/models/QuizSessionListItem.d.ts +85 -0
- package/dist/esm/models/QuizSessionListItem.js +81 -0
- package/dist/esm/models/QuizSessionScore.d.ts +38 -0
- package/dist/esm/models/QuizSessionScore.js +47 -0
- package/dist/esm/models/index.d.ts +3 -0
- package/dist/esm/models/index.js +3 -0
- package/dist/models/PaginatedQuizSessions.d.ts +39 -0
- package/dist/models/PaginatedQuizSessions.js +55 -0
- package/dist/models/QuizSessionListItem.d.ts +85 -0
- package/dist/models/QuizSessionListItem.js +89 -0
- package/dist/models/QuizSessionScore.d.ts +38 -0
- package/dist/models/QuizSessionScore.js +54 -0
- package/dist/models/index.d.ts +3 -0
- package/dist/models/index.js +3 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -104,6 +104,7 @@ All URIs are relative to *http://localhost:3000*
|
|
|
104
104
|
*PlansApi* | [**updatePlan**](docs/PlansApi.md#updateplan) | **PATCH** /api/v1/plans/{id} | Update a plan
|
|
105
105
|
*QuizSessionsApi* | [**createQuizSession**](docs/QuizSessionsApi.md#createquizsession) | **POST** /api/v1/quizzes/{quizId}/sessions | Create a quiz session
|
|
106
106
|
*QuizSessionsApi* | [**getQuizSessionSummary**](docs/QuizSessionsApi.md#getquizsessionsummary) | **GET** /api/v1/quiz-sessions/{sessionId}/summary | Get quiz session summary
|
|
107
|
+
*QuizSessionsApi* | [**listQuizSessions**](docs/QuizSessionsApi.md#listquizsessions) | **GET** /api/v1/quiz-sessions | List user quiz sessions
|
|
107
108
|
*QuizSessionsApi* | [**submitQuizResponse**](docs/QuizSessionsApi.md#submitquizresponseoperation) | **POST** /api/v1/quiz-sessions/{sessionId}/responses | Submit a quiz response
|
|
108
109
|
*QuizSessionsApi* | [**updateQuizSession**](docs/QuizSessionsApi.md#updatequizsessionoperation) | **PATCH** /api/v1/quiz-sessions/{sessionId} | Update quiz session status
|
|
109
110
|
*QuizzesApi* | [**getQuiz**](docs/QuizzesApi.md#getquiz) | **GET** /api/v1/quizzes/{quizId} | Get quiz with questions
|
|
@@ -174,6 +175,7 @@ All URIs are relative to *http://localhost:3000*
|
|
|
174
175
|
- [PaginatedChats](docs/PaginatedChats.md)
|
|
175
176
|
- [PaginatedLearningMoments](docs/PaginatedLearningMoments.md)
|
|
176
177
|
- [PaginatedMessages](docs/PaginatedMessages.md)
|
|
178
|
+
- [PaginatedQuizSessions](docs/PaginatedQuizSessions.md)
|
|
177
179
|
- [PaginatedQuizzes](docs/PaginatedQuizzes.md)
|
|
178
180
|
- [PaginatedTaxonomies](docs/PaginatedTaxonomies.md)
|
|
179
181
|
- [Plan](docs/Plan.md)
|
|
@@ -182,6 +184,8 @@ All URIs are relative to *http://localhost:3000*
|
|
|
182
184
|
- [QuizQuestion](docs/QuizQuestion.md)
|
|
183
185
|
- [QuizResponse](docs/QuizResponse.md)
|
|
184
186
|
- [QuizSession](docs/QuizSession.md)
|
|
187
|
+
- [QuizSessionListItem](docs/QuizSessionListItem.md)
|
|
188
|
+
- [QuizSessionScore](docs/QuizSessionScore.md)
|
|
185
189
|
- [QuizSessionSummary](docs/QuizSessionSummary.md)
|
|
186
190
|
- [QuizWithQuestions](docs/QuizWithQuestions.md)
|
|
187
191
|
- [Score](docs/Score.md)
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { QuizResponse, QuizSession, QuizSessionSummary, SubmitQuizResponseRequest, UpdateQuizSessionRequest } from '../models/index';
|
|
13
|
+
import type { PaginatedQuizSessions, QuizResponse, QuizSession, QuizSessionSummary, SubmitQuizResponseRequest, UpdateQuizSessionRequest } from '../models/index';
|
|
14
14
|
export interface CreateQuizSessionRequest {
|
|
15
15
|
quizId: string;
|
|
16
16
|
xUserId: string;
|
|
@@ -19,6 +19,13 @@ export interface GetQuizSessionSummaryRequest {
|
|
|
19
19
|
sessionId: string;
|
|
20
20
|
xUserId: string;
|
|
21
21
|
}
|
|
22
|
+
export interface ListQuizSessionsRequest {
|
|
23
|
+
xUserId: string;
|
|
24
|
+
limit?: number;
|
|
25
|
+
cursor?: string;
|
|
26
|
+
mode?: ListQuizSessionsModeEnum;
|
|
27
|
+
status?: ListQuizSessionsStatusEnum;
|
|
28
|
+
}
|
|
22
29
|
export interface SubmitQuizResponseOperationRequest {
|
|
23
30
|
sessionId: string;
|
|
24
31
|
xUserId: string;
|
|
@@ -53,6 +60,16 @@ export declare class QuizSessionsApi extends runtime.BaseAPI {
|
|
|
53
60
|
* Get quiz session summary
|
|
54
61
|
*/
|
|
55
62
|
getQuizSessionSummary(requestParameters: GetQuizSessionSummaryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<QuizSessionSummary>;
|
|
63
|
+
/**
|
|
64
|
+
* Returns a paginated list of quiz sessions owned by the authenticated user, ordered by start date (newest first), with embedded quiz info and score summary.
|
|
65
|
+
* List user quiz sessions
|
|
66
|
+
*/
|
|
67
|
+
listQuizSessionsRaw(requestParameters: ListQuizSessionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedQuizSessions>>;
|
|
68
|
+
/**
|
|
69
|
+
* Returns a paginated list of quiz sessions owned by the authenticated user, ordered by start date (newest first), with embedded quiz info and score summary.
|
|
70
|
+
* List user quiz sessions
|
|
71
|
+
*/
|
|
72
|
+
listQuizSessions(requestParameters: ListQuizSessionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedQuizSessions>;
|
|
56
73
|
/**
|
|
57
74
|
* Submits an answer for a question within a quiz session.
|
|
58
75
|
* Submit a quiz response
|
|
@@ -74,3 +91,20 @@ export declare class QuizSessionsApi extends runtime.BaseAPI {
|
|
|
74
91
|
*/
|
|
75
92
|
updateQuizSession(requestParameters: UpdateQuizSessionOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<QuizSession>;
|
|
76
93
|
}
|
|
94
|
+
/**
|
|
95
|
+
* @export
|
|
96
|
+
*/
|
|
97
|
+
export declare const ListQuizSessionsModeEnum: {
|
|
98
|
+
readonly Quiz: "quiz";
|
|
99
|
+
readonly Flashcards: "flashcards";
|
|
100
|
+
};
|
|
101
|
+
export type ListQuizSessionsModeEnum = typeof ListQuizSessionsModeEnum[keyof typeof ListQuizSessionsModeEnum];
|
|
102
|
+
/**
|
|
103
|
+
* @export
|
|
104
|
+
*/
|
|
105
|
+
export declare const ListQuizSessionsStatusEnum: {
|
|
106
|
+
readonly Active: "active";
|
|
107
|
+
readonly Completed: "completed";
|
|
108
|
+
readonly Abandoned: "abandoned";
|
|
109
|
+
};
|
|
110
|
+
export type ListQuizSessionsStatusEnum = typeof ListQuizSessionsStatusEnum[keyof typeof ListQuizSessionsStatusEnum];
|
|
@@ -22,7 +22,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
22
22
|
});
|
|
23
23
|
};
|
|
24
24
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
|
-
exports.QuizSessionsApi = void 0;
|
|
25
|
+
exports.ListQuizSessionsStatusEnum = exports.ListQuizSessionsModeEnum = exports.QuizSessionsApi = void 0;
|
|
26
26
|
const runtime = require("../runtime");
|
|
27
27
|
const index_1 = require("../models/index");
|
|
28
28
|
/**
|
|
@@ -111,6 +111,55 @@ class QuizSessionsApi extends runtime.BaseAPI {
|
|
|
111
111
|
return yield response.value();
|
|
112
112
|
});
|
|
113
113
|
}
|
|
114
|
+
/**
|
|
115
|
+
* Returns a paginated list of quiz sessions owned by the authenticated user, ordered by start date (newest first), with embedded quiz info and score summary.
|
|
116
|
+
* List user quiz sessions
|
|
117
|
+
*/
|
|
118
|
+
listQuizSessionsRaw(requestParameters, initOverrides) {
|
|
119
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
120
|
+
if (requestParameters['xUserId'] == null) {
|
|
121
|
+
throw new runtime.RequiredError('xUserId', 'Required parameter "xUserId" was null or undefined when calling listQuizSessions().');
|
|
122
|
+
}
|
|
123
|
+
const queryParameters = {};
|
|
124
|
+
if (requestParameters['limit'] != null) {
|
|
125
|
+
queryParameters['limit'] = requestParameters['limit'];
|
|
126
|
+
}
|
|
127
|
+
if (requestParameters['cursor'] != null) {
|
|
128
|
+
queryParameters['cursor'] = requestParameters['cursor'];
|
|
129
|
+
}
|
|
130
|
+
if (requestParameters['mode'] != null) {
|
|
131
|
+
queryParameters['mode'] = requestParameters['mode'];
|
|
132
|
+
}
|
|
133
|
+
if (requestParameters['status'] != null) {
|
|
134
|
+
queryParameters['status'] = requestParameters['status'];
|
|
135
|
+
}
|
|
136
|
+
const headerParameters = {};
|
|
137
|
+
if (requestParameters['xUserId'] != null) {
|
|
138
|
+
headerParameters['X-User-Id'] = String(requestParameters['xUserId']);
|
|
139
|
+
}
|
|
140
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
141
|
+
headerParameters["X-Auth-Token"] = yield this.configuration.apiKey("X-Auth-Token"); // AuthToken authentication
|
|
142
|
+
}
|
|
143
|
+
let urlPath = `/api/v1/quiz-sessions`;
|
|
144
|
+
const response = yield this.request({
|
|
145
|
+
path: urlPath,
|
|
146
|
+
method: 'GET',
|
|
147
|
+
headers: headerParameters,
|
|
148
|
+
query: queryParameters,
|
|
149
|
+
}, initOverrides);
|
|
150
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.PaginatedQuizSessionsFromJSON)(jsonValue));
|
|
151
|
+
});
|
|
152
|
+
}
|
|
153
|
+
/**
|
|
154
|
+
* Returns a paginated list of quiz sessions owned by the authenticated user, ordered by start date (newest first), with embedded quiz info and score summary.
|
|
155
|
+
* List user quiz sessions
|
|
156
|
+
*/
|
|
157
|
+
listQuizSessions(requestParameters, initOverrides) {
|
|
158
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
159
|
+
const response = yield this.listQuizSessionsRaw(requestParameters, initOverrides);
|
|
160
|
+
return yield response.value();
|
|
161
|
+
});
|
|
162
|
+
}
|
|
114
163
|
/**
|
|
115
164
|
* Submits an answer for a question within a quiz session.
|
|
116
165
|
* Submit a quiz response
|
|
@@ -205,3 +254,18 @@ class QuizSessionsApi extends runtime.BaseAPI {
|
|
|
205
254
|
}
|
|
206
255
|
}
|
|
207
256
|
exports.QuizSessionsApi = QuizSessionsApi;
|
|
257
|
+
/**
|
|
258
|
+
* @export
|
|
259
|
+
*/
|
|
260
|
+
exports.ListQuizSessionsModeEnum = {
|
|
261
|
+
Quiz: 'quiz',
|
|
262
|
+
Flashcards: 'flashcards'
|
|
263
|
+
};
|
|
264
|
+
/**
|
|
265
|
+
* @export
|
|
266
|
+
*/
|
|
267
|
+
exports.ListQuizSessionsStatusEnum = {
|
|
268
|
+
Active: 'active',
|
|
269
|
+
Completed: 'completed',
|
|
270
|
+
Abandoned: 'abandoned'
|
|
271
|
+
};
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { QuizResponse, QuizSession, QuizSessionSummary, SubmitQuizResponseRequest, UpdateQuizSessionRequest } from '../models/index';
|
|
13
|
+
import type { PaginatedQuizSessions, QuizResponse, QuizSession, QuizSessionSummary, SubmitQuizResponseRequest, UpdateQuizSessionRequest } from '../models/index';
|
|
14
14
|
export interface CreateQuizSessionRequest {
|
|
15
15
|
quizId: string;
|
|
16
16
|
xUserId: string;
|
|
@@ -19,6 +19,13 @@ export interface GetQuizSessionSummaryRequest {
|
|
|
19
19
|
sessionId: string;
|
|
20
20
|
xUserId: string;
|
|
21
21
|
}
|
|
22
|
+
export interface ListQuizSessionsRequest {
|
|
23
|
+
xUserId: string;
|
|
24
|
+
limit?: number;
|
|
25
|
+
cursor?: string;
|
|
26
|
+
mode?: ListQuizSessionsModeEnum;
|
|
27
|
+
status?: ListQuizSessionsStatusEnum;
|
|
28
|
+
}
|
|
22
29
|
export interface SubmitQuizResponseOperationRequest {
|
|
23
30
|
sessionId: string;
|
|
24
31
|
xUserId: string;
|
|
@@ -53,6 +60,16 @@ export declare class QuizSessionsApi extends runtime.BaseAPI {
|
|
|
53
60
|
* Get quiz session summary
|
|
54
61
|
*/
|
|
55
62
|
getQuizSessionSummary(requestParameters: GetQuizSessionSummaryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<QuizSessionSummary>;
|
|
63
|
+
/**
|
|
64
|
+
* Returns a paginated list of quiz sessions owned by the authenticated user, ordered by start date (newest first), with embedded quiz info and score summary.
|
|
65
|
+
* List user quiz sessions
|
|
66
|
+
*/
|
|
67
|
+
listQuizSessionsRaw(requestParameters: ListQuizSessionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedQuizSessions>>;
|
|
68
|
+
/**
|
|
69
|
+
* Returns a paginated list of quiz sessions owned by the authenticated user, ordered by start date (newest first), with embedded quiz info and score summary.
|
|
70
|
+
* List user quiz sessions
|
|
71
|
+
*/
|
|
72
|
+
listQuizSessions(requestParameters: ListQuizSessionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedQuizSessions>;
|
|
56
73
|
/**
|
|
57
74
|
* Submits an answer for a question within a quiz session.
|
|
58
75
|
* Submit a quiz response
|
|
@@ -74,3 +91,20 @@ export declare class QuizSessionsApi extends runtime.BaseAPI {
|
|
|
74
91
|
*/
|
|
75
92
|
updateQuizSession(requestParameters: UpdateQuizSessionOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<QuizSession>;
|
|
76
93
|
}
|
|
94
|
+
/**
|
|
95
|
+
* @export
|
|
96
|
+
*/
|
|
97
|
+
export declare const ListQuizSessionsModeEnum: {
|
|
98
|
+
readonly Quiz: "quiz";
|
|
99
|
+
readonly Flashcards: "flashcards";
|
|
100
|
+
};
|
|
101
|
+
export type ListQuizSessionsModeEnum = typeof ListQuizSessionsModeEnum[keyof typeof ListQuizSessionsModeEnum];
|
|
102
|
+
/**
|
|
103
|
+
* @export
|
|
104
|
+
*/
|
|
105
|
+
export declare const ListQuizSessionsStatusEnum: {
|
|
106
|
+
readonly Active: "active";
|
|
107
|
+
readonly Completed: "completed";
|
|
108
|
+
readonly Abandoned: "abandoned";
|
|
109
|
+
};
|
|
110
|
+
export type ListQuizSessionsStatusEnum = typeof ListQuizSessionsStatusEnum[keyof typeof ListQuizSessionsStatusEnum];
|
|
@@ -21,7 +21,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
21
21
|
});
|
|
22
22
|
};
|
|
23
23
|
import * as runtime from '../runtime';
|
|
24
|
-
import { QuizResponseFromJSON, QuizSessionFromJSON, QuizSessionSummaryFromJSON, SubmitQuizResponseRequestToJSON, UpdateQuizSessionRequestToJSON, } from '../models/index';
|
|
24
|
+
import { PaginatedQuizSessionsFromJSON, QuizResponseFromJSON, QuizSessionFromJSON, QuizSessionSummaryFromJSON, SubmitQuizResponseRequestToJSON, UpdateQuizSessionRequestToJSON, } from '../models/index';
|
|
25
25
|
/**
|
|
26
26
|
*
|
|
27
27
|
*/
|
|
@@ -108,6 +108,55 @@ export class QuizSessionsApi extends runtime.BaseAPI {
|
|
|
108
108
|
return yield response.value();
|
|
109
109
|
});
|
|
110
110
|
}
|
|
111
|
+
/**
|
|
112
|
+
* Returns a paginated list of quiz sessions owned by the authenticated user, ordered by start date (newest first), with embedded quiz info and score summary.
|
|
113
|
+
* List user quiz sessions
|
|
114
|
+
*/
|
|
115
|
+
listQuizSessionsRaw(requestParameters, initOverrides) {
|
|
116
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
117
|
+
if (requestParameters['xUserId'] == null) {
|
|
118
|
+
throw new runtime.RequiredError('xUserId', 'Required parameter "xUserId" was null or undefined when calling listQuizSessions().');
|
|
119
|
+
}
|
|
120
|
+
const queryParameters = {};
|
|
121
|
+
if (requestParameters['limit'] != null) {
|
|
122
|
+
queryParameters['limit'] = requestParameters['limit'];
|
|
123
|
+
}
|
|
124
|
+
if (requestParameters['cursor'] != null) {
|
|
125
|
+
queryParameters['cursor'] = requestParameters['cursor'];
|
|
126
|
+
}
|
|
127
|
+
if (requestParameters['mode'] != null) {
|
|
128
|
+
queryParameters['mode'] = requestParameters['mode'];
|
|
129
|
+
}
|
|
130
|
+
if (requestParameters['status'] != null) {
|
|
131
|
+
queryParameters['status'] = requestParameters['status'];
|
|
132
|
+
}
|
|
133
|
+
const headerParameters = {};
|
|
134
|
+
if (requestParameters['xUserId'] != null) {
|
|
135
|
+
headerParameters['X-User-Id'] = String(requestParameters['xUserId']);
|
|
136
|
+
}
|
|
137
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
138
|
+
headerParameters["X-Auth-Token"] = yield this.configuration.apiKey("X-Auth-Token"); // AuthToken authentication
|
|
139
|
+
}
|
|
140
|
+
let urlPath = `/api/v1/quiz-sessions`;
|
|
141
|
+
const response = yield this.request({
|
|
142
|
+
path: urlPath,
|
|
143
|
+
method: 'GET',
|
|
144
|
+
headers: headerParameters,
|
|
145
|
+
query: queryParameters,
|
|
146
|
+
}, initOverrides);
|
|
147
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => PaginatedQuizSessionsFromJSON(jsonValue));
|
|
148
|
+
});
|
|
149
|
+
}
|
|
150
|
+
/**
|
|
151
|
+
* Returns a paginated list of quiz sessions owned by the authenticated user, ordered by start date (newest first), with embedded quiz info and score summary.
|
|
152
|
+
* List user quiz sessions
|
|
153
|
+
*/
|
|
154
|
+
listQuizSessions(requestParameters, initOverrides) {
|
|
155
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
156
|
+
const response = yield this.listQuizSessionsRaw(requestParameters, initOverrides);
|
|
157
|
+
return yield response.value();
|
|
158
|
+
});
|
|
159
|
+
}
|
|
111
160
|
/**
|
|
112
161
|
* Submits an answer for a question within a quiz session.
|
|
113
162
|
* Submit a quiz response
|
|
@@ -201,3 +250,18 @@ export class QuizSessionsApi extends runtime.BaseAPI {
|
|
|
201
250
|
});
|
|
202
251
|
}
|
|
203
252
|
}
|
|
253
|
+
/**
|
|
254
|
+
* @export
|
|
255
|
+
*/
|
|
256
|
+
export const ListQuizSessionsModeEnum = {
|
|
257
|
+
Quiz: 'quiz',
|
|
258
|
+
Flashcards: 'flashcards'
|
|
259
|
+
};
|
|
260
|
+
/**
|
|
261
|
+
* @export
|
|
262
|
+
*/
|
|
263
|
+
export const ListQuizSessionsStatusEnum = {
|
|
264
|
+
Active: 'active',
|
|
265
|
+
Completed: 'completed',
|
|
266
|
+
Abandoned: 'abandoned'
|
|
267
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Athena API
|
|
3
|
+
* REST API for the Athena system
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { QuizSessionListItem } from './QuizSessionListItem';
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @export
|
|
16
|
+
* @interface PaginatedQuizSessions
|
|
17
|
+
*/
|
|
18
|
+
export interface PaginatedQuizSessions {
|
|
19
|
+
/**
|
|
20
|
+
* Array of quiz session objects
|
|
21
|
+
* @type {Array<QuizSessionListItem>}
|
|
22
|
+
* @memberof PaginatedQuizSessions
|
|
23
|
+
*/
|
|
24
|
+
data: Array<QuizSessionListItem>;
|
|
25
|
+
/**
|
|
26
|
+
* Opaque cursor for fetching the next page. Null when there are no more results.
|
|
27
|
+
* @type {string}
|
|
28
|
+
* @memberof PaginatedQuizSessions
|
|
29
|
+
*/
|
|
30
|
+
nextCursor: string | null;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Check if a given object implements the PaginatedQuizSessions interface.
|
|
34
|
+
*/
|
|
35
|
+
export declare function instanceOfPaginatedQuizSessions(value: object): value is PaginatedQuizSessions;
|
|
36
|
+
export declare function PaginatedQuizSessionsFromJSON(json: any): PaginatedQuizSessions;
|
|
37
|
+
export declare function PaginatedQuizSessionsFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaginatedQuizSessions;
|
|
38
|
+
export declare function PaginatedQuizSessionsToJSON(json: any): PaginatedQuizSessions;
|
|
39
|
+
export declare function PaginatedQuizSessionsToJSONTyped(value?: PaginatedQuizSessions | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Athena API
|
|
5
|
+
* REST API for the Athena system
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
import { QuizSessionListItemFromJSON, QuizSessionListItemToJSON, } from './QuizSessionListItem';
|
|
15
|
+
/**
|
|
16
|
+
* Check if a given object implements the PaginatedQuizSessions interface.
|
|
17
|
+
*/
|
|
18
|
+
export function instanceOfPaginatedQuizSessions(value) {
|
|
19
|
+
if (!('data' in value) || value['data'] === undefined)
|
|
20
|
+
return false;
|
|
21
|
+
if (!('nextCursor' in value) || value['nextCursor'] === undefined)
|
|
22
|
+
return false;
|
|
23
|
+
return true;
|
|
24
|
+
}
|
|
25
|
+
export function PaginatedQuizSessionsFromJSON(json) {
|
|
26
|
+
return PaginatedQuizSessionsFromJSONTyped(json, false);
|
|
27
|
+
}
|
|
28
|
+
export function PaginatedQuizSessionsFromJSONTyped(json, ignoreDiscriminator) {
|
|
29
|
+
if (json == null) {
|
|
30
|
+
return json;
|
|
31
|
+
}
|
|
32
|
+
return {
|
|
33
|
+
'data': (json['data'].map(QuizSessionListItemFromJSON)),
|
|
34
|
+
'nextCursor': json['nextCursor'],
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
export function PaginatedQuizSessionsToJSON(json) {
|
|
38
|
+
return PaginatedQuizSessionsToJSONTyped(json, false);
|
|
39
|
+
}
|
|
40
|
+
export function PaginatedQuizSessionsToJSONTyped(value, ignoreDiscriminator = false) {
|
|
41
|
+
if (value == null) {
|
|
42
|
+
return value;
|
|
43
|
+
}
|
|
44
|
+
return {
|
|
45
|
+
'data': (value['data'].map(QuizSessionListItemToJSON)),
|
|
46
|
+
'nextCursor': value['nextCursor'],
|
|
47
|
+
};
|
|
48
|
+
}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Athena API
|
|
3
|
+
* REST API for the Athena system
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { Quiz } from './Quiz';
|
|
13
|
+
import type { QuizSessionScore } from './QuizSessionScore';
|
|
14
|
+
/**
|
|
15
|
+
*
|
|
16
|
+
* @export
|
|
17
|
+
* @interface QuizSessionListItem
|
|
18
|
+
*/
|
|
19
|
+
export interface QuizSessionListItem {
|
|
20
|
+
/**
|
|
21
|
+
*
|
|
22
|
+
* @type {string}
|
|
23
|
+
* @memberof QuizSessionListItem
|
|
24
|
+
*/
|
|
25
|
+
id: string;
|
|
26
|
+
/**
|
|
27
|
+
*
|
|
28
|
+
* @type {string}
|
|
29
|
+
* @memberof QuizSessionListItem
|
|
30
|
+
*/
|
|
31
|
+
quizId: string;
|
|
32
|
+
/**
|
|
33
|
+
*
|
|
34
|
+
* @type {string}
|
|
35
|
+
* @memberof QuizSessionListItem
|
|
36
|
+
*/
|
|
37
|
+
accountUserId: string;
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @type {string}
|
|
41
|
+
* @memberof QuizSessionListItem
|
|
42
|
+
*/
|
|
43
|
+
status: QuizSessionListItemStatusEnum;
|
|
44
|
+
/**
|
|
45
|
+
*
|
|
46
|
+
* @type {Date}
|
|
47
|
+
* @memberof QuizSessionListItem
|
|
48
|
+
*/
|
|
49
|
+
startedAt: Date;
|
|
50
|
+
/**
|
|
51
|
+
*
|
|
52
|
+
* @type {Date}
|
|
53
|
+
* @memberof QuizSessionListItem
|
|
54
|
+
*/
|
|
55
|
+
completedAt: Date | null;
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* @type {Quiz}
|
|
59
|
+
* @memberof QuizSessionListItem
|
|
60
|
+
*/
|
|
61
|
+
quiz: Quiz;
|
|
62
|
+
/**
|
|
63
|
+
*
|
|
64
|
+
* @type {QuizSessionScore}
|
|
65
|
+
* @memberof QuizSessionListItem
|
|
66
|
+
*/
|
|
67
|
+
score: QuizSessionScore;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* @export
|
|
71
|
+
*/
|
|
72
|
+
export declare const QuizSessionListItemStatusEnum: {
|
|
73
|
+
readonly Active: "active";
|
|
74
|
+
readonly Completed: "completed";
|
|
75
|
+
readonly Abandoned: "abandoned";
|
|
76
|
+
};
|
|
77
|
+
export type QuizSessionListItemStatusEnum = typeof QuizSessionListItemStatusEnum[keyof typeof QuizSessionListItemStatusEnum];
|
|
78
|
+
/**
|
|
79
|
+
* Check if a given object implements the QuizSessionListItem interface.
|
|
80
|
+
*/
|
|
81
|
+
export declare function instanceOfQuizSessionListItem(value: object): value is QuizSessionListItem;
|
|
82
|
+
export declare function QuizSessionListItemFromJSON(json: any): QuizSessionListItem;
|
|
83
|
+
export declare function QuizSessionListItemFromJSONTyped(json: any, ignoreDiscriminator: boolean): QuizSessionListItem;
|
|
84
|
+
export declare function QuizSessionListItemToJSON(json: any): QuizSessionListItem;
|
|
85
|
+
export declare function QuizSessionListItemToJSONTyped(value?: QuizSessionListItem | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Athena API
|
|
5
|
+
* REST API for the Athena system
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
import { QuizFromJSON, QuizToJSON, } from './Quiz';
|
|
15
|
+
import { QuizSessionScoreFromJSON, QuizSessionScoreToJSON, } from './QuizSessionScore';
|
|
16
|
+
/**
|
|
17
|
+
* @export
|
|
18
|
+
*/
|
|
19
|
+
export const QuizSessionListItemStatusEnum = {
|
|
20
|
+
Active: 'active',
|
|
21
|
+
Completed: 'completed',
|
|
22
|
+
Abandoned: 'abandoned'
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* Check if a given object implements the QuizSessionListItem interface.
|
|
26
|
+
*/
|
|
27
|
+
export function instanceOfQuizSessionListItem(value) {
|
|
28
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
29
|
+
return false;
|
|
30
|
+
if (!('quizId' in value) || value['quizId'] === undefined)
|
|
31
|
+
return false;
|
|
32
|
+
if (!('accountUserId' in value) || value['accountUserId'] === undefined)
|
|
33
|
+
return false;
|
|
34
|
+
if (!('status' in value) || value['status'] === undefined)
|
|
35
|
+
return false;
|
|
36
|
+
if (!('startedAt' in value) || value['startedAt'] === undefined)
|
|
37
|
+
return false;
|
|
38
|
+
if (!('completedAt' in value) || value['completedAt'] === undefined)
|
|
39
|
+
return false;
|
|
40
|
+
if (!('quiz' in value) || value['quiz'] === undefined)
|
|
41
|
+
return false;
|
|
42
|
+
if (!('score' in value) || value['score'] === undefined)
|
|
43
|
+
return false;
|
|
44
|
+
return true;
|
|
45
|
+
}
|
|
46
|
+
export function QuizSessionListItemFromJSON(json) {
|
|
47
|
+
return QuizSessionListItemFromJSONTyped(json, false);
|
|
48
|
+
}
|
|
49
|
+
export function QuizSessionListItemFromJSONTyped(json, ignoreDiscriminator) {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
'id': json['id'],
|
|
55
|
+
'quizId': json['quizId'],
|
|
56
|
+
'accountUserId': json['accountUserId'],
|
|
57
|
+
'status': json['status'],
|
|
58
|
+
'startedAt': (new Date(json['startedAt'])),
|
|
59
|
+
'completedAt': (json['completedAt'] == null ? null : new Date(json['completedAt'])),
|
|
60
|
+
'quiz': QuizFromJSON(json['quiz']),
|
|
61
|
+
'score': QuizSessionScoreFromJSON(json['score']),
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
export function QuizSessionListItemToJSON(json) {
|
|
65
|
+
return QuizSessionListItemToJSONTyped(json, false);
|
|
66
|
+
}
|
|
67
|
+
export function QuizSessionListItemToJSONTyped(value, ignoreDiscriminator = false) {
|
|
68
|
+
if (value == null) {
|
|
69
|
+
return value;
|
|
70
|
+
}
|
|
71
|
+
return {
|
|
72
|
+
'id': value['id'],
|
|
73
|
+
'quizId': value['quizId'],
|
|
74
|
+
'accountUserId': value['accountUserId'],
|
|
75
|
+
'status': value['status'],
|
|
76
|
+
'startedAt': value['startedAt'].toISOString(),
|
|
77
|
+
'completedAt': value['completedAt'] == null ? value['completedAt'] : value['completedAt'].toISOString(),
|
|
78
|
+
'quiz': QuizToJSON(value['quiz']),
|
|
79
|
+
'score': QuizSessionScoreToJSON(value['score']),
|
|
80
|
+
};
|
|
81
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Athena API
|
|
3
|
+
* REST API for the Athena system
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface QuizSessionScore
|
|
16
|
+
*/
|
|
17
|
+
export interface QuizSessionScore {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {number}
|
|
21
|
+
* @memberof QuizSessionScore
|
|
22
|
+
*/
|
|
23
|
+
totalCorrect: number;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @type {number}
|
|
27
|
+
* @memberof QuizSessionScore
|
|
28
|
+
*/
|
|
29
|
+
totalQuestions: number;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Check if a given object implements the QuizSessionScore interface.
|
|
33
|
+
*/
|
|
34
|
+
export declare function instanceOfQuizSessionScore(value: object): value is QuizSessionScore;
|
|
35
|
+
export declare function QuizSessionScoreFromJSON(json: any): QuizSessionScore;
|
|
36
|
+
export declare function QuizSessionScoreFromJSONTyped(json: any, ignoreDiscriminator: boolean): QuizSessionScore;
|
|
37
|
+
export declare function QuizSessionScoreToJSON(json: any): QuizSessionScore;
|
|
38
|
+
export declare function QuizSessionScoreToJSONTyped(value?: QuizSessionScore | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Athena API
|
|
5
|
+
* REST API for the Athena system
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
/**
|
|
15
|
+
* Check if a given object implements the QuizSessionScore interface.
|
|
16
|
+
*/
|
|
17
|
+
export function instanceOfQuizSessionScore(value) {
|
|
18
|
+
if (!('totalCorrect' in value) || value['totalCorrect'] === undefined)
|
|
19
|
+
return false;
|
|
20
|
+
if (!('totalQuestions' in value) || value['totalQuestions'] === undefined)
|
|
21
|
+
return false;
|
|
22
|
+
return true;
|
|
23
|
+
}
|
|
24
|
+
export function QuizSessionScoreFromJSON(json) {
|
|
25
|
+
return QuizSessionScoreFromJSONTyped(json, false);
|
|
26
|
+
}
|
|
27
|
+
export function QuizSessionScoreFromJSONTyped(json, ignoreDiscriminator) {
|
|
28
|
+
if (json == null) {
|
|
29
|
+
return json;
|
|
30
|
+
}
|
|
31
|
+
return {
|
|
32
|
+
'totalCorrect': json['totalCorrect'],
|
|
33
|
+
'totalQuestions': json['totalQuestions'],
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
export function QuizSessionScoreToJSON(json) {
|
|
37
|
+
return QuizSessionScoreToJSONTyped(json, false);
|
|
38
|
+
}
|
|
39
|
+
export function QuizSessionScoreToJSONTyped(value, ignoreDiscriminator = false) {
|
|
40
|
+
if (value == null) {
|
|
41
|
+
return value;
|
|
42
|
+
}
|
|
43
|
+
return {
|
|
44
|
+
'totalCorrect': value['totalCorrect'],
|
|
45
|
+
'totalQuestions': value['totalQuestions'],
|
|
46
|
+
};
|
|
47
|
+
}
|
|
@@ -43,6 +43,7 @@ export * from './MessagePartsInner';
|
|
|
43
43
|
export * from './PaginatedChats';
|
|
44
44
|
export * from './PaginatedLearningMoments';
|
|
45
45
|
export * from './PaginatedMessages';
|
|
46
|
+
export * from './PaginatedQuizSessions';
|
|
46
47
|
export * from './PaginatedQuizzes';
|
|
47
48
|
export * from './PaginatedTaxonomies';
|
|
48
49
|
export * from './Plan';
|
|
@@ -51,6 +52,8 @@ export * from './QuizListItem';
|
|
|
51
52
|
export * from './QuizQuestion';
|
|
52
53
|
export * from './QuizResponse';
|
|
53
54
|
export * from './QuizSession';
|
|
55
|
+
export * from './QuizSessionListItem';
|
|
56
|
+
export * from './QuizSessionScore';
|
|
54
57
|
export * from './QuizSessionSummary';
|
|
55
58
|
export * from './QuizWithQuestions';
|
|
56
59
|
export * from './Score';
|
package/dist/esm/models/index.js
CHANGED
|
@@ -45,6 +45,7 @@ export * from './MessagePartsInner';
|
|
|
45
45
|
export * from './PaginatedChats';
|
|
46
46
|
export * from './PaginatedLearningMoments';
|
|
47
47
|
export * from './PaginatedMessages';
|
|
48
|
+
export * from './PaginatedQuizSessions';
|
|
48
49
|
export * from './PaginatedQuizzes';
|
|
49
50
|
export * from './PaginatedTaxonomies';
|
|
50
51
|
export * from './Plan';
|
|
@@ -53,6 +54,8 @@ export * from './QuizListItem';
|
|
|
53
54
|
export * from './QuizQuestion';
|
|
54
55
|
export * from './QuizResponse';
|
|
55
56
|
export * from './QuizSession';
|
|
57
|
+
export * from './QuizSessionListItem';
|
|
58
|
+
export * from './QuizSessionScore';
|
|
56
59
|
export * from './QuizSessionSummary';
|
|
57
60
|
export * from './QuizWithQuestions';
|
|
58
61
|
export * from './Score';
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Athena API
|
|
3
|
+
* REST API for the Athena system
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { QuizSessionListItem } from './QuizSessionListItem';
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @export
|
|
16
|
+
* @interface PaginatedQuizSessions
|
|
17
|
+
*/
|
|
18
|
+
export interface PaginatedQuizSessions {
|
|
19
|
+
/**
|
|
20
|
+
* Array of quiz session objects
|
|
21
|
+
* @type {Array<QuizSessionListItem>}
|
|
22
|
+
* @memberof PaginatedQuizSessions
|
|
23
|
+
*/
|
|
24
|
+
data: Array<QuizSessionListItem>;
|
|
25
|
+
/**
|
|
26
|
+
* Opaque cursor for fetching the next page. Null when there are no more results.
|
|
27
|
+
* @type {string}
|
|
28
|
+
* @memberof PaginatedQuizSessions
|
|
29
|
+
*/
|
|
30
|
+
nextCursor: string | null;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Check if a given object implements the PaginatedQuizSessions interface.
|
|
34
|
+
*/
|
|
35
|
+
export declare function instanceOfPaginatedQuizSessions(value: object): value is PaginatedQuizSessions;
|
|
36
|
+
export declare function PaginatedQuizSessionsFromJSON(json: any): PaginatedQuizSessions;
|
|
37
|
+
export declare function PaginatedQuizSessionsFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaginatedQuizSessions;
|
|
38
|
+
export declare function PaginatedQuizSessionsToJSON(json: any): PaginatedQuizSessions;
|
|
39
|
+
export declare function PaginatedQuizSessionsToJSONTyped(value?: PaginatedQuizSessions | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Athena API
|
|
6
|
+
* REST API for the Athena system
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfPaginatedQuizSessions = instanceOfPaginatedQuizSessions;
|
|
17
|
+
exports.PaginatedQuizSessionsFromJSON = PaginatedQuizSessionsFromJSON;
|
|
18
|
+
exports.PaginatedQuizSessionsFromJSONTyped = PaginatedQuizSessionsFromJSONTyped;
|
|
19
|
+
exports.PaginatedQuizSessionsToJSON = PaginatedQuizSessionsToJSON;
|
|
20
|
+
exports.PaginatedQuizSessionsToJSONTyped = PaginatedQuizSessionsToJSONTyped;
|
|
21
|
+
const QuizSessionListItem_1 = require("./QuizSessionListItem");
|
|
22
|
+
/**
|
|
23
|
+
* Check if a given object implements the PaginatedQuizSessions interface.
|
|
24
|
+
*/
|
|
25
|
+
function instanceOfPaginatedQuizSessions(value) {
|
|
26
|
+
if (!('data' in value) || value['data'] === undefined)
|
|
27
|
+
return false;
|
|
28
|
+
if (!('nextCursor' in value) || value['nextCursor'] === undefined)
|
|
29
|
+
return false;
|
|
30
|
+
return true;
|
|
31
|
+
}
|
|
32
|
+
function PaginatedQuizSessionsFromJSON(json) {
|
|
33
|
+
return PaginatedQuizSessionsFromJSONTyped(json, false);
|
|
34
|
+
}
|
|
35
|
+
function PaginatedQuizSessionsFromJSONTyped(json, ignoreDiscriminator) {
|
|
36
|
+
if (json == null) {
|
|
37
|
+
return json;
|
|
38
|
+
}
|
|
39
|
+
return {
|
|
40
|
+
'data': (json['data'].map(QuizSessionListItem_1.QuizSessionListItemFromJSON)),
|
|
41
|
+
'nextCursor': json['nextCursor'],
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
function PaginatedQuizSessionsToJSON(json) {
|
|
45
|
+
return PaginatedQuizSessionsToJSONTyped(json, false);
|
|
46
|
+
}
|
|
47
|
+
function PaginatedQuizSessionsToJSONTyped(value, ignoreDiscriminator = false) {
|
|
48
|
+
if (value == null) {
|
|
49
|
+
return value;
|
|
50
|
+
}
|
|
51
|
+
return {
|
|
52
|
+
'data': (value['data'].map(QuizSessionListItem_1.QuizSessionListItemToJSON)),
|
|
53
|
+
'nextCursor': value['nextCursor'],
|
|
54
|
+
};
|
|
55
|
+
}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Athena API
|
|
3
|
+
* REST API for the Athena system
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { Quiz } from './Quiz';
|
|
13
|
+
import type { QuizSessionScore } from './QuizSessionScore';
|
|
14
|
+
/**
|
|
15
|
+
*
|
|
16
|
+
* @export
|
|
17
|
+
* @interface QuizSessionListItem
|
|
18
|
+
*/
|
|
19
|
+
export interface QuizSessionListItem {
|
|
20
|
+
/**
|
|
21
|
+
*
|
|
22
|
+
* @type {string}
|
|
23
|
+
* @memberof QuizSessionListItem
|
|
24
|
+
*/
|
|
25
|
+
id: string;
|
|
26
|
+
/**
|
|
27
|
+
*
|
|
28
|
+
* @type {string}
|
|
29
|
+
* @memberof QuizSessionListItem
|
|
30
|
+
*/
|
|
31
|
+
quizId: string;
|
|
32
|
+
/**
|
|
33
|
+
*
|
|
34
|
+
* @type {string}
|
|
35
|
+
* @memberof QuizSessionListItem
|
|
36
|
+
*/
|
|
37
|
+
accountUserId: string;
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @type {string}
|
|
41
|
+
* @memberof QuizSessionListItem
|
|
42
|
+
*/
|
|
43
|
+
status: QuizSessionListItemStatusEnum;
|
|
44
|
+
/**
|
|
45
|
+
*
|
|
46
|
+
* @type {Date}
|
|
47
|
+
* @memberof QuizSessionListItem
|
|
48
|
+
*/
|
|
49
|
+
startedAt: Date;
|
|
50
|
+
/**
|
|
51
|
+
*
|
|
52
|
+
* @type {Date}
|
|
53
|
+
* @memberof QuizSessionListItem
|
|
54
|
+
*/
|
|
55
|
+
completedAt: Date | null;
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* @type {Quiz}
|
|
59
|
+
* @memberof QuizSessionListItem
|
|
60
|
+
*/
|
|
61
|
+
quiz: Quiz;
|
|
62
|
+
/**
|
|
63
|
+
*
|
|
64
|
+
* @type {QuizSessionScore}
|
|
65
|
+
* @memberof QuizSessionListItem
|
|
66
|
+
*/
|
|
67
|
+
score: QuizSessionScore;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* @export
|
|
71
|
+
*/
|
|
72
|
+
export declare const QuizSessionListItemStatusEnum: {
|
|
73
|
+
readonly Active: "active";
|
|
74
|
+
readonly Completed: "completed";
|
|
75
|
+
readonly Abandoned: "abandoned";
|
|
76
|
+
};
|
|
77
|
+
export type QuizSessionListItemStatusEnum = typeof QuizSessionListItemStatusEnum[keyof typeof QuizSessionListItemStatusEnum];
|
|
78
|
+
/**
|
|
79
|
+
* Check if a given object implements the QuizSessionListItem interface.
|
|
80
|
+
*/
|
|
81
|
+
export declare function instanceOfQuizSessionListItem(value: object): value is QuizSessionListItem;
|
|
82
|
+
export declare function QuizSessionListItemFromJSON(json: any): QuizSessionListItem;
|
|
83
|
+
export declare function QuizSessionListItemFromJSONTyped(json: any, ignoreDiscriminator: boolean): QuizSessionListItem;
|
|
84
|
+
export declare function QuizSessionListItemToJSON(json: any): QuizSessionListItem;
|
|
85
|
+
export declare function QuizSessionListItemToJSONTyped(value?: QuizSessionListItem | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Athena API
|
|
6
|
+
* REST API for the Athena system
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.QuizSessionListItemStatusEnum = void 0;
|
|
17
|
+
exports.instanceOfQuizSessionListItem = instanceOfQuizSessionListItem;
|
|
18
|
+
exports.QuizSessionListItemFromJSON = QuizSessionListItemFromJSON;
|
|
19
|
+
exports.QuizSessionListItemFromJSONTyped = QuizSessionListItemFromJSONTyped;
|
|
20
|
+
exports.QuizSessionListItemToJSON = QuizSessionListItemToJSON;
|
|
21
|
+
exports.QuizSessionListItemToJSONTyped = QuizSessionListItemToJSONTyped;
|
|
22
|
+
const Quiz_1 = require("./Quiz");
|
|
23
|
+
const QuizSessionScore_1 = require("./QuizSessionScore");
|
|
24
|
+
/**
|
|
25
|
+
* @export
|
|
26
|
+
*/
|
|
27
|
+
exports.QuizSessionListItemStatusEnum = {
|
|
28
|
+
Active: 'active',
|
|
29
|
+
Completed: 'completed',
|
|
30
|
+
Abandoned: 'abandoned'
|
|
31
|
+
};
|
|
32
|
+
/**
|
|
33
|
+
* Check if a given object implements the QuizSessionListItem interface.
|
|
34
|
+
*/
|
|
35
|
+
function instanceOfQuizSessionListItem(value) {
|
|
36
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
37
|
+
return false;
|
|
38
|
+
if (!('quizId' in value) || value['quizId'] === undefined)
|
|
39
|
+
return false;
|
|
40
|
+
if (!('accountUserId' in value) || value['accountUserId'] === undefined)
|
|
41
|
+
return false;
|
|
42
|
+
if (!('status' in value) || value['status'] === undefined)
|
|
43
|
+
return false;
|
|
44
|
+
if (!('startedAt' in value) || value['startedAt'] === undefined)
|
|
45
|
+
return false;
|
|
46
|
+
if (!('completedAt' in value) || value['completedAt'] === undefined)
|
|
47
|
+
return false;
|
|
48
|
+
if (!('quiz' in value) || value['quiz'] === undefined)
|
|
49
|
+
return false;
|
|
50
|
+
if (!('score' in value) || value['score'] === undefined)
|
|
51
|
+
return false;
|
|
52
|
+
return true;
|
|
53
|
+
}
|
|
54
|
+
function QuizSessionListItemFromJSON(json) {
|
|
55
|
+
return QuizSessionListItemFromJSONTyped(json, false);
|
|
56
|
+
}
|
|
57
|
+
function QuizSessionListItemFromJSONTyped(json, ignoreDiscriminator) {
|
|
58
|
+
if (json == null) {
|
|
59
|
+
return json;
|
|
60
|
+
}
|
|
61
|
+
return {
|
|
62
|
+
'id': json['id'],
|
|
63
|
+
'quizId': json['quizId'],
|
|
64
|
+
'accountUserId': json['accountUserId'],
|
|
65
|
+
'status': json['status'],
|
|
66
|
+
'startedAt': (new Date(json['startedAt'])),
|
|
67
|
+
'completedAt': (json['completedAt'] == null ? null : new Date(json['completedAt'])),
|
|
68
|
+
'quiz': (0, Quiz_1.QuizFromJSON)(json['quiz']),
|
|
69
|
+
'score': (0, QuizSessionScore_1.QuizSessionScoreFromJSON)(json['score']),
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
function QuizSessionListItemToJSON(json) {
|
|
73
|
+
return QuizSessionListItemToJSONTyped(json, false);
|
|
74
|
+
}
|
|
75
|
+
function QuizSessionListItemToJSONTyped(value, ignoreDiscriminator = false) {
|
|
76
|
+
if (value == null) {
|
|
77
|
+
return value;
|
|
78
|
+
}
|
|
79
|
+
return {
|
|
80
|
+
'id': value['id'],
|
|
81
|
+
'quizId': value['quizId'],
|
|
82
|
+
'accountUserId': value['accountUserId'],
|
|
83
|
+
'status': value['status'],
|
|
84
|
+
'startedAt': value['startedAt'].toISOString(),
|
|
85
|
+
'completedAt': value['completedAt'] == null ? value['completedAt'] : value['completedAt'].toISOString(),
|
|
86
|
+
'quiz': (0, Quiz_1.QuizToJSON)(value['quiz']),
|
|
87
|
+
'score': (0, QuizSessionScore_1.QuizSessionScoreToJSON)(value['score']),
|
|
88
|
+
};
|
|
89
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Athena API
|
|
3
|
+
* REST API for the Athena system
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface QuizSessionScore
|
|
16
|
+
*/
|
|
17
|
+
export interface QuizSessionScore {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {number}
|
|
21
|
+
* @memberof QuizSessionScore
|
|
22
|
+
*/
|
|
23
|
+
totalCorrect: number;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @type {number}
|
|
27
|
+
* @memberof QuizSessionScore
|
|
28
|
+
*/
|
|
29
|
+
totalQuestions: number;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Check if a given object implements the QuizSessionScore interface.
|
|
33
|
+
*/
|
|
34
|
+
export declare function instanceOfQuizSessionScore(value: object): value is QuizSessionScore;
|
|
35
|
+
export declare function QuizSessionScoreFromJSON(json: any): QuizSessionScore;
|
|
36
|
+
export declare function QuizSessionScoreFromJSONTyped(json: any, ignoreDiscriminator: boolean): QuizSessionScore;
|
|
37
|
+
export declare function QuizSessionScoreToJSON(json: any): QuizSessionScore;
|
|
38
|
+
export declare function QuizSessionScoreToJSONTyped(value?: QuizSessionScore | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Athena API
|
|
6
|
+
* REST API for the Athena system
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfQuizSessionScore = instanceOfQuizSessionScore;
|
|
17
|
+
exports.QuizSessionScoreFromJSON = QuizSessionScoreFromJSON;
|
|
18
|
+
exports.QuizSessionScoreFromJSONTyped = QuizSessionScoreFromJSONTyped;
|
|
19
|
+
exports.QuizSessionScoreToJSON = QuizSessionScoreToJSON;
|
|
20
|
+
exports.QuizSessionScoreToJSONTyped = QuizSessionScoreToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the QuizSessionScore interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfQuizSessionScore(value) {
|
|
25
|
+
if (!('totalCorrect' in value) || value['totalCorrect'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
if (!('totalQuestions' in value) || value['totalQuestions'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
return true;
|
|
30
|
+
}
|
|
31
|
+
function QuizSessionScoreFromJSON(json) {
|
|
32
|
+
return QuizSessionScoreFromJSONTyped(json, false);
|
|
33
|
+
}
|
|
34
|
+
function QuizSessionScoreFromJSONTyped(json, ignoreDiscriminator) {
|
|
35
|
+
if (json == null) {
|
|
36
|
+
return json;
|
|
37
|
+
}
|
|
38
|
+
return {
|
|
39
|
+
'totalCorrect': json['totalCorrect'],
|
|
40
|
+
'totalQuestions': json['totalQuestions'],
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
function QuizSessionScoreToJSON(json) {
|
|
44
|
+
return QuizSessionScoreToJSONTyped(json, false);
|
|
45
|
+
}
|
|
46
|
+
function QuizSessionScoreToJSONTyped(value, ignoreDiscriminator = false) {
|
|
47
|
+
if (value == null) {
|
|
48
|
+
return value;
|
|
49
|
+
}
|
|
50
|
+
return {
|
|
51
|
+
'totalCorrect': value['totalCorrect'],
|
|
52
|
+
'totalQuestions': value['totalQuestions'],
|
|
53
|
+
};
|
|
54
|
+
}
|
package/dist/models/index.d.ts
CHANGED
|
@@ -43,6 +43,7 @@ export * from './MessagePartsInner';
|
|
|
43
43
|
export * from './PaginatedChats';
|
|
44
44
|
export * from './PaginatedLearningMoments';
|
|
45
45
|
export * from './PaginatedMessages';
|
|
46
|
+
export * from './PaginatedQuizSessions';
|
|
46
47
|
export * from './PaginatedQuizzes';
|
|
47
48
|
export * from './PaginatedTaxonomies';
|
|
48
49
|
export * from './Plan';
|
|
@@ -51,6 +52,8 @@ export * from './QuizListItem';
|
|
|
51
52
|
export * from './QuizQuestion';
|
|
52
53
|
export * from './QuizResponse';
|
|
53
54
|
export * from './QuizSession';
|
|
55
|
+
export * from './QuizSessionListItem';
|
|
56
|
+
export * from './QuizSessionScore';
|
|
54
57
|
export * from './QuizSessionSummary';
|
|
55
58
|
export * from './QuizWithQuestions';
|
|
56
59
|
export * from './Score';
|
package/dist/models/index.js
CHANGED
|
@@ -61,6 +61,7 @@ __exportStar(require("./MessagePartsInner"), exports);
|
|
|
61
61
|
__exportStar(require("./PaginatedChats"), exports);
|
|
62
62
|
__exportStar(require("./PaginatedLearningMoments"), exports);
|
|
63
63
|
__exportStar(require("./PaginatedMessages"), exports);
|
|
64
|
+
__exportStar(require("./PaginatedQuizSessions"), exports);
|
|
64
65
|
__exportStar(require("./PaginatedQuizzes"), exports);
|
|
65
66
|
__exportStar(require("./PaginatedTaxonomies"), exports);
|
|
66
67
|
__exportStar(require("./Plan"), exports);
|
|
@@ -69,6 +70,8 @@ __exportStar(require("./QuizListItem"), exports);
|
|
|
69
70
|
__exportStar(require("./QuizQuestion"), exports);
|
|
70
71
|
__exportStar(require("./QuizResponse"), exports);
|
|
71
72
|
__exportStar(require("./QuizSession"), exports);
|
|
73
|
+
__exportStar(require("./QuizSessionListItem"), exports);
|
|
74
|
+
__exportStar(require("./QuizSessionScore"), exports);
|
|
72
75
|
__exportStar(require("./QuizSessionSummary"), exports);
|
|
73
76
|
__exportStar(require("./QuizWithQuestions"), exports);
|
|
74
77
|
__exportStar(require("./Score"), exports);
|