@harnessio/react-ssca-manager-client 0.14.0 → 0.17.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.
Files changed (54) hide show
  1. package/dist/ssca-manager/src/services/hooks/useCalculateDriftForArtifactMutation.d.ts +24 -0
  2. package/dist/ssca-manager/src/services/hooks/useCalculateDriftForArtifactMutation.js +14 -0
  3. package/dist/ssca-manager/src/services/hooks/useGetBaselineForArtifactQuery.d.ts +21 -0
  4. package/dist/ssca-manager/src/services/hooks/useGetBaselineForArtifactQuery.js +14 -0
  5. package/dist/ssca-manager/src/services/hooks/useGetComponentDriftQuery.d.ts +34 -0
  6. package/dist/ssca-manager/src/services/hooks/useGetComponentDriftQuery.js +14 -0
  7. package/dist/ssca-manager/src/services/hooks/useGetLicenseDriftQuery.d.ts +34 -0
  8. package/dist/ssca-manager/src/services/hooks/useGetLicenseDriftQuery.js +14 -0
  9. package/dist/ssca-manager/src/services/hooks/useGetSbomScorecardQuery.d.ts +21 -0
  10. package/dist/ssca-manager/src/services/hooks/useGetSbomScorecardQuery.js +14 -0
  11. package/dist/ssca-manager/src/services/hooks/useSetBaselineForArtifactMutation.d.ts +24 -0
  12. package/dist/ssca-manager/src/services/hooks/useSetBaselineForArtifactMutation.js +14 -0
  13. package/dist/ssca-manager/src/services/index.d.ts +31 -0
  14. package/dist/ssca-manager/src/services/index.js +6 -0
  15. package/dist/ssca-manager/src/services/requestBodies/BaselineRequestBodyRequestBody.d.ts +2 -0
  16. package/dist/ssca-manager/src/services/requestBodies/BaselineRequestBodyRequestBody.js +1 -0
  17. package/dist/ssca-manager/src/services/responses/ArtifactSbomDriftResponseBodyResponse.d.ts +2 -0
  18. package/dist/ssca-manager/src/services/responses/ArtifactSbomDriftResponseBodyResponse.js +1 -0
  19. package/dist/ssca-manager/src/services/responses/BaselineResponseBodyResponse.d.ts +2 -0
  20. package/dist/ssca-manager/src/services/responses/BaselineResponseBodyResponse.js +1 -0
  21. package/dist/ssca-manager/src/services/responses/ComponentDriftResponseBodyResponse.d.ts +2 -0
  22. package/dist/ssca-manager/src/services/responses/ComponentDriftResponseBodyResponse.js +1 -0
  23. package/dist/ssca-manager/src/services/responses/LicenseDriftResponseBodyResponse.d.ts +2 -0
  24. package/dist/ssca-manager/src/services/responses/LicenseDriftResponseBodyResponse.js +1 -0
  25. package/dist/ssca-manager/src/services/responses/SaveResponseResponse.d.ts +2 -0
  26. package/dist/ssca-manager/src/services/responses/SaveResponseResponse.js +1 -0
  27. package/dist/ssca-manager/src/services/responses/SbomScorecardResponseBodyResponse.d.ts +2 -0
  28. package/dist/ssca-manager/src/services/responses/SbomScorecardResponseBodyResponse.js +1 -0
  29. package/dist/ssca-manager/src/services/schemas/ArtifactListingResponse.d.ts +1 -0
  30. package/dist/ssca-manager/src/services/schemas/ArtifactSbomDriftRequestBody.d.ts +13 -0
  31. package/dist/ssca-manager/src/services/schemas/ArtifactSbomDriftRequestBody.js +4 -0
  32. package/dist/ssca-manager/src/services/schemas/ArtifactSbomDriftResponse.d.ts +21 -0
  33. package/dist/ssca-manager/src/services/schemas/ArtifactSbomDriftResponse.js +4 -0
  34. package/dist/ssca-manager/src/services/schemas/BaselineRequestBody.d.ts +6 -0
  35. package/dist/ssca-manager/src/services/schemas/BaselineRequestBody.js +4 -0
  36. package/dist/ssca-manager/src/services/schemas/BaselineResponseBody.d.ts +10 -0
  37. package/dist/ssca-manager/src/services/schemas/BaselineResponseBody.js +4 -0
  38. package/dist/ssca-manager/src/services/schemas/CategoryScorecard.d.ts +14 -0
  39. package/dist/ssca-manager/src/services/schemas/CategoryScorecard.js +4 -0
  40. package/dist/ssca-manager/src/services/schemas/ComponentDrift.d.ts +12 -0
  41. package/dist/ssca-manager/src/services/schemas/ComponentDrift.js +1 -0
  42. package/dist/ssca-manager/src/services/schemas/ComponentSummary.d.ts +29 -0
  43. package/dist/ssca-manager/src/services/schemas/ComponentSummary.js +4 -0
  44. package/dist/ssca-manager/src/services/schemas/LicenseDrift.d.ts +16 -0
  45. package/dist/ssca-manager/src/services/schemas/LicenseDrift.js +1 -0
  46. package/dist/ssca-manager/src/services/schemas/SaveResponse.d.ts +6 -0
  47. package/dist/ssca-manager/src/services/schemas/SaveResponse.js +4 -0
  48. package/dist/ssca-manager/src/services/schemas/SbomDetailsForScorecard.d.ts +8 -0
  49. package/dist/ssca-manager/src/services/schemas/SbomDetailsForScorecard.js +4 -0
  50. package/dist/ssca-manager/src/services/schemas/SbomScorecardResponseBody.d.ts +15 -0
  51. package/dist/ssca-manager/src/services/schemas/SbomScorecardResponseBody.js +1 -0
  52. package/dist/ssca-manager/src/services/schemas/ScorecardInfo.d.ts +4 -0
  53. package/dist/ssca-manager/src/services/schemas/ScorecardInfo.js +4 -0
  54. package/package.json +1 -1
