@forteplatforms/sdk 1.0.45 → 1.0.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/generated/apis/ProjectsServerApi.d.ts +46 -1
- package/dist/generated/apis/ProjectsServerApi.js +213 -0
- package/dist/generated/models/ForteApiException.d.ts +2 -0
- package/dist/generated/models/ForteApiException.js +3 -1
- package/dist/generated/models/UserActionLogObject.d.ts +6 -0
- package/dist/generated/models/UserActionLogObject.js +2 -0
- package/package.json +1 -1
|
@@ -10,7 +10,28 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { ApiKeySummary, CreateForteServiceRequest, CreateProjectApiKeyRequest, CreateProjectApiKeyResponse, CreateServiceRequestProxyRequest, CreateServiceRequestProxyResponse, PaginatedResponseLogLineObject, PaginatedResponseRequestLogObject, PaginatedResponseServiceBuildRequestObject, PaginatedResponseUserActionLogObject, PaginatedResponseUserObject, ProjectObject, RequestLogObject, ServiceBuildRequestObject, ServiceMetricsResponse, ServiceObject, TestInvocationRequest, TestInvocationResponse, UpdateForteServiceRequest, UpdateForteServiceResponse, UpdateProjectRequest, UserMetricsResponse, UserObject } from '../models/index';
|
|
13
|
+
import type { AddContactMethodRequest, ApiKeySummary, ContactMethod, CreateForteServiceRequest, CreateProjectApiKeyRequest, CreateProjectApiKeyResponse, CreateServiceRequestProxyRequest, CreateServiceRequestProxyResponse, PaginatedResponseLogLineObject, PaginatedResponseRequestLogObject, PaginatedResponseServiceBuildRequestObject, PaginatedResponseUserActionLogObject, PaginatedResponseUserObject, ProjectObject, RequestLogObject, ServiceBuildRequestObject, ServiceMetricsResponse, ServiceObject, TestInvocationRequest, TestInvocationResponse, UpdateForteServiceRequest, UpdateForteServiceResponse, UpdateProjectRequest, UserMetricsResponse, UserObject } from '../models/index';
|
|
14
|
+
export interface AdminAddUserContactMethodRequest {
|
|
15
|
+
projectId: string;
|
|
16
|
+
userId: string;
|
|
17
|
+
addContactMethodRequest: AddContactMethodRequest;
|
|
18
|
+
}
|
|
19
|
+
export interface AdminRemoveUserContactMethodRequest {
|
|
20
|
+
projectId: string;
|
|
21
|
+
userId: string;
|
|
22
|
+
contactMethodId: string;
|
|
23
|
+
}
|
|
24
|
+
export interface AdminSendUserContactMethodVerificationCodeRequest {
|
|
25
|
+
projectId: string;
|
|
26
|
+
userId: string;
|
|
27
|
+
contactMethodId: string;
|
|
28
|
+
}
|
|
29
|
+
export interface AdminVerifyUserContactMethodRequest {
|
|
30
|
+
projectId: string;
|
|
31
|
+
userId: string;
|
|
32
|
+
contactMethodId: string;
|
|
33
|
+
verificationCode: string;
|
|
34
|
+
}
|
|
14
35
|
export interface CreateProjectRequest {
|
|
15
36
|
projectName: string;
|
|
16
37
|
}
|
|
@@ -158,6 +179,30 @@ export interface UpdateServiceRequest {
|
|
|
158
179
|
*
|
|
159
180
|
*/
|
|
160
181
|
export declare class ProjectsServerApi extends runtime.BaseAPI {
|
|
182
|
+
/**
|
|
183
|
+
*/
|
|
184
|
+
adminAddUserContactMethodRaw(requestParameters: AdminAddUserContactMethodRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ContactMethod>>;
|
|
185
|
+
/**
|
|
186
|
+
*/
|
|
187
|
+
adminAddUserContactMethod(requestParameters: AdminAddUserContactMethodRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ContactMethod>;
|
|
188
|
+
/**
|
|
189
|
+
*/
|
|
190
|
+
adminRemoveUserContactMethodRaw(requestParameters: AdminRemoveUserContactMethodRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
191
|
+
/**
|
|
192
|
+
*/
|
|
193
|
+
adminRemoveUserContactMethod(requestParameters: AdminRemoveUserContactMethodRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
194
|
+
/**
|
|
195
|
+
*/
|
|
196
|
+
adminSendUserContactMethodVerificationCodeRaw(requestParameters: AdminSendUserContactMethodVerificationCodeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ContactMethod>>;
|
|
197
|
+
/**
|
|
198
|
+
*/
|
|
199
|
+
adminSendUserContactMethodVerificationCode(requestParameters: AdminSendUserContactMethodVerificationCodeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ContactMethod>;
|
|
200
|
+
/**
|
|
201
|
+
*/
|
|
202
|
+
adminVerifyUserContactMethodRaw(requestParameters: AdminVerifyUserContactMethodRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ContactMethod>>;
|
|
203
|
+
/**
|
|
204
|
+
*/
|
|
205
|
+
adminVerifyUserContactMethod(requestParameters: AdminVerifyUserContactMethodRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ContactMethod>;
|
|
161
206
|
/**
|
|
162
207
|
*/
|
|
163
208
|
createProjectRaw(requestParameters: CreateProjectRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ProjectObject>>;
|
|
@@ -75,6 +75,219 @@ var ProjectsServerApi = /** @class */ (function (_super) {
|
|
|
75
75
|
function ProjectsServerApi() {
|
|
76
76
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
77
77
|
}
|
|
78
|
+
/**
|
|
79
|
+
*/
|
|
80
|
+
ProjectsServerApi.prototype.adminAddUserContactMethodRaw = function (requestParameters, initOverrides) {
|
|
81
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
82
|
+
var queryParameters, headerParameters, urlPath, response;
|
|
83
|
+
return __generator(this, function (_a) {
|
|
84
|
+
switch (_a.label) {
|
|
85
|
+
case 0:
|
|
86
|
+
if (requestParameters['projectId'] == null) {
|
|
87
|
+
throw new runtime.RequiredError('projectId', 'Required parameter "projectId" was null or undefined when calling adminAddUserContactMethod().');
|
|
88
|
+
}
|
|
89
|
+
if (requestParameters['userId'] == null) {
|
|
90
|
+
throw new runtime.RequiredError('userId', 'Required parameter "userId" was null or undefined when calling adminAddUserContactMethod().');
|
|
91
|
+
}
|
|
92
|
+
if (requestParameters['addContactMethodRequest'] == null) {
|
|
93
|
+
throw new runtime.RequiredError('addContactMethodRequest', 'Required parameter "addContactMethodRequest" was null or undefined when calling adminAddUserContactMethod().');
|
|
94
|
+
}
|
|
95
|
+
queryParameters = {};
|
|
96
|
+
headerParameters = {};
|
|
97
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
98
|
+
urlPath = "/api/v1/projects/{projectId}/users/{userId}/contact-methods";
|
|
99
|
+
urlPath = urlPath.replace("{".concat("projectId", "}"), encodeURIComponent(String(requestParameters['projectId'])));
|
|
100
|
+
urlPath = urlPath.replace("{".concat("userId", "}"), encodeURIComponent(String(requestParameters['userId'])));
|
|
101
|
+
return [4 /*yield*/, this.request({
|
|
102
|
+
path: urlPath,
|
|
103
|
+
method: 'POST',
|
|
104
|
+
headers: headerParameters,
|
|
105
|
+
query: queryParameters,
|
|
106
|
+
body: (0, index_1.AddContactMethodRequestToJSON)(requestParameters['addContactMethodRequest']),
|
|
107
|
+
}, initOverrides)];
|
|
108
|
+
case 1:
|
|
109
|
+
response = _a.sent();
|
|
110
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.ContactMethodFromJSON)(jsonValue); })];
|
|
111
|
+
}
|
|
112
|
+
});
|
|
113
|
+
});
|
|
114
|
+
};
|
|
115
|
+
/**
|
|
116
|
+
*/
|
|
117
|
+
ProjectsServerApi.prototype.adminAddUserContactMethod = function (requestParameters, initOverrides) {
|
|
118
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
119
|
+
var response;
|
|
120
|
+
return __generator(this, function (_a) {
|
|
121
|
+
switch (_a.label) {
|
|
122
|
+
case 0: return [4 /*yield*/, this.adminAddUserContactMethodRaw(requestParameters, initOverrides)];
|
|
123
|
+
case 1:
|
|
124
|
+
response = _a.sent();
|
|
125
|
+
return [4 /*yield*/, response.value()];
|
|
126
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
127
|
+
}
|
|
128
|
+
});
|
|
129
|
+
});
|
|
130
|
+
};
|
|
131
|
+
/**
|
|
132
|
+
*/
|
|
133
|
+
ProjectsServerApi.prototype.adminRemoveUserContactMethodRaw = function (requestParameters, initOverrides) {
|
|
134
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
135
|
+
var queryParameters, headerParameters, urlPath, response;
|
|
136
|
+
return __generator(this, function (_a) {
|
|
137
|
+
switch (_a.label) {
|
|
138
|
+
case 0:
|
|
139
|
+
if (requestParameters['projectId'] == null) {
|
|
140
|
+
throw new runtime.RequiredError('projectId', 'Required parameter "projectId" was null or undefined when calling adminRemoveUserContactMethod().');
|
|
141
|
+
}
|
|
142
|
+
if (requestParameters['userId'] == null) {
|
|
143
|
+
throw new runtime.RequiredError('userId', 'Required parameter "userId" was null or undefined when calling adminRemoveUserContactMethod().');
|
|
144
|
+
}
|
|
145
|
+
if (requestParameters['contactMethodId'] == null) {
|
|
146
|
+
throw new runtime.RequiredError('contactMethodId', 'Required parameter "contactMethodId" was null or undefined when calling adminRemoveUserContactMethod().');
|
|
147
|
+
}
|
|
148
|
+
queryParameters = {};
|
|
149
|
+
headerParameters = {};
|
|
150
|
+
urlPath = "/api/v1/projects/{projectId}/users/{userId}/contact-methods/{contactMethodId}";
|
|
151
|
+
urlPath = urlPath.replace("{".concat("projectId", "}"), encodeURIComponent(String(requestParameters['projectId'])));
|
|
152
|
+
urlPath = urlPath.replace("{".concat("userId", "}"), encodeURIComponent(String(requestParameters['userId'])));
|
|
153
|
+
urlPath = urlPath.replace("{".concat("contactMethodId", "}"), encodeURIComponent(String(requestParameters['contactMethodId'])));
|
|
154
|
+
return [4 /*yield*/, this.request({
|
|
155
|
+
path: urlPath,
|
|
156
|
+
method: 'DELETE',
|
|
157
|
+
headers: headerParameters,
|
|
158
|
+
query: queryParameters,
|
|
159
|
+
}, initOverrides)];
|
|
160
|
+
case 1:
|
|
161
|
+
response = _a.sent();
|
|
162
|
+
return [2 /*return*/, new runtime.VoidApiResponse(response)];
|
|
163
|
+
}
|
|
164
|
+
});
|
|
165
|
+
});
|
|
166
|
+
};
|
|
167
|
+
/**
|
|
168
|
+
*/
|
|
169
|
+
ProjectsServerApi.prototype.adminRemoveUserContactMethod = function (requestParameters, initOverrides) {
|
|
170
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
171
|
+
return __generator(this, function (_a) {
|
|
172
|
+
switch (_a.label) {
|
|
173
|
+
case 0: return [4 /*yield*/, this.adminRemoveUserContactMethodRaw(requestParameters, initOverrides)];
|
|
174
|
+
case 1:
|
|
175
|
+
_a.sent();
|
|
176
|
+
return [2 /*return*/];
|
|
177
|
+
}
|
|
178
|
+
});
|
|
179
|
+
});
|
|
180
|
+
};
|
|
181
|
+
/**
|
|
182
|
+
*/
|
|
183
|
+
ProjectsServerApi.prototype.adminSendUserContactMethodVerificationCodeRaw = function (requestParameters, initOverrides) {
|
|
184
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
185
|
+
var queryParameters, headerParameters, urlPath, response;
|
|
186
|
+
return __generator(this, function (_a) {
|
|
187
|
+
switch (_a.label) {
|
|
188
|
+
case 0:
|
|
189
|
+
if (requestParameters['projectId'] == null) {
|
|
190
|
+
throw new runtime.RequiredError('projectId', 'Required parameter "projectId" was null or undefined when calling adminSendUserContactMethodVerificationCode().');
|
|
191
|
+
}
|
|
192
|
+
if (requestParameters['userId'] == null) {
|
|
193
|
+
throw new runtime.RequiredError('userId', 'Required parameter "userId" was null or undefined when calling adminSendUserContactMethodVerificationCode().');
|
|
194
|
+
}
|
|
195
|
+
if (requestParameters['contactMethodId'] == null) {
|
|
196
|
+
throw new runtime.RequiredError('contactMethodId', 'Required parameter "contactMethodId" was null or undefined when calling adminSendUserContactMethodVerificationCode().');
|
|
197
|
+
}
|
|
198
|
+
queryParameters = {};
|
|
199
|
+
headerParameters = {};
|
|
200
|
+
urlPath = "/api/v1/projects/{projectId}/users/{userId}/contact-methods/{contactMethodId}/send-verification-code";
|
|
201
|
+
urlPath = urlPath.replace("{".concat("projectId", "}"), encodeURIComponent(String(requestParameters['projectId'])));
|
|
202
|
+
urlPath = urlPath.replace("{".concat("userId", "}"), encodeURIComponent(String(requestParameters['userId'])));
|
|
203
|
+
urlPath = urlPath.replace("{".concat("contactMethodId", "}"), encodeURIComponent(String(requestParameters['contactMethodId'])));
|
|
204
|
+
return [4 /*yield*/, this.request({
|
|
205
|
+
path: urlPath,
|
|
206
|
+
method: 'POST',
|
|
207
|
+
headers: headerParameters,
|
|
208
|
+
query: queryParameters,
|
|
209
|
+
}, initOverrides)];
|
|
210
|
+
case 1:
|
|
211
|
+
response = _a.sent();
|
|
212
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.ContactMethodFromJSON)(jsonValue); })];
|
|
213
|
+
}
|
|
214
|
+
});
|
|
215
|
+
});
|
|
216
|
+
};
|
|
217
|
+
/**
|
|
218
|
+
*/
|
|
219
|
+
ProjectsServerApi.prototype.adminSendUserContactMethodVerificationCode = function (requestParameters, initOverrides) {
|
|
220
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
221
|
+
var response;
|
|
222
|
+
return __generator(this, function (_a) {
|
|
223
|
+
switch (_a.label) {
|
|
224
|
+
case 0: return [4 /*yield*/, this.adminSendUserContactMethodVerificationCodeRaw(requestParameters, initOverrides)];
|
|
225
|
+
case 1:
|
|
226
|
+
response = _a.sent();
|
|
227
|
+
return [4 /*yield*/, response.value()];
|
|
228
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
229
|
+
}
|
|
230
|
+
});
|
|
231
|
+
});
|
|
232
|
+
};
|
|
233
|
+
/**
|
|
234
|
+
*/
|
|
235
|
+
ProjectsServerApi.prototype.adminVerifyUserContactMethodRaw = function (requestParameters, initOverrides) {
|
|
236
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
237
|
+
var queryParameters, headerParameters, urlPath, response;
|
|
238
|
+
return __generator(this, function (_a) {
|
|
239
|
+
switch (_a.label) {
|
|
240
|
+
case 0:
|
|
241
|
+
if (requestParameters['projectId'] == null) {
|
|
242
|
+
throw new runtime.RequiredError('projectId', 'Required parameter "projectId" was null or undefined when calling adminVerifyUserContactMethod().');
|
|
243
|
+
}
|
|
244
|
+
if (requestParameters['userId'] == null) {
|
|
245
|
+
throw new runtime.RequiredError('userId', 'Required parameter "userId" was null or undefined when calling adminVerifyUserContactMethod().');
|
|
246
|
+
}
|
|
247
|
+
if (requestParameters['contactMethodId'] == null) {
|
|
248
|
+
throw new runtime.RequiredError('contactMethodId', 'Required parameter "contactMethodId" was null or undefined when calling adminVerifyUserContactMethod().');
|
|
249
|
+
}
|
|
250
|
+
if (requestParameters['verificationCode'] == null) {
|
|
251
|
+
throw new runtime.RequiredError('verificationCode', 'Required parameter "verificationCode" was null or undefined when calling adminVerifyUserContactMethod().');
|
|
252
|
+
}
|
|
253
|
+
queryParameters = {};
|
|
254
|
+
if (requestParameters['verificationCode'] != null) {
|
|
255
|
+
queryParameters['verificationCode'] = requestParameters['verificationCode'];
|
|
256
|
+
}
|
|
257
|
+
headerParameters = {};
|
|
258
|
+
urlPath = "/api/v1/projects/{projectId}/users/{userId}/contact-methods/{contactMethodId}/verify";
|
|
259
|
+
urlPath = urlPath.replace("{".concat("projectId", "}"), encodeURIComponent(String(requestParameters['projectId'])));
|
|
260
|
+
urlPath = urlPath.replace("{".concat("userId", "}"), encodeURIComponent(String(requestParameters['userId'])));
|
|
261
|
+
urlPath = urlPath.replace("{".concat("contactMethodId", "}"), encodeURIComponent(String(requestParameters['contactMethodId'])));
|
|
262
|
+
return [4 /*yield*/, this.request({
|
|
263
|
+
path: urlPath,
|
|
264
|
+
method: 'POST',
|
|
265
|
+
headers: headerParameters,
|
|
266
|
+
query: queryParameters,
|
|
267
|
+
}, initOverrides)];
|
|
268
|
+
case 1:
|
|
269
|
+
response = _a.sent();
|
|
270
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.ContactMethodFromJSON)(jsonValue); })];
|
|
271
|
+
}
|
|
272
|
+
});
|
|
273
|
+
});
|
|
274
|
+
};
|
|
275
|
+
/**
|
|
276
|
+
*/
|
|
277
|
+
ProjectsServerApi.prototype.adminVerifyUserContactMethod = function (requestParameters, initOverrides) {
|
|
278
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
279
|
+
var response;
|
|
280
|
+
return __generator(this, function (_a) {
|
|
281
|
+
switch (_a.label) {
|
|
282
|
+
case 0: return [4 /*yield*/, this.adminVerifyUserContactMethodRaw(requestParameters, initOverrides)];
|
|
283
|
+
case 1:
|
|
284
|
+
response = _a.sent();
|
|
285
|
+
return [4 /*yield*/, response.value()];
|
|
286
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
287
|
+
}
|
|
288
|
+
});
|
|
289
|
+
});
|
|
290
|
+
};
|
|
78
291
|
/**
|
|
79
292
|
*/
|
|
80
293
|
ProjectsServerApi.prototype.createProjectRaw = function (requestParameters, initOverrides) {
|
|
@@ -86,6 +86,8 @@ export declare const ForteApiExceptionErrorCodeType: {
|
|
|
86
86
|
readonly COMPLIANCE_DOCUMENT_MISSING_CONTENTS: "COMPLIANCE_DOCUMENT_MISSING_CONTENTS";
|
|
87
87
|
readonly COMPLIANCE_DOCUMENT_INVALID_OWNER: "COMPLIANCE_DOCUMENT_INVALID_OWNER";
|
|
88
88
|
readonly COMPLIANCE_REGISTRATION_NOT_APPROVED: "COMPLIANCE_REGISTRATION_NOT_APPROVED";
|
|
89
|
+
readonly EMAIL_LOGIN_NOT_ENABLED: "EMAIL_LOGIN_NOT_ENABLED";
|
|
90
|
+
readonly PHONE_LOGIN_NOT_ENABLED: "PHONE_LOGIN_NOT_ENABLED";
|
|
89
91
|
};
|
|
90
92
|
export type ForteApiExceptionErrorCodeType = typeof ForteApiExceptionErrorCodeType[keyof typeof ForteApiExceptionErrorCodeType];
|
|
91
93
|
/**
|
|
@@ -70,7 +70,9 @@ exports.ForteApiExceptionErrorCodeType = {
|
|
|
70
70
|
COMPLIANCE_DOCUMENT_ALREADY_HAS_CONTENTS: 'COMPLIANCE_DOCUMENT_ALREADY_HAS_CONTENTS',
|
|
71
71
|
COMPLIANCE_DOCUMENT_MISSING_CONTENTS: 'COMPLIANCE_DOCUMENT_MISSING_CONTENTS',
|
|
72
72
|
COMPLIANCE_DOCUMENT_INVALID_OWNER: 'COMPLIANCE_DOCUMENT_INVALID_OWNER',
|
|
73
|
-
COMPLIANCE_REGISTRATION_NOT_APPROVED: 'COMPLIANCE_REGISTRATION_NOT_APPROVED'
|
|
73
|
+
COMPLIANCE_REGISTRATION_NOT_APPROVED: 'COMPLIANCE_REGISTRATION_NOT_APPROVED',
|
|
74
|
+
EMAIL_LOGIN_NOT_ENABLED: 'EMAIL_LOGIN_NOT_ENABLED',
|
|
75
|
+
PHONE_LOGIN_NOT_ENABLED: 'PHONE_LOGIN_NOT_ENABLED'
|
|
74
76
|
};
|
|
75
77
|
/**
|
|
76
78
|
* Check if a given object implements the ForteApiException interface.
|
|
@@ -58,6 +58,7 @@ function UserActionLogObjectFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
58
58
|
'userId': json['userId'],
|
|
59
59
|
'actionType': json['actionType'],
|
|
60
60
|
'contactMethodId': json['contactMethodId'] == null ? undefined : json['contactMethodId'],
|
|
61
|
+
'performedByAccountId': json['performedByAccountId'] == null ? undefined : json['performedByAccountId'],
|
|
61
62
|
};
|
|
62
63
|
}
|
|
63
64
|
function UserActionLogObjectToJSON(json) {
|
|
@@ -73,5 +74,6 @@ function UserActionLogObjectToJSONTyped(value, ignoreDiscriminator) {
|
|
|
73
74
|
'userId': value['userId'],
|
|
74
75
|
'actionType': value['actionType'],
|
|
75
76
|
'contactMethodId': value['contactMethodId'],
|
|
77
|
+
'performedByAccountId': value['performedByAccountId'],
|
|
76
78
|
};
|
|
77
79
|
}
|