@harnessio/react-ssca-manager-client 0.86.15 → 0.86.17
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/ssca-manager/src/services/hooks/useGetLicenseConditionsQuery.d.ts +20 -0
- package/dist/ssca-manager/src/services/hooks/useGetLicenseConditionsQuery.js +15 -0
- package/dist/ssca-manager/src/services/index.d.ts +4 -0
- package/dist/ssca-manager/src/services/index.js +1 -0
- package/dist/ssca-manager/src/services/schemas/LicenseCondition.d.ts +21 -0
- package/dist/ssca-manager/src/services/schemas/LicenseCondition.js +4 -0
- package/dist/ssca-manager/src/services/schemas/LicenseConditionsResponse.d.ts +11 -0
- package/dist/ssca-manager/src/services/schemas/LicenseConditionsResponse.js +1 -0
- package/dist/ssca-manager/src/services/schemas/RspmScannerId.d.ts +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { LicenseConditionsResponse } from '../schemas/LicenseConditionsResponse';
|
|
3
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
4
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
5
|
+
export interface GetLicenseConditionsQueryPathParams {
|
|
6
|
+
licenseId: string;
|
|
7
|
+
}
|
|
8
|
+
export interface GetLicenseConditionsQueryHeaderParams {
|
|
9
|
+
'Harness-Account': string;
|
|
10
|
+
}
|
|
11
|
+
export type GetLicenseConditionsOkResponse = ResponseWithPagination<LicenseConditionsResponse>;
|
|
12
|
+
export type GetLicenseConditionsErrorResponse = unknown;
|
|
13
|
+
export interface GetLicenseConditionsProps extends GetLicenseConditionsQueryPathParams, Omit<FetcherOptions<unknown, unknown, GetLicenseConditionsQueryHeaderParams>, 'url'> {
|
|
14
|
+
}
|
|
15
|
+
export declare function getLicenseConditions(props: GetLicenseConditionsProps): Promise<GetLicenseConditionsOkResponse>;
|
|
16
|
+
/**
|
|
17
|
+
* Returns the static license conditions (obligations, permissions, and grant/limitations) for a single SPDX license identifier. Unknown or unmapped licenses return an empty conditions array.
|
|
18
|
+
*
|
|
19
|
+
*/
|
|
20
|
+
export declare function useGetLicenseConditionsQuery(props: GetLicenseConditionsProps, options?: Omit<UseQueryOptions<GetLicenseConditionsOkResponse, GetLicenseConditionsErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<GetLicenseConditionsOkResponse, unknown>;
|
|
@@ -0,0 +1,15 @@
|
|
|
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 getLicenseConditions(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/v1/license-conditions/${props.licenseId}`, method: 'GET' }, props));
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Returns the static license conditions (obligations, permissions, and grant/limitations) for a single SPDX license identifier. Unknown or unmapped licenses return an empty conditions array.
|
|
11
|
+
*
|
|
12
|
+
*/
|
|
13
|
+
export function useGetLicenseConditionsQuery(props, options) {
|
|
14
|
+
return useQuery(['getLicenseConditions', props.licenseId], ({ signal }) => getLicenseConditions(Object.assign(Object.assign({}, props), { signal })), options);
|
|
15
|
+
}
|
|
@@ -159,6 +159,8 @@ export type { GetIntegrationReposErrorResponse, GetIntegrationReposOkResponse, G
|
|
|
159
159
|
export { getIntegrationRepos, useGetIntegrationReposQuery, } from './hooks/useGetIntegrationReposQuery';
|
|
160
160
|
export type { GetIntegrationsConfigErrorResponse, GetIntegrationsConfigOkResponse, GetIntegrationsConfigProps, GetIntegrationsConfigQueryQueryParams, } from './hooks/useGetIntegrationsConfigQuery';
|
|
161
161
|
export { getIntegrationsConfig, useGetIntegrationsConfigQuery, } from './hooks/useGetIntegrationsConfigQuery';
|
|
162
|
+
export type { GetLicenseConditionsErrorResponse, GetLicenseConditionsOkResponse, GetLicenseConditionsProps, GetLicenseConditionsQueryPathParams, } from './hooks/useGetLicenseConditionsQuery';
|
|
163
|
+
export { getLicenseConditions, useGetLicenseConditionsQuery, } from './hooks/useGetLicenseConditionsQuery';
|
|
162
164
|
export type { GetLicenseDriftErrorResponse, GetLicenseDriftOkResponse, GetLicenseDriftProps, GetLicenseDriftQueryPathParams, GetLicenseDriftQueryQueryParams, } from './hooks/useGetLicenseDriftQuery';
|
|
163
165
|
export { getLicenseDrift, useGetLicenseDriftQuery } from './hooks/useGetLicenseDriftQuery';
|
|
164
166
|
export type { GetLicenseFamilyConfigErrorResponse, GetLicenseFamilyConfigOkResponse, GetLicenseFamilyConfigProps, GetLicenseFamilyConfigQueryPathParams, } from './hooks/useGetLicenseFamilyConfigQuery';
|
|
@@ -697,6 +699,8 @@ export type { JenkinsRunner } from './schemas/JenkinsRunner';
|
|
|
697
699
|
export type { JenkinsRunnerDetail } from './schemas/JenkinsRunnerDetail';
|
|
698
700
|
export type { JenkinsScmRepo } from './schemas/JenkinsScmRepo';
|
|
699
701
|
export type { LayerType } from './schemas/LayerType';
|
|
702
|
+
export type { LicenseCondition } from './schemas/LicenseCondition';
|
|
703
|
+
export type { LicenseConditionsResponse } from './schemas/LicenseConditionsResponse';
|
|
700
704
|
export type { LicenseDrift } from './schemas/LicenseDrift';
|
|
701
705
|
export type { LicenseDriftSummary } from './schemas/LicenseDriftSummary';
|
|
702
706
|
export type { LicenseFamilyConfigResponse } from './schemas/LicenseFamilyConfigResponse';
|
|
@@ -78,6 +78,7 @@ export { getHarnessPipelineIntegration, useGetHarnessPipelineIntegrationQuery, }
|
|
|
78
78
|
export { getIntegrationCounts, useGetIntegrationCountsQuery, } from './hooks/useGetIntegrationCountsQuery';
|
|
79
79
|
export { getIntegrationRepos, useGetIntegrationReposQuery, } from './hooks/useGetIntegrationReposQuery';
|
|
80
80
|
export { getIntegrationsConfig, useGetIntegrationsConfigQuery, } from './hooks/useGetIntegrationsConfigQuery';
|
|
81
|
+
export { getLicenseConditions, useGetLicenseConditionsQuery, } from './hooks/useGetLicenseConditionsQuery';
|
|
81
82
|
export { getLicenseDrift, useGetLicenseDriftQuery } from './hooks/useGetLicenseDriftQuery';
|
|
82
83
|
export { getLicenseFamilyConfig, useGetLicenseFamilyConfigQuery, } from './hooks/useGetLicenseFamilyConfigQuery';
|
|
83
84
|
export { getOssScoringCapConfig, useGetOssScoringCapConfigQuery, } from './hooks/useGetOssScoringCapConfigQuery';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A single license condition (obligation, permission, or grant/limitation)
|
|
3
|
+
*/
|
|
4
|
+
export interface LicenseCondition {
|
|
5
|
+
/**
|
|
6
|
+
* Optional extra guidance for the condition
|
|
7
|
+
*/
|
|
8
|
+
additional_guidance?: string | null;
|
|
9
|
+
/**
|
|
10
|
+
* Short display label for the condition
|
|
11
|
+
*/
|
|
12
|
+
description?: string;
|
|
13
|
+
/**
|
|
14
|
+
* Longer explanation of what the condition means
|
|
15
|
+
*/
|
|
16
|
+
message?: string;
|
|
17
|
+
/**
|
|
18
|
+
* Canonical condition key (for example must_attribute)
|
|
19
|
+
*/
|
|
20
|
+
name?: string;
|
|
21
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { LicenseCondition } from '../schemas/LicenseCondition';
|
|
2
|
+
export interface LicenseConditionsResponse {
|
|
3
|
+
/**
|
|
4
|
+
* Conditions for the license; empty when the SPDX id is unknown or has no mapping
|
|
5
|
+
*/
|
|
6
|
+
conditions?: LicenseCondition[];
|
|
7
|
+
/**
|
|
8
|
+
* SPDX license identifier that was looked up
|
|
9
|
+
*/
|
|
10
|
+
license_id?: string;
|
|
11
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Supported RSPM sequential scanner identifiers (STO scanners plus serial SCS steps)
|
|
3
3
|
*/
|
|
4
|
-
export type RspmScannerId = 'CHECKMARX_ONE' | 'CHECKOV' | 'GENERATE_SBOM' | 'SNYK' | 'SSCA_COMPLIANCE' | 'WIZ';
|
|
4
|
+
export type RspmScannerId = 'AQUA_TRIVY' | 'BANDIT' | 'BLACKDUCK' | 'BRAKEMAN' | 'CHECKMARX' | 'CHECKMARX_ONE' | 'CHECKOV' | 'GENERATE_SBOM' | 'GITHUB_ADVANCED_SECURITY' | 'GITLEAKS' | 'HARNESS_SAST' | 'MEND' | 'NEXUS_IQ' | 'OSV_SCANNER' | 'OWASP' | 'SEMGREP' | 'SNYK' | 'SONARQUBE' | 'SSCA_COMPLIANCE' | 'VERACODE' | 'WIZ';
|