@harnessio/react-idp-service-client 0.18.0 → 0.20.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.
@@ -0,0 +1,16 @@
1
+ import { UseQueryOptions } from '@tanstack/react-query';
2
+ import type { HarnessEntitiesCountResponseResponse } from '../responses/HarnessEntitiesCountResponseResponse';
3
+ import type { ResponseWithPagination } from '../helpers';
4
+ import { FetcherOptions } from './../../fetcher';
5
+ export interface GetHarnessEntitiesCountQueryHeaderParams {
6
+ 'Harness-Account'?: string;
7
+ }
8
+ export type GetHarnessEntitiesCountOkResponse = ResponseWithPagination<HarnessEntitiesCountResponseResponse>;
9
+ export type GetHarnessEntitiesCountErrorResponse = unknown;
10
+ export interface GetHarnessEntitiesCountProps extends Omit<FetcherOptions<unknown, unknown, GetHarnessEntitiesCountQueryHeaderParams>, 'url'> {
11
+ }
12
+ export declare function getHarnessEntitiesCount(props: GetHarnessEntitiesCountProps): Promise<GetHarnessEntitiesCountOkResponse>;
13
+ /**
14
+ * Get Harness Entities Count
15
+ */
16
+ export declare function useGetHarnessEntitiesCountQuery(props: GetHarnessEntitiesCountProps, options?: Omit<UseQueryOptions<GetHarnessEntitiesCountOkResponse, GetHarnessEntitiesCountErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<GetHarnessEntitiesCountOkResponse, 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';
6
+ export function getHarnessEntitiesCount(props) {
7
+ return fetcher(Object.assign({ url: `/v1/onboarding/harness-entities-count`, method: 'GET' }, props));
8
+ }
9
+ /**
10
+ * Get Harness Entities Count
11
+ */
12
+ export function useGetHarnessEntitiesCountQuery(props, options) {
13
+ return useQuery(['get-harness-entities-count'], ({ signal }) => getHarnessEntitiesCount(Object.assign(Object.assign({}, props), { signal })), options);
14
+ }
@@ -8,6 +8,7 @@ export interface GetHarnessEntitiesQueryQueryParams {
8
8
  sort?: string;
9
9
  order?: string;
10
10
  search_term?: string;
11
+ project_to_filter?: string;
11
12
  }
12
13
  export interface GetHarnessEntitiesQueryHeaderParams {
13
14
  'Harness-Account'?: string;
@@ -3,7 +3,7 @@ import type { PluginDetailedInfoResponseResponse } from '../responses/PluginDeta
3
3
  import type { ResponseWithPagination } from '../helpers';
4
4
  import { FetcherOptions } from './../../fetcher';
5
5
  export interface GetPluginsInfoPluginIdQueryPathParams {
6
- 'plugin-id': 'github-pull-requests-board' | 'harness-ci-cd' | 'pager-duty' | 'snyk-security';
6
+ 'plugin-id': 'github-pull-requests-board' | 'harness-ci-cd' | 'kafka' | 'lighthouse' | 'pager-duty' | 'snyk-security' | 'todo';
7
7
  }
8
8
  export interface GetPluginsInfoPluginIdQueryHeaderParams {
9
9
  'Harness-Account'?: string;
@@ -9,6 +9,8 @@ export type { GetBackstagePermissionsErrorResponse, GetBackstagePermissionsOkRes
9
9
  export { getBackstagePermissions, useGetBackstagePermissionsQuery, } from './hooks/useGetBackstagePermissionsQuery';
10
10
  export type { GetConnectorInfoErrorResponse, GetConnectorInfoOkResponse, GetConnectorInfoProps, } from './hooks/useGetConnectorInfoQuery';
11
11
  export { getConnectorInfo, useGetConnectorInfoQuery } from './hooks/useGetConnectorInfoQuery';
12
+ export type { GetHarnessEntitiesCountErrorResponse, GetHarnessEntitiesCountOkResponse, GetHarnessEntitiesCountProps, } from './hooks/useGetHarnessEntitiesCountQuery';
13
+ export { getHarnessEntitiesCount, useGetHarnessEntitiesCountQuery, } from './hooks/useGetHarnessEntitiesCountQuery';
12
14
  export type { GetHarnessEntitiesErrorResponse, GetHarnessEntitiesOkResponse, GetHarnessEntitiesProps, GetHarnessEntitiesQueryQueryParams, } from './hooks/useGetHarnessEntitiesQuery';
13
15
  export { getHarnessEntities, useGetHarnessEntitiesQuery } from './hooks/useGetHarnessEntitiesQuery';
14
16
  export type { GetLayoutErrorResponse, GetLayoutOkResponse, GetLayoutProps, GetLayoutQueryPathParams, } from './hooks/useGetLayoutQuery';
@@ -36,6 +38,7 @@ export type { ImportHarnessEntitiesRequestRequestBody } from './requestBodies/Im
36
38
  export type { AppConfigResponseResponse } from './responses/AppConfigResponseResponse';
37
39
  export type { BackstagePermissionsResponseResponse } from './responses/BackstagePermissionsResponseResponse';
38
40
  export type { ConnectorInfoResponseResponse } from './responses/ConnectorInfoResponseResponse';
41
+ export type { HarnessEntitiesCountResponseResponse } from './responses/HarnessEntitiesCountResponseResponse';
39
42
  export type { HarnessEntitiesResponseResponse } from './responses/HarnessEntitiesResponseResponse';
40
43
  export type { ImportEntitiesResponseResponse } from './responses/ImportEntitiesResponseResponse';
41
44
  export type { LayoutResponseResponse } from './responses/LayoutResponseResponse';
@@ -57,6 +60,7 @@ export type { ConnectorInfoResponse } from './schemas/ConnectorInfoResponse';
57
60
  export type { EntitiesForImport } from './schemas/EntitiesForImport';
58
61
  export type { Exports } from './schemas/Exports';
59
62
  export type { HarnessBackstageEntities } from './schemas/HarnessBackstageEntities';
63
+ export type { HarnessEntitiesCountResponse } from './schemas/HarnessEntitiesCountResponse';
60
64
  export type { HarnessEntitiesResponse } from './schemas/HarnessEntitiesResponse';
61
65
  export type { ImportEntitiesResponse } from './schemas/ImportEntitiesResponse';
62
66
  export type { ImportHarnessEntitiesRequest } from './schemas/ImportHarnessEntitiesRequest';
@@ -3,6 +3,7 @@ export { createLayout, useCreateLayoutMutation } from './hooks/useCreateLayoutMu
3
3
  export { getAllLayouts, useGetAllLayoutsQuery } from './hooks/useGetAllLayoutsQuery';
4
4
  export { getBackstagePermissions, useGetBackstagePermissionsQuery, } from './hooks/useGetBackstagePermissionsQuery';
5
5
  export { getConnectorInfo, useGetConnectorInfoQuery } from './hooks/useGetConnectorInfoQuery';
6
+ export { getHarnessEntitiesCount, useGetHarnessEntitiesCountQuery, } from './hooks/useGetHarnessEntitiesCountQuery';
6
7
  export { getHarnessEntities, useGetHarnessEntitiesQuery } from './hooks/useGetHarnessEntitiesQuery';
7
8
  export { getLayout, useGetLayoutQuery } from './hooks/useGetLayoutQuery';
8
9
  export { getPluginsInfoPluginId, useGetPluginsInfoPluginIdQuery, } from './hooks/useGetPluginsInfoPluginIdQuery';
@@ -0,0 +1,2 @@
1
+ import type { HarnessEntitiesCountResponse } from '../schemas/HarnessEntitiesCountResponse';
2
+ export type HarnessEntitiesCountResponseResponse = HarnessEntitiesCountResponse;
@@ -1,4 +1,4 @@
1
1
  import type { ConnectorDetails } from '../schemas/ConnectorDetails';
2
2
  export interface ConnectorInfoResponse {
3
- connector_details?: ConnectorDetails;
3
+ connector_details: ConnectorDetails;
4
4
  }
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Response for harness entities count that can be imported to IDP
3
+ */
4
+ export interface HarnessEntitiesCountResponse {
5
+ org_count: number;
6
+ project_count: number;
7
+ service_count: number;
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 {};
@@ -4,7 +4,4 @@ import type { HarnessBackstageEntities } from '../schemas/HarnessBackstageEntiti
4
4
  */
5
5
  export interface HarnessEntitiesResponse {
6
6
  harness_backstage_entities: HarnessBackstageEntities[];
7
- org_count: number;
8
- project_count: number;
9
- service_count: number;
10
7
  }
@@ -1,5 +1,5 @@
1
1
  export interface PluginInfo {
2
- category: 'CI/CD' | 'Monitoring' | 'Security' | 'Source Control Mgmt';
2
+ category: 'CI/CD' | 'Discovery' | 'Monitoring' | 'Quality' | 'Security' | 'Source Control Mgmt';
3
3
  core: boolean;
4
4
  created_by: string;
5
5
  description: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@harnessio/react-idp-service-client",
3
- "version": "0.18.0",
3
+ "version": "0.20.0",
4
4
  "description": "Harness React idp service client - IDP APIs integrated with react hooks",
5
5
  "author": "Harness Inc",
6
6
  "license": "MIT",