api: update image builder api via npm run api
This commit is contained in:
parent
22d8eb6634
commit
04e02b9426
3 changed files with 33 additions and 0 deletions
|
|
@ -23,6 +23,7 @@ const config: ConfigFile = {
|
|||
'composeBlueprint',
|
||||
'getBlueprints',
|
||||
'getBlueprintComposes',
|
||||
'deleteBlueprint',
|
||||
],
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -537,6 +537,22 @@ paths:
|
|||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/HTTPErrorList'
|
||||
delete:
|
||||
summary: delete a blueprint
|
||||
description: |
|
||||
Deletes all versions of Blueprint, the compose will still count towards quota.
|
||||
operationId: deleteBlueprint
|
||||
tags:
|
||||
- blueprint
|
||||
responses:
|
||||
'204':
|
||||
description: Successfully deleted
|
||||
'404':
|
||||
description: Blueprint to delete was not found
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/HTTPErrorList'
|
||||
/experimental/blueprints/{id}/compose:
|
||||
post:
|
||||
parameters:
|
||||
|
|
|
|||
|
|
@ -110,6 +110,15 @@ const injectedRtkApi = api.injectEndpoints({
|
|||
body: queryArg.createBlueprintRequest,
|
||||
}),
|
||||
}),
|
||||
deleteBlueprint: build.mutation<
|
||||
DeleteBlueprintApiResponse,
|
||||
DeleteBlueprintApiArg
|
||||
>({
|
||||
query: (queryArg) => ({
|
||||
url: `/experimental/blueprints/${queryArg.id}`,
|
||||
method: "DELETE",
|
||||
}),
|
||||
}),
|
||||
composeBlueprint: build.mutation<
|
||||
ComposeBlueprintApiResponse,
|
||||
ComposeBlueprintApiArg
|
||||
|
|
@ -242,6 +251,12 @@ export type UpdateBlueprintApiArg = {
|
|||
/** details of blueprint */
|
||||
createBlueprintRequest: CreateBlueprintRequest;
|
||||
};
|
||||
export type DeleteBlueprintApiResponse =
|
||||
/** status 204 Successfully deleted */ void;
|
||||
export type DeleteBlueprintApiArg = {
|
||||
/** UUID of a blueprint */
|
||||
id: string;
|
||||
};
|
||||
export type ComposeBlueprintApiResponse =
|
||||
/** status 201 compose was created */ ComposeResponse[];
|
||||
export type ComposeBlueprintApiArg = {
|
||||
|
|
@ -782,6 +797,7 @@ export const {
|
|||
useGetBlueprintsQuery,
|
||||
useCreateBlueprintMutation,
|
||||
useUpdateBlueprintMutation,
|
||||
useDeleteBlueprintMutation,
|
||||
useComposeBlueprintMutation,
|
||||
useGetBlueprintComposesQuery,
|
||||
} = injectedRtkApi;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue