@daocloud-proto/ghippo 0.7.9 → 0.7.12
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/package.json +1 -1
- package/v1alpha1/ldap.pb.ts +113 -0
- package/v1alpha1/workspace.pb.ts +105 -6
package/package.json
CHANGED
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// @ts-nocheck
|
|
3
|
+
/*
|
|
4
|
+
* This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
import * as fm from "../fetch.pb"
|
|
8
|
+
export type GetLdapRequest = {
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export type GetLdapResponse = {
|
|
12
|
+
id?: string
|
|
13
|
+
name?: string
|
|
14
|
+
providerType?: string
|
|
15
|
+
startTls?: string
|
|
16
|
+
ldapProtocol?: string
|
|
17
|
+
ldapHost?: string
|
|
18
|
+
usersDn?: string
|
|
19
|
+
bindDn?: string
|
|
20
|
+
bindCredential?: string
|
|
21
|
+
userObjectClasses?: string
|
|
22
|
+
usernameLdapAttribute?: string
|
|
23
|
+
fullSyncPeriod?: string
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export type CreateLdapRequest = {
|
|
27
|
+
providerType?: string
|
|
28
|
+
startTls?: string
|
|
29
|
+
ldapProtocol?: string
|
|
30
|
+
ldapHost?: string
|
|
31
|
+
usersDn?: string
|
|
32
|
+
bindDn?: string
|
|
33
|
+
bindCredential?: string
|
|
34
|
+
userObjectClasses?: string
|
|
35
|
+
usernameLdapAttribute?: string
|
|
36
|
+
fullSyncPeriod?: string
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export type CreateLdapResponse = {
|
|
40
|
+
id?: string
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export type TestLdapConnectionRequest = {
|
|
44
|
+
bindDn?: string
|
|
45
|
+
bindCredential?: string
|
|
46
|
+
connectionUrl?: string
|
|
47
|
+
connectionTimeout?: string
|
|
48
|
+
action?: string
|
|
49
|
+
startTls?: string
|
|
50
|
+
useTruststoreSpi?: string
|
|
51
|
+
componentId?: string
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export type TestLdapConnectionResponse = {
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export type UpdateLdapRequest = {
|
|
58
|
+
id?: string
|
|
59
|
+
providerType?: string
|
|
60
|
+
startTls?: string
|
|
61
|
+
ldapProtocol?: string
|
|
62
|
+
ldapHost?: string
|
|
63
|
+
usersDn?: string
|
|
64
|
+
bindDn?: string
|
|
65
|
+
bindCredential?: string
|
|
66
|
+
userObjectClasses?: string
|
|
67
|
+
usernameLdapAttribute?: string
|
|
68
|
+
fullSyncPeriod?: string
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export type UpdateLdapResponse = {
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export type SyncUsersRequest = {
|
|
75
|
+
id?: string
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
export type SyncUserResponse = {
|
|
79
|
+
ignored?: boolean
|
|
80
|
+
added?: number
|
|
81
|
+
updated?: number
|
|
82
|
+
removed?: number
|
|
83
|
+
failed?: number
|
|
84
|
+
status?: string
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
export type DeleteLdapRequest = {
|
|
88
|
+
id?: string
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
export type DeleteLdapResponse = {
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export class Ldap {
|
|
95
|
+
static GetLdap(req: GetLdapRequest, initReq?: fm.InitReq): Promise<GetLdapResponse> {
|
|
96
|
+
return fm.fetchReq<GetLdapRequest, GetLdapResponse>(`/apis/ghippo.io/v1alpha1/ldap?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
97
|
+
}
|
|
98
|
+
static CreateLdap(req: CreateLdapRequest, initReq?: fm.InitReq): Promise<CreateLdapResponse> {
|
|
99
|
+
return fm.fetchReq<CreateLdapRequest, CreateLdapResponse>(`/apis/ghippo.io/v1alpha1/ldap`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
100
|
+
}
|
|
101
|
+
static TestLdapConnection(req: TestLdapConnectionRequest, initReq?: fm.InitReq): Promise<TestLdapConnectionResponse> {
|
|
102
|
+
return fm.fetchReq<TestLdapConnectionRequest, TestLdapConnectionResponse>(`/apis/ghippo.io/v1alpha1/testLdapConnection`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
103
|
+
}
|
|
104
|
+
static UpdateLdap(req: UpdateLdapRequest, initReq?: fm.InitReq): Promise<UpdateLdapResponse> {
|
|
105
|
+
return fm.fetchReq<UpdateLdapRequest, UpdateLdapResponse>(`/apis/ghippo.io/v1alpha1/ldap/${req["id"]}`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
106
|
+
}
|
|
107
|
+
static SyncUsers(req: SyncUsersRequest, initReq?: fm.InitReq): Promise<SyncUserResponse> {
|
|
108
|
+
return fm.fetchReq<SyncUsersRequest, SyncUserResponse>(`/apis/ghippo.io/v1alpha1/ldap/${req["id"]}/sync?${fm.renderURLSearchParams(req, ["id"])}`, {...initReq, method: "GET"})
|
|
109
|
+
}
|
|
110
|
+
static DeleteLdap(req: DeleteLdapRequest, initReq?: fm.InitReq): Promise<DeleteLdapResponse> {
|
|
111
|
+
return fm.fetchReq<DeleteLdapRequest, DeleteLdapResponse>(`/apis/ghippo.io/v1alpha1/ldap/${req["id"]}`, {...initReq, method: "DELETE"})
|
|
112
|
+
}
|
|
113
|
+
}
|
package/v1alpha1/workspace.pb.ts
CHANGED
|
@@ -47,6 +47,28 @@ export type ListResourcesResponse = {
|
|
|
47
47
|
pagination?: Pagination
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
+
export type ListExclusiveResourcesByWorkspaceRequest = {
|
|
51
|
+
page?: number
|
|
52
|
+
pageSize?: number
|
|
53
|
+
workspaceId?: number
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export type ListExclusiveResourcesByWorkspaceResponse = {
|
|
57
|
+
items?: ResourceInfo[]
|
|
58
|
+
pagination?: Pagination
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export type ListSharedResourcesByWorkspaceRequest = {
|
|
62
|
+
page?: number
|
|
63
|
+
pageSize?: number
|
|
64
|
+
workspaceId?: number
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export type ListSharedResourcesByWorkspaceResponse = {
|
|
68
|
+
items?: ResourceInfo[]
|
|
69
|
+
pagination?: Pagination
|
|
70
|
+
}
|
|
71
|
+
|
|
50
72
|
export type BindResourceToWorkspaceRequest = {
|
|
51
73
|
workspaceId?: number
|
|
52
74
|
resourceName?: string
|
|
@@ -76,6 +98,7 @@ export type CreateWorkspaceRequest = {
|
|
|
76
98
|
}
|
|
77
99
|
|
|
78
100
|
export type CreateWorkspaceResponse = {
|
|
101
|
+
workspaceId?: number
|
|
79
102
|
}
|
|
80
103
|
|
|
81
104
|
export type GetWorkspaceRequest = {
|
|
@@ -153,6 +176,7 @@ export type CreateFolderRequest = {
|
|
|
153
176
|
}
|
|
154
177
|
|
|
155
178
|
export type CreateFolderResponse = {
|
|
179
|
+
folderId?: number
|
|
156
180
|
}
|
|
157
181
|
|
|
158
182
|
export type GetFolderRequest = {
|
|
@@ -259,14 +283,62 @@ export type ProductResourceType = {
|
|
|
259
283
|
name?: string
|
|
260
284
|
}
|
|
261
285
|
|
|
262
|
-
export type
|
|
286
|
+
export type ListResourceTypesRequest = {
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
export type ListResourceTypesResponse = {
|
|
290
|
+
items?: ProductResourceType[]
|
|
291
|
+
pagination?: Pagination
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
export type ListExclusiveResourceTypesRequest = {
|
|
295
|
+
}
|
|
296
|
+
|
|
297
|
+
export type ListExclusiveResourceTypesResponse = {
|
|
298
|
+
items?: ProductResourceType[]
|
|
299
|
+
pagination?: Pagination
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
export type ListSharedResourceTypesRequest = {
|
|
263
303
|
}
|
|
264
304
|
|
|
265
|
-
export type
|
|
305
|
+
export type ListSharedResourceTypesResponse = {
|
|
266
306
|
items?: ProductResourceType[]
|
|
267
307
|
pagination?: Pagination
|
|
268
308
|
}
|
|
269
309
|
|
|
310
|
+
export type BindResourceAndSetQuotaHardToWorkspaceRequest = {
|
|
311
|
+
workspaceId?: number
|
|
312
|
+
resourceName?: string
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
export type BindResourceAndSetQuotaHardToWorkspaceResponse = {
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
export type SetQuotaHardForWorkspaceResourceRequest = {
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
export type SetQuotaHardForWorkspaceResourceResponse = {
|
|
322
|
+
}
|
|
323
|
+
|
|
324
|
+
export type GetWorkspaceResourceQuotaUsedRequest = {
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
export type GetWorkspaceResourceQuotaUsedResponse = {
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
export type GetWorkspaceResourceQuotaAllocatableRequest = {
|
|
331
|
+
}
|
|
332
|
+
|
|
333
|
+
export type GetWorkspaceResourceQuotaAllocatableResponse = {
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
export type ListResourceQuotaTypesRequest = {
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
export type ListResourceQuotaTypesResponse = {
|
|
340
|
+
}
|
|
341
|
+
|
|
270
342
|
export class Workspace {
|
|
271
343
|
static ListWorkspaces(req: ListWorkspacesRequest, initReq?: fm.InitReq): Promise<ListWorkspacesResponse> {
|
|
272
344
|
return fm.fetchReq<ListWorkspacesRequest, ListWorkspacesResponse>(`/apis/ghippo.io/v1alpha1/workspaces?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
@@ -274,11 +346,17 @@ export class Workspace {
|
|
|
274
346
|
static ListResources(req: ListResourcesRequest, initReq?: fm.InitReq): Promise<ListResourcesResponse> {
|
|
275
347
|
return fm.fetchReq<ListResourcesRequest, ListResourcesResponse>(`/apis/ghippo.io/v1alpha1/resources?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
276
348
|
}
|
|
349
|
+
static ListExclusiveResourcesByWorkspace(req: ListExclusiveResourcesByWorkspaceRequest, initReq?: fm.InitReq): Promise<ListExclusiveResourcesByWorkspaceResponse> {
|
|
350
|
+
return fm.fetchReq<ListExclusiveResourcesByWorkspaceRequest, ListExclusiveResourcesByWorkspaceResponse>(`/apis/ghippo.io/v1alpha1/workspaces/${req["workspaceId"]}/exclusiveresources?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
351
|
+
}
|
|
352
|
+
static ListSharedResourcesByWorkspace(req: ListSharedResourcesByWorkspaceRequest, initReq?: fm.InitReq): Promise<ListSharedResourcesByWorkspaceResponse> {
|
|
353
|
+
return fm.fetchReq<ListSharedResourcesByWorkspaceRequest, ListSharedResourcesByWorkspaceResponse>(`/apis/ghippo.io/v1alpha1/workspaces/${req["workspaceId"]}/sharedresources?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
354
|
+
}
|
|
277
355
|
static BindResourceToWorkspace(req: BindResourceToWorkspaceRequest, initReq?: fm.InitReq): Promise<BindResourceToWorkspaceResponse> {
|
|
278
|
-
return fm.fetchReq<BindResourceToWorkspaceRequest, BindResourceToWorkspaceResponse>(`/apis/ghippo.io/v1alpha1/
|
|
356
|
+
return fm.fetchReq<BindResourceToWorkspaceRequest, BindResourceToWorkspaceResponse>(`/apis/ghippo.io/v1alpha1/workspaces/${req["workspaceId"]}/bind-workspace`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
279
357
|
}
|
|
280
358
|
static UnbindResourceFromWorkspace(req: UnbindResourceFromWorkspaceRequest, initReq?: fm.InitReq): Promise<UnbindResourceFromWorkspaceResponse> {
|
|
281
|
-
return fm.fetchReq<UnbindResourceFromWorkspaceRequest, UnbindResourceFromWorkspaceResponse>(`/apis/ghippo.io/v1alpha1/
|
|
359
|
+
return fm.fetchReq<UnbindResourceFromWorkspaceRequest, UnbindResourceFromWorkspaceResponse>(`/apis/ghippo.io/v1alpha1/workspaces/${req["workspaceId"]}/unbind-workspace`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
282
360
|
}
|
|
283
361
|
static CreateWorkspace(req: CreateWorkspaceRequest, initReq?: fm.InitReq): Promise<CreateWorkspaceResponse> {
|
|
284
362
|
return fm.fetchReq<CreateWorkspaceRequest, CreateWorkspaceResponse>(`/apis/ghippo.io/v1alpha1/workspaces`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
@@ -325,7 +403,28 @@ export class Workspace {
|
|
|
325
403
|
static ListProductResources(req: ListProductResourcesRequest, initReq?: fm.InitReq): Promise<ListProductResourcesResponse> {
|
|
326
404
|
return fm.fetchReq<ListProductResourcesRequest, ListProductResourcesResponse>(`/apis/ghippo.io/v1alpha1/product-resources?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
327
405
|
}
|
|
328
|
-
static
|
|
329
|
-
return fm.fetchReq<
|
|
406
|
+
static ListResourceTypes(req: ListResourceTypesRequest, initReq?: fm.InitReq): Promise<ListResourceTypesResponse> {
|
|
407
|
+
return fm.fetchReq<ListResourceTypesRequest, ListResourceTypesResponse>(`/apis/ghippo.io/v1alpha1/resource-types?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
408
|
+
}
|
|
409
|
+
static ListExclusiveResourceTypes(req: ListExclusiveResourceTypesRequest, initReq?: fm.InitReq): Promise<ListExclusiveResourceTypesResponse> {
|
|
410
|
+
return fm.fetchReq<ListExclusiveResourceTypesRequest, ListExclusiveResourceTypesResponse>(`/apis/ghippo.io/v1alpha1/exclusiveresource-types?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
411
|
+
}
|
|
412
|
+
static ListSharedResourceTypes(req: ListSharedResourceTypesRequest, initReq?: fm.InitReq): Promise<ListSharedResourceTypesResponse> {
|
|
413
|
+
return fm.fetchReq<ListSharedResourceTypesRequest, ListSharedResourceTypesResponse>(`/apis/ghippo.io/v1alpha1/sharedresource-types?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
414
|
+
}
|
|
415
|
+
static BindResourceAndSetQuotaHardToWorkspace(req: BindResourceAndSetQuotaHardToWorkspaceRequest, initReq?: fm.InitReq): Promise<BindResourceAndSetQuotaHardToWorkspaceResponse> {
|
|
416
|
+
return fm.fetchReq<BindResourceAndSetQuotaHardToWorkspaceRequest, BindResourceAndSetQuotaHardToWorkspaceResponse>(`/apis/ghippo.io/v1alpha1/workspaces/${req["workspaceId"]}/bind-resource-setquota`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
417
|
+
}
|
|
418
|
+
static SetQuotaHardForWorkspaceResource(req: SetQuotaHardForWorkspaceResourceRequest, initReq?: fm.InitReq): Promise<SetQuotaHardForWorkspaceResourceResponse> {
|
|
419
|
+
return fm.fetchReq<SetQuotaHardForWorkspaceResourceRequest, SetQuotaHardForWorkspaceResourceResponse>(`/apis/ghippo.io/v1alpha1/workspaceresource-quota-hard`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
420
|
+
}
|
|
421
|
+
static GetWorkspaceResourceQuotaUsed(req: GetWorkspaceResourceQuotaUsedRequest, initReq?: fm.InitReq): Promise<GetWorkspaceResourceQuotaUsedResponse> {
|
|
422
|
+
return fm.fetchReq<GetWorkspaceResourceQuotaUsedRequest, GetWorkspaceResourceQuotaUsedResponse>(`/apis/ghippo.io/v1alpha1/workspaceresource-quota-used?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
423
|
+
}
|
|
424
|
+
static GetWorkspaceResourceQuotaAllocatable(req: GetWorkspaceResourceQuotaAllocatableRequest, initReq?: fm.InitReq): Promise<GetWorkspaceResourceQuotaAllocatableResponse> {
|
|
425
|
+
return fm.fetchReq<GetWorkspaceResourceQuotaAllocatableRequest, GetWorkspaceResourceQuotaAllocatableResponse>(`/apis/ghippo.io/v1alpha1/workspaceresource-quota-allocatable?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
426
|
+
}
|
|
427
|
+
static ListResourceQuotaTypes(req: ListResourceQuotaTypesRequest, initReq?: fm.InitReq): Promise<ListResourceQuotaTypesResponse> {
|
|
428
|
+
return fm.fetchReq<ListResourceQuotaTypesRequest, ListResourceQuotaTypesResponse>(`/apis/ghippo.io/v1alpha1/resourcequota-types?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
330
429
|
}
|
|
331
430
|
}
|