@harnessio/react-har-service-client 0.22.0 → 0.24.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/har-service/src/services/hooks/useDefineSpaceLabelMutation.d.ts +23 -0
- package/dist/har-service/src/services/hooks/useDefineSpaceLabelMutation.js +11 -0
- package/dist/har-service/src/services/hooks/useDefineSpaceLabelValueMutation.d.ts +21 -0
- package/dist/har-service/src/services/hooks/useDefineSpaceLabelValueMutation.js +11 -0
- package/dist/har-service/src/services/hooks/useDeleteArtifactMutation.d.ts +5 -1
- package/dist/har-service/src/services/hooks/useDeleteArtifactVersionMutation.d.ts +5 -1
- package/dist/har-service/src/services/hooks/useDeleteQuarantineFilePathMutation.d.ts +26 -0
- package/dist/har-service/src/services/hooks/useDeleteQuarantineFilePathMutation.js +14 -0
- package/dist/har-service/src/services/hooks/useDeleteSpaceLabelMutation.d.ts +14 -0
- package/dist/har-service/src/services/hooks/useDeleteSpaceLabelMutation.js +11 -0
- package/dist/har-service/src/services/hooks/useDeleteSpaceLabelValueMutation.d.ts +15 -0
- package/dist/har-service/src/services/hooks/useDeleteSpaceLabelValueMutation.js +11 -0
- package/dist/har-service/src/services/hooks/useFindSpaceLabelQuery.d.ts +19 -0
- package/dist/har-service/src/services/hooks/useFindSpaceLabelQuery.js +11 -0
- package/dist/har-service/src/services/hooks/useGetAllArtifactsByRegistryQuery.d.ts +1 -0
- package/dist/har-service/src/services/hooks/useGetAllRegistriesQuery.d.ts +2 -1
- package/dist/har-service/src/services/hooks/useGetAllRegistriesQuery.js +1 -1
- package/dist/har-service/src/services/hooks/useGetArtifactDetailsQuery.d.ts +1 -0
- package/dist/har-service/src/services/hooks/useGetArtifactFileQuery.d.ts +28 -0
- package/dist/har-service/src/services/hooks/useGetArtifactFileQuery.js +21 -0
- package/dist/har-service/src/services/hooks/useGetArtifactFilesQuery.d.ts +1 -0
- package/dist/har-service/src/services/hooks/useGetArtifactStatsForSpaceQuery.d.ts +1 -1
- package/dist/har-service/src/services/hooks/useGetArtifactStatsForSpaceQuery.js +1 -1
- package/dist/har-service/src/services/hooks/useGetArtifactSummaryQuery.d.ts +5 -1
- package/dist/har-service/src/services/hooks/useGetArtifactSummaryQuery.js +1 -1
- package/dist/har-service/src/services/hooks/useGetArtifactVersionSummaryQuery.d.ts +1 -0
- package/dist/har-service/src/services/hooks/useListSpaceLabelValuesQuery.d.ts +15 -0
- package/dist/har-service/src/services/hooks/useListSpaceLabelValuesQuery.js +11 -0
- package/dist/har-service/src/services/hooks/useListSpaceLabelsQuery.d.ts +27 -0
- package/dist/har-service/src/services/hooks/useListSpaceLabelsQuery.js +11 -0
- package/dist/har-service/src/services/hooks/useQuarantineFilePathMutation.d.ts +23 -0
- package/dist/har-service/src/services/hooks/useQuarantineFilePathMutation.js +14 -0
- package/dist/har-service/src/services/hooks/useSaveSpaceLabelMutation.d.ts +21 -0
- package/dist/har-service/src/services/hooks/useSaveSpaceLabelMutation.js +11 -0
- package/dist/har-service/src/services/hooks/useUpdateArtifactLabelsMutation.d.ts +5 -1
- package/dist/har-service/src/services/hooks/useUpdateSpaceLabelMutation.d.ts +24 -0
- package/dist/har-service/src/services/hooks/useUpdateSpaceLabelMutation.js +11 -0
- package/dist/har-service/src/services/hooks/useUpdateSpaceLabelValueMutation.d.ts +22 -0
- package/dist/har-service/src/services/hooks/useUpdateSpaceLabelValueMutation.js +11 -0
- package/dist/har-service/src/services/index.d.ts +45 -6
- package/dist/har-service/src/services/index.js +13 -0
- package/dist/har-service/src/services/requestBodies/QuarantineRequestRequestBody.d.ts +2 -0
- package/dist/har-service/src/services/responses/ArtifactFileResponseResponse.d.ts +8 -0
- package/dist/har-service/src/services/responses/QuarantinePathResponseResponse.d.ts +6 -0
- package/dist/har-service/src/services/responses/QuarantinePathResponseResponse.js +1 -0
- package/dist/har-service/src/services/schemas/ArtifactDetail.d.ts +7 -3
- package/dist/har-service/src/services/schemas/ArtifactMetadata.d.ts +2 -2
- package/dist/har-service/src/services/schemas/ArtifactSummary.d.ts +2 -0
- package/dist/har-service/src/services/schemas/ArtifactType.d.ts +4 -0
- package/dist/har-service/src/services/schemas/ArtifactType.js +4 -0
- package/dist/har-service/src/services/schemas/ArtifactVersionMetadata.d.ts +3 -0
- package/dist/har-service/src/services/schemas/ArtifactVersionSummary.d.ts +2 -0
- package/dist/har-service/src/services/schemas/DockerArtifactDetail.d.ts +1 -0
- package/dist/har-service/src/services/schemas/EnumLabelColor.d.ts +1 -0
- package/dist/har-service/src/services/schemas/EnumLabelColor.js +4 -0
- package/dist/har-service/src/services/schemas/EnumLabelType.d.ts +1 -0
- package/dist/har-service/src/services/schemas/EnumLabelType.js +4 -0
- package/dist/har-service/src/services/schemas/HuggingFaceArtifactDetailConfig.d.ts +8 -0
- package/dist/har-service/src/services/schemas/HuggingFaceArtifactDetailConfig.js +4 -0
- package/dist/har-service/src/services/schemas/PackageType.d.ts +1 -1
- package/dist/har-service/src/services/schemas/QuarantinePath.d.ts +20 -0
- package/dist/har-service/src/services/schemas/QuarantinePath.js +4 -0
- package/dist/har-service/src/services/schemas/QuarantineRequest.d.ts +6 -0
- package/dist/har-service/src/services/schemas/QuarantineRequest.js +4 -0
- package/dist/har-service/src/services/schemas/RegistryArtifactMetadata.d.ts +3 -0
- package/dist/har-service/src/services/schemas/RegistryRequest.d.ts +10 -0
- package/dist/har-service/src/services/schemas/TypesLabel.d.ts +40 -0
- package/dist/har-service/src/services/schemas/TypesLabel.js +1 -0
- package/dist/har-service/src/services/schemas/TypesLabelValue.d.ts +11 -0
- package/dist/har-service/src/services/schemas/TypesLabelValue.js +1 -0
- package/dist/har-service/src/services/schemas/TypesLabelWithValues.d.ts +6 -0
- package/dist/har-service/src/services/schemas/TypesLabelWithValues.js +1 -0
- package/dist/har-service/src/services/schemas/TypesSaveLabelInput.d.ts +9 -0
- package/dist/har-service/src/services/schemas/TypesSaveLabelInput.js +1 -0
- package/dist/har-service/src/services/schemas/TypesSaveLabelValueInput.d.ts +6 -0
- package/dist/har-service/src/services/schemas/TypesSaveLabelValueInput.js +1 -0
- package/dist/har-service/src/services/schemas/UpstreamConfig.d.ts +1 -1
- package/dist/har-service/src/services/schemas/UsererrorError.d.ts +6 -0
- package/dist/har-service/src/services/schemas/UsererrorError.js +4 -0
- package/package.json +1 -1
- package/dist/har-service/src/services/schemas/StoDigestMetadata.d.ts +0 -8
- package/dist/har-service/src/services/schemas/StoMetadata.d.ts +0 -12
- /package/dist/har-service/src/services/{schemas/StoDigestMetadata.js → requestBodies/QuarantineRequestRequestBody.js} +0 -0
- /package/dist/har-service/src/services/{schemas/StoMetadata.js → responses/ArtifactFileResponseResponse.js} +0 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { TypesLabel } from '../schemas/TypesLabel';
|
|
3
|
+
import type { UsererrorError } from '../schemas/UsererrorError';
|
|
4
|
+
import type { EnumLabelColor } from '../schemas/EnumLabelColor';
|
|
5
|
+
import type { EnumLabelType } from '../schemas/EnumLabelType';
|
|
6
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
7
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
8
|
+
export interface DefineSpaceLabelMutationPathParams {
|
|
9
|
+
space_ref: string;
|
|
10
|
+
}
|
|
11
|
+
export type DefineSpaceLabelRequestBody = {
|
|
12
|
+
color?: EnumLabelColor;
|
|
13
|
+
description?: string;
|
|
14
|
+
key?: string;
|
|
15
|
+
type?: EnumLabelType;
|
|
16
|
+
};
|
|
17
|
+
export type DefineSpaceLabelOkResponse = ResponseWithPagination<TypesLabel>;
|
|
18
|
+
export type DefineSpaceLabelErrorResponse = UsererrorError;
|
|
19
|
+
export interface DefineSpaceLabelProps extends DefineSpaceLabelMutationPathParams, Omit<FetcherOptions<unknown, DefineSpaceLabelRequestBody>, 'url'> {
|
|
20
|
+
body: DefineSpaceLabelRequestBody;
|
|
21
|
+
}
|
|
22
|
+
export declare function defineSpaceLabel(props: DefineSpaceLabelProps): Promise<DefineSpaceLabelOkResponse>;
|
|
23
|
+
export declare function useDefineSpaceLabelMutation(options?: Omit<UseMutationOptions<DefineSpaceLabelOkResponse, DefineSpaceLabelErrorResponse, DefineSpaceLabelProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<DefineSpaceLabelOkResponse, UsererrorError, DefineSpaceLabelProps, unknown>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useMutation } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function defineSpaceLabel(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/labels`, method: 'POST' }, props));
|
|
8
|
+
}
|
|
9
|
+
export function useDefineSpaceLabelMutation(options) {
|
|
10
|
+
return useMutation((mutateProps) => defineSpaceLabel(mutateProps), options);
|
|
11
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { TypesLabelValue } from '../schemas/TypesLabelValue';
|
|
3
|
+
import type { UsererrorError } from '../schemas/UsererrorError';
|
|
4
|
+
import type { EnumLabelColor } from '../schemas/EnumLabelColor';
|
|
5
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
6
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
7
|
+
export interface DefineSpaceLabelValueMutationPathParams {
|
|
8
|
+
space_ref: string;
|
|
9
|
+
key: string;
|
|
10
|
+
}
|
|
11
|
+
export type DefineSpaceLabelValueRequestBody = {
|
|
12
|
+
color?: EnumLabelColor;
|
|
13
|
+
value?: string;
|
|
14
|
+
};
|
|
15
|
+
export type DefineSpaceLabelValueOkResponse = ResponseWithPagination<TypesLabelValue>;
|
|
16
|
+
export type DefineSpaceLabelValueErrorResponse = UsererrorError;
|
|
17
|
+
export interface DefineSpaceLabelValueProps extends DefineSpaceLabelValueMutationPathParams, Omit<FetcherOptions<unknown, DefineSpaceLabelValueRequestBody>, 'url'> {
|
|
18
|
+
body: DefineSpaceLabelValueRequestBody;
|
|
19
|
+
}
|
|
20
|
+
export declare function defineSpaceLabelValue(props: DefineSpaceLabelValueProps): Promise<DefineSpaceLabelValueOkResponse>;
|
|
21
|
+
export declare function useDefineSpaceLabelValueMutation(options?: Omit<UseMutationOptions<DefineSpaceLabelValueOkResponse, DefineSpaceLabelValueErrorResponse, DefineSpaceLabelValueProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<DefineSpaceLabelValueOkResponse, UsererrorError, DefineSpaceLabelValueProps, unknown>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useMutation } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function defineSpaceLabelValue(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/labels/${props.key}/values`, method: 'POST' }, props));
|
|
8
|
+
}
|
|
9
|
+
export function useDefineSpaceLabelValueMutation(options) {
|
|
10
|
+
return useMutation((mutateProps) => defineSpaceLabelValue(mutateProps), options);
|
|
11
|
+
}
|
|
@@ -11,9 +11,13 @@ export interface DeleteArtifactMutationPathParams {
|
|
|
11
11
|
registry_ref: string;
|
|
12
12
|
artifact: string;
|
|
13
13
|
}
|
|
14
|
+
export interface DeleteArtifactMutationQueryParams {
|
|
15
|
+
artifact_type?: 'DATASET' | 'MODEL';
|
|
16
|
+
}
|
|
14
17
|
export type DeleteArtifactOkResponse = ResponseWithPagination<SuccessResponse>;
|
|
15
18
|
export type DeleteArtifactErrorResponse = BadRequestResponse | UnauthenticatedResponse | UnauthorizedResponse | NotFoundResponse | InternalServerErrorResponse;
|
|
16
|
-
export interface DeleteArtifactProps extends DeleteArtifactMutationPathParams, Omit<FetcherOptions<
|
|
19
|
+
export interface DeleteArtifactProps extends DeleteArtifactMutationPathParams, Omit<FetcherOptions<DeleteArtifactMutationQueryParams, unknown>, 'url'> {
|
|
20
|
+
queryParams: DeleteArtifactMutationQueryParams;
|
|
17
21
|
}
|
|
18
22
|
export declare function deleteArtifact(props: DeleteArtifactProps): Promise<DeleteArtifactOkResponse>;
|
|
19
23
|
/**
|
|
@@ -12,9 +12,13 @@ export interface DeleteArtifactVersionMutationPathParams {
|
|
|
12
12
|
artifact: string;
|
|
13
13
|
version: string;
|
|
14
14
|
}
|
|
15
|
+
export interface DeleteArtifactVersionMutationQueryParams {
|
|
16
|
+
artifact_type?: 'DATASET' | 'MODEL';
|
|
17
|
+
}
|
|
15
18
|
export type DeleteArtifactVersionOkResponse = ResponseWithPagination<SuccessResponse>;
|
|
16
19
|
export type DeleteArtifactVersionErrorResponse = BadRequestResponse | UnauthenticatedResponse | UnauthorizedResponse | NotFoundResponse | InternalServerErrorResponse;
|
|
17
|
-
export interface DeleteArtifactVersionProps extends DeleteArtifactVersionMutationPathParams, Omit<FetcherOptions<
|
|
20
|
+
export interface DeleteArtifactVersionProps extends DeleteArtifactVersionMutationPathParams, Omit<FetcherOptions<DeleteArtifactVersionMutationQueryParams, unknown>, 'url'> {
|
|
21
|
+
queryParams: DeleteArtifactVersionMutationQueryParams;
|
|
18
22
|
}
|
|
19
23
|
export declare function deleteArtifactVersion(props: DeleteArtifactVersionProps): Promise<DeleteArtifactVersionOkResponse>;
|
|
20
24
|
/**
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { SuccessResponse } from '../responses/SuccessResponse';
|
|
3
|
+
import type { BadRequestResponse } from '../responses/BadRequestResponse';
|
|
4
|
+
import type { UnauthenticatedResponse } from '../responses/UnauthenticatedResponse';
|
|
5
|
+
import type { UnauthorizedResponse } from '../responses/UnauthorizedResponse';
|
|
6
|
+
import type { InternalServerErrorResponse } from '../responses/InternalServerErrorResponse';
|
|
7
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
8
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
9
|
+
export interface DeleteQuarantineFilePathMutationPathParams {
|
|
10
|
+
registry_ref: string;
|
|
11
|
+
}
|
|
12
|
+
export interface DeleteQuarantineFilePathMutationQueryParams {
|
|
13
|
+
artifact?: string;
|
|
14
|
+
version?: string;
|
|
15
|
+
file_path?: string;
|
|
16
|
+
}
|
|
17
|
+
export type DeleteQuarantineFilePathOkResponse = ResponseWithPagination<SuccessResponse>;
|
|
18
|
+
export type DeleteQuarantineFilePathErrorResponse = BadRequestResponse | UnauthenticatedResponse | UnauthorizedResponse | InternalServerErrorResponse;
|
|
19
|
+
export interface DeleteQuarantineFilePathProps extends DeleteQuarantineFilePathMutationPathParams, Omit<FetcherOptions<DeleteQuarantineFilePathMutationQueryParams, unknown>, 'url'> {
|
|
20
|
+
queryParams: DeleteQuarantineFilePathMutationQueryParams;
|
|
21
|
+
}
|
|
22
|
+
export declare function deleteQuarantineFilePath(props: DeleteQuarantineFilePathProps): Promise<DeleteQuarantineFilePathOkResponse>;
|
|
23
|
+
/**
|
|
24
|
+
* delete Quarantine file path
|
|
25
|
+
*/
|
|
26
|
+
export declare function useDeleteQuarantineFilePathMutation(options?: Omit<UseMutationOptions<DeleteQuarantineFilePathOkResponse, DeleteQuarantineFilePathErrorResponse, DeleteQuarantineFilePathProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<DeleteQuarantineFilePathOkResponse, import("..").Error, DeleteQuarantineFilePathProps, unknown>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useMutation } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function deleteQuarantineFilePath(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/registry/${props.registry_ref}/quarantine`, method: 'DELETE' }, props));
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* delete Quarantine file path
|
|
11
|
+
*/
|
|
12
|
+
export function useDeleteQuarantineFilePathMutation(options) {
|
|
13
|
+
return useMutation((mutateProps) => deleteQuarantineFilePath(mutateProps), options);
|
|
14
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { UsererrorError } from '../schemas/UsererrorError';
|
|
3
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
4
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
5
|
+
export interface DeleteSpaceLabelMutationPathParams {
|
|
6
|
+
space_ref: string;
|
|
7
|
+
key: string;
|
|
8
|
+
}
|
|
9
|
+
export type DeleteSpaceLabelOkResponse = ResponseWithPagination<unknown>;
|
|
10
|
+
export type DeleteSpaceLabelErrorResponse = UsererrorError;
|
|
11
|
+
export interface DeleteSpaceLabelProps extends DeleteSpaceLabelMutationPathParams, Omit<FetcherOptions<unknown, unknown>, 'url'> {
|
|
12
|
+
}
|
|
13
|
+
export declare function deleteSpaceLabel(props: DeleteSpaceLabelProps): Promise<DeleteSpaceLabelOkResponse>;
|
|
14
|
+
export declare function useDeleteSpaceLabelMutation(options?: Omit<UseMutationOptions<DeleteSpaceLabelOkResponse, DeleteSpaceLabelErrorResponse, DeleteSpaceLabelProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<DeleteSpaceLabelOkResponse, UsererrorError, DeleteSpaceLabelProps, unknown>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useMutation } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function deleteSpaceLabel(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/labels/${props.key}`, method: 'DELETE' }, props));
|
|
8
|
+
}
|
|
9
|
+
export function useDeleteSpaceLabelMutation(options) {
|
|
10
|
+
return useMutation((mutateProps) => deleteSpaceLabel(mutateProps), options);
|
|
11
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { UsererrorError } from '../schemas/UsererrorError';
|
|
3
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
4
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
5
|
+
export interface DeleteSpaceLabelValueMutationPathParams {
|
|
6
|
+
space_ref: string;
|
|
7
|
+
key: string;
|
|
8
|
+
value: string;
|
|
9
|
+
}
|
|
10
|
+
export type DeleteSpaceLabelValueOkResponse = ResponseWithPagination<unknown>;
|
|
11
|
+
export type DeleteSpaceLabelValueErrorResponse = UsererrorError;
|
|
12
|
+
export interface DeleteSpaceLabelValueProps extends DeleteSpaceLabelValueMutationPathParams, Omit<FetcherOptions<unknown, unknown>, 'url'> {
|
|
13
|
+
}
|
|
14
|
+
export declare function deleteSpaceLabelValue(props: DeleteSpaceLabelValueProps): Promise<DeleteSpaceLabelValueOkResponse>;
|
|
15
|
+
export declare function useDeleteSpaceLabelValueMutation(options?: Omit<UseMutationOptions<DeleteSpaceLabelValueOkResponse, DeleteSpaceLabelValueErrorResponse, DeleteSpaceLabelValueProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<DeleteSpaceLabelValueOkResponse, UsererrorError, DeleteSpaceLabelValueProps, unknown>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useMutation } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function deleteSpaceLabelValue(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/labels/${props.key}/values/${props.value}`, method: 'DELETE' }, props));
|
|
8
|
+
}
|
|
9
|
+
export function useDeleteSpaceLabelValueMutation(options) {
|
|
10
|
+
return useMutation((mutateProps) => deleteSpaceLabelValue(mutateProps), options);
|
|
11
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { TypesLabelWithValues } from '../schemas/TypesLabelWithValues';
|
|
3
|
+
import type { UsererrorError } from '../schemas/UsererrorError';
|
|
4
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
5
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
6
|
+
export interface FindSpaceLabelQueryPathParams {
|
|
7
|
+
space_ref: string;
|
|
8
|
+
key: string;
|
|
9
|
+
}
|
|
10
|
+
export interface FindSpaceLabelQueryQueryParams {
|
|
11
|
+
include_values?: boolean;
|
|
12
|
+
}
|
|
13
|
+
export type FindSpaceLabelOkResponse = ResponseWithPagination<TypesLabelWithValues>;
|
|
14
|
+
export type FindSpaceLabelErrorResponse = UsererrorError;
|
|
15
|
+
export interface FindSpaceLabelProps extends FindSpaceLabelQueryPathParams, Omit<FetcherOptions<FindSpaceLabelQueryQueryParams, unknown>, 'url'> {
|
|
16
|
+
queryParams: FindSpaceLabelQueryQueryParams;
|
|
17
|
+
}
|
|
18
|
+
export declare function findSpaceLabel(props: FindSpaceLabelProps): Promise<FindSpaceLabelOkResponse>;
|
|
19
|
+
export declare function useFindSpaceLabelQuery(props: FindSpaceLabelProps, options?: Omit<UseQueryOptions<FindSpaceLabelOkResponse, FindSpaceLabelErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<FindSpaceLabelOkResponse, UsererrorError>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useQuery } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function findSpaceLabel(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/labels/${props.key}`, method: 'GET' }, props));
|
|
8
|
+
}
|
|
9
|
+
export function useFindSpaceLabelQuery(props, options) {
|
|
10
|
+
return useQuery(['findSpaceLabel', props.space_ref, props.key, props.queryParams], ({ signal }) => findSpaceLabel(Object.assign(Object.assign({}, props), { signal })), options);
|
|
11
|
+
}
|
|
@@ -25,6 +25,7 @@ export interface GetAllArtifactsByRegistryQueryQueryParams {
|
|
|
25
25
|
sort_order?: string;
|
|
26
26
|
sort_field?: string;
|
|
27
27
|
search_term?: string;
|
|
28
|
+
artifact_type?: 'DATASET' | 'MODEL';
|
|
28
29
|
}
|
|
29
30
|
export type GetAllArtifactsByRegistryOkResponse = ResponseWithPagination<ListRegistryArtifactResponseResponse>;
|
|
30
31
|
export type GetAllArtifactsByRegistryErrorResponse = BadRequestResponse | UnauthenticatedResponse | UnauthorizedResponse | NotFoundResponse | InternalServerErrorResponse;
|
|
@@ -27,6 +27,7 @@ export interface GetAllRegistriesQueryQueryParams {
|
|
|
27
27
|
sort_field?: string;
|
|
28
28
|
search_term?: string;
|
|
29
29
|
recursive?: boolean;
|
|
30
|
+
scope?: 'ancestors' | 'descendants' | 'none';
|
|
30
31
|
}
|
|
31
32
|
export type GetAllRegistriesOkResponse = ResponseWithPagination<ListRegistryResponseResponse>;
|
|
32
33
|
export type GetAllRegistriesErrorResponse = BadRequestResponse | UnauthenticatedResponse | UnauthorizedResponse | NotFoundResponse | InternalServerErrorResponse;
|
|
@@ -35,6 +36,6 @@ export interface GetAllRegistriesProps extends GetAllRegistriesQueryPathParams,
|
|
|
35
36
|
}
|
|
36
37
|
export declare function getAllRegistries(props: GetAllRegistriesProps): Promise<GetAllRegistriesOkResponse>;
|
|
37
38
|
/**
|
|
38
|
-
* Lists all the
|
|
39
|
+
* Lists all the registries.
|
|
39
40
|
*/
|
|
40
41
|
export declare function useGetAllRegistriesQuery(props: GetAllRegistriesProps, options?: Omit<UseQueryOptions<GetAllRegistriesOkResponse, GetAllRegistriesErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<GetAllRegistriesOkResponse, import("..").Error>;
|
|
@@ -7,7 +7,7 @@ export function getAllRegistries(props) {
|
|
|
7
7
|
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/registries`, method: 'GET' }, props));
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* Lists all the
|
|
10
|
+
* Lists all the registries.
|
|
11
11
|
*/
|
|
12
12
|
export function useGetAllRegistriesQuery(props, options) {
|
|
13
13
|
return useQuery(['GetAllRegistries', props.space_ref, props.queryParams], ({ signal }) => getAllRegistries(Object.assign(Object.assign({}, props), { signal })), options);
|
|
@@ -13,6 +13,7 @@ export interface GetArtifactDetailsQueryPathParams {
|
|
|
13
13
|
version: string;
|
|
14
14
|
}
|
|
15
15
|
export interface GetArtifactDetailsQueryQueryParams {
|
|
16
|
+
artifact_type?: 'DATASET' | 'MODEL';
|
|
16
17
|
childVersion?: string;
|
|
17
18
|
}
|
|
18
19
|
export type GetArtifactDetailsOkResponse = ResponseWithPagination<ArtifactDetailResponseResponse>;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { ArtifactFileResponseResponse } from '../responses/ArtifactFileResponseResponse';
|
|
3
|
+
import type { BadRequestResponse } from '../responses/BadRequestResponse';
|
|
4
|
+
import type { UnauthenticatedResponse } from '../responses/UnauthenticatedResponse';
|
|
5
|
+
import type { UnauthorizedResponse } from '../responses/UnauthorizedResponse';
|
|
6
|
+
import type { NotFoundResponse } from '../responses/NotFoundResponse';
|
|
7
|
+
import type { InternalServerErrorResponse } from '../responses/InternalServerErrorResponse';
|
|
8
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
9
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
10
|
+
export interface GetArtifactFileQueryPathParams {
|
|
11
|
+
registry_ref: string;
|
|
12
|
+
artifact: string;
|
|
13
|
+
version: string;
|
|
14
|
+
file_name: string;
|
|
15
|
+
}
|
|
16
|
+
export interface GetArtifactFileQueryQueryParams {
|
|
17
|
+
artifact_type?: 'DATASET' | 'MODEL';
|
|
18
|
+
}
|
|
19
|
+
export type GetArtifactFileOkResponse = ResponseWithPagination<ArtifactFileResponseResponse>;
|
|
20
|
+
export type GetArtifactFileErrorResponse = BadRequestResponse | UnauthenticatedResponse | UnauthorizedResponse | NotFoundResponse | InternalServerErrorResponse;
|
|
21
|
+
export interface GetArtifactFileProps extends GetArtifactFileQueryPathParams, Omit<FetcherOptions<GetArtifactFileQueryQueryParams, unknown>, 'url'> {
|
|
22
|
+
queryParams: GetArtifactFileQueryQueryParams;
|
|
23
|
+
}
|
|
24
|
+
export declare function getArtifactFile(props: GetArtifactFileProps): Promise<GetArtifactFileOkResponse>;
|
|
25
|
+
/**
|
|
26
|
+
* just validate existence of Artifact file
|
|
27
|
+
*/
|
|
28
|
+
export declare function useGetArtifactFileQuery(props: GetArtifactFileProps, options?: Omit<UseQueryOptions<GetArtifactFileOkResponse, GetArtifactFileErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<GetArtifactFileOkResponse, import("..").Error>;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useQuery } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function getArtifactFile(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/registry/${props.registry_ref}/artifact/${props.artifact}/version/${props.version}/file/${props.file_name}`, method: 'GET' }, props));
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* just validate existence of Artifact file
|
|
11
|
+
*/
|
|
12
|
+
export function useGetArtifactFileQuery(props, options) {
|
|
13
|
+
return useQuery([
|
|
14
|
+
'GetArtifactFile',
|
|
15
|
+
props.registry_ref,
|
|
16
|
+
props.artifact,
|
|
17
|
+
props.version,
|
|
18
|
+
props.file_name,
|
|
19
|
+
props.queryParams,
|
|
20
|
+
], ({ signal }) => getArtifactFile(Object.assign(Object.assign({}, props), { signal })), options);
|
|
21
|
+
}
|
|
@@ -21,6 +21,6 @@ export interface GetArtifactStatsForSpaceProps extends GetArtifactStatsForSpaceQ
|
|
|
21
21
|
}
|
|
22
22
|
export declare function getArtifactStatsForSpace(props: GetArtifactStatsForSpaceProps): Promise<GetArtifactStatsForSpaceOkResponse>;
|
|
23
23
|
/**
|
|
24
|
-
* Get
|
|
24
|
+
* Get artifact stats
|
|
25
25
|
*/
|
|
26
26
|
export declare function useGetArtifactStatsForSpaceQuery(props: GetArtifactStatsForSpaceProps, options?: Omit<UseQueryOptions<GetArtifactStatsForSpaceOkResponse, GetArtifactStatsForSpaceErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<GetArtifactStatsForSpaceOkResponse, import("..").Error>;
|
|
@@ -7,7 +7,7 @@ export function getArtifactStatsForSpace(props) {
|
|
|
7
7
|
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/artifact/stats`, method: 'GET' }, props));
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* Get
|
|
10
|
+
* Get artifact stats
|
|
11
11
|
*/
|
|
12
12
|
export function useGetArtifactStatsForSpaceQuery(props, options) {
|
|
13
13
|
return useQuery(['GetArtifactStatsForSpace', props.space_ref, props.queryParams], ({ signal }) => getArtifactStatsForSpace(Object.assign(Object.assign({}, props), { signal })), options);
|
|
@@ -11,9 +11,13 @@ export interface GetArtifactSummaryQueryPathParams {
|
|
|
11
11
|
registry_ref: string;
|
|
12
12
|
artifact: string;
|
|
13
13
|
}
|
|
14
|
+
export interface GetArtifactSummaryQueryQueryParams {
|
|
15
|
+
artifact_type?: 'DATASET' | 'MODEL';
|
|
16
|
+
}
|
|
14
17
|
export type GetArtifactSummaryOkResponse = ResponseWithPagination<ArtifactSummaryResponseResponse>;
|
|
15
18
|
export type GetArtifactSummaryErrorResponse = BadRequestResponse | UnauthenticatedResponse | UnauthorizedResponse | NotFoundResponse | InternalServerErrorResponse;
|
|
16
|
-
export interface GetArtifactSummaryProps extends GetArtifactSummaryQueryPathParams, Omit<FetcherOptions<
|
|
19
|
+
export interface GetArtifactSummaryProps extends GetArtifactSummaryQueryPathParams, Omit<FetcherOptions<GetArtifactSummaryQueryQueryParams, unknown>, 'url'> {
|
|
20
|
+
queryParams: GetArtifactSummaryQueryQueryParams;
|
|
17
21
|
}
|
|
18
22
|
export declare function getArtifactSummary(props: GetArtifactSummaryProps): Promise<GetArtifactSummaryOkResponse>;
|
|
19
23
|
/**
|
|
@@ -10,5 +10,5 @@ export function getArtifactSummary(props) {
|
|
|
10
10
|
* Get Artifact Summary.
|
|
11
11
|
*/
|
|
12
12
|
export function useGetArtifactSummaryQuery(props, options) {
|
|
13
|
-
return useQuery(['GetArtifactSummary', props.registry_ref, props.artifact], ({ signal }) => getArtifactSummary(Object.assign(Object.assign({}, props), { signal })), options);
|
|
13
|
+
return useQuery(['GetArtifactSummary', props.registry_ref, props.artifact, props.queryParams], ({ signal }) => getArtifactSummary(Object.assign(Object.assign({}, props), { signal })), options);
|
|
14
14
|
}
|
|
@@ -14,6 +14,7 @@ export interface GetArtifactVersionSummaryQueryPathParams {
|
|
|
14
14
|
}
|
|
15
15
|
export interface GetArtifactVersionSummaryQueryQueryParams {
|
|
16
16
|
digest?: string;
|
|
17
|
+
artifact_type?: 'DATASET' | 'MODEL';
|
|
17
18
|
}
|
|
18
19
|
export type GetArtifactVersionSummaryOkResponse = ResponseWithPagination<ArtifactVersionSummaryResponseResponse>;
|
|
19
20
|
export type GetArtifactVersionSummaryErrorResponse = BadRequestResponse | UnauthenticatedResponse | UnauthorizedResponse | NotFoundResponse | InternalServerErrorResponse;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { TypesLabelValue } from '../schemas/TypesLabelValue';
|
|
3
|
+
import type { UsererrorError } from '../schemas/UsererrorError';
|
|
4
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
5
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
6
|
+
export interface ListSpaceLabelValuesQueryPathParams {
|
|
7
|
+
space_ref: string;
|
|
8
|
+
key: string;
|
|
9
|
+
}
|
|
10
|
+
export type ListSpaceLabelValuesOkResponse = ResponseWithPagination<TypesLabelValue[]>;
|
|
11
|
+
export type ListSpaceLabelValuesErrorResponse = UsererrorError;
|
|
12
|
+
export interface ListSpaceLabelValuesProps extends ListSpaceLabelValuesQueryPathParams, Omit<FetcherOptions<unknown, unknown>, 'url'> {
|
|
13
|
+
}
|
|
14
|
+
export declare function listSpaceLabelValues(props: ListSpaceLabelValuesProps): Promise<ListSpaceLabelValuesOkResponse>;
|
|
15
|
+
export declare function useListSpaceLabelValuesQuery(props: ListSpaceLabelValuesProps, options?: Omit<UseQueryOptions<ListSpaceLabelValuesOkResponse, ListSpaceLabelValuesErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<ListSpaceLabelValuesOkResponse, UsererrorError>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useQuery } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function listSpaceLabelValues(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/labels/${props.key}/values`, method: 'GET' }, props));
|
|
8
|
+
}
|
|
9
|
+
export function useListSpaceLabelValuesQuery(props, options) {
|
|
10
|
+
return useQuery(['listSpaceLabelValues', props.space_ref, props.key], ({ signal }) => listSpaceLabelValues(Object.assign(Object.assign({}, props), { signal })), options);
|
|
11
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { TypesLabel } from '../schemas/TypesLabel';
|
|
3
|
+
import type { UsererrorError } from '../schemas/UsererrorError';
|
|
4
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
5
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
6
|
+
export interface ListSpaceLabelsQueryPathParams {
|
|
7
|
+
space_ref: string;
|
|
8
|
+
}
|
|
9
|
+
export interface ListSpaceLabelsQueryQueryParams {
|
|
10
|
+
/**
|
|
11
|
+
* @default 1
|
|
12
|
+
*/
|
|
13
|
+
page?: number;
|
|
14
|
+
/**
|
|
15
|
+
* @default 30
|
|
16
|
+
*/
|
|
17
|
+
limit?: number;
|
|
18
|
+
inherited?: boolean;
|
|
19
|
+
query?: string;
|
|
20
|
+
}
|
|
21
|
+
export type ListSpaceLabelsOkResponse = ResponseWithPagination<TypesLabel[]>;
|
|
22
|
+
export type ListSpaceLabelsErrorResponse = UsererrorError;
|
|
23
|
+
export interface ListSpaceLabelsProps extends ListSpaceLabelsQueryPathParams, Omit<FetcherOptions<ListSpaceLabelsQueryQueryParams, unknown>, 'url'> {
|
|
24
|
+
queryParams: ListSpaceLabelsQueryQueryParams;
|
|
25
|
+
}
|
|
26
|
+
export declare function listSpaceLabels(props: ListSpaceLabelsProps): Promise<ListSpaceLabelsOkResponse>;
|
|
27
|
+
export declare function useListSpaceLabelsQuery(props: ListSpaceLabelsProps, options?: Omit<UseQueryOptions<ListSpaceLabelsOkResponse, ListSpaceLabelsErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<ListSpaceLabelsOkResponse, UsererrorError>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useQuery } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function listSpaceLabels(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/labels`, method: 'GET' }, props));
|
|
8
|
+
}
|
|
9
|
+
export function useListSpaceLabelsQuery(props, options) {
|
|
10
|
+
return useQuery(['listSpaceLabels', props.space_ref, props.queryParams], ({ signal }) => listSpaceLabels(Object.assign(Object.assign({}, props), { signal })), options);
|
|
11
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { QuarantinePathResponseResponse } from '../responses/QuarantinePathResponseResponse';
|
|
3
|
+
import type { BadRequestResponse } from '../responses/BadRequestResponse';
|
|
4
|
+
import type { UnauthenticatedResponse } from '../responses/UnauthenticatedResponse';
|
|
5
|
+
import type { UnauthorizedResponse } from '../responses/UnauthorizedResponse';
|
|
6
|
+
import type { InternalServerErrorResponse } from '../responses/InternalServerErrorResponse';
|
|
7
|
+
import type { QuarantineRequestRequestBody } from '../requestBodies/QuarantineRequestRequestBody';
|
|
8
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
9
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
10
|
+
export interface QuarantineFilePathMutationPathParams {
|
|
11
|
+
registry_ref: string;
|
|
12
|
+
}
|
|
13
|
+
export type QuarantineFilePathRequestBody = QuarantineRequestRequestBody;
|
|
14
|
+
export type QuarantineFilePathOkResponse = ResponseWithPagination<QuarantinePathResponseResponse>;
|
|
15
|
+
export type QuarantineFilePathErrorResponse = BadRequestResponse | UnauthenticatedResponse | UnauthorizedResponse | InternalServerErrorResponse;
|
|
16
|
+
export interface QuarantineFilePathProps extends QuarantineFilePathMutationPathParams, Omit<FetcherOptions<unknown, QuarantineFilePathRequestBody>, 'url'> {
|
|
17
|
+
body: QuarantineFilePathRequestBody;
|
|
18
|
+
}
|
|
19
|
+
export declare function quarantineFilePath(props: QuarantineFilePathProps): Promise<QuarantineFilePathOkResponse>;
|
|
20
|
+
/**
|
|
21
|
+
* quarantine file path
|
|
22
|
+
*/
|
|
23
|
+
export declare function useQuarantineFilePathMutation(options?: Omit<UseMutationOptions<QuarantineFilePathOkResponse, QuarantineFilePathErrorResponse, QuarantineFilePathProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<QuarantineFilePathOkResponse, import("..").Error, QuarantineFilePathProps, unknown>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useMutation } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function quarantineFilePath(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/registry/${props.registry_ref}/quarantine`, method: 'PUT' }, props));
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* quarantine file path
|
|
11
|
+
*/
|
|
12
|
+
export function useQuarantineFilePathMutation(options) {
|
|
13
|
+
return useMutation((mutateProps) => quarantineFilePath(mutateProps), options);
|
|
14
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { TypesLabelWithValues } from '../schemas/TypesLabelWithValues';
|
|
3
|
+
import type { UsererrorError } from '../schemas/UsererrorError';
|
|
4
|
+
import type { TypesSaveLabelInput } from '../schemas/TypesSaveLabelInput';
|
|
5
|
+
import type { TypesSaveLabelValueInput } from '../schemas/TypesSaveLabelValueInput';
|
|
6
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
7
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
8
|
+
export interface SaveSpaceLabelMutationPathParams {
|
|
9
|
+
space_ref: string;
|
|
10
|
+
}
|
|
11
|
+
export type SaveSpaceLabelRequestBody = {
|
|
12
|
+
label?: TypesSaveLabelInput;
|
|
13
|
+
values?: TypesSaveLabelValueInput[];
|
|
14
|
+
};
|
|
15
|
+
export type SaveSpaceLabelOkResponse = ResponseWithPagination<TypesLabelWithValues>;
|
|
16
|
+
export type SaveSpaceLabelErrorResponse = UsererrorError;
|
|
17
|
+
export interface SaveSpaceLabelProps extends SaveSpaceLabelMutationPathParams, Omit<FetcherOptions<unknown, SaveSpaceLabelRequestBody>, 'url'> {
|
|
18
|
+
body: SaveSpaceLabelRequestBody;
|
|
19
|
+
}
|
|
20
|
+
export declare function saveSpaceLabel(props: SaveSpaceLabelProps): Promise<SaveSpaceLabelOkResponse>;
|
|
21
|
+
export declare function useSaveSpaceLabelMutation(options?: Omit<UseMutationOptions<SaveSpaceLabelOkResponse, SaveSpaceLabelErrorResponse, SaveSpaceLabelProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<SaveSpaceLabelOkResponse, UsererrorError, SaveSpaceLabelProps, unknown>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useMutation } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function saveSpaceLabel(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/labels`, method: 'PUT' }, props));
|
|
8
|
+
}
|
|
9
|
+
export function useSaveSpaceLabelMutation(options) {
|
|
10
|
+
return useMutation((mutateProps) => saveSpaceLabel(mutateProps), options);
|
|
11
|
+
}
|
|
@@ -12,10 +12,14 @@ export interface UpdateArtifactLabelsMutationPathParams {
|
|
|
12
12
|
registry_ref: string;
|
|
13
13
|
artifact: string;
|
|
14
14
|
}
|
|
15
|
+
export interface UpdateArtifactLabelsMutationQueryParams {
|
|
16
|
+
artifact_type?: 'DATASET' | 'MODEL';
|
|
17
|
+
}
|
|
15
18
|
export type UpdateArtifactLabelsRequestBody = ArtifactLabelRequestRequestBody;
|
|
16
19
|
export type UpdateArtifactLabelsOkResponse = ResponseWithPagination<ArtifactLabelResponseResponse>;
|
|
17
20
|
export type UpdateArtifactLabelsErrorResponse = BadRequestResponse | UnauthenticatedResponse | UnauthorizedResponse | NotFoundResponse | InternalServerErrorResponse;
|
|
18
|
-
export interface UpdateArtifactLabelsProps extends UpdateArtifactLabelsMutationPathParams, Omit<FetcherOptions<
|
|
21
|
+
export interface UpdateArtifactLabelsProps extends UpdateArtifactLabelsMutationPathParams, Omit<FetcherOptions<UpdateArtifactLabelsMutationQueryParams, UpdateArtifactLabelsRequestBody>, 'url'> {
|
|
22
|
+
queryParams: UpdateArtifactLabelsMutationQueryParams;
|
|
19
23
|
body: UpdateArtifactLabelsRequestBody;
|
|
20
24
|
}
|
|
21
25
|
export declare function updateArtifactLabels(props: UpdateArtifactLabelsProps): Promise<UpdateArtifactLabelsOkResponse>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { TypesLabel } from '../schemas/TypesLabel';
|
|
3
|
+
import type { UsererrorError } from '../schemas/UsererrorError';
|
|
4
|
+
import type { EnumLabelColor } from '../schemas/EnumLabelColor';
|
|
5
|
+
import type { EnumLabelType } from '../schemas/EnumLabelType';
|
|
6
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
7
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
8
|
+
export interface UpdateSpaceLabelMutationPathParams {
|
|
9
|
+
space_ref: string;
|
|
10
|
+
key: string;
|
|
11
|
+
}
|
|
12
|
+
export type UpdateSpaceLabelRequestBody = {
|
|
13
|
+
color?: EnumLabelColor;
|
|
14
|
+
description?: string;
|
|
15
|
+
key?: string;
|
|
16
|
+
type?: EnumLabelType;
|
|
17
|
+
};
|
|
18
|
+
export type UpdateSpaceLabelOkResponse = ResponseWithPagination<TypesLabel>;
|
|
19
|
+
export type UpdateSpaceLabelErrorResponse = UsererrorError;
|
|
20
|
+
export interface UpdateSpaceLabelProps extends UpdateSpaceLabelMutationPathParams, Omit<FetcherOptions<unknown, UpdateSpaceLabelRequestBody>, 'url'> {
|
|
21
|
+
body: UpdateSpaceLabelRequestBody;
|
|
22
|
+
}
|
|
23
|
+
export declare function updateSpaceLabel(props: UpdateSpaceLabelProps): Promise<UpdateSpaceLabelOkResponse>;
|
|
24
|
+
export declare function useUpdateSpaceLabelMutation(options?: Omit<UseMutationOptions<UpdateSpaceLabelOkResponse, UpdateSpaceLabelErrorResponse, UpdateSpaceLabelProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<UpdateSpaceLabelOkResponse, UsererrorError, UpdateSpaceLabelProps, unknown>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useMutation } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function updateSpaceLabel(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/spaces/${props.space_ref}/labels/${props.key}`, method: 'PATCH' }, props));
|
|
8
|
+
}
|
|
9
|
+
export function useUpdateSpaceLabelMutation(options) {
|
|
10
|
+
return useMutation((mutateProps) => updateSpaceLabel(mutateProps), options);
|
|
11
|
+
}
|