@acm-uiuc/core-client 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/.openapi-generator/FILES +127 -0
- package/.openapi-generator/VERSION +1 -0
- package/.openapi-generator-ignore +23 -0
- package/README.md +277 -0
- package/dist/apis/APIKeysApi.d.ts +54 -0
- package/dist/apis/APIKeysApi.js +143 -0
- package/dist/apis/EventsApi.d.ts +86 -0
- package/dist/apis/EventsApi.js +250 -0
- package/dist/apis/GenericApi.d.ts +88 -0
- package/dist/apis/GenericApi.js +249 -0
- package/dist/apis/IAMApi.d.ts +108 -0
- package/dist/apis/IAMApi.js +327 -0
- package/dist/apis/ICalendarIntegrationApi.d.ts +29 -0
- package/dist/apis/ICalendarIntegrationApi.js +61 -0
- package/dist/apis/LinkryApi.d.ts +100 -0
- package/dist/apis/LinkryApi.js +330 -0
- package/dist/apis/LoggingApi.d.ts +51 -0
- package/dist/apis/LoggingApi.js +103 -0
- package/dist/apis/MembershipApi.d.ts +107 -0
- package/dist/apis/MembershipApi.js +330 -0
- package/dist/apis/MobileWalletApi.d.ts +28 -0
- package/dist/apis/MobileWalletApi.js +64 -0
- package/dist/apis/OrganizationsApi.d.ts +65 -0
- package/dist/apis/OrganizationsApi.js +192 -0
- package/dist/apis/RSVPApi.d.ts +109 -0
- package/dist/apis/RSVPApi.js +345 -0
- package/dist/apis/RoomRequestsApi.d.ts +102 -0
- package/dist/apis/RoomRequestsApi.js +279 -0
- package/dist/apis/StoreApi.d.ts +141 -0
- package/dist/apis/StoreApi.js +449 -0
- package/dist/apis/StripeApi.d.ts +54 -0
- package/dist/apis/StripeApi.js +152 -0
- package/dist/apis/VendingApi.d.ts +33 -0
- package/dist/apis/VendingApi.js +83 -0
- package/dist/apis/index.d.ts +15 -0
- package/dist/apis/index.js +33 -0
- package/dist/esm/apis/APIKeysApi.d.ts +54 -0
- package/dist/esm/apis/APIKeysApi.js +139 -0
- package/dist/esm/apis/EventsApi.d.ts +86 -0
- package/dist/esm/apis/EventsApi.js +246 -0
- package/dist/esm/apis/GenericApi.d.ts +88 -0
- package/dist/esm/apis/GenericApi.js +245 -0
- package/dist/esm/apis/IAMApi.d.ts +108 -0
- package/dist/esm/apis/IAMApi.js +323 -0
- package/dist/esm/apis/ICalendarIntegrationApi.d.ts +29 -0
- package/dist/esm/apis/ICalendarIntegrationApi.js +57 -0
- package/dist/esm/apis/LinkryApi.d.ts +100 -0
- package/dist/esm/apis/LinkryApi.js +326 -0
- package/dist/esm/apis/LoggingApi.d.ts +51 -0
- package/dist/esm/apis/LoggingApi.js +99 -0
- package/dist/esm/apis/MembershipApi.d.ts +107 -0
- package/dist/esm/apis/MembershipApi.js +326 -0
- package/dist/esm/apis/MobileWalletApi.d.ts +28 -0
- package/dist/esm/apis/MobileWalletApi.js +60 -0
- package/dist/esm/apis/OrganizationsApi.d.ts +65 -0
- package/dist/esm/apis/OrganizationsApi.js +188 -0
- package/dist/esm/apis/RSVPApi.d.ts +109 -0
- package/dist/esm/apis/RSVPApi.js +341 -0
- package/dist/esm/apis/RoomRequestsApi.d.ts +102 -0
- package/dist/esm/apis/RoomRequestsApi.js +275 -0
- package/dist/esm/apis/StoreApi.d.ts +141 -0
- package/dist/esm/apis/StoreApi.js +445 -0
- package/dist/esm/apis/StripeApi.d.ts +54 -0
- package/dist/esm/apis/StripeApi.js +148 -0
- package/dist/esm/apis/VendingApi.d.ts +33 -0
- package/dist/esm/apis/VendingApi.js +79 -0
- package/dist/esm/apis/index.d.ts +15 -0
- package/dist/esm/apis/index.js +17 -0
- package/dist/esm/index.d.ts +3 -0
- package/dist/esm/index.js +5 -0
- package/dist/esm/models/index.d.ts +3567 -0
- package/dist/esm/models/index.js +539 -0
- package/dist/esm/runtime.d.ts +181 -0
- package/dist/esm/runtime.js +327 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +21 -0
- package/dist/models/index.d.ts +3567 -0
- package/dist/models/index.js +543 -0
- package/dist/runtime.d.ts +181 -0
- package/dist/runtime.js +342 -0
- package/package.json +23 -0
- package/tsconfig.esm.json +7 -0
- package/tsconfig.json +16 -0
|
@@ -0,0 +1,246 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* ACM @ UIUC Core API
|
|
5
|
+
* The ACM @ UIUC Core API provides services for managing chapter operations. ## Usage The primary consumer of the Core API is the Management Portal, which allows members to manage the chapter. Others may call the API with an API key; please contact us to obtain one. This API also integrates into the ACM website and other suborganization to provide calendar services. Calendar clients call the iCal endpoints (available through [ical.acm.illinois.edu](https://ical.acm.illinois.edu)) for calendar services. ## Contact <hr /> If you are an ACM @ UIUC member, please join the Infra Committee Discord for support. Otherwise, email [infra@acm.illinois.edu](mailto:infra@acm.illinois.edu) for support. **For all security concerns, please email [infra@acm.illinois.edu](mailto:infra@acm.illinois.edu) with the subject \"Security Concern\".**
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.0.1
|
|
8
|
+
* Contact: infra@acm.illinois.edu
|
|
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.js';
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
*/
|
|
27
|
+
export class EventsApi extends runtime.BaseAPI {
|
|
28
|
+
/**
|
|
29
|
+
* Retrieve calendar events with applied filters.
|
|
30
|
+
*/
|
|
31
|
+
apiV1EventsGetRaw(requestParameters, initOverrides) {
|
|
32
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
33
|
+
const queryParameters = {};
|
|
34
|
+
if (requestParameters['upcomingOnly'] != null) {
|
|
35
|
+
queryParameters['upcomingOnly'] = requestParameters['upcomingOnly'];
|
|
36
|
+
}
|
|
37
|
+
if (requestParameters['featuredOnly'] != null) {
|
|
38
|
+
queryParameters['featuredOnly'] = requestParameters['featuredOnly'];
|
|
39
|
+
}
|
|
40
|
+
if (requestParameters['host'] != null) {
|
|
41
|
+
queryParameters['host'] = requestParameters['host'];
|
|
42
|
+
}
|
|
43
|
+
if (requestParameters['ts'] != null) {
|
|
44
|
+
queryParameters['ts'] = requestParameters['ts'];
|
|
45
|
+
}
|
|
46
|
+
if (requestParameters['includeMetadata'] != null) {
|
|
47
|
+
queryParameters['includeMetadata'] = requestParameters['includeMetadata'];
|
|
48
|
+
}
|
|
49
|
+
const headerParameters = {};
|
|
50
|
+
let urlPath = `/api/v1/events`;
|
|
51
|
+
const response = yield this.request({
|
|
52
|
+
path: urlPath,
|
|
53
|
+
method: 'GET',
|
|
54
|
+
headers: headerParameters,
|
|
55
|
+
query: queryParameters,
|
|
56
|
+
}, initOverrides);
|
|
57
|
+
return new runtime.JSONApiResponse(response);
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* Retrieve calendar events with applied filters.
|
|
62
|
+
*/
|
|
63
|
+
apiV1EventsGet() {
|
|
64
|
+
return __awaiter(this, arguments, void 0, function* (requestParameters = {}, initOverrides) {
|
|
65
|
+
const response = yield this.apiV1EventsGetRaw(requestParameters, initOverrides);
|
|
66
|
+
return yield response.value();
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* #### Authorization <hr /> Requires any of the following roles: * Events Manager (<code>manage:events</code>)
|
|
71
|
+
* Delete a calendar event.
|
|
72
|
+
*/
|
|
73
|
+
apiV1EventsIdDeleteRaw(requestParameters, initOverrides) {
|
|
74
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
75
|
+
if (requestParameters['id'] == null) {
|
|
76
|
+
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1EventsIdDelete().');
|
|
77
|
+
}
|
|
78
|
+
const queryParameters = {};
|
|
79
|
+
const headerParameters = {};
|
|
80
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
81
|
+
const token = this.configuration.accessToken;
|
|
82
|
+
const tokenString = yield token("httpBearer", []);
|
|
83
|
+
if (tokenString) {
|
|
84
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
88
|
+
headerParameters["X-Api-Key"] = yield this.configuration.apiKey("X-Api-Key"); // apiKeyHeader authentication
|
|
89
|
+
}
|
|
90
|
+
let urlPath = `/api/v1/events/{id}`;
|
|
91
|
+
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
92
|
+
const response = yield this.request({
|
|
93
|
+
path: urlPath,
|
|
94
|
+
method: 'DELETE',
|
|
95
|
+
headers: headerParameters,
|
|
96
|
+
query: queryParameters,
|
|
97
|
+
}, initOverrides);
|
|
98
|
+
if (this.isJsonMime(response.headers.get('content-type'))) {
|
|
99
|
+
return new runtime.JSONApiResponse(response);
|
|
100
|
+
}
|
|
101
|
+
else {
|
|
102
|
+
return new runtime.TextApiResponse(response);
|
|
103
|
+
}
|
|
104
|
+
});
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* #### Authorization <hr /> Requires any of the following roles: * Events Manager (<code>manage:events</code>)
|
|
108
|
+
* Delete a calendar event.
|
|
109
|
+
*/
|
|
110
|
+
apiV1EventsIdDelete(requestParameters, initOverrides) {
|
|
111
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
112
|
+
const response = yield this.apiV1EventsIdDeleteRaw(requestParameters, initOverrides);
|
|
113
|
+
return yield response.value();
|
|
114
|
+
});
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* Retrieve a calendar event.
|
|
118
|
+
*/
|
|
119
|
+
apiV1EventsIdGetRaw(requestParameters, initOverrides) {
|
|
120
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
121
|
+
if (requestParameters['id'] == null) {
|
|
122
|
+
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1EventsIdGet().');
|
|
123
|
+
}
|
|
124
|
+
const queryParameters = {};
|
|
125
|
+
if (requestParameters['ts'] != null) {
|
|
126
|
+
queryParameters['ts'] = requestParameters['ts'];
|
|
127
|
+
}
|
|
128
|
+
if (requestParameters['includeMetadata'] != null) {
|
|
129
|
+
queryParameters['includeMetadata'] = requestParameters['includeMetadata'];
|
|
130
|
+
}
|
|
131
|
+
const headerParameters = {};
|
|
132
|
+
let urlPath = `/api/v1/events/{id}`;
|
|
133
|
+
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
134
|
+
const response = yield this.request({
|
|
135
|
+
path: urlPath,
|
|
136
|
+
method: 'GET',
|
|
137
|
+
headers: headerParameters,
|
|
138
|
+
query: queryParameters,
|
|
139
|
+
}, initOverrides);
|
|
140
|
+
return new runtime.JSONApiResponse(response);
|
|
141
|
+
});
|
|
142
|
+
}
|
|
143
|
+
/**
|
|
144
|
+
* Retrieve a calendar event.
|
|
145
|
+
*/
|
|
146
|
+
apiV1EventsIdGet(requestParameters, initOverrides) {
|
|
147
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
148
|
+
const response = yield this.apiV1EventsIdGetRaw(requestParameters, initOverrides);
|
|
149
|
+
return yield response.value();
|
|
150
|
+
});
|
|
151
|
+
}
|
|
152
|
+
/**
|
|
153
|
+
* #### Authorization <hr /> Requires any of the following roles: * Events Manager (<code>manage:events</code>)
|
|
154
|
+
* Modify a calendar event.
|
|
155
|
+
*/
|
|
156
|
+
apiV1EventsIdPatchRaw(requestParameters, initOverrides) {
|
|
157
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
158
|
+
if (requestParameters['id'] == null) {
|
|
159
|
+
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1EventsIdPatch().');
|
|
160
|
+
}
|
|
161
|
+
if (requestParameters['apiV1EventsIdPatchRequest'] == null) {
|
|
162
|
+
throw new runtime.RequiredError('apiV1EventsIdPatchRequest', 'Required parameter "apiV1EventsIdPatchRequest" was null or undefined when calling apiV1EventsIdPatch().');
|
|
163
|
+
}
|
|
164
|
+
const queryParameters = {};
|
|
165
|
+
const headerParameters = {};
|
|
166
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
167
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
168
|
+
const token = this.configuration.accessToken;
|
|
169
|
+
const tokenString = yield token("httpBearer", []);
|
|
170
|
+
if (tokenString) {
|
|
171
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
175
|
+
headerParameters["X-Api-Key"] = yield this.configuration.apiKey("X-Api-Key"); // apiKeyHeader authentication
|
|
176
|
+
}
|
|
177
|
+
let urlPath = `/api/v1/events/{id}`;
|
|
178
|
+
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
179
|
+
const response = yield this.request({
|
|
180
|
+
path: urlPath,
|
|
181
|
+
method: 'PATCH',
|
|
182
|
+
headers: headerParameters,
|
|
183
|
+
query: queryParameters,
|
|
184
|
+
body: requestParameters['apiV1EventsIdPatchRequest'],
|
|
185
|
+
}, initOverrides);
|
|
186
|
+
return new runtime.VoidApiResponse(response);
|
|
187
|
+
});
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* #### Authorization <hr /> Requires any of the following roles: * Events Manager (<code>manage:events</code>)
|
|
191
|
+
* Modify a calendar event.
|
|
192
|
+
*/
|
|
193
|
+
apiV1EventsIdPatch(requestParameters, initOverrides) {
|
|
194
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
195
|
+
yield this.apiV1EventsIdPatchRaw(requestParameters, initOverrides);
|
|
196
|
+
});
|
|
197
|
+
}
|
|
198
|
+
/**
|
|
199
|
+
* #### Authorization <hr /> Requires any of the following roles: * Events Manager (<code>manage:events</code>)
|
|
200
|
+
* Create a calendar event.
|
|
201
|
+
*/
|
|
202
|
+
apiV1EventsPostRaw(requestParameters, initOverrides) {
|
|
203
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
204
|
+
if (requestParameters['apiV1EventsPostRequest'] == null) {
|
|
205
|
+
throw new runtime.RequiredError('apiV1EventsPostRequest', 'Required parameter "apiV1EventsPostRequest" was null or undefined when calling apiV1EventsPost().');
|
|
206
|
+
}
|
|
207
|
+
const queryParameters = {};
|
|
208
|
+
const headerParameters = {};
|
|
209
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
210
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
211
|
+
const token = this.configuration.accessToken;
|
|
212
|
+
const tokenString = yield token("httpBearer", []);
|
|
213
|
+
if (tokenString) {
|
|
214
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
218
|
+
headerParameters["X-Api-Key"] = yield this.configuration.apiKey("X-Api-Key"); // apiKeyHeader authentication
|
|
219
|
+
}
|
|
220
|
+
let urlPath = `/api/v1/events`;
|
|
221
|
+
const response = yield this.request({
|
|
222
|
+
path: urlPath,
|
|
223
|
+
method: 'POST',
|
|
224
|
+
headers: headerParameters,
|
|
225
|
+
query: queryParameters,
|
|
226
|
+
body: requestParameters['apiV1EventsPostRequest'],
|
|
227
|
+
}, initOverrides);
|
|
228
|
+
if (this.isJsonMime(response.headers.get('content-type'))) {
|
|
229
|
+
return new runtime.JSONApiResponse(response);
|
|
230
|
+
}
|
|
231
|
+
else {
|
|
232
|
+
return new runtime.TextApiResponse(response);
|
|
233
|
+
}
|
|
234
|
+
});
|
|
235
|
+
}
|
|
236
|
+
/**
|
|
237
|
+
* #### Authorization <hr /> Requires any of the following roles: * Events Manager (<code>manage:events</code>)
|
|
238
|
+
* Create a calendar event.
|
|
239
|
+
*/
|
|
240
|
+
apiV1EventsPost(requestParameters, initOverrides) {
|
|
241
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
242
|
+
const response = yield this.apiV1EventsPostRaw(requestParameters, initOverrides);
|
|
243
|
+
return yield response.value();
|
|
244
|
+
});
|
|
245
|
+
}
|
|
246
|
+
}
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ACM @ UIUC Core API
|
|
3
|
+
* The ACM @ UIUC Core API provides services for managing chapter operations. ## Usage The primary consumer of the Core API is the Management Portal, which allows members to manage the chapter. Others may call the API with an API key; please contact us to obtain one. This API also integrates into the ACM website and other suborganization to provide calendar services. Calendar clients call the iCal endpoints (available through [ical.acm.illinois.edu](https://ical.acm.illinois.edu)) for calendar services. ## Contact <hr /> If you are an ACM @ UIUC member, please join the Infra Committee Discord for support. Otherwise, email [infra@acm.illinois.edu](mailto:infra@acm.illinois.edu) for support. **For all security concerns, please email [infra@acm.illinois.edu](mailto:infra@acm.illinois.edu) with the subject \"Security Concern\".**
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 2.0.1
|
|
6
|
+
* Contact: infra@acm.illinois.edu
|
|
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.js';
|
|
13
|
+
import type { ApiV1SyncIdentityIsRequiredGet200Response, ApiV1UsersBatchResolveInfoPost200ResponseValue, ApiV1UsersBatchResolveInfoPostRequest, ApiV1UsersFindUserByUinPost200Response, ApiV1UsersFindUserByUinPostRequest } from '../models/index.js';
|
|
14
|
+
export interface ApiV1SyncIdentityIsRequiredGetRequest {
|
|
15
|
+
xUiucToken: string;
|
|
16
|
+
}
|
|
17
|
+
export interface ApiV1SyncIdentityPostRequest {
|
|
18
|
+
xUiucToken: string;
|
|
19
|
+
}
|
|
20
|
+
export interface ApiV1UsersBatchResolveInfoPostOperationRequest {
|
|
21
|
+
apiV1UsersBatchResolveInfoPostRequest: ApiV1UsersBatchResolveInfoPostRequest;
|
|
22
|
+
}
|
|
23
|
+
export interface ApiV1UsersFindUserByUinPostOperationRequest {
|
|
24
|
+
apiV1UsersFindUserByUinPostRequest: ApiV1UsersFindUserByUinPostRequest;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
*
|
|
28
|
+
*/
|
|
29
|
+
export declare class GenericApi extends runtime.BaseAPI {
|
|
30
|
+
/**
|
|
31
|
+
* Verify that the API server is healthy.
|
|
32
|
+
*/
|
|
33
|
+
apiV1HealthzGetRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
34
|
+
/**
|
|
35
|
+
* Verify that the API server is healthy.
|
|
36
|
+
*/
|
|
37
|
+
apiV1HealthzGet(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
38
|
+
/**
|
|
39
|
+
* #### Authorization <hr /> Requires valid authentication but no specific authorization.
|
|
40
|
+
* Get a user\'s username and roles.
|
|
41
|
+
*/
|
|
42
|
+
apiV1ProtectedGetRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
43
|
+
/**
|
|
44
|
+
* #### Authorization <hr /> Requires valid authentication but no specific authorization.
|
|
45
|
+
* Get a user\'s username and roles.
|
|
46
|
+
*/
|
|
47
|
+
apiV1ProtectedGet(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
48
|
+
/**
|
|
49
|
+
* Check if a user needs a full user identity sync.
|
|
50
|
+
*/
|
|
51
|
+
apiV1SyncIdentityIsRequiredGetRaw(requestParameters: ApiV1SyncIdentityIsRequiredGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ApiV1SyncIdentityIsRequiredGet200Response>>;
|
|
52
|
+
/**
|
|
53
|
+
* Check if a user needs a full user identity sync.
|
|
54
|
+
*/
|
|
55
|
+
apiV1SyncIdentityIsRequiredGet(requestParameters: ApiV1SyncIdentityIsRequiredGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ApiV1SyncIdentityIsRequiredGet200Response>;
|
|
56
|
+
/**
|
|
57
|
+
* Sync the Illinois NetID account with the ACM @ UIUC account.
|
|
58
|
+
*/
|
|
59
|
+
apiV1SyncIdentityPostRaw(requestParameters: ApiV1SyncIdentityPostRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<any>>;
|
|
60
|
+
/**
|
|
61
|
+
* Sync the Illinois NetID account with the ACM @ UIUC account.
|
|
62
|
+
*/
|
|
63
|
+
apiV1SyncIdentityPost(requestParameters: ApiV1SyncIdentityPostRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<any>;
|
|
64
|
+
/**
|
|
65
|
+
* #### Authorization <hr /> Requires valid authentication but no specific authorization.
|
|
66
|
+
* Resolve user emails to user info.
|
|
67
|
+
*/
|
|
68
|
+
apiV1UsersBatchResolveInfoPostRaw(requestParameters: ApiV1UsersBatchResolveInfoPostOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<{
|
|
69
|
+
[key: string]: ApiV1UsersBatchResolveInfoPost200ResponseValue;
|
|
70
|
+
}>>;
|
|
71
|
+
/**
|
|
72
|
+
* #### Authorization <hr /> Requires valid authentication but no specific authorization.
|
|
73
|
+
* Resolve user emails to user info.
|
|
74
|
+
*/
|
|
75
|
+
apiV1UsersBatchResolveInfoPost(requestParameters: ApiV1UsersBatchResolveInfoPostOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<{
|
|
76
|
+
[key: string]: ApiV1UsersBatchResolveInfoPost200ResponseValue;
|
|
77
|
+
}>;
|
|
78
|
+
/**
|
|
79
|
+
* #### Authorization <hr /> Requires any of the following roles: * User Information Viewer (<code>view:userInfo</code>)
|
|
80
|
+
* Find a user by UIN.
|
|
81
|
+
*/
|
|
82
|
+
apiV1UsersFindUserByUinPostRaw(requestParameters: ApiV1UsersFindUserByUinPostOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ApiV1UsersFindUserByUinPost200Response>>;
|
|
83
|
+
/**
|
|
84
|
+
* #### Authorization <hr /> Requires any of the following roles: * User Information Viewer (<code>view:userInfo</code>)
|
|
85
|
+
* Find a user by UIN.
|
|
86
|
+
*/
|
|
87
|
+
apiV1UsersFindUserByUinPost(requestParameters: ApiV1UsersFindUserByUinPostOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ApiV1UsersFindUserByUinPost200Response>;
|
|
88
|
+
}
|
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* ACM @ UIUC Core API
|
|
5
|
+
* The ACM @ UIUC Core API provides services for managing chapter operations. ## Usage The primary consumer of the Core API is the Management Portal, which allows members to manage the chapter. Others may call the API with an API key; please contact us to obtain one. This API also integrates into the ACM website and other suborganization to provide calendar services. Calendar clients call the iCal endpoints (available through [ical.acm.illinois.edu](https://ical.acm.illinois.edu)) for calendar services. ## Contact <hr /> If you are an ACM @ UIUC member, please join the Infra Committee Discord for support. Otherwise, email [infra@acm.illinois.edu](mailto:infra@acm.illinois.edu) for support. **For all security concerns, please email [infra@acm.illinois.edu](mailto:infra@acm.illinois.edu) with the subject \"Security Concern\".**
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.0.1
|
|
8
|
+
* Contact: infra@acm.illinois.edu
|
|
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.js';
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
*/
|
|
27
|
+
export class GenericApi extends runtime.BaseAPI {
|
|
28
|
+
/**
|
|
29
|
+
* Verify that the API server is healthy.
|
|
30
|
+
*/
|
|
31
|
+
apiV1HealthzGetRaw(initOverrides) {
|
|
32
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
33
|
+
const queryParameters = {};
|
|
34
|
+
const headerParameters = {};
|
|
35
|
+
let urlPath = `/api/v1/healthz`;
|
|
36
|
+
const response = yield this.request({
|
|
37
|
+
path: urlPath,
|
|
38
|
+
method: 'GET',
|
|
39
|
+
headers: headerParameters,
|
|
40
|
+
query: queryParameters,
|
|
41
|
+
}, initOverrides);
|
|
42
|
+
return new runtime.VoidApiResponse(response);
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Verify that the API server is healthy.
|
|
47
|
+
*/
|
|
48
|
+
apiV1HealthzGet(initOverrides) {
|
|
49
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
50
|
+
yield this.apiV1HealthzGetRaw(initOverrides);
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* #### Authorization <hr /> Requires valid authentication but no specific authorization.
|
|
55
|
+
* Get a user\'s username and roles.
|
|
56
|
+
*/
|
|
57
|
+
apiV1ProtectedGetRaw(initOverrides) {
|
|
58
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
59
|
+
const queryParameters = {};
|
|
60
|
+
const headerParameters = {};
|
|
61
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
62
|
+
const token = this.configuration.accessToken;
|
|
63
|
+
const tokenString = yield token("httpBearer", []);
|
|
64
|
+
if (tokenString) {
|
|
65
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
69
|
+
headerParameters["X-Api-Key"] = yield this.configuration.apiKey("X-Api-Key"); // apiKeyHeader authentication
|
|
70
|
+
}
|
|
71
|
+
let urlPath = `/api/v1/protected`;
|
|
72
|
+
const response = yield this.request({
|
|
73
|
+
path: urlPath,
|
|
74
|
+
method: 'GET',
|
|
75
|
+
headers: headerParameters,
|
|
76
|
+
query: queryParameters,
|
|
77
|
+
}, initOverrides);
|
|
78
|
+
return new runtime.VoidApiResponse(response);
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* #### Authorization <hr /> Requires valid authentication but no specific authorization.
|
|
83
|
+
* Get a user\'s username and roles.
|
|
84
|
+
*/
|
|
85
|
+
apiV1ProtectedGet(initOverrides) {
|
|
86
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
87
|
+
yield this.apiV1ProtectedGetRaw(initOverrides);
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
/**
|
|
91
|
+
* Check if a user needs a full user identity sync.
|
|
92
|
+
*/
|
|
93
|
+
apiV1SyncIdentityIsRequiredGetRaw(requestParameters, initOverrides) {
|
|
94
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
95
|
+
if (requestParameters['xUiucToken'] == null) {
|
|
96
|
+
throw new runtime.RequiredError('xUiucToken', 'Required parameter "xUiucToken" was null or undefined when calling apiV1SyncIdentityIsRequiredGet().');
|
|
97
|
+
}
|
|
98
|
+
const queryParameters = {};
|
|
99
|
+
const headerParameters = {};
|
|
100
|
+
if (requestParameters['xUiucToken'] != null) {
|
|
101
|
+
headerParameters['x-uiuc-token'] = String(requestParameters['xUiucToken']);
|
|
102
|
+
}
|
|
103
|
+
let urlPath = `/api/v1/syncIdentity/isRequired`;
|
|
104
|
+
const response = yield this.request({
|
|
105
|
+
path: urlPath,
|
|
106
|
+
method: 'GET',
|
|
107
|
+
headers: headerParameters,
|
|
108
|
+
query: queryParameters,
|
|
109
|
+
}, initOverrides);
|
|
110
|
+
return new runtime.JSONApiResponse(response);
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
/**
|
|
114
|
+
* Check if a user needs a full user identity sync.
|
|
115
|
+
*/
|
|
116
|
+
apiV1SyncIdentityIsRequiredGet(requestParameters, initOverrides) {
|
|
117
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
118
|
+
const response = yield this.apiV1SyncIdentityIsRequiredGetRaw(requestParameters, initOverrides);
|
|
119
|
+
return yield response.value();
|
|
120
|
+
});
|
|
121
|
+
}
|
|
122
|
+
/**
|
|
123
|
+
* Sync the Illinois NetID account with the ACM @ UIUC account.
|
|
124
|
+
*/
|
|
125
|
+
apiV1SyncIdentityPostRaw(requestParameters, initOverrides) {
|
|
126
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
127
|
+
if (requestParameters['xUiucToken'] == null) {
|
|
128
|
+
throw new runtime.RequiredError('xUiucToken', 'Required parameter "xUiucToken" was null or undefined when calling apiV1SyncIdentityPost().');
|
|
129
|
+
}
|
|
130
|
+
const queryParameters = {};
|
|
131
|
+
const headerParameters = {};
|
|
132
|
+
if (requestParameters['xUiucToken'] != null) {
|
|
133
|
+
headerParameters['x-uiuc-token'] = String(requestParameters['xUiucToken']);
|
|
134
|
+
}
|
|
135
|
+
let urlPath = `/api/v1/syncIdentity`;
|
|
136
|
+
const response = yield this.request({
|
|
137
|
+
path: urlPath,
|
|
138
|
+
method: 'POST',
|
|
139
|
+
headers: headerParameters,
|
|
140
|
+
query: queryParameters,
|
|
141
|
+
}, initOverrides);
|
|
142
|
+
if (this.isJsonMime(response.headers.get('content-type'))) {
|
|
143
|
+
return new runtime.JSONApiResponse(response);
|
|
144
|
+
}
|
|
145
|
+
else {
|
|
146
|
+
return new runtime.TextApiResponse(response);
|
|
147
|
+
}
|
|
148
|
+
});
|
|
149
|
+
}
|
|
150
|
+
/**
|
|
151
|
+
* Sync the Illinois NetID account with the ACM @ UIUC account.
|
|
152
|
+
*/
|
|
153
|
+
apiV1SyncIdentityPost(requestParameters, initOverrides) {
|
|
154
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
155
|
+
const response = yield this.apiV1SyncIdentityPostRaw(requestParameters, initOverrides);
|
|
156
|
+
return yield response.value();
|
|
157
|
+
});
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* #### Authorization <hr /> Requires valid authentication but no specific authorization.
|
|
161
|
+
* Resolve user emails to user info.
|
|
162
|
+
*/
|
|
163
|
+
apiV1UsersBatchResolveInfoPostRaw(requestParameters, initOverrides) {
|
|
164
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
165
|
+
if (requestParameters['apiV1UsersBatchResolveInfoPostRequest'] == null) {
|
|
166
|
+
throw new runtime.RequiredError('apiV1UsersBatchResolveInfoPostRequest', 'Required parameter "apiV1UsersBatchResolveInfoPostRequest" was null or undefined when calling apiV1UsersBatchResolveInfoPost().');
|
|
167
|
+
}
|
|
168
|
+
const queryParameters = {};
|
|
169
|
+
const headerParameters = {};
|
|
170
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
171
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
172
|
+
const token = this.configuration.accessToken;
|
|
173
|
+
const tokenString = yield token("httpBearer", []);
|
|
174
|
+
if (tokenString) {
|
|
175
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
179
|
+
headerParameters["X-Api-Key"] = yield this.configuration.apiKey("X-Api-Key"); // apiKeyHeader authentication
|
|
180
|
+
}
|
|
181
|
+
let urlPath = `/api/v1/users/batchResolveInfo`;
|
|
182
|
+
const response = yield this.request({
|
|
183
|
+
path: urlPath,
|
|
184
|
+
method: 'POST',
|
|
185
|
+
headers: headerParameters,
|
|
186
|
+
query: queryParameters,
|
|
187
|
+
body: requestParameters['apiV1UsersBatchResolveInfoPostRequest'],
|
|
188
|
+
}, initOverrides);
|
|
189
|
+
return new runtime.JSONApiResponse(response);
|
|
190
|
+
});
|
|
191
|
+
}
|
|
192
|
+
/**
|
|
193
|
+
* #### Authorization <hr /> Requires valid authentication but no specific authorization.
|
|
194
|
+
* Resolve user emails to user info.
|
|
195
|
+
*/
|
|
196
|
+
apiV1UsersBatchResolveInfoPost(requestParameters, initOverrides) {
|
|
197
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
198
|
+
const response = yield this.apiV1UsersBatchResolveInfoPostRaw(requestParameters, initOverrides);
|
|
199
|
+
return yield response.value();
|
|
200
|
+
});
|
|
201
|
+
}
|
|
202
|
+
/**
|
|
203
|
+
* #### Authorization <hr /> Requires any of the following roles: * User Information Viewer (<code>view:userInfo</code>)
|
|
204
|
+
* Find a user by UIN.
|
|
205
|
+
*/
|
|
206
|
+
apiV1UsersFindUserByUinPostRaw(requestParameters, initOverrides) {
|
|
207
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
208
|
+
if (requestParameters['apiV1UsersFindUserByUinPostRequest'] == null) {
|
|
209
|
+
throw new runtime.RequiredError('apiV1UsersFindUserByUinPostRequest', 'Required parameter "apiV1UsersFindUserByUinPostRequest" was null or undefined when calling apiV1UsersFindUserByUinPost().');
|
|
210
|
+
}
|
|
211
|
+
const queryParameters = {};
|
|
212
|
+
const headerParameters = {};
|
|
213
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
214
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
215
|
+
const token = this.configuration.accessToken;
|
|
216
|
+
const tokenString = yield token("httpBearer", []);
|
|
217
|
+
if (tokenString) {
|
|
218
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
222
|
+
headerParameters["X-Api-Key"] = yield this.configuration.apiKey("X-Api-Key"); // apiKeyHeader authentication
|
|
223
|
+
}
|
|
224
|
+
let urlPath = `/api/v1/users/findUserByUin`;
|
|
225
|
+
const response = yield this.request({
|
|
226
|
+
path: urlPath,
|
|
227
|
+
method: 'POST',
|
|
228
|
+
headers: headerParameters,
|
|
229
|
+
query: queryParameters,
|
|
230
|
+
body: requestParameters['apiV1UsersFindUserByUinPostRequest'],
|
|
231
|
+
}, initOverrides);
|
|
232
|
+
return new runtime.JSONApiResponse(response);
|
|
233
|
+
});
|
|
234
|
+
}
|
|
235
|
+
/**
|
|
236
|
+
* #### Authorization <hr /> Requires any of the following roles: * User Information Viewer (<code>view:userInfo</code>)
|
|
237
|
+
* Find a user by UIN.
|
|
238
|
+
*/
|
|
239
|
+
apiV1UsersFindUserByUinPost(requestParameters, initOverrides) {
|
|
240
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
241
|
+
const response = yield this.apiV1UsersFindUserByUinPostRaw(requestParameters, initOverrides);
|
|
242
|
+
return yield response.value();
|
|
243
|
+
});
|
|
244
|
+
}
|
|
245
|
+
}
|