@instructure/athena-api-client 1.0.2 → 1.0.3

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 CHANGED
@@ -64,7 +64,9 @@ All URIs are relative to *http://localhost:3000*
64
64
  *ChatsApi* | [**sendChatMessage**](docs/ChatsApi.md#sendchatmessage) | **POST** /api/v1/chat | Send a message to a chat
65
65
  *ChatsApi* | [**updateChat**](docs/ChatsApi.md#updatechatoperation) | **PATCH** /api/v1/chats/{chatId} | Update a chat
66
66
  *HealthApi* | [**healthCheck**](docs/HealthApi.md#healthcheck) | **GET** /health | Health check endpoint
67
+ *LearningDaysApi* | [**getLearningDays**](docs/LearningDaysApi.md#getlearningdays) | **GET** /api/v1/learning-days | Get learning days in range
67
68
  *LearningMomentsApi* | [**listLearningMoments**](docs/LearningMomentsApi.md#listlearningmoments) | **GET** /api/v1/learning-moments | List learning moments
69
+ *MessagesApi* | [**deleteMessages**](docs/MessagesApi.md#deletemessages) | **DELETE** /api/v1/chats/{chatId}/messages | Delete messages from timestamp
68
70
  *MessagesApi* | [**getChatMessage**](docs/MessagesApi.md#getchatmessage) | **GET** /api/v1/chats/{chatId}/messages/{messageId} | Get a chat message
69
71
  *MessagesApi* | [**getChatMessages**](docs/MessagesApi.md#getchatmessages) | **GET** /api/v1/chats/{chatId}/messages | List chat messages
70
72
  *MessagesApi* | [**getMessageCount**](docs/MessagesApi.md#getmessagecount) | **GET** /api/v1/messages/count | Count user messages
@@ -86,6 +88,7 @@ All URIs are relative to *http://localhost:3000*
86
88
  - [CreateTokenRequest](docs/CreateTokenRequest.md)
87
89
  - [CreateTokenResponse](docs/CreateTokenResponse.md)
88
90
  - [HealthCheck](docs/HealthCheck.md)
91
+ - [LearningDaysResponse](docs/LearningDaysResponse.md)
89
92
  - [LearningMoment](docs/LearningMoment.md)
90
93
  - [Message](docs/Message.md)
91
94
  - [MessageCountResponse](docs/MessageCountResponse.md)
@@ -35,6 +35,7 @@ export interface MarkChatAsViewedRequest {
35
35
  export interface SendChatMessageRequest {
36
36
  xUserId: string;
37
37
  chatRequest: ChatRequest;
38
+ xUserTimezone?: string;
38
39
  xCanvasToken?: string;
39
40
  }
40
41
  export interface UpdateChatOperationRequest {
@@ -248,6 +248,9 @@ class ChatsApi extends runtime.BaseAPI {
248
248
  const queryParameters = {};
249
249
  const headerParameters = {};
250
250
  headerParameters['Content-Type'] = 'application/json';
251
+ if (requestParameters['xUserTimezone'] != null) {
252
+ headerParameters['X-User-Timezone'] = String(requestParameters['xUserTimezone']);
253
+ }
251
254
  if (requestParameters['xCanvasToken'] != null) {
252
255
  headerParameters['X-Canvas-Token'] = String(requestParameters['xCanvasToken']);
253
256
  }
@@ -0,0 +1,33 @@
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 * as runtime from '../runtime';
13
+ import type { LearningDaysResponse } from '../models/index';
14
+ export interface GetLearningDaysRequest {
15
+ xUserId: string;
16
+ startDate: Date;
17
+ endDate: Date;
18
+ }
19
+ /**
20
+ *
21
+ */
22
+ export declare class LearningDaysApi extends runtime.BaseAPI {
23
+ /**
24
+ * Returns distinct dates within the given range on which the user had at least one learning moment, plus the date of their most recent learning moment overall.
25
+ * Get learning days in range
26
+ */
27
+ getLearningDaysRaw(requestParameters: GetLearningDaysRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<LearningDaysResponse>>;
28
+ /**
29
+ * Returns distinct dates within the given range on which the user had at least one learning moment, plus the date of their most recent learning moment overall.
30
+ * Get learning days in range
31
+ */
32
+ getLearningDays(requestParameters: GetLearningDaysRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<LearningDaysResponse>;
33
+ }
@@ -0,0 +1,82 @@
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
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
16
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
17
+ return new (P || (P = Promise))(function (resolve, reject) {
18
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
19
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
20
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
21
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
22
+ });
23
+ };
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.LearningDaysApi = void 0;
26
+ const runtime = require("../runtime");
27
+ const index_1 = require("../models/index");
28
+ /**
29
+ *
30
+ */
31
+ class LearningDaysApi extends runtime.BaseAPI {
32
+ /**
33
+ * Returns distinct dates within the given range on which the user had at least one learning moment, plus the date of their most recent learning moment overall.
34
+ * Get learning days in range
35
+ */
36
+ getLearningDaysRaw(requestParameters, initOverrides) {
37
+ return __awaiter(this, void 0, void 0, function* () {
38
+ if (requestParameters['xUserId'] == null) {
39
+ throw new runtime.RequiredError('xUserId', 'Required parameter "xUserId" was null or undefined when calling getLearningDays().');
40
+ }
41
+ if (requestParameters['startDate'] == null) {
42
+ throw new runtime.RequiredError('startDate', 'Required parameter "startDate" was null or undefined when calling getLearningDays().');
43
+ }
44
+ if (requestParameters['endDate'] == null) {
45
+ throw new runtime.RequiredError('endDate', 'Required parameter "endDate" was null or undefined when calling getLearningDays().');
46
+ }
47
+ const queryParameters = {};
48
+ if (requestParameters['startDate'] != null) {
49
+ queryParameters['startDate'] = requestParameters['startDate'].toISOString().substring(0, 10);
50
+ }
51
+ if (requestParameters['endDate'] != null) {
52
+ queryParameters['endDate'] = requestParameters['endDate'].toISOString().substring(0, 10);
53
+ }
54
+ const headerParameters = {};
55
+ if (requestParameters['xUserId'] != null) {
56
+ headerParameters['X-User-Id'] = String(requestParameters['xUserId']);
57
+ }
58
+ if (this.configuration && this.configuration.apiKey) {
59
+ headerParameters["X-Auth-Token"] = yield this.configuration.apiKey("X-Auth-Token"); // AuthToken authentication
60
+ }
61
+ let urlPath = `/api/v1/learning-days`;
62
+ const response = yield this.request({
63
+ path: urlPath,
64
+ method: 'GET',
65
+ headers: headerParameters,
66
+ query: queryParameters,
67
+ }, initOverrides);
68
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.LearningDaysResponseFromJSON)(jsonValue));
69
+ });
70
+ }
71
+ /**
72
+ * Returns distinct dates within the given range on which the user had at least one learning moment, plus the date of their most recent learning moment overall.
73
+ * Get learning days in range
74
+ */
75
+ getLearningDays(requestParameters, initOverrides) {
76
+ return __awaiter(this, void 0, void 0, function* () {
77
+ const response = yield this.getLearningDaysRaw(requestParameters, initOverrides);
78
+ return yield response.value();
79
+ });
80
+ }
81
+ }
82
+ exports.LearningDaysApi = LearningDaysApi;
@@ -11,6 +11,11 @@
11
11
  */
12
12
  import * as runtime from '../runtime';
13
13
  import type { Message, MessageCountResponse, PaginatedMessages } from '../models/index';
14
+ export interface DeleteMessagesRequest {
15
+ xUserId: string;
16
+ chatId: string;
17
+ since: Date;
18
+ }
14
19
  export interface GetChatMessageRequest {
15
20
  xUserId: string;
16
21
  chatId: string;
@@ -30,6 +35,16 @@ export interface GetMessageCountRequest {
30
35
  *
31
36
  */
32
37
  export declare class MessagesApi extends runtime.BaseAPI {
38
+ /**
39
+ * Deletes all messages in a chat at or after the given timestamp.
40
+ * Delete messages from timestamp
41
+ */
42
+ deleteMessagesRaw(requestParameters: DeleteMessagesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
43
+ /**
44
+ * Deletes all messages in a chat at or after the given timestamp.
45
+ * Delete messages from timestamp
46
+ */
47
+ deleteMessages(requestParameters: DeleteMessagesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
33
48
  /**
34
49
  * Returns a single message belonging to the specified chat.
35
50
  * Get a chat message
@@ -29,6 +29,52 @@ const index_1 = require("../models/index");
29
29
  *
30
30
  */
31
31
  class MessagesApi extends runtime.BaseAPI {
32
+ /**
33
+ * Deletes all messages in a chat at or after the given timestamp.
34
+ * Delete messages from timestamp
35
+ */
36
+ deleteMessagesRaw(requestParameters, initOverrides) {
37
+ return __awaiter(this, void 0, void 0, function* () {
38
+ if (requestParameters['xUserId'] == null) {
39
+ throw new runtime.RequiredError('xUserId', 'Required parameter "xUserId" was null or undefined when calling deleteMessages().');
40
+ }
41
+ if (requestParameters['chatId'] == null) {
42
+ throw new runtime.RequiredError('chatId', 'Required parameter "chatId" was null or undefined when calling deleteMessages().');
43
+ }
44
+ if (requestParameters['since'] == null) {
45
+ throw new runtime.RequiredError('since', 'Required parameter "since" was null or undefined when calling deleteMessages().');
46
+ }
47
+ const queryParameters = {};
48
+ if (requestParameters['since'] != null) {
49
+ queryParameters['since'] = requestParameters['since'].toISOString();
50
+ }
51
+ const headerParameters = {};
52
+ if (requestParameters['xUserId'] != null) {
53
+ headerParameters['X-User-Id'] = String(requestParameters['xUserId']);
54
+ }
55
+ if (this.configuration && this.configuration.apiKey) {
56
+ headerParameters["X-Auth-Token"] = yield this.configuration.apiKey("X-Auth-Token"); // AuthToken authentication
57
+ }
58
+ let urlPath = `/api/v1/chats/{chatId}/messages`;
59
+ urlPath = urlPath.replace(`{${"chatId"}}`, encodeURIComponent(String(requestParameters['chatId'])));
60
+ const response = yield this.request({
61
+ path: urlPath,
62
+ method: 'DELETE',
63
+ headers: headerParameters,
64
+ query: queryParameters,
65
+ }, initOverrides);
66
+ return new runtime.VoidApiResponse(response);
67
+ });
68
+ }
69
+ /**
70
+ * Deletes all messages in a chat at or after the given timestamp.
71
+ * Delete messages from timestamp
72
+ */
73
+ deleteMessages(requestParameters, initOverrides) {
74
+ return __awaiter(this, void 0, void 0, function* () {
75
+ yield this.deleteMessagesRaw(requestParameters, initOverrides);
76
+ });
77
+ }
32
78
  /**
33
79
  * Returns a single message belonging to the specified chat.
34
80
  * Get a chat message
@@ -1,6 +1,7 @@
1
1
  export * from './AccountsApi';
2
2
  export * from './ChatsApi';
3
3
  export * from './HealthApi';
4
+ export * from './LearningDaysApi';
4
5
  export * from './LearningMomentsApi';
5
6
  export * from './MessagesApi';
6
7
  export * from './ServiceTokensApi';
@@ -19,6 +19,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
19
19
  __exportStar(require("./AccountsApi"), exports);
20
20
  __exportStar(require("./ChatsApi"), exports);
21
21
  __exportStar(require("./HealthApi"), exports);
22
+ __exportStar(require("./LearningDaysApi"), exports);
22
23
  __exportStar(require("./LearningMomentsApi"), exports);
23
24
  __exportStar(require("./MessagesApi"), exports);
24
25
  __exportStar(require("./ServiceTokensApi"), exports);
@@ -35,6 +35,7 @@ export interface MarkChatAsViewedRequest {
35
35
  export interface SendChatMessageRequest {
36
36
  xUserId: string;
37
37
  chatRequest: ChatRequest;
38
+ xUserTimezone?: string;
38
39
  xCanvasToken?: string;
39
40
  }
40
41
  export interface UpdateChatOperationRequest {
@@ -245,6 +245,9 @@ export class ChatsApi extends runtime.BaseAPI {
245
245
  const queryParameters = {};
246
246
  const headerParameters = {};
247
247
  headerParameters['Content-Type'] = 'application/json';
248
+ if (requestParameters['xUserTimezone'] != null) {
249
+ headerParameters['X-User-Timezone'] = String(requestParameters['xUserTimezone']);
250
+ }
248
251
  if (requestParameters['xCanvasToken'] != null) {
249
252
  headerParameters['X-Canvas-Token'] = String(requestParameters['xCanvasToken']);
250
253
  }
@@ -0,0 +1,33 @@
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 * as runtime from '../runtime';
13
+ import type { LearningDaysResponse } from '../models/index';
14
+ export interface GetLearningDaysRequest {
15
+ xUserId: string;
16
+ startDate: Date;
17
+ endDate: Date;
18
+ }
19
+ /**
20
+ *
21
+ */
22
+ export declare class LearningDaysApi extends runtime.BaseAPI {
23
+ /**
24
+ * Returns distinct dates within the given range on which the user had at least one learning moment, plus the date of their most recent learning moment overall.
25
+ * Get learning days in range
26
+ */
27
+ getLearningDaysRaw(requestParameters: GetLearningDaysRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<LearningDaysResponse>>;
28
+ /**
29
+ * Returns distinct dates within the given range on which the user had at least one learning moment, plus the date of their most recent learning moment overall.
30
+ * Get learning days in range
31
+ */
32
+ getLearningDays(requestParameters: GetLearningDaysRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<LearningDaysResponse>;
33
+ }
@@ -0,0 +1,78 @@
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
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
15
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
16
+ return new (P || (P = Promise))(function (resolve, reject) {
17
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
18
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
19
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
20
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
21
+ });
22
+ };
23
+ import * as runtime from '../runtime';
24
+ import { LearningDaysResponseFromJSON, } from '../models/index';
25
+ /**
26
+ *
27
+ */
28
+ export class LearningDaysApi extends runtime.BaseAPI {
29
+ /**
30
+ * Returns distinct dates within the given range on which the user had at least one learning moment, plus the date of their most recent learning moment overall.
31
+ * Get learning days in range
32
+ */
33
+ getLearningDaysRaw(requestParameters, initOverrides) {
34
+ return __awaiter(this, void 0, void 0, function* () {
35
+ if (requestParameters['xUserId'] == null) {
36
+ throw new runtime.RequiredError('xUserId', 'Required parameter "xUserId" was null or undefined when calling getLearningDays().');
37
+ }
38
+ if (requestParameters['startDate'] == null) {
39
+ throw new runtime.RequiredError('startDate', 'Required parameter "startDate" was null or undefined when calling getLearningDays().');
40
+ }
41
+ if (requestParameters['endDate'] == null) {
42
+ throw new runtime.RequiredError('endDate', 'Required parameter "endDate" was null or undefined when calling getLearningDays().');
43
+ }
44
+ const queryParameters = {};
45
+ if (requestParameters['startDate'] != null) {
46
+ queryParameters['startDate'] = requestParameters['startDate'].toISOString().substring(0, 10);
47
+ }
48
+ if (requestParameters['endDate'] != null) {
49
+ queryParameters['endDate'] = requestParameters['endDate'].toISOString().substring(0, 10);
50
+ }
51
+ const headerParameters = {};
52
+ if (requestParameters['xUserId'] != null) {
53
+ headerParameters['X-User-Id'] = String(requestParameters['xUserId']);
54
+ }
55
+ if (this.configuration && this.configuration.apiKey) {
56
+ headerParameters["X-Auth-Token"] = yield this.configuration.apiKey("X-Auth-Token"); // AuthToken authentication
57
+ }
58
+ let urlPath = `/api/v1/learning-days`;
59
+ const response = yield this.request({
60
+ path: urlPath,
61
+ method: 'GET',
62
+ headers: headerParameters,
63
+ query: queryParameters,
64
+ }, initOverrides);
65
+ return new runtime.JSONApiResponse(response, (jsonValue) => LearningDaysResponseFromJSON(jsonValue));
66
+ });
67
+ }
68
+ /**
69
+ * Returns distinct dates within the given range on which the user had at least one learning moment, plus the date of their most recent learning moment overall.
70
+ * Get learning days in range
71
+ */
72
+ getLearningDays(requestParameters, initOverrides) {
73
+ return __awaiter(this, void 0, void 0, function* () {
74
+ const response = yield this.getLearningDaysRaw(requestParameters, initOverrides);
75
+ return yield response.value();
76
+ });
77
+ }
78
+ }
@@ -11,6 +11,11 @@
11
11
  */
12
12
  import * as runtime from '../runtime';
13
13
  import type { Message, MessageCountResponse, PaginatedMessages } from '../models/index';
14
+ export interface DeleteMessagesRequest {
15
+ xUserId: string;
16
+ chatId: string;
17
+ since: Date;
18
+ }
14
19
  export interface GetChatMessageRequest {
15
20
  xUserId: string;
16
21
  chatId: string;
@@ -30,6 +35,16 @@ export interface GetMessageCountRequest {
30
35
  *
31
36
  */
32
37
  export declare class MessagesApi extends runtime.BaseAPI {
38
+ /**
39
+ * Deletes all messages in a chat at or after the given timestamp.
40
+ * Delete messages from timestamp
41
+ */
42
+ deleteMessagesRaw(requestParameters: DeleteMessagesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
43
+ /**
44
+ * Deletes all messages in a chat at or after the given timestamp.
45
+ * Delete messages from timestamp
46
+ */
47
+ deleteMessages(requestParameters: DeleteMessagesRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
33
48
  /**
34
49
  * Returns a single message belonging to the specified chat.
35
50
  * Get a chat message
@@ -26,6 +26,52 @@ import { MessageFromJSON, MessageCountResponseFromJSON, PaginatedMessagesFromJSO
26
26
  *
27
27
  */
28
28
  export class MessagesApi extends runtime.BaseAPI {
29
+ /**
30
+ * Deletes all messages in a chat at or after the given timestamp.
31
+ * Delete messages from timestamp
32
+ */
33
+ deleteMessagesRaw(requestParameters, initOverrides) {
34
+ return __awaiter(this, void 0, void 0, function* () {
35
+ if (requestParameters['xUserId'] == null) {
36
+ throw new runtime.RequiredError('xUserId', 'Required parameter "xUserId" was null or undefined when calling deleteMessages().');
37
+ }
38
+ if (requestParameters['chatId'] == null) {
39
+ throw new runtime.RequiredError('chatId', 'Required parameter "chatId" was null or undefined when calling deleteMessages().');
40
+ }
41
+ if (requestParameters['since'] == null) {
42
+ throw new runtime.RequiredError('since', 'Required parameter "since" was null or undefined when calling deleteMessages().');
43
+ }
44
+ const queryParameters = {};
45
+ if (requestParameters['since'] != null) {
46
+ queryParameters['since'] = requestParameters['since'].toISOString();
47
+ }
48
+ const headerParameters = {};
49
+ if (requestParameters['xUserId'] != null) {
50
+ headerParameters['X-User-Id'] = String(requestParameters['xUserId']);
51
+ }
52
+ if (this.configuration && this.configuration.apiKey) {
53
+ headerParameters["X-Auth-Token"] = yield this.configuration.apiKey("X-Auth-Token"); // AuthToken authentication
54
+ }
55
+ let urlPath = `/api/v1/chats/{chatId}/messages`;
56
+ urlPath = urlPath.replace(`{${"chatId"}}`, encodeURIComponent(String(requestParameters['chatId'])));
57
+ const response = yield this.request({
58
+ path: urlPath,
59
+ method: 'DELETE',
60
+ headers: headerParameters,
61
+ query: queryParameters,
62
+ }, initOverrides);
63
+ return new runtime.VoidApiResponse(response);
64
+ });
65
+ }
66
+ /**
67
+ * Deletes all messages in a chat at or after the given timestamp.
68
+ * Delete messages from timestamp
69
+ */
70
+ deleteMessages(requestParameters, initOverrides) {
71
+ return __awaiter(this, void 0, void 0, function* () {
72
+ yield this.deleteMessagesRaw(requestParameters, initOverrides);
73
+ });
74
+ }
29
75
  /**
30
76
  * Returns a single message belonging to the specified chat.
31
77
  * Get a chat message
@@ -1,6 +1,7 @@
1
1
  export * from './AccountsApi';
2
2
  export * from './ChatsApi';
3
3
  export * from './HealthApi';
4
+ export * from './LearningDaysApi';
4
5
  export * from './LearningMomentsApi';
5
6
  export * from './MessagesApi';
6
7
  export * from './ServiceTokensApi';
@@ -3,6 +3,7 @@
3
3
  export * from './AccountsApi';
4
4
  export * from './ChatsApi';
5
5
  export * from './HealthApi';
6
+ export * from './LearningDaysApi';
6
7
  export * from './LearningMomentsApi';
7
8
  export * from './MessagesApi';
8
9
  export * from './ServiceTokensApi';
@@ -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 LearningDaysResponse
16
+ */
17
+ export interface LearningDaysResponse {
18
+ /**
19
+ *
20
+ * @type {Date}
21
+ * @memberof LearningDaysResponse
22
+ */
23
+ latestMomentDate: Date | null;
24
+ /**
25
+ *
26
+ * @type {Array<Date>}
27
+ * @memberof LearningDaysResponse
28
+ */
29
+ days: Array<Date>;
30
+ }
31
+ /**
32
+ * Check if a given object implements the LearningDaysResponse interface.
33
+ */
34
+ export declare function instanceOfLearningDaysResponse(value: object): value is LearningDaysResponse;
35
+ export declare function LearningDaysResponseFromJSON(json: any): LearningDaysResponse;
36
+ export declare function LearningDaysResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): LearningDaysResponse;
37
+ export declare function LearningDaysResponseToJSON(json: any): LearningDaysResponse;
38
+ export declare function LearningDaysResponseToJSONTyped(value?: LearningDaysResponse | 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 LearningDaysResponse interface.
16
+ */
17
+ export function instanceOfLearningDaysResponse(value) {
18
+ if (!('latestMomentDate' in value) || value['latestMomentDate'] === undefined)
19
+ return false;
20
+ if (!('days' in value) || value['days'] === undefined)
21
+ return false;
22
+ return true;
23
+ }
24
+ export function LearningDaysResponseFromJSON(json) {
25
+ return LearningDaysResponseFromJSONTyped(json, false);
26
+ }
27
+ export function LearningDaysResponseFromJSONTyped(json, ignoreDiscriminator) {
28
+ if (json == null) {
29
+ return json;
30
+ }
31
+ return {
32
+ 'latestMomentDate': (json['latestMomentDate'] == null ? null : new Date(json['latestMomentDate'])),
33
+ 'days': json['days'],
34
+ };
35
+ }
36
+ export function LearningDaysResponseToJSON(json) {
37
+ return LearningDaysResponseToJSONTyped(json, false);
38
+ }
39
+ export function LearningDaysResponseToJSONTyped(value, ignoreDiscriminator = false) {
40
+ if (value == null) {
41
+ return value;
42
+ }
43
+ return {
44
+ 'latestMomentDate': value['latestMomentDate'] == null ? value['latestMomentDate'] : value['latestMomentDate'].toISOString().substring(0, 10),
45
+ 'days': value['days'],
46
+ };
47
+ }
@@ -6,6 +6,7 @@ export * from './CreateChatRequest';
6
6
  export * from './CreateTokenRequest';
7
7
  export * from './CreateTokenResponse';
8
8
  export * from './HealthCheck';
9
+ export * from './LearningDaysResponse';
9
10
  export * from './LearningMoment';
10
11
  export * from './Message';
11
12
  export * from './MessageCountResponse';
@@ -8,6 +8,7 @@ export * from './CreateChatRequest';
8
8
  export * from './CreateTokenRequest';
9
9
  export * from './CreateTokenResponse';
10
10
  export * from './HealthCheck';
11
+ export * from './LearningDaysResponse';
11
12
  export * from './LearningMoment';
12
13
  export * from './Message';
13
14
  export * from './MessageCountResponse';
@@ -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 LearningDaysResponse
16
+ */
17
+ export interface LearningDaysResponse {
18
+ /**
19
+ *
20
+ * @type {Date}
21
+ * @memberof LearningDaysResponse
22
+ */
23
+ latestMomentDate: Date | null;
24
+ /**
25
+ *
26
+ * @type {Array<Date>}
27
+ * @memberof LearningDaysResponse
28
+ */
29
+ days: Array<Date>;
30
+ }
31
+ /**
32
+ * Check if a given object implements the LearningDaysResponse interface.
33
+ */
34
+ export declare function instanceOfLearningDaysResponse(value: object): value is LearningDaysResponse;
35
+ export declare function LearningDaysResponseFromJSON(json: any): LearningDaysResponse;
36
+ export declare function LearningDaysResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): LearningDaysResponse;
37
+ export declare function LearningDaysResponseToJSON(json: any): LearningDaysResponse;
38
+ export declare function LearningDaysResponseToJSONTyped(value?: LearningDaysResponse | 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.instanceOfLearningDaysResponse = instanceOfLearningDaysResponse;
17
+ exports.LearningDaysResponseFromJSON = LearningDaysResponseFromJSON;
18
+ exports.LearningDaysResponseFromJSONTyped = LearningDaysResponseFromJSONTyped;
19
+ exports.LearningDaysResponseToJSON = LearningDaysResponseToJSON;
20
+ exports.LearningDaysResponseToJSONTyped = LearningDaysResponseToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the LearningDaysResponse interface.
23
+ */
24
+ function instanceOfLearningDaysResponse(value) {
25
+ if (!('latestMomentDate' in value) || value['latestMomentDate'] === undefined)
26
+ return false;
27
+ if (!('days' in value) || value['days'] === undefined)
28
+ return false;
29
+ return true;
30
+ }
31
+ function LearningDaysResponseFromJSON(json) {
32
+ return LearningDaysResponseFromJSONTyped(json, false);
33
+ }
34
+ function LearningDaysResponseFromJSONTyped(json, ignoreDiscriminator) {
35
+ if (json == null) {
36
+ return json;
37
+ }
38
+ return {
39
+ 'latestMomentDate': (json['latestMomentDate'] == null ? null : new Date(json['latestMomentDate'])),
40
+ 'days': json['days'],
41
+ };
42
+ }
43
+ function LearningDaysResponseToJSON(json) {
44
+ return LearningDaysResponseToJSONTyped(json, false);
45
+ }
46
+ function LearningDaysResponseToJSONTyped(value, ignoreDiscriminator = false) {
47
+ if (value == null) {
48
+ return value;
49
+ }
50
+ return {
51
+ 'latestMomentDate': value['latestMomentDate'] == null ? value['latestMomentDate'] : value['latestMomentDate'].toISOString().substring(0, 10),
52
+ 'days': value['days'],
53
+ };
54
+ }
@@ -6,6 +6,7 @@ export * from './CreateChatRequest';
6
6
  export * from './CreateTokenRequest';
7
7
  export * from './CreateTokenResponse';
8
8
  export * from './HealthCheck';
9
+ export * from './LearningDaysResponse';
9
10
  export * from './LearningMoment';
10
11
  export * from './Message';
11
12
  export * from './MessageCountResponse';
@@ -24,6 +24,7 @@ __exportStar(require("./CreateChatRequest"), exports);
24
24
  __exportStar(require("./CreateTokenRequest"), exports);
25
25
  __exportStar(require("./CreateTokenResponse"), exports);
26
26
  __exportStar(require("./HealthCheck"), exports);
27
+ __exportStar(require("./LearningDaysResponse"), exports);
27
28
  __exportStar(require("./LearningMoment"), exports);
28
29
  __exportStar(require("./Message"), exports);
29
30
  __exportStar(require("./MessageCountResponse"), exports);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@instructure/athena-api-client",
3
3
  "private": false,
4
- "version": "1.0.2",
4
+ "version": "1.0.3",
5
5
  "description": "OpenAPI client for the Athena API",
6
6
  "author": "Instructure",
7
7
  "repository": {