@harnessio/react-ssca-manager-client 0.83.0 → 0.83.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.
@@ -0,0 +1,24 @@
1
+ import { UseMutationOptions } from '@tanstack/react-query';
2
+ import type { SaveResponseResponse } from '../responses/SaveResponseResponse';
3
+ import type { BaselineV2RequestBodyRequestBody } from '../requestBodies/BaselineV2RequestBodyRequestBody';
4
+ import type { ResponseWithPagination } from '../helpers';
5
+ import { FetcherOptions } from '../../../../fetcher/index.js';
6
+ export interface SetBaselineForArtifactV2MutationPathParams {
7
+ org: string;
8
+ project: string;
9
+ source: string;
10
+ }
11
+ export interface SetBaselineForArtifactV2MutationHeaderParams {
12
+ 'Harness-Account': string;
13
+ }
14
+ export type SetBaselineForArtifactV2RequestBody = BaselineV2RequestBodyRequestBody;
15
+ export type SetBaselineForArtifactV2OkResponse = ResponseWithPagination<SaveResponseResponse>;
16
+ export type SetBaselineForArtifactV2ErrorResponse = unknown;
17
+ export interface SetBaselineForArtifactV2Props extends SetBaselineForArtifactV2MutationPathParams, Omit<FetcherOptions<unknown, SetBaselineForArtifactV2RequestBody, SetBaselineForArtifactV2MutationHeaderParams>, 'url'> {
18
+ body: SetBaselineForArtifactV2RequestBody;
19
+ }
20
+ export declare function setBaselineForArtifactV2(props: SetBaselineForArtifactV2Props): Promise<SetBaselineForArtifactV2OkResponse>;
21
+ /**
22
+ * Save the baseline for an artifact
23
+ */
24
+ export declare function useSetBaselineForArtifactV2Mutation(options?: Omit<UseMutationOptions<SetBaselineForArtifactV2OkResponse, SetBaselineForArtifactV2ErrorResponse, SetBaselineForArtifactV2Props>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<SetBaselineForArtifactV2OkResponse, unknown, SetBaselineForArtifactV2Props, 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 setBaselineForArtifactV2(props) {
7
+ return fetcher(Object.assign({ url: `/v1/orgs/${props.org}/projects/${props.project}/artifact-sources/${props.source}/baseline`, method: 'POST' }, props));
8
+ }
9
+ /**
10
+ * Save the baseline for an artifact
11
+ */
12
+ export function useSetBaselineForArtifactV2Mutation(options) {
13
+ return useMutation((mutateProps) => setBaselineForArtifactV2(mutateProps), options);
14
+ }
@@ -115,6 +115,8 @@ export type { PostComplianceResultStatsEvaluationBreakdownArtifactTypeErrorRespo
115
115
  export { postComplianceResultStatsEvaluationBreakdownArtifactType, usePostComplianceResultStatsEvaluationBreakdownArtifactTypeMutation, } from './hooks/usePostComplianceResultStatsEvaluationBreakdownArtifactTypeMutation';
116
116
  export type { PostComplianceResultStatsOverviewErrorResponse, PostComplianceResultStatsOverviewMutationPathParams, PostComplianceResultStatsOverviewMutationQueryParams, PostComplianceResultStatsOverviewOkResponse, PostComplianceResultStatsOverviewProps, PostComplianceResultStatsOverviewRequestBody, } from './hooks/usePostComplianceResultStatsOverviewMutation';
117
117
  export { postComplianceResultStatsOverview, usePostComplianceResultStatsOverviewMutation, } from './hooks/usePostComplianceResultStatsOverviewMutation';
118
+ export type { SetBaselineForArtifactV2ErrorResponse, SetBaselineForArtifactV2MutationPathParams, SetBaselineForArtifactV2OkResponse, SetBaselineForArtifactV2Props, SetBaselineForArtifactV2RequestBody, } from './hooks/useSetBaselineForArtifactV2Mutation';
119
+ export { setBaselineForArtifactV2, useSetBaselineForArtifactV2Mutation, } from './hooks/useSetBaselineForArtifactV2Mutation';
118
120
  export type { SscaLicenseUsageErrorResponse, SscaLicenseUsageOkResponse, SscaLicenseUsageProps, SscaLicenseUsageQueryQueryParams, } from './hooks/useSscaLicenseUsageQuery';
119
121
  export { sscaLicenseUsage, useSscaLicenseUsageQuery } from './hooks/useSscaLicenseUsageQuery';
120
122
  export type { UpdateRemediationTrackerErrorResponse, UpdateRemediationTrackerMutationPathParams, UpdateRemediationTrackerOkResponse, UpdateRemediationTrackerProps, UpdateRemediationTrackerRequestBody, } from './hooks/useUpdateRemediationTrackerMutation';
@@ -386,6 +388,7 @@ export type { OrchestrationModelPipeline } from './schemas/OrchestrationModelPip
386
388
  export type { OrchestrationScorecardSummary } from './schemas/OrchestrationScorecardSummary';
387
389
  export type { OrchestrationStepDriftRequestBody } from './schemas/OrchestrationStepDriftRequestBody';
388
390
  export type { OrchestrationSummaryResponse } from './schemas/OrchestrationSummaryResponse';
391
+ export type { OwaspFilter } from './schemas/OwaspFilter';
389
392
  export type { PipelineConfigUpdateRequest } from './schemas/PipelineConfigUpdateRequest';
390
393
  export type { PipelineDetails } from './schemas/PipelineDetails';
391
394
  export type { PipelineInfo } from './schemas/PipelineInfo';
@@ -56,5 +56,6 @@ export { listIntegrations, useListIntegrationsQuery } from './hooks/useListInteg
56
56
  export { listRemediations, useListRemediationsQuery } from './hooks/useListRemediationsQuery';
57
57
  export { postComplianceResultStatsEvaluationBreakdownArtifactType, usePostComplianceResultStatsEvaluationBreakdownArtifactTypeMutation, } from './hooks/usePostComplianceResultStatsEvaluationBreakdownArtifactTypeMutation';
58
58
  export { postComplianceResultStatsOverview, usePostComplianceResultStatsOverviewMutation, } from './hooks/usePostComplianceResultStatsOverviewMutation';
59
+ export { setBaselineForArtifactV2, useSetBaselineForArtifactV2Mutation, } from './hooks/useSetBaselineForArtifactV2Mutation';
59
60
  export { sscaLicenseUsage, useSscaLicenseUsageQuery } from './hooks/useSscaLicenseUsageQuery';
60
61
  export { updateRemediationTracker, useUpdateRemediationTrackerMutation, } from './hooks/useUpdateRemediationTrackerMutation';
@@ -1,10 +1,12 @@
1
1
  import type { ComponentFilter } from '../schemas/ComponentFilter';
2
2
  import type { LayerType } from '../schemas/LayerType';
3
3
  import type { LicenseFilter } from '../schemas/LicenseFilter';
4
+ import type { OwaspFilter } from '../schemas/OwaspFilter';
4
5
  export interface ArtifactComponentViewRequestBody {
5
6
  component_filter?: ComponentFilter[];
6
7
  image_layer?: LayerType;
7
8
  license_filter?: LicenseFilter;
9
+ owasp_filter?: OwaspFilter;
8
10
  package_manager?: string;
9
11
  package_supplier?: string;
10
12
  }
@@ -1,13 +1,31 @@
1
1
  import type { LayerType } from '../schemas/LayerType';
2
2
  import type { StoIssueCount } from '../schemas/StoIssueCount';
3
+ import type { TicketInfo } from '../schemas/TicketInfo';
3
4
  export interface ArtifactComponentViewResponse {
5
+ /**
6
+ * details of the component
7
+ */
8
+ description?: string;
4
9
  exemption_status?: 'FULLY_EXEMPTED' | 'NOT_EXEMPTED' | 'PARTIALLY_EXEMPTED';
5
10
  filter_tags?: LayerType[];
11
+ /**
12
+ * boolean field to indicate whether a particular component is outdated or not.
13
+ */
14
+ is_outdated?: boolean;
15
+ /**
16
+ * boolean field to indicate whether a component is deprecated or not.
17
+ */
18
+ is_unmaintained?: boolean;
6
19
  issue_count?: StoIssueCount;
20
+ /**
21
+ * latest version available of a component
22
+ */
23
+ latest_version?: string;
7
24
  package_license?: string;
8
25
  package_manager?: string;
9
26
  package_name?: string;
10
27
  package_supplier?: string;
11
28
  package_version?: string;
12
29
  purl?: string;
30
+ ticket?: TicketInfo;
13
31
  }
@@ -0,0 +1 @@
1
+ export type OwaspFilter = 'OUTDATED_COMPONENT' | 'UNMAINTAINED_COMPONENT' | 'VULNERABLE_COMPONENT';
@@ -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.83.0",
3
+ "version": "0.83.2",
4
4
  "description": "Harness SSCA manager APIs integrated with react hooks",
5
5
  "author": "Harness Inc",
6
6
  "license": "MIT",