@explo-tech/fido-api 3.12.0 → 3.13.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/index.ts CHANGED
@@ -100,6 +100,7 @@ export type { ListBranchContentResponse } from './models/ListBranchContentRespon
100
100
  export type { ListBranchResponse } from './models/ListBranchResponse';
101
101
  export type { ListCommitResponse } from './models/ListCommitResponse';
102
102
  export type { ListNamespacesResponse } from './models/ListNamespacesResponse';
103
+ export type { ListResourcesResponse } from './models/ListResourcesResponse';
103
104
  export type { ListVersionedViewsRequest } from './models/ListVersionedViewsRequest';
104
105
  export type { ListViewsRequest } from './models/ListViewsRequest';
105
106
  export type { ListViewsResponse } from './models/ListViewsResponse';
@@ -0,0 +1,11 @@
1
+ /* istanbul ignore file */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+
5
+ import type { Resource } from './Resource';
6
+
7
+ export type ListResourcesResponse = {
8
+ resources: Array<Resource>;
9
+ totalResults: number;
10
+ };
11
+
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@explo-tech/fido-api",
3
3
  "description": "Fido api",
4
4
  "homepage": "https://github.com/trust-kaz/fido",
5
- "version": "3.12.0",
5
+ "version": "3.13.0",
6
6
  "repository": {
7
7
  "type": "git",
8
8
  "url": "https://github.com/trust-kaz/fido"
@@ -2,6 +2,7 @@
2
2
  /* tslint:disable */
3
3
  /* eslint-disable */
4
4
  import type { ListBranchContentResponse } from '../models/ListBranchContentResponse';
5
+ import type { ListResourcesResponse } from '../models/ListResourcesResponse';
5
6
  import type { ListViewsResponse } from '../models/ListViewsResponse';
6
7
  import type { ResourceResponse } from '../models/ResourceResponse';
7
8
  import type { UUID } from '../models/UUID';
@@ -13,6 +14,35 @@ import { request as __request } from '../core/request';
13
14
 
14
15
  export class BranchContentResourceService {
15
16
 
17
+ /**
18
+ * Returns a paginated view of all versions of a resource at the requested branch
19
+ * @param branchId
20
+ * @param resourceId
21
+ * @param page
22
+ * @param perPage
23
+ * @returns ListResourcesResponse The history of the requested resource
24
+ * @throws ApiError
25
+ */
26
+ public static getResourceHistory(
27
+ branchId: UUID,
28
+ resourceId: UUID,
29
+ page?: number,
30
+ perPage: number = 50,
31
+ ): CancelablePromise<ListResourcesResponse> {
32
+ return __request(OpenAPI, {
33
+ method: 'GET',
34
+ url: '/v1/branches/{branchId}/resources/{resourceId}/history',
35
+ path: {
36
+ 'branchId': branchId,
37
+ 'resourceId': resourceId,
38
+ },
39
+ query: {
40
+ 'page': page,
41
+ 'perPage': perPage,
42
+ },
43
+ });
44
+ }
45
+
16
46
  /**
17
47
  * Lists the state at the head of the requested branch
18
48
  * @param id
@@ -109,6 +109,24 @@ export class BranchResourceService {
109
109
  });
110
110
  }
111
111
 
112
+ /**
113
+ * Deletes a branch
114
+ * @param id
115
+ * @returns any 200 if the branch was deleted properly
116
+ * @throws ApiError
117
+ */
118
+ public static deleteBranch(
119
+ id: UUID,
120
+ ): CancelablePromise<Record<string, any>> {
121
+ return __request(OpenAPI, {
122
+ method: 'DELETE',
123
+ url: '/v1/branches/{id}',
124
+ path: {
125
+ 'id': id,
126
+ },
127
+ });
128
+ }
129
+
112
130
  /**
113
131
  * Merge the provided source branch into the provided target branch
114
132
  * @param targetBranchId