@revisium/endpoint 0.11.0-alpha.3 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/endpoint-microservice/core-api/generated/api.d.ts +83 -68
- package/dist/endpoint-microservice/core-api/generated/api.js +489 -466
- package/dist/endpoint-microservice/core-api/generated/api.js.map +1 -1
- package/dist/endpoint-microservice/core-api/internal-core-api.service.js +1 -1
- package/dist/endpoint-microservice/core-api/internal-core-api.service.js.map +1 -1
- package/dist/endpoint-microservice/core-api/utils/transformFromPrismaToRowModel.js +2 -0
- package/dist/endpoint-microservice/core-api/utils/transformFromPrismaToRowModel.js.map +1 -1
- package/dist/endpoint-microservice/graphql/graphql-schema-converter/graphql-schema.converter.js +1 -1
- package/dist/endpoint-microservice/graphql/graphql-schema-converter/graphql-schema.converter.js.map +1 -1
- package/dist/endpoint-microservice/graphql/queries/handlers/get-graphql-schema.handler.js +1 -1
- package/dist/endpoint-microservice/graphql/queries/handlers/get-graphql-schema.handler.js.map +1 -1
- package/dist/endpoint-microservice/restapi/queries/handlers/get-open-api-schema.handler.js +5 -4
- package/dist/endpoint-microservice/restapi/queries/handlers/get-open-api-schema.handler.js.map +1 -1
- package/dist/endpoint-microservice/restapi/restapi-endpoint.service.js +7 -7
- package/dist/endpoint-microservice/restapi/restapi-endpoint.service.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +3 -2
@@ -7,7 +7,7 @@ export interface LoginResponse {
|
|
7
7
|
}
|
8
8
|
export interface CreateUserDto {
|
9
9
|
username: string;
|
10
|
-
roleId:
|
10
|
+
roleId: "systemAdmin" | "systemFullApiRead" | "systemUser";
|
11
11
|
password: string;
|
12
12
|
email?: string;
|
13
13
|
}
|
@@ -65,7 +65,7 @@ export interface UsersOrganizationConnection {
|
|
65
65
|
}
|
66
66
|
export interface AddUserToOrganizationDto {
|
67
67
|
userId: string;
|
68
|
-
roleId:
|
68
|
+
roleId: "organizationOwner" | "organizationAdmin" | "developer" | "editor" | "reader";
|
69
69
|
}
|
70
70
|
export interface RemoveUserFromOrganizationDto {
|
71
71
|
userId: string;
|
@@ -105,7 +105,7 @@ export interface UsersProjectConnection {
|
|
105
105
|
}
|
106
106
|
export interface AddUserToProjectDto {
|
107
107
|
userId: string;
|
108
|
-
roleId:
|
108
|
+
roleId: "developer" | "editor" | "reader";
|
109
109
|
}
|
110
110
|
export interface Id {
|
111
111
|
id: string;
|
@@ -137,9 +137,11 @@ export interface ChildBranchResponse {
|
|
137
137
|
revision: Id;
|
138
138
|
}
|
139
139
|
export interface TableModel {
|
140
|
-
|
140
|
+
createdId: string;
|
141
141
|
id: string;
|
142
|
+
versionId: string;
|
142
143
|
createdAt: string;
|
144
|
+
updatedAt: string;
|
143
145
|
readonly: boolean;
|
144
146
|
}
|
145
147
|
export interface TableModelEdgeType {
|
@@ -154,13 +156,13 @@ export interface TablesConnection {
|
|
154
156
|
export interface EndpointModel {
|
155
157
|
id: string;
|
156
158
|
createdAt: string;
|
157
|
-
type:
|
159
|
+
type: "GRAPHQL" | "REST_API";
|
158
160
|
}
|
159
161
|
export interface CreateBranchByRevisionDto {
|
160
162
|
branchName: string;
|
161
163
|
}
|
162
164
|
export interface CreateEndpointDto {
|
163
|
-
type:
|
165
|
+
type: "GRAPHQL" | "REST_API";
|
164
166
|
}
|
165
167
|
export interface CreateTableDto {
|
166
168
|
tableId: string;
|
@@ -171,9 +173,11 @@ export interface CreateTableResponse {
|
|
171
173
|
table: TableModel;
|
172
174
|
}
|
173
175
|
export interface RowModel {
|
174
|
-
|
176
|
+
createdId: string;
|
175
177
|
id: string;
|
178
|
+
versionId: string;
|
176
179
|
createdAt: string;
|
180
|
+
updatedAt: string;
|
177
181
|
readonly: boolean;
|
178
182
|
data: object;
|
179
183
|
}
|
@@ -230,6 +234,12 @@ export interface RenameRowResponse {
|
|
230
234
|
row?: RowModel;
|
231
235
|
previousVersionRowId?: string;
|
232
236
|
}
|
237
|
+
export interface UploadFileResponse {
|
238
|
+
table?: TableModel;
|
239
|
+
previousVersionTableId?: string;
|
240
|
+
row?: RowModel;
|
241
|
+
previousVersionRowId?: string;
|
242
|
+
}
|
233
243
|
export interface GoogleOauth {
|
234
244
|
available: boolean;
|
235
245
|
clientId?: string;
|
@@ -317,8 +327,8 @@ export interface RowForeignKeysToParams {
|
|
317
327
|
rowId: string;
|
318
328
|
}
|
319
329
|
export type QueryParamsType = Record<string | number, any>;
|
320
|
-
export type ResponseFormat = keyof Omit<Body,
|
321
|
-
export interface FullRequestParams extends Omit<RequestInit,
|
330
|
+
export type ResponseFormat = keyof Omit<Body, "body" | "bodyUsed">;
|
331
|
+
export interface FullRequestParams extends Omit<RequestInit, "body"> {
|
322
332
|
secure?: boolean;
|
323
333
|
path: string;
|
324
334
|
type?: ContentType;
|
@@ -328,10 +338,10 @@ export interface FullRequestParams extends Omit<RequestInit, 'body'> {
|
|
328
338
|
baseUrl?: string;
|
329
339
|
cancelToken?: CancelToken;
|
330
340
|
}
|
331
|
-
export type RequestParams = Omit<FullRequestParams,
|
341
|
+
export type RequestParams = Omit<FullRequestParams, "body" | "method" | "query" | "path">;
|
332
342
|
export interface ApiConfig<SecurityDataType = unknown> {
|
333
343
|
baseUrl?: string;
|
334
|
-
baseApiParams?: Omit<RequestParams,
|
344
|
+
baseApiParams?: Omit<RequestParams, "baseUrl" | "cancelToken" | "signal">;
|
335
345
|
securityWorker?: (securityData: SecurityDataType | null) => Promise<RequestParams | void> | RequestParams | void;
|
336
346
|
customFetch?: typeof fetch;
|
337
347
|
}
|
@@ -367,63 +377,68 @@ export declare class HttpClient<SecurityDataType = unknown> {
|
|
367
377
|
request: <T = any, E = any>({ body, secure, path, type, query, format, baseUrl, cancelToken, ...params }: FullRequestParams) => Promise<HttpResponse<T, E>>;
|
368
378
|
}
|
369
379
|
export declare class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDataType> {
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
376
|
-
|
377
|
-
|
378
|
-
|
379
|
-
|
380
|
-
|
381
|
-
|
382
|
-
|
383
|
-
|
384
|
-
|
385
|
-
|
386
|
-
|
387
|
-
|
388
|
-
|
389
|
-
|
390
|
-
|
391
|
-
|
392
|
-
|
393
|
-
|
394
|
-
|
395
|
-
|
396
|
-
|
397
|
-
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
|
402
|
-
|
403
|
-
|
404
|
-
|
405
|
-
|
406
|
-
|
407
|
-
|
408
|
-
|
409
|
-
|
410
|
-
|
411
|
-
|
412
|
-
|
413
|
-
|
414
|
-
|
415
|
-
|
416
|
-
|
417
|
-
|
418
|
-
|
419
|
-
|
420
|
-
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
-
|
425
|
-
|
426
|
-
|
380
|
+
api: {
|
381
|
+
login: (data: LoginDto, params?: RequestParams) => Promise<HttpResponse<LoginResponse, any>>;
|
382
|
+
createUser: (data: CreateUserDto, params?: RequestParams) => Promise<HttpResponse<boolean, any>>;
|
383
|
+
updatePassword: (data: UpdatePasswordDto, params?: RequestParams) => Promise<HttpResponse<boolean, any>>;
|
384
|
+
me: (params?: RequestParams) => Promise<HttpResponse<UserModel, any>>;
|
385
|
+
projects: ({ organizationId, ...query }: ProjectsParams, params?: RequestParams) => Promise<HttpResponse<ProjectsConnection, any>>;
|
386
|
+
createProject: ({ organizationId, ...query }: CreateProjectParams, data: CreateProjectDto, params?: RequestParams) => Promise<HttpResponse<ProjectModel, any>>;
|
387
|
+
usersOrganization: ({ organizationId, ...query }: UsersOrganizationParams, params?: RequestParams) => Promise<HttpResponse<UsersOrganizationConnection, any>>;
|
388
|
+
addUserToOrganization: (organizationId: string, data: AddUserToOrganizationDto, params?: RequestParams) => Promise<HttpResponse<boolean, any>>;
|
389
|
+
removeUserFromOrganization: (organizationId: string, data: RemoveUserFromOrganizationDto, params?: RequestParams) => Promise<HttpResponse<boolean, any>>;
|
390
|
+
project: (organizationId: string, projectName: string, params?: RequestParams) => Promise<HttpResponse<ProjectModel, any>>;
|
391
|
+
deleteProject: (organizationId: string, projectName: string, params?: RequestParams) => Promise<HttpResponse<boolean, any>>;
|
392
|
+
updateProject: (organizationId: string, projectName: string, data: UpdateProjectDto, params?: RequestParams) => Promise<HttpResponse<boolean, any>>;
|
393
|
+
rootBranch: (organizationId: string, projectName: string, params?: RequestParams) => Promise<HttpResponse<BranchModel, any>>;
|
394
|
+
branches: ({ organizationId, projectName, ...query }: BranchesParams, params?: RequestParams) => Promise<HttpResponse<BranchesConnection, any>>;
|
395
|
+
usersProject: ({ organizationId, projectName, ...query }: UsersProjectParams, params?: RequestParams) => Promise<HttpResponse<UsersProjectConnection, any>>;
|
396
|
+
addUserToProject: (organizationId: string, projectName: string, data: AddUserToProjectDto, params?: RequestParams) => Promise<HttpResponse<boolean, any>>;
|
397
|
+
removeUserFromProject: (organizationId: string, projectName: string, userId: string, params?: RequestParams) => Promise<HttpResponse<boolean, any>>;
|
398
|
+
branch: (organizationId: string, projectName: string, branchName: string, params?: RequestParams) => Promise<HttpResponse<BranchModel, any>>;
|
399
|
+
branchTouched: (organizationId: string, projectName: string, branchName: string, params?: RequestParams) => Promise<HttpResponse<boolean, any>>;
|
400
|
+
parentBranch: (organizationId: string, projectName: string, branchName: string, params?: RequestParams) => Promise<HttpResponse<ParentBranchResponse, any>>;
|
401
|
+
startRevision: (organizationId: string, projectName: string, branchName: string, params?: RequestParams) => Promise<HttpResponse<RevisionModel, any>>;
|
402
|
+
headRevision: (organizationId: string, projectName: string, branchName: string, params?: RequestParams) => Promise<HttpResponse<RevisionModel, any>>;
|
403
|
+
draftRevision: (organizationId: string, projectName: string, branchName: string, params?: RequestParams) => Promise<HttpResponse<RevisionModel, any>>;
|
404
|
+
revisions: ({ organizationId, projectName, branchName, ...query }: RevisionsParams, params?: RequestParams) => Promise<HttpResponse<RevisionsConnection, any>>;
|
405
|
+
createRevision: (organizationId: string, projectName: string, branchName: string, data: CreateRevisionDto, params?: RequestParams) => Promise<HttpResponse<RevisionModel, any>>;
|
406
|
+
revertChanges: (organizationId: string, projectName: string, branchName: string, params?: RequestParams) => Promise<HttpResponse<BranchModel, any>>;
|
407
|
+
revision: (revisionId: string, params?: RequestParams) => Promise<HttpResponse<RevisionModel, any>>;
|
408
|
+
parentRevision: (revisionId: string, params?: RequestParams) => Promise<HttpResponse<RevisionModel, any>>;
|
409
|
+
childRevision: (revisionId: string, params?: RequestParams) => Promise<HttpResponse<RevisionModel, any>>;
|
410
|
+
childBranches: (revisionId: string, params?: RequestParams) => Promise<HttpResponse<ChildBranchResponse[], any>>;
|
411
|
+
createBranch: (revisionId: string, data: CreateBranchByRevisionDto, params?: RequestParams) => Promise<HttpResponse<BranchModel, any>>;
|
412
|
+
tables: ({ revisionId, ...query }: TablesParams, params?: RequestParams) => Promise<HttpResponse<TablesConnection, any>>;
|
413
|
+
createTable: (revisionId: string, data: CreateTableDto, params?: RequestParams) => Promise<HttpResponse<CreateTableResponse, any>>;
|
414
|
+
endpoints: (revisionId: string, params?: RequestParams) => Promise<HttpResponse<EndpointModel[], any>>;
|
415
|
+
createEndpoint: (revisionId: string, data: CreateEndpointDto, params?: RequestParams) => Promise<HttpResponse<EndpointModel, any>>;
|
416
|
+
table: (revisionId: string, tableId: string, params?: RequestParams) => Promise<HttpResponse<TableModel, any>>;
|
417
|
+
deleteTable: (revisionId: string, tableId: string, params?: RequestParams) => Promise<HttpResponse<BranchModel, any>>;
|
418
|
+
updateTable: (revisionId: string, tableId: string, data: UpdateTableDto, params?: RequestParams) => Promise<HttpResponse<UpdateTableResponse, any>>;
|
419
|
+
tableCountRows: (revisionId: string, tableId: string, params?: RequestParams) => Promise<HttpResponse<number, any>>;
|
420
|
+
rows: ({ revisionId, tableId, ...query }: RowsParams, params?: RequestParams) => Promise<HttpResponse<RowsConnection, any>>;
|
421
|
+
createRow: (revisionId: string, tableId: string, data: CreateRowDto, params?: RequestParams) => Promise<HttpResponse<CreateRowResponse, any>>;
|
422
|
+
tableSchema: (revisionId: string, tableId: string, params?: RequestParams) => Promise<HttpResponse<object, any>>;
|
423
|
+
tableCountForeignKeysBy: (revisionId: string, tableId: string, params?: RequestParams) => Promise<HttpResponse<number, any>>;
|
424
|
+
tableForeignKeysBy: ({ revisionId, tableId, ...query }: TableForeignKeysByParams, params?: RequestParams) => Promise<HttpResponse<TablesConnection, any>>;
|
425
|
+
tableCountForeignKeysTo: (revisionId: string, tableId: string, params?: RequestParams) => Promise<HttpResponse<number, any>>;
|
426
|
+
tableForeignKeysTo: ({ revisionId, tableId, ...query }: TableForeignKeysToParams, params?: RequestParams) => Promise<HttpResponse<TablesConnection, any>>;
|
427
|
+
renameTable: (revisionId: string, tableId: string, data: UpdateTableDto, params?: RequestParams) => Promise<HttpResponse<UpdateTableResponse, any>>;
|
428
|
+
row: (revisionId: string, tableId: string, rowId: string, params?: RequestParams) => Promise<HttpResponse<RowModel, ErrorModel>>;
|
429
|
+
deleteRow: (revisionId: string, tableId: string, rowId: string, params?: RequestParams) => Promise<HttpResponse<RemoveRowResponse, any>>;
|
430
|
+
updateRow: (revisionId: string, tableId: string, rowId: string, data: UpdateRowDto, params?: RequestParams) => Promise<HttpResponse<UpdateRowResponse, any>>;
|
431
|
+
rowCountForeignKeysBy: (revisionId: string, tableId: string, rowId: string, params?: RequestParams) => Promise<HttpResponse<number, any>>;
|
432
|
+
rowForeignKeysBy: ({ revisionId, tableId, rowId, ...query }: RowForeignKeysByParams, params?: RequestParams) => Promise<HttpResponse<RowsConnection, any>>;
|
433
|
+
rowCountForeignKeysTo: (revisionId: string, tableId: string, rowId: string, params?: RequestParams) => Promise<HttpResponse<number, any>>;
|
434
|
+
rowForeignKeysTo: ({ revisionId, tableId, rowId, ...query }: RowForeignKeysToParams, params?: RequestParams) => Promise<HttpResponse<RowsConnection, any>>;
|
435
|
+
renameRow: (revisionId: string, tableId: string, rowId: string, data: RenameRowDto, params?: RequestParams) => Promise<HttpResponse<RenameRowResponse, any>>;
|
436
|
+
uploadFile: (revisionId: string, tableId: string, rowId: string, fileId: string, data: {
|
437
|
+
file: File;
|
438
|
+
}, params?: RequestParams) => Promise<HttpResponse<UploadFileResponse, any>>;
|
439
|
+
deleteEndpoint: (endpointId: string, params?: RequestParams) => Promise<HttpResponse<boolean, any>>;
|
440
|
+
getConfiguration: (params?: RequestParams) => Promise<HttpResponse<ConfigurationResponse, any>>;
|
441
|
+
};
|
427
442
|
health: {
|
428
443
|
liveness: (params?: RequestParams) => Promise<HttpResponse<{
|
429
444
|
status?: string;
|