@@ -0,0 +1,24 @@
1
+ import { UseMutationOptions } from '@tanstack/react-query';
2
+ import type { ArtifactSbomDriftResponseBodyResponse } from '../responses/ArtifactSbomDriftResponseBodyResponse';
3
+ import type { ArtifactSbomDriftRequestBody } from '../schemas/ArtifactSbomDriftRequestBody';
4
+ import type { ResponseWithPagination } from '../helpers';
5
+ import { FetcherOptions } from '../../../../fetcher/index.js';
6
+ export interface CalculateDriftForArtifactMutationPathParams {
7
+ org: string;
8
+ project: string;
9
+ artifact: string;
10
+ }
11
+ export interface CalculateDriftForArtifactMutationHeaderParams {
12
+ 'Harness-Account'?: string;
13
+ }
14
+ export type CalculateDriftForArtifactRequestBody = ArtifactSbomDriftRequestBody;
15
+ export type CalculateDriftForArtifactOkResponse = ResponseWithPagination<ArtifactSbomDriftResponseBodyResponse>;
16
+ export type CalculateDriftForArtifactErrorResponse = unknown;
17
+ export interface CalculateDriftForArtifactProps extends CalculateDriftForArtifactMutationPathParams, Omit<FetcherOptions<unknown, CalculateDriftForArtifactRequestBody, CalculateDriftForArtifactMutationHeaderParams>, 'url'> {
18
+ body: CalculateDriftForArtifactRequestBody;
19
+ }
20
+ export declare function calculateDriftForArtifact(props: CalculateDriftForArtifactProps): Promise<CalculateDriftForArtifactOkResponse>;
21
+ /**
22
+ * This API calculates and stores drift between 2 versions of an artifact with TTL of 1 hour.
23
+ */
24
+ export declare function useCalculateDriftForArtifactMutation(options?: Omit<UseMutationOptions<CalculateDriftForArtifactOkResponse, CalculateDriftForArtifactErrorResponse, CalculateDriftForArtifactProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<CalculateDriftForArtifactOkResponse, unknown, CalculateDriftForArtifactProps, 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 calculateDriftForArtifact(props) {
7
+ return fetcher(Object.assign({ url: `/v1/orgs/${props.org}/projects/${props.project}/artifact/${props.artifact}/sbom-drift`, method: 'POST' }, props));
8
+ }
9
+ /**
10
+ * This API calculates and stores drift between 2 versions of an artifact with TTL of 1 hour.
11
+ */
12
+ export function useCalculateDriftForArtifactMutation(options) {
13
+ return useMutation((mutateProps) => calculateDriftForArtifact(mutateProps), options);
14
+ }
@@ -0,0 +1,21 @@
1
+ import { UseQueryOptions } from '@tanstack/react-query';
2
+ import type { BaselineResponseBodyResponse } from '../responses/BaselineResponseBodyResponse';
3
+ import type { ResponseWithPagination } from '../helpers';
4
+ import { FetcherOptions } from '../../../../fetcher/index.js';
5
+ export interface GetBaselineForArtifactQueryPathParams {
6
+ org: string;
7
+ project: string;
8
+ artifact: string;
9
+ }
10
+ export interface GetBaselineForArtifactQueryHeaderParams {
11
+ 'Harness-Account'?: string;
12
+ }
13
+ export type GetBaselineForArtifactOkResponse = ResponseWithPagination<BaselineResponseBodyResponse>;
14
+ export type GetBaselineForArtifactErrorResponse = unknown;
15
+ export interface GetBaselineForArtifactProps extends GetBaselineForArtifactQueryPathParams, Omit<FetcherOptions<unknown, unknown, GetBaselineForArtifactQueryHeaderParams>, 'url'> {
16
+ }
17
+ export declare function getBaselineForArtifact(props: GetBaselineForArtifactProps): Promise<GetBaselineForArtifactOkResponse>;
18
+ /**
19
+ * Get the baseline for an artifact
20
+ */
21
+ export declare function useGetBaselineForArtifactQuery(props: GetBaselineForArtifactProps, options?: Omit<UseQueryOptions<GetBaselineForArtifactOkResponse, GetBaselineForArtifactErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<GetBaselineForArtifactOkResponse, 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 { useQuery } from '@tanstack/react-query';
5
+ import { fetcher } from '../../../../fetcher/index.js';
6
+ export function getBaselineForArtifact(props) {
7
+ return fetcher(Object.assign({ url: `/v1/orgs/${props.org}/projects/${props.project}/artifact/${props.artifact}/baseline`, method: 'GET' }, props));
8
+ }
9
+ /**
10
+ * Get the baseline for an artifact
11
+ */
12
+ export function useGetBaselineForArtifactQuery(props, options) {
13
+ return useQuery(['getBaselineForArtifact', props.org, props.project, props.artifact], ({ signal }) => getBaselineForArtifact(Object.assign(Object.assign({}, props), { signal })), options);
14
+ }
@@ -0,0 +1,34 @@
1
+ import { UseQueryOptions } from '@tanstack/react-query';
2
+ import type { ComponentDriftResponseBodyResponse } from '../responses/ComponentDriftResponseBodyResponse';
3
+ import type { ResponseWithPagination } from '../helpers';
4
+ import { FetcherOptions } from '../../../../fetcher/index.js';
5
+ export interface GetComponentDriftQueryPathParams {
6
+ org: string;
7
+ project: string;
8
+ drift: string;
9
+ }
10
+ export interface GetComponentDriftQueryQueryParams {
11
+ status?: 'added' | 'all' | 'deleted' | 'modified';
12
+ /**
13
+ * @default 0
14
+ */
15
+ page?: number;
16
+ /**
17
+ * @default 30
18
+ */
19
+ limit?: number;
20
+ search_term?: string;
21
+ }
22
+ export interface GetComponentDriftQueryHeaderParams {
23
+ 'Harness-Account'?: string;
24
+ }
25
+ export type GetComponentDriftOkResponse = ResponseWithPagination<ComponentDriftResponseBodyResponse>;
26
+ export type GetComponentDriftErrorResponse = unknown;
27
+ export interface GetComponentDriftProps extends GetComponentDriftQueryPathParams, Omit<FetcherOptions<GetComponentDriftQueryQueryParams, unknown, GetComponentDriftQueryHeaderParams>, 'url'> {
28
+ queryParams: GetComponentDriftQueryQueryParams;
29
+ }
30
+ export declare function getComponentDrift(props: GetComponentDriftProps): Promise<GetComponentDriftOkResponse>;
31
+ /**
32
+ * Get component drift for provided drift ID.
33
+ */
34
+ export declare function useGetComponentDriftQuery(props: GetComponentDriftProps, options?: Omit<UseQueryOptions<GetComponentDriftOkResponse, GetComponentDriftErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<GetComponentDriftOkResponse, 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 { useQuery } from '@tanstack/react-query';
5
+ import { fetcher } from '../../../../fetcher/index.js';
6
+ export function getComponentDrift(props) {
7
+ return fetcher(Object.assign({ url: `/v1/orgs/${props.org}/projects/${props.project}/sbom-drift/${props.drift}/components`, method: 'GET' }, props));
8
+ }
9
+ /**
10
+ * Get component drift for provided drift ID.
11
+ */
12
+ export function useGetComponentDriftQuery(props, options) {
13
+ return useQuery(['getComponentDrift', props.org, props.project, props.drift, props.queryParams], ({ signal }) => getComponentDrift(Object.assign(Object.assign({}, props), { signal })), options);
14
+ }
@@ -0,0 +1,34 @@
1
+ import { UseQueryOptions } from '@tanstack/react-query';
2
+ import type { LicenseDriftResponseBodyResponse } from '../responses/LicenseDriftResponseBodyResponse';
3
+ import type { ResponseWithPagination } from '../helpers';
4
+ import { FetcherOptions } from '../../../../fetcher/index.js';
5
+ export interface GetLicenseDriftQueryPathParams {
6
+ org: string;
7
+ project: string;
8
+ drift: string;
9
+ }
10
+ export interface GetLicenseDriftQueryQueryParams {
11
+ status?: 'added' | 'all' | 'deleted';
12
+ /**
13
+ * @default 0
14
+ */
15
+ page?: number;
16
+ /**
17
+ * @default 30
18
+ */
19
+ limit?: number;
20
+ search_term?: string;
21
+ }
22
+ export interface GetLicenseDriftQueryHeaderParams {
23
+ 'Harness-Account'?: string;
24
+ }
25
+ export type GetLicenseDriftOkResponse = ResponseWithPagination<LicenseDriftResponseBodyResponse>;
26
+ export type GetLicenseDriftErrorResponse = unknown;
27
+ export interface GetLicenseDriftProps extends GetLicenseDriftQueryPathParams, Omit<FetcherOptions<GetLicenseDriftQueryQueryParams, unknown, GetLicenseDriftQueryHeaderParams>, 'url'> {
28
+ queryParams: GetLicenseDriftQueryQueryParams;
29
+ }
30
+ export declare function getLicenseDrift(props: GetLicenseDriftProps): Promise<GetLicenseDriftOkResponse>;
31
+ /**
32
+ * Get license drift for provided drift ID.
33
+ */
34
+ export declare function useGetLicenseDriftQuery(props: GetLicenseDriftProps, options?: Omit<UseQueryOptions<GetLicenseDriftOkResponse, GetLicenseDriftErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<GetLicenseDriftOkResponse, 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 { useQuery } from '@tanstack/react-query';
5
+ import { fetcher } from '../../../../fetcher/index.js';
6
+ export function getLicenseDrift(props) {
7
+ return fetcher(Object.assign({ url: `/v1/orgs/${props.org}/projects/${props.project}/sbom-drift/${props.drift}/licenses`, method: 'GET' }, props));
8
+ }
9
+ /**
10
+ * Get license drift for provided drift ID.
11
+ */
12
+ export function useGetLicenseDriftQuery(props, options) {
13
+ return useQuery(['getLicenseDrift', props.org, props.project, props.drift, props.queryParams], ({ signal }) => getLicenseDrift(Object.assign(Object.assign({}, props), { signal })), options);
14
+ }
@@ -0,0 +1,21 @@
1
+ import { UseQueryOptions } from '@tanstack/react-query';
2
+ import type { SbomScorecardResponseBodyResponse } from '../responses/SbomScorecardResponseBodyResponse';
3
+ import type { ResponseWithPagination } from '../helpers';
4
+ import { FetcherOptions } from '../../../../fetcher/index.js';
5
+ export interface GetSbomScorecardQueryPathParams {
6
+ org: string;
7
+ project: string;
8
+ 'orchestration-id': string;
9
+ }
10
+ export interface GetSbomScorecardQueryHeaderParams {
11
+ 'Harness-Account'?: string;
12
+ }
13
+ export type GetSbomScorecardOkResponse = ResponseWithPagination<SbomScorecardResponseBodyResponse>;
14
+ export type GetSbomScorecardErrorResponse = unknown;
15
+ export interface GetSbomScorecardProps extends GetSbomScorecardQueryPathParams, Omit<FetcherOptions<unknown, unknown, GetSbomScorecardQueryHeaderParams>, 'url'> {
16
+ }
17
+ export declare function getSbomScorecard(props: GetSbomScorecardProps): Promise<GetSbomScorecardOkResponse>;
18
+ /**
19
+ * Get SBOM Scorecard
20
+ */
21
+ export declare function useGetSbomScorecardQuery(props: GetSbomScorecardProps, options?: Omit<UseQueryOptions<GetSbomScorecardOkResponse, GetSbomScorecardErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<GetSbomScorecardOkResponse, 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 { useQuery } from '@tanstack/react-query';
5
+ import { fetcher } from '../../../../fetcher/index.js';
6
+ export function getSbomScorecard(props) {
7
+ return fetcher(Object.assign({ url: `/v1/org/${props.org}/project/${props.project}/orchestration/${props['orchestration-id']}/sbom-scorecard`, method: 'GET' }, props));
8
+ }
9
+ /**
10
+ * Get SBOM Scorecard
11
+ */
12
+ export function useGetSbomScorecardQuery(props, options) {
13
+ return useQuery(['getSbomScorecard', props.org, props.project, props['orchestration-id']], ({ signal }) => getSbomScorecard(Object.assign(Object.assign({}, props), { signal })), options);
14
+ }
@@ -0,0 +1,24 @@
1
+ import { UseMutationOptions } from '@tanstack/react-query';
2
+ import type { SaveResponseResponse } from '../responses/SaveResponseResponse';
3
+ import type { BaselineRequestBodyRequestBody } from '../requestBodies/BaselineRequestBodyRequestBody';
4
+ import type { ResponseWithPagination } from '../helpers';
5
+ import { FetcherOptions } from '../../../../fetcher/index.js';
6
+ export interface SetBaselineForArtifactMutationPathParams {
7
+ org: string;
8
+ project: string;
9
+ artifact: string;
10
+ }
11
+ export interface SetBaselineForArtifactMutationHeaderParams {
12
+ 'Harness-Account'?: string;
13
+ }
14
+ export type SetBaselineForArtifactRequestBody = BaselineRequestBodyRequestBody;
15
+ export type SetBaselineForArtifactOkResponse = ResponseWithPagination<SaveResponseResponse>;
16
+ export type SetBaselineForArtifactErrorResponse = unknown;
17
+ export interface SetBaselineForArtifactProps extends SetBaselineForArtifactMutationPathParams, Omit<FetcherOptions<unknown, SetBaselineForArtifactRequestBody, SetBaselineForArtifactMutationHeaderParams>, 'url'> {
18
+ body: SetBaselineForArtifactRequestBody;
19
+ }
20
+ export declare function setBaselineForArtifact(props: SetBaselineForArtifactProps): Promise<SetBaselineForArtifactOkResponse>;
21
+ /**
22
+ * Save the baseline for an artifact
23
+ */
24
+ export declare function useSetBaselineForArtifactMutation(options?: Omit<UseMutationOptions<SetBaselineForArtifactOkResponse, SetBaselineForArtifactErrorResponse, SetBaselineForArtifactProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<SetBaselineForArtifactOkResponse, unknown, SetBaselineForArtifactProps, 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 setBaselineForArtifact(props) {
7
+ return fetcher(Object.assign({ url: `/v1/orgs/${props.org}/projects/${props.project}/artifact/${props.artifact}/baseline`, method: 'POST' }, props));
8
+ }
9
+ /**
10
+ * Save the baseline for an artifact
11
+ */
12
+ export function useSetBaselineForArtifactMutation(options) {
13
+ return useMutation((mutateProps) => setBaselineForArtifact(mutateProps), options);
14
+ }
@@ -1,4 +1,6 @@
1
1
  export type { GetPathParamsType, ResponseWithPagination } from './helpers';
2
+ export type { CalculateDriftForArtifactErrorResponse, CalculateDriftForArtifactMutationPathParams, CalculateDriftForArtifactOkResponse, CalculateDriftForArtifactProps, CalculateDriftForArtifactRequestBody, } from './hooks/useCalculateDriftForArtifactMutation';
3
+ export { calculateDriftForArtifact, useCalculateDriftForArtifactMutation, } from './hooks/useCalculateDriftForArtifactMutation';
2
4
  export type { DownloadSbomErrorResponse, DownloadSbomOkResponse, DownloadSbomProps, DownloadSbomQueryPathParams, } from './hooks/useDownloadSbomQuery';
3
5
  export { downloadSbom, useDownloadSbomQuery } from './hooks/useDownloadSbomQuery';
4
6
  export type { GetArtifactDetailComponentViewErrorResponse, GetArtifactDetailComponentViewOkResponse, GetArtifactDetailComponentViewProps, GetArtifactDetailComponentViewQueryPathParams, GetArtifactDetailComponentViewQueryQueryParams, GetArtifactDetailComponentViewRequestBody, } from './hooks/useGetArtifactDetailComponentViewQuery';
@@ -7,19 +9,36 @@ export type { GetArtifactDetailDeploymentViewErrorResponse, GetArtifactDetailDep
7
9
  export { getArtifactDetailDeploymentView, useGetArtifactDetailDeploymentViewQuery, } from './hooks/useGetArtifactDetailDeploymentViewQuery';
8
10
  export type { GetArtifactDetailsErrorResponse, GetArtifactDetailsOkResponse, GetArtifactDetailsProps, GetArtifactDetailsQueryPathParams, } from './hooks/useGetArtifactDetailsQuery';
9
11
  export { getArtifactDetails, useGetArtifactDetailsQuery } from './hooks/useGetArtifactDetailsQuery';
12
+ export type { GetBaselineForArtifactErrorResponse, GetBaselineForArtifactOkResponse, GetBaselineForArtifactProps, GetBaselineForArtifactQueryPathParams, } from './hooks/useGetBaselineForArtifactQuery';
13
+ export { getBaselineForArtifact, useGetBaselineForArtifactQuery, } from './hooks/useGetBaselineForArtifactQuery';
14
+ export type { GetComponentDriftErrorResponse, GetComponentDriftOkResponse, GetComponentDriftProps, GetComponentDriftQueryPathParams, GetComponentDriftQueryQueryParams, } from './hooks/useGetComponentDriftQuery';
15
+ export { getComponentDrift, useGetComponentDriftQuery } from './hooks/useGetComponentDriftQuery';
16
+ export type { GetLicenseDriftErrorResponse, GetLicenseDriftOkResponse, GetLicenseDriftProps, GetLicenseDriftQueryPathParams, GetLicenseDriftQueryQueryParams, } from './hooks/useGetLicenseDriftQuery';
17
+ export { getLicenseDrift, useGetLicenseDriftQuery } from './hooks/useGetLicenseDriftQuery';
10
18
  export type { GetPolicyViolationsErrorResponse, GetPolicyViolationsOkResponse, GetPolicyViolationsProps, GetPolicyViolationsQueryPathParams, GetPolicyViolationsQueryQueryParams, } from './hooks/useGetPolicyViolationsQuery';
11
19
  export { getPolicyViolations, useGetPolicyViolationsQuery, } from './hooks/useGetPolicyViolationsQuery';
20
+ export type { GetSbomScorecardErrorResponse, GetSbomScorecardOkResponse, GetSbomScorecardProps, GetSbomScorecardQueryPathParams, } from './hooks/useGetSbomScorecardQuery';
21
+ export { getSbomScorecard, useGetSbomScorecardQuery } from './hooks/useGetSbomScorecardQuery';
12
22
  export type { ListArtifactsErrorResponse, ListArtifactsOkResponse, ListArtifactsProps, ListArtifactsQueryPathParams, ListArtifactsQueryQueryParams, ListArtifactsRequestBody, } from './hooks/useListArtifactsQuery';
13
23
  export { listArtifacts, useListArtifactsQuery } from './hooks/useListArtifactsQuery';
14
24
  export type { ListLatestArtifactsErrorResponse, ListLatestArtifactsOkResponse, ListLatestArtifactsProps, ListLatestArtifactsQueryPathParams, ListLatestArtifactsQueryQueryParams, } from './hooks/useListLatestArtifactsQuery';
15
25
  export { listLatestArtifacts, useListLatestArtifactsQuery, } from './hooks/useListLatestArtifactsQuery';
26
+ export type { SetBaselineForArtifactErrorResponse, SetBaselineForArtifactMutationPathParams, SetBaselineForArtifactOkResponse, SetBaselineForArtifactProps, SetBaselineForArtifactRequestBody, } from './hooks/useSetBaselineForArtifactMutation';
27
+ export { setBaselineForArtifact, useSetBaselineForArtifactMutation, } from './hooks/useSetBaselineForArtifactMutation';
16
28
  export type { ArtifactListingRequestBodyRequestBody } from './requestBodies/ArtifactListingRequestBodyRequestBody';
29
+ export type { BaselineRequestBodyRequestBody } from './requestBodies/BaselineRequestBodyRequestBody';
17
30
  export type { ArtifactComponentViewResponseBodyResponse } from './responses/ArtifactComponentViewResponseBodyResponse';
18
31
  export type { ArtifactDeploymentViewResponseBodyResponse } from './responses/ArtifactDeploymentViewResponseBodyResponse';
19
32
  export type { ArtifactDetailResponseBodyResponse } from './responses/ArtifactDetailResponseBodyResponse';
20
33
  export type { ArtifactListingResponseBodyResponse } from './responses/ArtifactListingResponseBodyResponse';
34
+ export type { ArtifactSbomDriftResponseBodyResponse } from './responses/ArtifactSbomDriftResponseBodyResponse';
21
35
  export type { ArtifactSbomResponseBodyResponse } from './responses/ArtifactSbomResponseBodyResponse';
36
+ export type { BaselineResponseBodyResponse } from './responses/BaselineResponseBodyResponse';
37
+ export type { ComponentDriftResponseBodyResponse } from './responses/ComponentDriftResponseBodyResponse';
38
+ export type { LicenseDriftResponseBodyResponse } from './responses/LicenseDriftResponseBodyResponse';
22
39
  export type { PolicyViolationResponseResponse } from './responses/PolicyViolationResponseResponse';
40
+ export type { SaveResponseResponse } from './responses/SaveResponseResponse';
41
+ export type { SbomScorecardResponseBodyResponse } from './responses/SbomScorecardResponseBodyResponse';
23
42
  export type { ArtifactComponentViewRequestBody } from './schemas/ArtifactComponentViewRequestBody';
24
43
  export type { ArtifactComponentViewResponse } from './schemas/ArtifactComponentViewResponse';
25
44
  export type { ArtifactDeploymentViewRequestBody } from './schemas/ArtifactDeploymentViewRequestBody';
@@ -27,9 +46,21 @@ export type { ArtifactDeploymentViewResponse } from './schemas/ArtifactDeploymen
27
46
  export type { ArtifactDetailResponse } from './schemas/ArtifactDetailResponse';
28
47
  export type { ArtifactListingRequestBody } from './schemas/ArtifactListingRequestBody';
29
48
  export type { ArtifactListingResponse } from './schemas/ArtifactListingResponse';
49
+ export type { ArtifactSbomDriftRequestBody } from './schemas/ArtifactSbomDriftRequestBody';
50
+ export type { ArtifactSbomDriftResponse } from './schemas/ArtifactSbomDriftResponse';
30
51
  export type { ArtifactSbomResponseBody } from './schemas/ArtifactSbomResponseBody';
52
+ export type { BaselineRequestBody } from './schemas/BaselineRequestBody';
53
+ export type { BaselineResponseBody } from './schemas/BaselineResponseBody';
54
+ export type { CategoryScorecard } from './schemas/CategoryScorecard';
55
+ export type { ComponentDrift } from './schemas/ComponentDrift';
31
56
  export type { ComponentFilter } from './schemas/ComponentFilter';
57
+ export type { ComponentSummary } from './schemas/ComponentSummary';
58
+ export type { LicenseDrift } from './schemas/LicenseDrift';
32
59
  export type { LicenseFilter } from './schemas/LicenseFilter';
33
60
  export type { Operator } from './schemas/Operator';
34
61
  export type { PolicyViolation } from './schemas/PolicyViolation';
62
+ export type { SaveResponse } from './schemas/SaveResponse';
63
+ export type { SbomDetailsForScorecard } from './schemas/SbomDetailsForScorecard';
64
+ export type { SbomScorecardResponseBody } from './schemas/SbomScorecardResponseBody';
65
+ export type { ScorecardInfo } from './schemas/ScorecardInfo';
35
66
  export type { Slsa } from './schemas/Slsa';
@@ -1,7 +1,13 @@
1
+ export { calculateDriftForArtifact, useCalculateDriftForArtifactMutation, } from './hooks/useCalculateDriftForArtifactMutation';
1
2
  export { downloadSbom, useDownloadSbomQuery } from './hooks/useDownloadSbomQuery';
2
3
  export { getArtifactDetailComponentView, useGetArtifactDetailComponentViewQuery, } from './hooks/useGetArtifactDetailComponentViewQuery';
3
4
  export { getArtifactDetailDeploymentView, useGetArtifactDetailDeploymentViewQuery, } from './hooks/useGetArtifactDetailDeploymentViewQuery';
4
5
  export { getArtifactDetails, useGetArtifactDetailsQuery } from './hooks/useGetArtifactDetailsQuery';
6
+ export { getBaselineForArtifact, useGetBaselineForArtifactQuery, } from './hooks/useGetBaselineForArtifactQuery';
7
+ export { getComponentDrift, useGetComponentDriftQuery } from './hooks/useGetComponentDriftQuery';
8
+ export { getLicenseDrift, useGetLicenseDriftQuery } from './hooks/useGetLicenseDriftQuery';
5
9
  export { getPolicyViolations, useGetPolicyViolationsQuery, } from './hooks/useGetPolicyViolationsQuery';
10
+ export { getSbomScorecard, useGetSbomScorecardQuery } from './hooks/useGetSbomScorecardQuery';
6
11
  export { listArtifacts, useListArtifactsQuery } from './hooks/useListArtifactsQuery';
7
12
  export { listLatestArtifacts, useListLatestArtifactsQuery, } from './hooks/useListLatestArtifactsQuery';
13
+ export { setBaselineForArtifact, useSetBaselineForArtifactMutation, } from './hooks/useSetBaselineForArtifactMutation';
@@ -0,0 +1,2 @@
1
+ import type { BaselineRequestBody } from '../schemas/BaselineRequestBody';
2
+ export type BaselineRequestBodyRequestBody = BaselineRequestBody;
@@ -0,0 +1,2 @@
1
+ import type { ArtifactSbomDriftResponse } from '../schemas/ArtifactSbomDriftResponse';
2
+ export type ArtifactSbomDriftResponseBodyResponse = ArtifactSbomDriftResponse;
@@ -0,0 +1,2 @@
1
+ import type { BaselineResponseBody } from '../schemas/BaselineResponseBody';
2
+ export type BaselineResponseBodyResponse = BaselineResponseBody;
@@ -0,0 +1,2 @@
1
+ import type { ComponentDrift } from '../schemas/ComponentDrift';
2
+ export type ComponentDriftResponseBodyResponse = ComponentDrift[];
@@ -0,0 +1,2 @@
1
+ import type { LicenseDrift } from '../schemas/LicenseDrift';
2
+ export type LicenseDriftResponseBodyResponse = LicenseDrift[];
@@ -0,0 +1,2 @@
1
+ import type { SaveResponse } from '../schemas/SaveResponse';
2
+ export type SaveResponseResponse = SaveResponse;
@@ -0,0 +1,2 @@
1
+ import type { SbomScorecardResponseBody } from '../schemas/SbomScorecardResponseBody';
2
+ export type SbomScorecardResponseBodyResponse = SbomScorecardResponseBody;
@@ -1,6 +1,7 @@
1
1
  export interface ArtifactListingResponse {
2
2
  activity?: 'DEPLOYED' | 'GENERATED';
3
3
  allow_list_violation_count?: string;
4
+ baseline?: boolean;
4
5
  build_pipeline_execution_id?: string;
5
6
  build_pipeline_id?: string;
6
7
  components_count?: number;
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Request body for caclulating drift between 2 versions of artifact
3
+ */
4
+ export interface ArtifactSbomDriftRequestBody {
5
+ /**
6
+ * Base tag to calculate drift from
7
+ */
8
+ base_tag: string;
9
+ /**
10
+ * Tag on which drift has to be calculated
11
+ */
12
+ tag: string;
13
+ }
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Response body for sbom drift calculation between 2 artifact versions.
3
+ */
4
+ export interface ArtifactSbomDriftResponse {
5
+ /**
6
+ * Artifact name
7
+ */
8
+ artifact_name?: string;
9
+ /**
10
+ * Base tag from which drift was calculated
11
+ */
12
+ base_tag?: string;
13
+ /**
14
+ * Drift ID to get the drift results
15
+ */
16
+ drift_id?: string;
17
+ /**
18
+ * Tag on which drift was calculated
19
+ */
20
+ tag?: string;
21
+ }
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
@@ -0,0 +1,6 @@
1
+ export interface BaselineRequestBody {
2
+ /**
3
+ * Version of the Artifact
4
+ */
5
+ tag?: string;
6
+ }
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
@@ -0,0 +1,10 @@
1
+ export interface BaselineResponseBody {
2
+ /**
3
+ * Id of the artifact
4
+ */
5
+ artifact_id?: string;
6
+ /**
7
+ * Version of the artifact
8
+ */
9
+ tag?: string;
10
+ }
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
@@ -0,0 +1,14 @@
1
+ export interface CategoryScorecard {
2
+ checks?: Array<{
3
+ description?: string;
4
+ is_enabled?: string;
5
+ max_score?: string;
6
+ name?: string;
7
+ score?: string;
8
+ }>;
9
+ is_enabled?: string;
10
+ max_score?: string;
11
+ name?: string;
12
+ score?: string;
13
+ weightage?: string;
14
+ }
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
@@ -0,0 +1,12 @@
1
+ import type { ComponentSummary } from '../schemas/ComponentSummary';
2
+ /**
3
+ * Compnent Drift model
4
+ */
5
+ export interface ComponentDrift {
6
+ new_component?: ComponentSummary;
7
+ old_component?: ComponentSummary;
8
+ /**
9
+ * Provides status of component whether it got added, deleted or modified
10
+ */
11
+ status?: {};
12
+ }
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Provides component summary
3
+ */
4
+ export interface ComponentSummary {
5
+ /**
6
+ * Licenses of component
7
+ */
8
+ package_license?: string;
9
+ /**
10
+ * Package manager of component
11
+ */
12
+ package_manager?: string;
13
+ /**
14
+ * Component Name
15
+ */
16
+ package_name?: string;
17
+ /**
18
+ * Component Supplier
19
+ */
20
+ package_supplier?: string;
21
+ /**
22
+ * Component Version
23
+ */
24
+ package_version?: string;
25
+ /**
26
+ * purl of component
27
+ */
28
+ purl?: string;
29
+ }
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
@@ -0,0 +1,16 @@
1
+ import type { ComponentSummary } from '../schemas/ComponentSummary';
2
+ /**
3
+ * Element of license drift
4
+ */
5
+ export interface LicenseDrift {
6
+ components?: ComponentSummary[];
7
+ /**
8
+ * License name
9
+ */
10
+ license?: string;
11
+ /**
12
+ * Status of license
13
+ *
14
+ */
15
+ status?: {};
16
+ }
@@ -0,0 +1,6 @@
1
+ /**
2
+ * response for Save/Update operations
3
+ */
4
+ export interface SaveResponse {
5
+ status?: string;
6
+ }
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
@@ -0,0 +1,8 @@
1
+ export interface SbomDetailsForScorecard {
2
+ file_format?: string;
3
+ sbom_file_name?: string;
4
+ sbom_format?: string;
5
+ sbom_version?: string;
6
+ tool_name?: string;
7
+ tool_version?: string;
8
+ }
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
@@ -0,0 +1,15 @@
1
+ import type { CategoryScorecard } from '../schemas/CategoryScorecard';
2
+ import type { SbomDetailsForScorecard } from '../schemas/SbomDetailsForScorecard';
3
+ import type { ScorecardInfo } from '../schemas/ScorecardInfo';
4
+ export interface SbomScorecardResponseBody {
5
+ account_id?: string;
6
+ avg_score?: string;
7
+ category?: CategoryScorecard[];
8
+ creation_on?: string;
9
+ max_score?: string;
10
+ orchestration_id?: string;
11
+ org_id?: string;
12
+ project_id?: string;
13
+ sbom_details?: SbomDetailsForScorecard;
14
+ score_card_info?: ScorecardInfo;
15
+ }
@@ -0,0 +1,4 @@
1
+ export interface ScorecardInfo {
2
+ tool_name?: string;
3
+ tool_version?: string;
4
+ }
@@ -0,0 +1,4 @@
1
+ /* eslint-disable */
2
+ // This code is autogenerated using @harnessio/oats-cli.
3
+ // Please do not modify this code directly.
4
+ export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@harnessio/react-ssca-manager-client",
3
- "version": "0.14.0",
3
+ "version": "0.17.0",
4
4
  "description": "Harness SSCA manager APIs integrated with react hooks",
5
5
  "author": "Harness Inc",
6
6
  "license": "MIT",