@daocloud-proto/ghippo 0.11.1-dev-1 → 0.11.2

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@daocloud-proto/ghippo",
3
- "version":"0.11.1-dev-1",
3
+ "version":"0.11.2",
4
4
  "description": "",
5
5
  "author": "",
6
6
  "license": "ISC"
@@ -78,6 +78,18 @@ export type WorkspacesResourceInfo = {
78
78
  module?: string
79
79
  }
80
80
 
81
+ export type ListResourcesRequest = {
82
+ page?: number
83
+ pageSize?: number
84
+ resourceName?: string
85
+ resourceType?: string
86
+ }
87
+
88
+ export type ListResourcesResponse = {
89
+ items?: ResourceInfo[]
90
+ pagination?: Pagination
91
+ }
92
+
81
93
  export type ListExclusiveResourcesByWorkspaceRequest = {
82
94
  page?: number
83
95
  pageSize?: number
@@ -459,6 +471,9 @@ export class Workspace {
459
471
  static ListWorkspaces(req: ListWorkspacesRequest, initReq?: fm.InitReq): Promise<ListWorkspacesResponse> {
460
472
  return fm.fetchReq<ListWorkspacesRequest, ListWorkspacesResponse>(`/apis/ghippo.io/v1alpha1/workspaces?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
461
473
  }
474
+ static ListResources(req: ListResourcesRequest, initReq?: fm.InitReq): Promise<ListResourcesResponse> {
475
+ return fm.fetchReq<ListResourcesRequest, ListResourcesResponse>(`/apis/ghippo.io/v1alpha1/resources?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
476
+ }
462
477
  static ListExclusiveResourcesByWorkspace(req: ListExclusiveResourcesByWorkspaceRequest, initReq?: fm.InitReq): Promise<ListExclusiveResourcesByWorkspaceResponse> {
463
478
  return fm.fetchReq<ListExclusiveResourcesByWorkspaceRequest, ListExclusiveResourcesByWorkspaceResponse>(`/apis/ghippo.io/v1alpha1/workspaces/${req["workspaceId"]}/exclusiveresources?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
464
479
  }