@examplary/sdk 0.0.1
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 +25 -0
- package/dist/generated/client/client/client.gen.d.ts +2 -0
- package/dist/generated/client/client/client.gen.js +204 -0
- package/dist/generated/client/client/index.d.ts +8 -0
- package/dist/generated/client/client/index.js +16 -0
- package/dist/generated/client/client/types.gen.d.ts +88 -0
- package/dist/generated/client/client/types.gen.js +3 -0
- package/dist/generated/client/client/utils.gen.d.ts +14 -0
- package/dist/generated/client/client/utils.gen.js +326 -0
- package/dist/generated/client/client.gen.d.ts +12 -0
- package/dist/generated/client/client.gen.js +6 -0
- package/dist/generated/client/core/auth.gen.d.ts +18 -0
- package/dist/generated/client/core/auth.gen.js +69 -0
- package/dist/generated/client/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/client/core/bodySerializer.gen.js +80 -0
- package/dist/generated/client/core/params.gen.d.ts +43 -0
- package/dist/generated/client/core/params.gen.js +191 -0
- package/dist/generated/client/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/client/core/pathSerializer.gen.js +147 -0
- package/dist/generated/client/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/client/core/queryKeySerializer.gen.js +140 -0
- package/dist/generated/client/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/client/core/serverSentEvents.gen.js +282 -0
- package/dist/generated/client/core/types.gen.d.ts +78 -0
- package/dist/generated/client/core/types.gen.js +3 -0
- package/dist/generated/client/core/utils.gen.d.ts +19 -0
- package/dist/generated/client/core/utils.gen.js +117 -0
- package/dist/generated/client/index.d.ts +2 -0
- package/dist/generated/client/index.js +31 -0
- package/dist/generated/client/sdk.gen.d.ts +685 -0
- package/dist/generated/client/sdk.gen.js +1295 -0
- package/dist/generated/client/types.gen.d.ts +1777 -0
- package/dist/generated/client/types.gen.js +3 -0
- package/dist/src/index.d.ts +14 -0
- package/dist/src/index.js +81 -0
- package/package.json +37 -0
|
@@ -0,0 +1,1295 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file is auto-generated based on the Examplary API schema.
|
|
3
|
+
var __extends = (this && this.__extends) || (function () {
|
|
4
|
+
var extendStatics = function (d, b) {
|
|
5
|
+
extendStatics = Object.setPrototypeOf ||
|
|
6
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
7
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
8
|
+
return extendStatics(d, b);
|
|
9
|
+
};
|
|
10
|
+
return function (d, b) {
|
|
11
|
+
if (typeof b !== "function" && b !== null)
|
|
12
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
13
|
+
extendStatics(d, b);
|
|
14
|
+
function __() { this.constructor = d; }
|
|
15
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
16
|
+
};
|
|
17
|
+
})();
|
|
18
|
+
var __assign = (this && this.__assign) || function () {
|
|
19
|
+
__assign = Object.assign || function(t) {
|
|
20
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
21
|
+
s = arguments[i];
|
|
22
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
23
|
+
t[p] = s[p];
|
|
24
|
+
}
|
|
25
|
+
return t;
|
|
26
|
+
};
|
|
27
|
+
return __assign.apply(this, arguments);
|
|
28
|
+
};
|
|
29
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
|
+
exports.Examplary = exports.QuestionBank = exports.Folders = exports.SourceMaterials = exports.PracticeSpaces = exports.Exams = exports.Exam = exports.Export = exports.Questions = exports.Sessions = exports.Users = exports.StudentLevels = exports.Permissions = exports.Taxonomies = exports.ApiKeys = exports.Orgs = exports.Org = exports.Media = exports.Me = exports.EmbedSessions = exports.Oauth = exports.Library = exports.Items2 = exports.Publishers = exports.Items = exports.QuestionTypes = void 0;
|
|
31
|
+
var client_gen_1 = require("./client.gen");
|
|
32
|
+
var HeyApiClient = /** @class */ (function () {
|
|
33
|
+
function HeyApiClient(args) {
|
|
34
|
+
var _a;
|
|
35
|
+
this.client = (_a = args === null || args === void 0 ? void 0 : args.client) !== null && _a !== void 0 ? _a : client_gen_1.client;
|
|
36
|
+
}
|
|
37
|
+
return HeyApiClient;
|
|
38
|
+
}());
|
|
39
|
+
var HeyApiRegistry = /** @class */ (function () {
|
|
40
|
+
function HeyApiRegistry() {
|
|
41
|
+
this.defaultKey = 'default';
|
|
42
|
+
this.instances = new Map();
|
|
43
|
+
}
|
|
44
|
+
HeyApiRegistry.prototype.get = function (key) {
|
|
45
|
+
var instance = this.instances.get(key !== null && key !== void 0 ? key : this.defaultKey);
|
|
46
|
+
if (!instance) {
|
|
47
|
+
throw new Error("No SDK client found. Create one with \"new Examplary()\" to fix this error.");
|
|
48
|
+
}
|
|
49
|
+
return instance;
|
|
50
|
+
};
|
|
51
|
+
HeyApiRegistry.prototype.set = function (value, key) {
|
|
52
|
+
this.instances.set(key !== null && key !== void 0 ? key : this.defaultKey, value);
|
|
53
|
+
};
|
|
54
|
+
return HeyApiRegistry;
|
|
55
|
+
}());
|
|
56
|
+
var QuestionTypes = /** @class */ (function (_super) {
|
|
57
|
+
__extends(QuestionTypes, _super);
|
|
58
|
+
function QuestionTypes() {
|
|
59
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* List public question types
|
|
63
|
+
*
|
|
64
|
+
* Lists all public question types, which can be enabled in workspaces.
|
|
65
|
+
*/
|
|
66
|
+
QuestionTypes.prototype.listPublic = function (options) {
|
|
67
|
+
var _a;
|
|
68
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-types/public' }, options));
|
|
69
|
+
};
|
|
70
|
+
/**
|
|
71
|
+
* Delete question type
|
|
72
|
+
*
|
|
73
|
+
* Deletes a specific question type by its ID. Note that only the owner organization of the question type can delete it, and only if it has not been used in an exam.
|
|
74
|
+
*/
|
|
75
|
+
QuestionTypes.prototype.delete = function (options) {
|
|
76
|
+
var _a;
|
|
77
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-types/{id}' }, options));
|
|
78
|
+
};
|
|
79
|
+
/**
|
|
80
|
+
* Get question type
|
|
81
|
+
*
|
|
82
|
+
* Retrieves a specific question type by its ID.
|
|
83
|
+
*/
|
|
84
|
+
QuestionTypes.prototype.get = function (options) {
|
|
85
|
+
var _a;
|
|
86
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-types/{id}' }, options));
|
|
87
|
+
};
|
|
88
|
+
/**
|
|
89
|
+
* Get question type PCI module for QTI 3 export
|
|
90
|
+
*
|
|
91
|
+
* Get JS module for a question type PCI for QTI 3 export.
|
|
92
|
+
*/
|
|
93
|
+
QuestionTypes.prototype.getQti3Pci = function (options) {
|
|
94
|
+
var _a;
|
|
95
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-types/{id}/export/qti3-pci' }, options));
|
|
96
|
+
};
|
|
97
|
+
/**
|
|
98
|
+
* List question types
|
|
99
|
+
*
|
|
100
|
+
* Lists all question types, either those available by default or those created within the user's organization.
|
|
101
|
+
*/
|
|
102
|
+
QuestionTypes.prototype.list = function (options) {
|
|
103
|
+
var _a;
|
|
104
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-types' }, options));
|
|
105
|
+
};
|
|
106
|
+
/**
|
|
107
|
+
* Upsert question type
|
|
108
|
+
*
|
|
109
|
+
* Creates a new question type or updates an existing one. If the question type already exists, it will be updated; otherwise, a new one will be created.
|
|
110
|
+
*/
|
|
111
|
+
QuestionTypes.prototype.upsert = function (options) {
|
|
112
|
+
var _a;
|
|
113
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-types' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
114
|
+
};
|
|
115
|
+
/**
|
|
116
|
+
* Enable question type
|
|
117
|
+
*
|
|
118
|
+
* Enable a question type for the current workspace.
|
|
119
|
+
*/
|
|
120
|
+
QuestionTypes.prototype.enable = function (options) {
|
|
121
|
+
var _a;
|
|
122
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-types/{id}/enable' }, options));
|
|
123
|
+
};
|
|
124
|
+
/**
|
|
125
|
+
* Disable question type
|
|
126
|
+
*
|
|
127
|
+
* Disable a question type for the current workspace.
|
|
128
|
+
*/
|
|
129
|
+
QuestionTypes.prototype.disable = function (options) {
|
|
130
|
+
var _a;
|
|
131
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-types/{id}/disable' }, options));
|
|
132
|
+
};
|
|
133
|
+
return QuestionTypes;
|
|
134
|
+
}(HeyApiClient));
|
|
135
|
+
exports.QuestionTypes = QuestionTypes;
|
|
136
|
+
var Items = /** @class */ (function (_super) {
|
|
137
|
+
__extends(Items, _super);
|
|
138
|
+
function Items() {
|
|
139
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
140
|
+
}
|
|
141
|
+
/**
|
|
142
|
+
* List items by publisher
|
|
143
|
+
*
|
|
144
|
+
* Lists all library items for the specified publisher profile.
|
|
145
|
+
*/
|
|
146
|
+
Items.prototype.list = function (options) {
|
|
147
|
+
var _a;
|
|
148
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/publishers/{publisherId}/items' }, options));
|
|
149
|
+
};
|
|
150
|
+
/**
|
|
151
|
+
* Create library item
|
|
152
|
+
*
|
|
153
|
+
* Adds an item to the library. Only the publisher owner can add items to their publisher profile.
|
|
154
|
+
*/
|
|
155
|
+
Items.prototype.create = function (options) {
|
|
156
|
+
var _a;
|
|
157
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/publishers/{publisherId}/items' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
158
|
+
};
|
|
159
|
+
return Items;
|
|
160
|
+
}(HeyApiClient));
|
|
161
|
+
exports.Items = Items;
|
|
162
|
+
var Publishers = /** @class */ (function (_super) {
|
|
163
|
+
__extends(Publishers, _super);
|
|
164
|
+
function Publishers() {
|
|
165
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
166
|
+
}
|
|
167
|
+
/**
|
|
168
|
+
* List featured publishers
|
|
169
|
+
*
|
|
170
|
+
* Lists all library publishers that are marked as featured.
|
|
171
|
+
*/
|
|
172
|
+
Publishers.prototype.listFeatured = function (options) {
|
|
173
|
+
var _a;
|
|
174
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/publishers/featured' }, options));
|
|
175
|
+
};
|
|
176
|
+
/**
|
|
177
|
+
* List all publishers
|
|
178
|
+
*
|
|
179
|
+
* Lists all library publisher profiles.
|
|
180
|
+
*/
|
|
181
|
+
Publishers.prototype.listAll = function (options) {
|
|
182
|
+
var _a;
|
|
183
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/publishers' }, options));
|
|
184
|
+
};
|
|
185
|
+
/**
|
|
186
|
+
* Create publisher
|
|
187
|
+
*
|
|
188
|
+
* Creates a new library publisher profile.
|
|
189
|
+
*/
|
|
190
|
+
Publishers.prototype.create = function (options) {
|
|
191
|
+
var _a;
|
|
192
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/publishers' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
193
|
+
};
|
|
194
|
+
/**
|
|
195
|
+
* List my publishers
|
|
196
|
+
*
|
|
197
|
+
* Lists all library publisher profiles created by the authenticated user.
|
|
198
|
+
*/
|
|
199
|
+
Publishers.prototype.listMine = function (options) {
|
|
200
|
+
var _a;
|
|
201
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/publishers/mine' }, options));
|
|
202
|
+
};
|
|
203
|
+
/**
|
|
204
|
+
* Delete publisher
|
|
205
|
+
*
|
|
206
|
+
* Deletes a library publisher profile. Only the owner can delete their publisher profile.
|
|
207
|
+
*/
|
|
208
|
+
Publishers.prototype.delete = function (options) {
|
|
209
|
+
var _a;
|
|
210
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/publishers/{publisherId}' }, options));
|
|
211
|
+
};
|
|
212
|
+
/**
|
|
213
|
+
* Update publisher
|
|
214
|
+
*
|
|
215
|
+
* Updates a library publisher profile. Only the owner can update their publisher profile.
|
|
216
|
+
*/
|
|
217
|
+
Publishers.prototype.update = function (options) {
|
|
218
|
+
var _a;
|
|
219
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).patch(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/publishers/{publisherId}' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
220
|
+
};
|
|
221
|
+
Object.defineProperty(Publishers.prototype, "items", {
|
|
222
|
+
get: function () {
|
|
223
|
+
var _a;
|
|
224
|
+
return (_a = this._items) !== null && _a !== void 0 ? _a : (this._items = new Items({ client: this.client }));
|
|
225
|
+
},
|
|
226
|
+
enumerable: false,
|
|
227
|
+
configurable: true
|
|
228
|
+
});
|
|
229
|
+
return Publishers;
|
|
230
|
+
}(HeyApiClient));
|
|
231
|
+
exports.Publishers = Publishers;
|
|
232
|
+
var Items2 = /** @class */ (function (_super) {
|
|
233
|
+
__extends(Items2, _super);
|
|
234
|
+
function Items2() {
|
|
235
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
236
|
+
}
|
|
237
|
+
/**
|
|
238
|
+
* List featured library items
|
|
239
|
+
*
|
|
240
|
+
* Lists all library items that are marked as featured.
|
|
241
|
+
*/
|
|
242
|
+
Items2.prototype.listFeatured = function (options) {
|
|
243
|
+
var _a;
|
|
244
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/items/featured' }, options));
|
|
245
|
+
};
|
|
246
|
+
/**
|
|
247
|
+
* Delete library item
|
|
248
|
+
*
|
|
249
|
+
* Deletes a library item. Only the publisher owner can delete items from their publisher profile.
|
|
250
|
+
*/
|
|
251
|
+
Items2.prototype.delete = function (options) {
|
|
252
|
+
var _a;
|
|
253
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/items/{itemId}' }, options));
|
|
254
|
+
};
|
|
255
|
+
/**
|
|
256
|
+
* Update library item
|
|
257
|
+
*
|
|
258
|
+
* Updates a library item. Only the publisher owner can update items in their publisher profile.
|
|
259
|
+
*/
|
|
260
|
+
Items2.prototype.update = function (options) {
|
|
261
|
+
var _a;
|
|
262
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).patch(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/library/items/{itemId}' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
263
|
+
};
|
|
264
|
+
return Items2;
|
|
265
|
+
}(HeyApiClient));
|
|
266
|
+
exports.Items2 = Items2;
|
|
267
|
+
var Library = /** @class */ (function (_super) {
|
|
268
|
+
__extends(Library, _super);
|
|
269
|
+
function Library() {
|
|
270
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
271
|
+
}
|
|
272
|
+
Object.defineProperty(Library.prototype, "publishers", {
|
|
273
|
+
get: function () {
|
|
274
|
+
var _a;
|
|
275
|
+
return (_a = this._publishers) !== null && _a !== void 0 ? _a : (this._publishers = new Publishers({ client: this.client }));
|
|
276
|
+
},
|
|
277
|
+
enumerable: false,
|
|
278
|
+
configurable: true
|
|
279
|
+
});
|
|
280
|
+
Object.defineProperty(Library.prototype, "items", {
|
|
281
|
+
get: function () {
|
|
282
|
+
var _a;
|
|
283
|
+
return (_a = this._items) !== null && _a !== void 0 ? _a : (this._items = new Items2({ client: this.client }));
|
|
284
|
+
},
|
|
285
|
+
enumerable: false,
|
|
286
|
+
configurable: true
|
|
287
|
+
});
|
|
288
|
+
return Library;
|
|
289
|
+
}(HeyApiClient));
|
|
290
|
+
exports.Library = Library;
|
|
291
|
+
var Oauth = /** @class */ (function (_super) {
|
|
292
|
+
__extends(Oauth, _super);
|
|
293
|
+
function Oauth() {
|
|
294
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
295
|
+
}
|
|
296
|
+
/**
|
|
297
|
+
* OAuth authorization endpoint
|
|
298
|
+
*
|
|
299
|
+
* Initiates OAuth authorization flow. Redirects to the frontend authorization UI where users can approve or deny access.
|
|
300
|
+
*/
|
|
301
|
+
Oauth.prototype.authorize = function (options) {
|
|
302
|
+
var _a;
|
|
303
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/oauth/authorize' }, options));
|
|
304
|
+
};
|
|
305
|
+
/**
|
|
306
|
+
* OAuth token endpoint
|
|
307
|
+
*
|
|
308
|
+
* Exchange authorization code for access token, or refresh an existing token.
|
|
309
|
+
*/
|
|
310
|
+
Oauth.prototype.token = function (options) {
|
|
311
|
+
var _a;
|
|
312
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/oauth/token' }, options));
|
|
313
|
+
};
|
|
314
|
+
return Oauth;
|
|
315
|
+
}(HeyApiClient));
|
|
316
|
+
exports.Oauth = Oauth;
|
|
317
|
+
var EmbedSessions = /** @class */ (function (_super) {
|
|
318
|
+
__extends(EmbedSessions, _super);
|
|
319
|
+
function EmbedSessions() {
|
|
320
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
321
|
+
}
|
|
322
|
+
/**
|
|
323
|
+
* Create embed session
|
|
324
|
+
*
|
|
325
|
+
* Create a new embed session. This allows you to embed the exam generation flow into your own application.
|
|
326
|
+
*/
|
|
327
|
+
EmbedSessions.prototype.create = function (options) {
|
|
328
|
+
var _a;
|
|
329
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/embed-sessions' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
330
|
+
};
|
|
331
|
+
/**
|
|
332
|
+
* Revoke embed session
|
|
333
|
+
*
|
|
334
|
+
* Revoke access to an embed session by its ID.
|
|
335
|
+
*/
|
|
336
|
+
EmbedSessions.prototype.revoke = function (options) {
|
|
337
|
+
var _a;
|
|
338
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/embed-sessions/{id}' }, options));
|
|
339
|
+
};
|
|
340
|
+
/**
|
|
341
|
+
* Get embed session
|
|
342
|
+
*
|
|
343
|
+
* Retrieve an embed session by its ID.
|
|
344
|
+
*/
|
|
345
|
+
EmbedSessions.prototype.get = function (options) {
|
|
346
|
+
var _a;
|
|
347
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/embed-sessions/{id}' }, options));
|
|
348
|
+
};
|
|
349
|
+
return EmbedSessions;
|
|
350
|
+
}(HeyApiClient));
|
|
351
|
+
exports.EmbedSessions = EmbedSessions;
|
|
352
|
+
var Me = /** @class */ (function (_super) {
|
|
353
|
+
__extends(Me, _super);
|
|
354
|
+
function Me() {
|
|
355
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
356
|
+
}
|
|
357
|
+
/**
|
|
358
|
+
* Get me
|
|
359
|
+
*
|
|
360
|
+
* Get the current user's account details.
|
|
361
|
+
*/
|
|
362
|
+
Me.prototype.get = function (options) {
|
|
363
|
+
var _a;
|
|
364
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/me' }, options));
|
|
365
|
+
};
|
|
366
|
+
/**
|
|
367
|
+
* Update me
|
|
368
|
+
*
|
|
369
|
+
* Update the current user's account details.
|
|
370
|
+
*/
|
|
371
|
+
Me.prototype.update = function (options) {
|
|
372
|
+
var _a;
|
|
373
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).patch(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/me' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
374
|
+
};
|
|
375
|
+
return Me;
|
|
376
|
+
}(HeyApiClient));
|
|
377
|
+
exports.Me = Me;
|
|
378
|
+
var Media = /** @class */ (function (_super) {
|
|
379
|
+
__extends(Media, _super);
|
|
380
|
+
function Media() {
|
|
381
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
382
|
+
}
|
|
383
|
+
/**
|
|
384
|
+
* Get file upload URL
|
|
385
|
+
*
|
|
386
|
+
* Returns a signed URL for uploading a file, and a public URL for accessing it afterwards.
|
|
387
|
+
*/
|
|
388
|
+
Media.prototype.upload = function (options) {
|
|
389
|
+
var _a;
|
|
390
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/media/upload' }, options));
|
|
391
|
+
};
|
|
392
|
+
return Media;
|
|
393
|
+
}(HeyApiClient));
|
|
394
|
+
exports.Media = Media;
|
|
395
|
+
var Org = /** @class */ (function (_super) {
|
|
396
|
+
__extends(Org, _super);
|
|
397
|
+
function Org() {
|
|
398
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
399
|
+
}
|
|
400
|
+
/**
|
|
401
|
+
* Delete organization
|
|
402
|
+
*/
|
|
403
|
+
Org.prototype.delete = function (options) {
|
|
404
|
+
var _a;
|
|
405
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/org' }, options));
|
|
406
|
+
};
|
|
407
|
+
/**
|
|
408
|
+
* Get organization
|
|
409
|
+
*/
|
|
410
|
+
Org.prototype.get = function (options) {
|
|
411
|
+
var _a;
|
|
412
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/org' }, options));
|
|
413
|
+
};
|
|
414
|
+
/**
|
|
415
|
+
* Update organization
|
|
416
|
+
*/
|
|
417
|
+
Org.prototype.update = function (options) {
|
|
418
|
+
var _a;
|
|
419
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).patch(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/org' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
420
|
+
};
|
|
421
|
+
return Org;
|
|
422
|
+
}(HeyApiClient));
|
|
423
|
+
exports.Org = Org;
|
|
424
|
+
var Orgs = /** @class */ (function (_super) {
|
|
425
|
+
__extends(Orgs, _super);
|
|
426
|
+
function Orgs() {
|
|
427
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
428
|
+
}
|
|
429
|
+
/**
|
|
430
|
+
* List all organizations
|
|
431
|
+
*/
|
|
432
|
+
Orgs.prototype.list = function (options) {
|
|
433
|
+
var _a;
|
|
434
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/orgs' }, options));
|
|
435
|
+
};
|
|
436
|
+
/**
|
|
437
|
+
* Create a new organization
|
|
438
|
+
*
|
|
439
|
+
* Create a new workspace to collaborate with others on exams.
|
|
440
|
+
*/
|
|
441
|
+
Orgs.prototype.create = function (options) {
|
|
442
|
+
var _a;
|
|
443
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/orgs' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
444
|
+
};
|
|
445
|
+
return Orgs;
|
|
446
|
+
}(HeyApiClient));
|
|
447
|
+
exports.Orgs = Orgs;
|
|
448
|
+
var ApiKeys = /** @class */ (function (_super) {
|
|
449
|
+
__extends(ApiKeys, _super);
|
|
450
|
+
function ApiKeys() {
|
|
451
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
452
|
+
}
|
|
453
|
+
/**
|
|
454
|
+
* Get API key
|
|
455
|
+
*
|
|
456
|
+
* Get the API key for the current org/user combination. Creates one if none exists.
|
|
457
|
+
*/
|
|
458
|
+
ApiKeys.prototype.get = function (options) {
|
|
459
|
+
var _a;
|
|
460
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/api-keys' }, options));
|
|
461
|
+
};
|
|
462
|
+
/**
|
|
463
|
+
* Reset API key
|
|
464
|
+
*
|
|
465
|
+
* Invalidate old API keys for this org/user and create a new one.
|
|
466
|
+
*/
|
|
467
|
+
ApiKeys.prototype.reset = function (options) {
|
|
468
|
+
var _a;
|
|
469
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/api-keys/reset' }, options));
|
|
470
|
+
};
|
|
471
|
+
return ApiKeys;
|
|
472
|
+
}(HeyApiClient));
|
|
473
|
+
exports.ApiKeys = ApiKeys;
|
|
474
|
+
var Taxonomies = /** @class */ (function (_super) {
|
|
475
|
+
__extends(Taxonomies, _super);
|
|
476
|
+
function Taxonomies() {
|
|
477
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
478
|
+
}
|
|
479
|
+
/**
|
|
480
|
+
* Get taxonomies
|
|
481
|
+
*
|
|
482
|
+
* Get a list available taxonomies, including defaults and taxonomies created in the current workspace.
|
|
483
|
+
*/
|
|
484
|
+
Taxonomies.prototype.list = function (options) {
|
|
485
|
+
var _a;
|
|
486
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/taxonomies' }, options));
|
|
487
|
+
};
|
|
488
|
+
/**
|
|
489
|
+
* Create taxonomy
|
|
490
|
+
*
|
|
491
|
+
* Save a new taxonomy in the current workspace.
|
|
492
|
+
*/
|
|
493
|
+
Taxonomies.prototype.create = function (options) {
|
|
494
|
+
var _a;
|
|
495
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/taxonomies' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
496
|
+
};
|
|
497
|
+
/**
|
|
498
|
+
* Delete taxonomy
|
|
499
|
+
*
|
|
500
|
+
* Delete a taxonomy from the current workspace. This fails if there are any exams associated with the taxonomy.
|
|
501
|
+
*/
|
|
502
|
+
Taxonomies.prototype.delete = function (options) {
|
|
503
|
+
var _a;
|
|
504
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/taxonomies/{id}' }, options));
|
|
505
|
+
};
|
|
506
|
+
/**
|
|
507
|
+
* Update taxonomy
|
|
508
|
+
*
|
|
509
|
+
* Update an existing taxonomy in the current workspace.
|
|
510
|
+
*/
|
|
511
|
+
Taxonomies.prototype.update = function (options) {
|
|
512
|
+
var _a;
|
|
513
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/taxonomies/{id}' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
514
|
+
};
|
|
515
|
+
return Taxonomies;
|
|
516
|
+
}(HeyApiClient));
|
|
517
|
+
exports.Taxonomies = Taxonomies;
|
|
518
|
+
var Permissions = /** @class */ (function (_super) {
|
|
519
|
+
__extends(Permissions, _super);
|
|
520
|
+
function Permissions() {
|
|
521
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
522
|
+
}
|
|
523
|
+
/**
|
|
524
|
+
* Get sharing permissions
|
|
525
|
+
*
|
|
526
|
+
* Get a list of users, groups and orgs that have access to a specific resource.
|
|
527
|
+
*/
|
|
528
|
+
Permissions.prototype.list = function (options) {
|
|
529
|
+
var _a;
|
|
530
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/permissions/{resource}' }, options));
|
|
531
|
+
};
|
|
532
|
+
/**
|
|
533
|
+
* Create permission
|
|
534
|
+
*
|
|
535
|
+
* Create a new permission for a specific resource, or update the role of an existing actor.
|
|
536
|
+
*/
|
|
537
|
+
Permissions.prototype.assign = function (options) {
|
|
538
|
+
var _a;
|
|
539
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/permissions/{resource}' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
540
|
+
};
|
|
541
|
+
/**
|
|
542
|
+
* Remove permission
|
|
543
|
+
*
|
|
544
|
+
* Remove a permission for a specific actor on a specific resource.
|
|
545
|
+
*/
|
|
546
|
+
Permissions.prototype.delete = function (options) {
|
|
547
|
+
var _a;
|
|
548
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/permissions/{resource}/{actor}' }, options));
|
|
549
|
+
};
|
|
550
|
+
/**
|
|
551
|
+
* Get actor role
|
|
552
|
+
*
|
|
553
|
+
* Get the role of a specific actor for a specific resource.
|
|
554
|
+
*/
|
|
555
|
+
Permissions.prototype.getActorRole = function (options) {
|
|
556
|
+
var _a;
|
|
557
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/permissions/{resource}/{actor}' }, options));
|
|
558
|
+
};
|
|
559
|
+
return Permissions;
|
|
560
|
+
}(HeyApiClient));
|
|
561
|
+
exports.Permissions = Permissions;
|
|
562
|
+
var StudentLevels = /** @class */ (function (_super) {
|
|
563
|
+
__extends(StudentLevels, _super);
|
|
564
|
+
function StudentLevels() {
|
|
565
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
566
|
+
}
|
|
567
|
+
/**
|
|
568
|
+
* List available student levels
|
|
569
|
+
*
|
|
570
|
+
* Get a list of available default student levels.
|
|
571
|
+
*/
|
|
572
|
+
StudentLevels.prototype.list = function (options) {
|
|
573
|
+
var _a;
|
|
574
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/student-levels' }, options));
|
|
575
|
+
};
|
|
576
|
+
return StudentLevels;
|
|
577
|
+
}(HeyApiClient));
|
|
578
|
+
exports.StudentLevels = StudentLevels;
|
|
579
|
+
var Users = /** @class */ (function (_super) {
|
|
580
|
+
__extends(Users, _super);
|
|
581
|
+
function Users() {
|
|
582
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
583
|
+
}
|
|
584
|
+
/**
|
|
585
|
+
* List users
|
|
586
|
+
*
|
|
587
|
+
* Get a list of all users in the workspace.
|
|
588
|
+
*/
|
|
589
|
+
Users.prototype.list = function (options) {
|
|
590
|
+
var _a;
|
|
591
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/users' }, options));
|
|
592
|
+
};
|
|
593
|
+
/**
|
|
594
|
+
* Create user
|
|
595
|
+
*
|
|
596
|
+
* Create a new user in the workspace.
|
|
597
|
+
*/
|
|
598
|
+
Users.prototype.create = function (options) {
|
|
599
|
+
var _a;
|
|
600
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/users' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
601
|
+
};
|
|
602
|
+
/**
|
|
603
|
+
* Delete user
|
|
604
|
+
*
|
|
605
|
+
* Delete a user from the workspace.
|
|
606
|
+
*/
|
|
607
|
+
Users.prototype.delete = function (options) {
|
|
608
|
+
var _a;
|
|
609
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/users/{id}' }, options));
|
|
610
|
+
};
|
|
611
|
+
/**
|
|
612
|
+
* Update user role
|
|
613
|
+
*
|
|
614
|
+
* Update a user's role within the workspace.
|
|
615
|
+
*/
|
|
616
|
+
Users.prototype.update = function (options) {
|
|
617
|
+
var _a;
|
|
618
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).patch(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/users/{id}' }, options));
|
|
619
|
+
};
|
|
620
|
+
return Users;
|
|
621
|
+
}(HeyApiClient));
|
|
622
|
+
exports.Users = Users;
|
|
623
|
+
var Sessions = /** @class */ (function (_super) {
|
|
624
|
+
__extends(Sessions, _super);
|
|
625
|
+
function Sessions() {
|
|
626
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
627
|
+
}
|
|
628
|
+
/**
|
|
629
|
+
* List exam sessions
|
|
630
|
+
*
|
|
631
|
+
* Get a list of all student sessions for an exam, representing a set of answers from a student.
|
|
632
|
+
*/
|
|
633
|
+
Sessions.prototype.list = function (options) {
|
|
634
|
+
var _a;
|
|
635
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/sessions' }, options));
|
|
636
|
+
};
|
|
637
|
+
/**
|
|
638
|
+
* Create session
|
|
639
|
+
*
|
|
640
|
+
* Manually create a session, possibly from uploaded data.
|
|
641
|
+
*/
|
|
642
|
+
Sessions.prototype.import = function (options) {
|
|
643
|
+
var _a;
|
|
644
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/sessions' }, options));
|
|
645
|
+
};
|
|
646
|
+
/**
|
|
647
|
+
* Get answers from scan
|
|
648
|
+
*
|
|
649
|
+
* Scan student answers from a document.
|
|
650
|
+
*/
|
|
651
|
+
Sessions.prototype.scan = function (options) {
|
|
652
|
+
var _a;
|
|
653
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/sessions/scan' }, options));
|
|
654
|
+
};
|
|
655
|
+
/**
|
|
656
|
+
* Delete exam session
|
|
657
|
+
*
|
|
658
|
+
* Remove an exam session.
|
|
659
|
+
*/
|
|
660
|
+
Sessions.prototype.delete = function (options) {
|
|
661
|
+
var _a;
|
|
662
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/sessions/{sessionId}' }, options));
|
|
663
|
+
};
|
|
664
|
+
/**
|
|
665
|
+
* Get exam session
|
|
666
|
+
*
|
|
667
|
+
* Get a single exam session by its ID, representing a set of answers from a student.
|
|
668
|
+
*/
|
|
669
|
+
Sessions.prototype.get = function (options) {
|
|
670
|
+
var _a;
|
|
671
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/sessions/{sessionId}' }, options));
|
|
672
|
+
};
|
|
673
|
+
/**
|
|
674
|
+
* Provide feedback
|
|
675
|
+
*
|
|
676
|
+
* Set teacher feedback and/or a grade for a specific question in an exam session.
|
|
677
|
+
*/
|
|
678
|
+
Sessions.prototype.saveFeedback = function (options) {
|
|
679
|
+
var _a;
|
|
680
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/sessions/{sessionId}/feedback' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
681
|
+
};
|
|
682
|
+
/**
|
|
683
|
+
* Provide overall feedback
|
|
684
|
+
*
|
|
685
|
+
* Set teacher feedback for the test as a whole in an exam session.
|
|
686
|
+
*/
|
|
687
|
+
Sessions.prototype.saveOverallFeedback = function (options) {
|
|
688
|
+
var _a;
|
|
689
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/sessions/{sessionId}/overall-feedback' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
690
|
+
};
|
|
691
|
+
/**
|
|
692
|
+
* Generate overall feedback
|
|
693
|
+
*
|
|
694
|
+
* Generate feedback for the test as a whole in an exam session.
|
|
695
|
+
*/
|
|
696
|
+
Sessions.prototype.generateOverallFeedback = function (options) {
|
|
697
|
+
var _a;
|
|
698
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/sessions/{sessionId}/generate-overall-feedback' }, options));
|
|
699
|
+
};
|
|
700
|
+
/**
|
|
701
|
+
* Accept AI grading suggestions
|
|
702
|
+
*
|
|
703
|
+
* Accept all AI-generated grading suggestions for the exam session.
|
|
704
|
+
*/
|
|
705
|
+
Sessions.prototype.acceptAllSuggestions = function (options) {
|
|
706
|
+
var _a;
|
|
707
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/sessions/{sessionId}/suggestions/accept-all' }, options));
|
|
708
|
+
};
|
|
709
|
+
/**
|
|
710
|
+
* Accept single AI grading suggestion
|
|
711
|
+
*
|
|
712
|
+
* Accept a single AI-generated grading suggestion for the exam session.
|
|
713
|
+
*/
|
|
714
|
+
Sessions.prototype.acceptSuggestion = function (options) {
|
|
715
|
+
var _a;
|
|
716
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/sessions/{sessionId}/suggestions/{questionId}/accept' }, options));
|
|
717
|
+
};
|
|
718
|
+
return Sessions;
|
|
719
|
+
}(HeyApiClient));
|
|
720
|
+
exports.Sessions = Sessions;
|
|
721
|
+
var Questions = /** @class */ (function (_super) {
|
|
722
|
+
__extends(Questions, _super);
|
|
723
|
+
function Questions() {
|
|
724
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
725
|
+
}
|
|
726
|
+
/**
|
|
727
|
+
* Import questions
|
|
728
|
+
*
|
|
729
|
+
* Import questions into an exam from a file. Support Word, PDF, Moodle quiz XML and plain text files.
|
|
730
|
+
*/
|
|
731
|
+
Questions.prototype.import = function (options) {
|
|
732
|
+
var _a;
|
|
733
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/questions/import' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
734
|
+
};
|
|
735
|
+
/**
|
|
736
|
+
* Generate question
|
|
737
|
+
*
|
|
738
|
+
* Generate a new question for the exam using an AI prompt.
|
|
739
|
+
*/
|
|
740
|
+
Questions.prototype.generate = function (options) {
|
|
741
|
+
var _a;
|
|
742
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/questions/generate' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
743
|
+
};
|
|
744
|
+
/**
|
|
745
|
+
* Regenerate question
|
|
746
|
+
*
|
|
747
|
+
* Update a question using an AI prompt.
|
|
748
|
+
*/
|
|
749
|
+
Questions.prototype.regenerate = function (options) {
|
|
750
|
+
var _a;
|
|
751
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/questions/{questionId}/generate' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
752
|
+
};
|
|
753
|
+
return Questions;
|
|
754
|
+
}(HeyApiClient));
|
|
755
|
+
exports.Questions = Questions;
|
|
756
|
+
var Export = /** @class */ (function (_super) {
|
|
757
|
+
__extends(Export, _super);
|
|
758
|
+
function Export() {
|
|
759
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
760
|
+
}
|
|
761
|
+
/**
|
|
762
|
+
* Export QTI 3 package
|
|
763
|
+
*
|
|
764
|
+
* Export an exam as a QTI 3 ZIP package.
|
|
765
|
+
*/
|
|
766
|
+
Export.prototype.qti3Zip = function (options) {
|
|
767
|
+
var _a;
|
|
768
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/export/qti3-zip' }, options));
|
|
769
|
+
};
|
|
770
|
+
/**
|
|
771
|
+
* Export QTI 2.1 package
|
|
772
|
+
*
|
|
773
|
+
* Export an exam as a QTI 2.1 ZIP package.
|
|
774
|
+
*/
|
|
775
|
+
Export.prototype.qti21Zip = function (options) {
|
|
776
|
+
var _a;
|
|
777
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/export/qti21-zip' }, options));
|
|
778
|
+
};
|
|
779
|
+
return Export;
|
|
780
|
+
}(HeyApiClient));
|
|
781
|
+
exports.Export = Export;
|
|
782
|
+
var Exam = /** @class */ (function (_super) {
|
|
783
|
+
__extends(Exam, _super);
|
|
784
|
+
function Exam() {
|
|
785
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
786
|
+
}
|
|
787
|
+
Object.defineProperty(Exam.prototype, "sessions", {
|
|
788
|
+
get: function () {
|
|
789
|
+
var _a;
|
|
790
|
+
return (_a = this._sessions) !== null && _a !== void 0 ? _a : (this._sessions = new Sessions({ client: this.client }));
|
|
791
|
+
},
|
|
792
|
+
enumerable: false,
|
|
793
|
+
configurable: true
|
|
794
|
+
});
|
|
795
|
+
Object.defineProperty(Exam.prototype, "questions", {
|
|
796
|
+
get: function () {
|
|
797
|
+
var _a;
|
|
798
|
+
return (_a = this._questions) !== null && _a !== void 0 ? _a : (this._questions = new Questions({ client: this.client }));
|
|
799
|
+
},
|
|
800
|
+
enumerable: false,
|
|
801
|
+
configurable: true
|
|
802
|
+
});
|
|
803
|
+
Object.defineProperty(Exam.prototype, "export", {
|
|
804
|
+
get: function () {
|
|
805
|
+
var _a;
|
|
806
|
+
return (_a = this._export) !== null && _a !== void 0 ? _a : (this._export = new Export({ client: this.client }));
|
|
807
|
+
},
|
|
808
|
+
enumerable: false,
|
|
809
|
+
configurable: true
|
|
810
|
+
});
|
|
811
|
+
return Exam;
|
|
812
|
+
}(HeyApiClient));
|
|
813
|
+
exports.Exam = Exam;
|
|
814
|
+
var Exams = /** @class */ (function (_super) {
|
|
815
|
+
__extends(Exams, _super);
|
|
816
|
+
function Exams() {
|
|
817
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
818
|
+
}
|
|
819
|
+
/**
|
|
820
|
+
* List exams
|
|
821
|
+
*
|
|
822
|
+
* Get a list of all exams within your workspace.
|
|
823
|
+
*/
|
|
824
|
+
Exams.prototype.list = function (options) {
|
|
825
|
+
var _a;
|
|
826
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams' }, options));
|
|
827
|
+
};
|
|
828
|
+
/**
|
|
829
|
+
* Create exam
|
|
830
|
+
*
|
|
831
|
+
* Create a new exam within your workspace.
|
|
832
|
+
*/
|
|
833
|
+
Exams.prototype.create = function (options) {
|
|
834
|
+
var _a;
|
|
835
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
836
|
+
};
|
|
837
|
+
/**
|
|
838
|
+
* Import exam
|
|
839
|
+
*
|
|
840
|
+
* Create an exam by importing one or more source materials (e.g. an existing exam).
|
|
841
|
+
*/
|
|
842
|
+
Exams.prototype.import = function (options) {
|
|
843
|
+
var _a;
|
|
844
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/import' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
845
|
+
};
|
|
846
|
+
/**
|
|
847
|
+
* Delete exam
|
|
848
|
+
*
|
|
849
|
+
* Delete the exam.
|
|
850
|
+
*/
|
|
851
|
+
Exams.prototype.delete = function (options) {
|
|
852
|
+
var _a;
|
|
853
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}' }, options));
|
|
854
|
+
};
|
|
855
|
+
/**
|
|
856
|
+
* Get exam
|
|
857
|
+
*
|
|
858
|
+
* Get a single exam by its ID.
|
|
859
|
+
*/
|
|
860
|
+
Exams.prototype.get = function (options) {
|
|
861
|
+
var _a;
|
|
862
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}' }, options));
|
|
863
|
+
};
|
|
864
|
+
/**
|
|
865
|
+
* Update exam
|
|
866
|
+
*
|
|
867
|
+
* Update an existing exam.
|
|
868
|
+
*/
|
|
869
|
+
Exams.prototype.update = function (options) {
|
|
870
|
+
var _a;
|
|
871
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}' }, options));
|
|
872
|
+
};
|
|
873
|
+
/**
|
|
874
|
+
* Duplicate exam
|
|
875
|
+
*
|
|
876
|
+
* Duplicate the exam's questions and settings to a new exam.
|
|
877
|
+
*/
|
|
878
|
+
Exams.prototype.duplicate = function (options) {
|
|
879
|
+
var _a;
|
|
880
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/duplicate' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
881
|
+
};
|
|
882
|
+
/**
|
|
883
|
+
* Print exam
|
|
884
|
+
*
|
|
885
|
+
* Export an exam to a PDF file or Word document.
|
|
886
|
+
*/
|
|
887
|
+
Exams.prototype.print = function (options) {
|
|
888
|
+
var _a;
|
|
889
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/print' }, options));
|
|
890
|
+
};
|
|
891
|
+
/**
|
|
892
|
+
* Generate exam
|
|
893
|
+
*
|
|
894
|
+
* Initiate a job to generate new questions for the exam using AI, based on the source materials and metadata specified.
|
|
895
|
+
*/
|
|
896
|
+
Exams.prototype.startGeneration = function (options) {
|
|
897
|
+
var _a;
|
|
898
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/generate' }, options));
|
|
899
|
+
};
|
|
900
|
+
/**
|
|
901
|
+
* Cancel exam generation
|
|
902
|
+
*
|
|
903
|
+
* Cancel an ongoing job to generate new questions for the exam using AI.
|
|
904
|
+
*/
|
|
905
|
+
Exams.prototype.cancelGeneration = function (options) {
|
|
906
|
+
var _a;
|
|
907
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/generate/cancel' }, options));
|
|
908
|
+
};
|
|
909
|
+
/**
|
|
910
|
+
* Get exam context suggestions
|
|
911
|
+
*
|
|
912
|
+
* Get AI-generated suggestions for context/instructions to include in the exam generation prompt, based on the source materials linked to the exam.
|
|
913
|
+
*/
|
|
914
|
+
Exams.prototype.getContextSuggestions = function (options) {
|
|
915
|
+
var _a;
|
|
916
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/exams/{id}/context-suggestions' }, options));
|
|
917
|
+
};
|
|
918
|
+
return Exams;
|
|
919
|
+
}(HeyApiClient));
|
|
920
|
+
exports.Exams = Exams;
|
|
921
|
+
var PracticeSpaces = /** @class */ (function (_super) {
|
|
922
|
+
__extends(PracticeSpaces, _super);
|
|
923
|
+
function PracticeSpaces() {
|
|
924
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
925
|
+
}
|
|
926
|
+
/**
|
|
927
|
+
* List practice spaces
|
|
928
|
+
*
|
|
929
|
+
* Get a list of all practice spaces you have access to in this workspace.
|
|
930
|
+
*/
|
|
931
|
+
PracticeSpaces.prototype.list = function (options) {
|
|
932
|
+
var _a;
|
|
933
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/practice-spaces' }, options));
|
|
934
|
+
};
|
|
935
|
+
/**
|
|
936
|
+
* Create practice space
|
|
937
|
+
*
|
|
938
|
+
* Create a new practice space within your workspace.
|
|
939
|
+
*/
|
|
940
|
+
PracticeSpaces.prototype.create = function (options) {
|
|
941
|
+
var _a;
|
|
942
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/practice-spaces' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
943
|
+
};
|
|
944
|
+
/**
|
|
945
|
+
* Delete practice space
|
|
946
|
+
*
|
|
947
|
+
* Delete the practice space.
|
|
948
|
+
*/
|
|
949
|
+
PracticeSpaces.prototype.delete = function (options) {
|
|
950
|
+
var _a;
|
|
951
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/practice-spaces/{id}' }, options));
|
|
952
|
+
};
|
|
953
|
+
/**
|
|
954
|
+
* Get practice space
|
|
955
|
+
*
|
|
956
|
+
* Get a single practice space by its ID.
|
|
957
|
+
*/
|
|
958
|
+
PracticeSpaces.prototype.get = function (options) {
|
|
959
|
+
var _a;
|
|
960
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/practice-spaces/{id}' }, options));
|
|
961
|
+
};
|
|
962
|
+
/**
|
|
963
|
+
* Update practice space
|
|
964
|
+
*
|
|
965
|
+
* Update an existing practice space.
|
|
966
|
+
*/
|
|
967
|
+
PracticeSpaces.prototype.update = function (options) {
|
|
968
|
+
var _a;
|
|
969
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/practice-spaces/{id}' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
970
|
+
};
|
|
971
|
+
/**
|
|
972
|
+
* Preview top practice space questions
|
|
973
|
+
*
|
|
974
|
+
* Get a preview of the top practice space questions by quality score.
|
|
975
|
+
*/
|
|
976
|
+
PracticeSpaces.prototype.questionsPreview = function (options) {
|
|
977
|
+
var _a;
|
|
978
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/practice-spaces/{id}/questions-preview' }, options));
|
|
979
|
+
};
|
|
980
|
+
return PracticeSpaces;
|
|
981
|
+
}(HeyApiClient));
|
|
982
|
+
exports.PracticeSpaces = PracticeSpaces;
|
|
983
|
+
var SourceMaterials = /** @class */ (function (_super) {
|
|
984
|
+
__extends(SourceMaterials, _super);
|
|
985
|
+
function SourceMaterials() {
|
|
986
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
987
|
+
}
|
|
988
|
+
/**
|
|
989
|
+
* List source materials in org
|
|
990
|
+
*
|
|
991
|
+
* Returns a list of source materials for the current organization.
|
|
992
|
+
*/
|
|
993
|
+
SourceMaterials.prototype.list = function (options) {
|
|
994
|
+
var _a;
|
|
995
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/source-materials' }, options));
|
|
996
|
+
};
|
|
997
|
+
/**
|
|
998
|
+
* Add source material
|
|
999
|
+
*
|
|
1000
|
+
* Add a source material and start processing it for later use in an exam.
|
|
1001
|
+
*/
|
|
1002
|
+
SourceMaterials.prototype.create = function (options) {
|
|
1003
|
+
var _a;
|
|
1004
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/source-materials' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
1005
|
+
};
|
|
1006
|
+
/**
|
|
1007
|
+
* Delete source material
|
|
1008
|
+
*
|
|
1009
|
+
* Deletes the specified source material.
|
|
1010
|
+
*/
|
|
1011
|
+
SourceMaterials.prototype.delete = function (options) {
|
|
1012
|
+
var _a;
|
|
1013
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/source-materials/{id}' }, options));
|
|
1014
|
+
};
|
|
1015
|
+
/**
|
|
1016
|
+
* Get source material
|
|
1017
|
+
*
|
|
1018
|
+
* Returns the current status and facts extracted from the specified source material.
|
|
1019
|
+
*/
|
|
1020
|
+
SourceMaterials.prototype.get = function (options) {
|
|
1021
|
+
var _a;
|
|
1022
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/source-materials/{id}' }, options));
|
|
1023
|
+
};
|
|
1024
|
+
/**
|
|
1025
|
+
* Update source material
|
|
1026
|
+
*
|
|
1027
|
+
* Updates the specified source material.
|
|
1028
|
+
*/
|
|
1029
|
+
SourceMaterials.prototype.update = function (options) {
|
|
1030
|
+
var _a;
|
|
1031
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).patch(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/source-materials/{id}' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
1032
|
+
};
|
|
1033
|
+
/**
|
|
1034
|
+
* Create a source material slice
|
|
1035
|
+
*
|
|
1036
|
+
* Create a new source material based on a specific page range of an existing source material.
|
|
1037
|
+
*/
|
|
1038
|
+
SourceMaterials.prototype.slice = function (options) {
|
|
1039
|
+
var _a;
|
|
1040
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ responseType: 'json', security: [{ name: 'Authorization', type: 'apiKey' }], url: '/source-materials/{id}/slice' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
1041
|
+
};
|
|
1042
|
+
return SourceMaterials;
|
|
1043
|
+
}(HeyApiClient));
|
|
1044
|
+
exports.SourceMaterials = SourceMaterials;
|
|
1045
|
+
var Folders = /** @class */ (function (_super) {
|
|
1046
|
+
__extends(Folders, _super);
|
|
1047
|
+
function Folders() {
|
|
1048
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
1049
|
+
}
|
|
1050
|
+
/**
|
|
1051
|
+
* Get folders
|
|
1052
|
+
*
|
|
1053
|
+
* Get a list of folders for exam organisation that exist within the current workspace.
|
|
1054
|
+
*/
|
|
1055
|
+
Folders.prototype.list = function (options) {
|
|
1056
|
+
var _a;
|
|
1057
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/folders' }, options));
|
|
1058
|
+
};
|
|
1059
|
+
/**
|
|
1060
|
+
* Create folder
|
|
1061
|
+
*
|
|
1062
|
+
* Create a new folder in the current workspace.
|
|
1063
|
+
*/
|
|
1064
|
+
Folders.prototype.create = function (options) {
|
|
1065
|
+
var _a;
|
|
1066
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/folders' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
1067
|
+
};
|
|
1068
|
+
/**
|
|
1069
|
+
* Delete folder
|
|
1070
|
+
*
|
|
1071
|
+
* Delete a folder from the current workspace. If there are any exams in the folder, they will be moved out of the folder.
|
|
1072
|
+
*/
|
|
1073
|
+
Folders.prototype.delete = function (options) {
|
|
1074
|
+
var _a;
|
|
1075
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/folders/{id}' }, options));
|
|
1076
|
+
};
|
|
1077
|
+
/**
|
|
1078
|
+
* Update folder
|
|
1079
|
+
*
|
|
1080
|
+
* Update an existing folder in the current workspace.
|
|
1081
|
+
*/
|
|
1082
|
+
Folders.prototype.update = function (options) {
|
|
1083
|
+
var _a;
|
|
1084
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/folders/{id}' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
1085
|
+
};
|
|
1086
|
+
return Folders;
|
|
1087
|
+
}(HeyApiClient));
|
|
1088
|
+
exports.Folders = Folders;
|
|
1089
|
+
var QuestionBank = /** @class */ (function (_super) {
|
|
1090
|
+
__extends(QuestionBank, _super);
|
|
1091
|
+
function QuestionBank() {
|
|
1092
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
1093
|
+
}
|
|
1094
|
+
/**
|
|
1095
|
+
* Get question bank items
|
|
1096
|
+
*
|
|
1097
|
+
* Get a list of question bank items that exist within the current workspace.
|
|
1098
|
+
*/
|
|
1099
|
+
QuestionBank.prototype.list = function (options) {
|
|
1100
|
+
var _a;
|
|
1101
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).get(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-bank' }, options));
|
|
1102
|
+
};
|
|
1103
|
+
/**
|
|
1104
|
+
* Add question to question bank
|
|
1105
|
+
*
|
|
1106
|
+
* Add a question to the question bank in the current workspace.
|
|
1107
|
+
*/
|
|
1108
|
+
QuestionBank.prototype.create = function (options) {
|
|
1109
|
+
var _a;
|
|
1110
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : this.client).post(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-bank' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options === null || options === void 0 ? void 0 : options.headers) }));
|
|
1111
|
+
};
|
|
1112
|
+
/**
|
|
1113
|
+
* Delete question bank item
|
|
1114
|
+
*
|
|
1115
|
+
* Delete a question bank item from the current workspace.
|
|
1116
|
+
*/
|
|
1117
|
+
QuestionBank.prototype.delete = function (options) {
|
|
1118
|
+
var _a;
|
|
1119
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).delete(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-bank/{id}' }, options));
|
|
1120
|
+
};
|
|
1121
|
+
/**
|
|
1122
|
+
* Update question bank item
|
|
1123
|
+
*
|
|
1124
|
+
* Update an existing question bank item in the current workspace.
|
|
1125
|
+
*/
|
|
1126
|
+
QuestionBank.prototype.update = function (options) {
|
|
1127
|
+
var _a;
|
|
1128
|
+
return ((_a = options.client) !== null && _a !== void 0 ? _a : this.client).patch(__assign(__assign({ security: [{ name: 'Authorization', type: 'apiKey' }], url: '/question-bank/{id}' }, options), { headers: __assign({ 'Content-Type': 'application/json' }, options.headers) }));
|
|
1129
|
+
};
|
|
1130
|
+
return QuestionBank;
|
|
1131
|
+
}(HeyApiClient));
|
|
1132
|
+
exports.QuestionBank = QuestionBank;
|
|
1133
|
+
var Examplary = /** @class */ (function (_super) {
|
|
1134
|
+
__extends(Examplary, _super);
|
|
1135
|
+
function Examplary(args) {
|
|
1136
|
+
var _this = _super.call(this, args) || this;
|
|
1137
|
+
Examplary.__registry.set(_this, args === null || args === void 0 ? void 0 : args.key);
|
|
1138
|
+
return _this;
|
|
1139
|
+
}
|
|
1140
|
+
Object.defineProperty(Examplary.prototype, "questionTypes", {
|
|
1141
|
+
get: function () {
|
|
1142
|
+
var _a;
|
|
1143
|
+
return (_a = this._questionTypes) !== null && _a !== void 0 ? _a : (this._questionTypes = new QuestionTypes({ client: this.client }));
|
|
1144
|
+
},
|
|
1145
|
+
enumerable: false,
|
|
1146
|
+
configurable: true
|
|
1147
|
+
});
|
|
1148
|
+
Object.defineProperty(Examplary.prototype, "library", {
|
|
1149
|
+
get: function () {
|
|
1150
|
+
var _a;
|
|
1151
|
+
return (_a = this._library) !== null && _a !== void 0 ? _a : (this._library = new Library({ client: this.client }));
|
|
1152
|
+
},
|
|
1153
|
+
enumerable: false,
|
|
1154
|
+
configurable: true
|
|
1155
|
+
});
|
|
1156
|
+
Object.defineProperty(Examplary.prototype, "oauth", {
|
|
1157
|
+
get: function () {
|
|
1158
|
+
var _a;
|
|
1159
|
+
return (_a = this._oauth) !== null && _a !== void 0 ? _a : (this._oauth = new Oauth({ client: this.client }));
|
|
1160
|
+
},
|
|
1161
|
+
enumerable: false,
|
|
1162
|
+
configurable: true
|
|
1163
|
+
});
|
|
1164
|
+
Object.defineProperty(Examplary.prototype, "embedSessions", {
|
|
1165
|
+
get: function () {
|
|
1166
|
+
var _a;
|
|
1167
|
+
return (_a = this._embedSessions) !== null && _a !== void 0 ? _a : (this._embedSessions = new EmbedSessions({ client: this.client }));
|
|
1168
|
+
},
|
|
1169
|
+
enumerable: false,
|
|
1170
|
+
configurable: true
|
|
1171
|
+
});
|
|
1172
|
+
Object.defineProperty(Examplary.prototype, "me", {
|
|
1173
|
+
get: function () {
|
|
1174
|
+
var _a;
|
|
1175
|
+
return (_a = this._me) !== null && _a !== void 0 ? _a : (this._me = new Me({ client: this.client }));
|
|
1176
|
+
},
|
|
1177
|
+
enumerable: false,
|
|
1178
|
+
configurable: true
|
|
1179
|
+
});
|
|
1180
|
+
Object.defineProperty(Examplary.prototype, "media", {
|
|
1181
|
+
get: function () {
|
|
1182
|
+
var _a;
|
|
1183
|
+
return (_a = this._media) !== null && _a !== void 0 ? _a : (this._media = new Media({ client: this.client }));
|
|
1184
|
+
},
|
|
1185
|
+
enumerable: false,
|
|
1186
|
+
configurable: true
|
|
1187
|
+
});
|
|
1188
|
+
Object.defineProperty(Examplary.prototype, "org", {
|
|
1189
|
+
get: function () {
|
|
1190
|
+
var _a;
|
|
1191
|
+
return (_a = this._org) !== null && _a !== void 0 ? _a : (this._org = new Org({ client: this.client }));
|
|
1192
|
+
},
|
|
1193
|
+
enumerable: false,
|
|
1194
|
+
configurable: true
|
|
1195
|
+
});
|
|
1196
|
+
Object.defineProperty(Examplary.prototype, "orgs", {
|
|
1197
|
+
get: function () {
|
|
1198
|
+
var _a;
|
|
1199
|
+
return (_a = this._orgs) !== null && _a !== void 0 ? _a : (this._orgs = new Orgs({ client: this.client }));
|
|
1200
|
+
},
|
|
1201
|
+
enumerable: false,
|
|
1202
|
+
configurable: true
|
|
1203
|
+
});
|
|
1204
|
+
Object.defineProperty(Examplary.prototype, "apiKeys", {
|
|
1205
|
+
get: function () {
|
|
1206
|
+
var _a;
|
|
1207
|
+
return (_a = this._apiKeys) !== null && _a !== void 0 ? _a : (this._apiKeys = new ApiKeys({ client: this.client }));
|
|
1208
|
+
},
|
|
1209
|
+
enumerable: false,
|
|
1210
|
+
configurable: true
|
|
1211
|
+
});
|
|
1212
|
+
Object.defineProperty(Examplary.prototype, "taxonomies", {
|
|
1213
|
+
get: function () {
|
|
1214
|
+
var _a;
|
|
1215
|
+
return (_a = this._taxonomies) !== null && _a !== void 0 ? _a : (this._taxonomies = new Taxonomies({ client: this.client }));
|
|
1216
|
+
},
|
|
1217
|
+
enumerable: false,
|
|
1218
|
+
configurable: true
|
|
1219
|
+
});
|
|
1220
|
+
Object.defineProperty(Examplary.prototype, "permissions", {
|
|
1221
|
+
get: function () {
|
|
1222
|
+
var _a;
|
|
1223
|
+
return (_a = this._permissions) !== null && _a !== void 0 ? _a : (this._permissions = new Permissions({ client: this.client }));
|
|
1224
|
+
},
|
|
1225
|
+
enumerable: false,
|
|
1226
|
+
configurable: true
|
|
1227
|
+
});
|
|
1228
|
+
Object.defineProperty(Examplary.prototype, "studentLevels", {
|
|
1229
|
+
get: function () {
|
|
1230
|
+
var _a;
|
|
1231
|
+
return (_a = this._studentLevels) !== null && _a !== void 0 ? _a : (this._studentLevels = new StudentLevels({ client: this.client }));
|
|
1232
|
+
},
|
|
1233
|
+
enumerable: false,
|
|
1234
|
+
configurable: true
|
|
1235
|
+
});
|
|
1236
|
+
Object.defineProperty(Examplary.prototype, "users", {
|
|
1237
|
+
get: function () {
|
|
1238
|
+
var _a;
|
|
1239
|
+
return (_a = this._users) !== null && _a !== void 0 ? _a : (this._users = new Users({ client: this.client }));
|
|
1240
|
+
},
|
|
1241
|
+
enumerable: false,
|
|
1242
|
+
configurable: true
|
|
1243
|
+
});
|
|
1244
|
+
Object.defineProperty(Examplary.prototype, "exam", {
|
|
1245
|
+
get: function () {
|
|
1246
|
+
var _a;
|
|
1247
|
+
return (_a = this._exam) !== null && _a !== void 0 ? _a : (this._exam = new Exam({ client: this.client }));
|
|
1248
|
+
},
|
|
1249
|
+
enumerable: false,
|
|
1250
|
+
configurable: true
|
|
1251
|
+
});
|
|
1252
|
+
Object.defineProperty(Examplary.prototype, "exams", {
|
|
1253
|
+
get: function () {
|
|
1254
|
+
var _a;
|
|
1255
|
+
return (_a = this._exams) !== null && _a !== void 0 ? _a : (this._exams = new Exams({ client: this.client }));
|
|
1256
|
+
},
|
|
1257
|
+
enumerable: false,
|
|
1258
|
+
configurable: true
|
|
1259
|
+
});
|
|
1260
|
+
Object.defineProperty(Examplary.prototype, "practiceSpaces", {
|
|
1261
|
+
get: function () {
|
|
1262
|
+
var _a;
|
|
1263
|
+
return (_a = this._practiceSpaces) !== null && _a !== void 0 ? _a : (this._practiceSpaces = new PracticeSpaces({ client: this.client }));
|
|
1264
|
+
},
|
|
1265
|
+
enumerable: false,
|
|
1266
|
+
configurable: true
|
|
1267
|
+
});
|
|
1268
|
+
Object.defineProperty(Examplary.prototype, "sourceMaterials", {
|
|
1269
|
+
get: function () {
|
|
1270
|
+
var _a;
|
|
1271
|
+
return (_a = this._sourceMaterials) !== null && _a !== void 0 ? _a : (this._sourceMaterials = new SourceMaterials({ client: this.client }));
|
|
1272
|
+
},
|
|
1273
|
+
enumerable: false,
|
|
1274
|
+
configurable: true
|
|
1275
|
+
});
|
|
1276
|
+
Object.defineProperty(Examplary.prototype, "folders", {
|
|
1277
|
+
get: function () {
|
|
1278
|
+
var _a;
|
|
1279
|
+
return (_a = this._folders) !== null && _a !== void 0 ? _a : (this._folders = new Folders({ client: this.client }));
|
|
1280
|
+
},
|
|
1281
|
+
enumerable: false,
|
|
1282
|
+
configurable: true
|
|
1283
|
+
});
|
|
1284
|
+
Object.defineProperty(Examplary.prototype, "questionBank", {
|
|
1285
|
+
get: function () {
|
|
1286
|
+
var _a;
|
|
1287
|
+
return (_a = this._questionBank) !== null && _a !== void 0 ? _a : (this._questionBank = new QuestionBank({ client: this.client }));
|
|
1288
|
+
},
|
|
1289
|
+
enumerable: false,
|
|
1290
|
+
configurable: true
|
|
1291
|
+
});
|
|
1292
|
+
Examplary.__registry = new HeyApiRegistry();
|
|
1293
|
+
return Examplary;
|
|
1294
|
+
}(HeyApiClient));
|
|
1295
|
+
exports.Examplary = Examplary;
|