@harnessio/react-idp-service-client 0.6.0 → 0.7.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.
@@ -1,16 +1,19 @@
1
1
  import { UseMutationOptions } from '@tanstack/react-query';
2
- import type { GeneralResponseResponse } from '../responses/GeneralResponseResponse';
2
+ import type { LayoutResponseResponse } from '../responses/LayoutResponseResponse';
3
+ import type { LayoutRequest } from '../schemas/LayoutRequest';
3
4
  import { FetcherOptions } from './../../fetcher';
4
5
  export interface CreateLayoutMutationHeaderParams {
5
6
  'Harness-Account'?: string;
6
7
  }
7
- export type CreateLayoutOkResponse = GeneralResponseResponse;
8
+ export type CreateLayoutRequestBody = LayoutRequest;
9
+ export type CreateLayoutOkResponse = LayoutResponseResponse;
8
10
  export type CreateLayoutErrorResponse = unknown;
9
- export interface CreateLayoutProps extends Omit<FetcherOptions<unknown, unknown, CreateLayoutMutationHeaderParams>, 'url'> {
11
+ export interface CreateLayoutProps extends Omit<FetcherOptions<unknown, CreateLayoutRequestBody, CreateLayoutMutationHeaderParams>, 'url'> {
12
+ body: CreateLayoutRequestBody;
10
13
  }
11
14
  export declare function createLayout(props: CreateLayoutProps): Promise<CreateLayoutOkResponse>;
12
15
  export type CreateLayoutMutationProps<T extends keyof CreateLayoutProps> = Omit<CreateLayoutProps, T> & Partial<Pick<CreateLayoutProps, T>>;
13
16
  /**
14
17
  * Create layout
15
18
  */
16
- export declare function useCreateLayoutMutation<T extends keyof CreateLayoutProps>(props: Pick<Partial<CreateLayoutProps>, T>, options?: Omit<UseMutationOptions<CreateLayoutOkResponse, CreateLayoutErrorResponse, CreateLayoutMutationProps<T>>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<import("..").GeneralResponse, unknown, CreateLayoutMutationProps<T>, unknown>;
19
+ export declare function useCreateLayoutMutation<T extends keyof CreateLayoutProps>(props: Pick<Partial<CreateLayoutProps>, T>, options?: Omit<UseMutationOptions<CreateLayoutOkResponse, CreateLayoutErrorResponse, CreateLayoutMutationProps<T>>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<import("..").LayoutResponse, unknown, CreateLayoutMutationProps<T>, unknown>;
@@ -1,10 +1,10 @@
1
1
  import { UseQueryOptions } from '@tanstack/react-query';
2
- import type { GeneralResponseResponse } from '../responses/GeneralResponseResponse';
2
+ import type { LayoutResponseResponse } from '../responses/LayoutResponseResponse';
3
3
  import { FetcherOptions } from './../../fetcher';
4
4
  export interface GetAllLayoutsQueryHeaderParams {
5
5
  'Harness-Account'?: string;
6
6
  }
7
- export type GetAllLayoutsOkResponse = GeneralResponseResponse;
7
+ export type GetAllLayoutsOkResponse = LayoutResponseResponse;
8
8
  export type GetAllLayoutsErrorResponse = unknown;
9
9
  export interface GetAllLayoutsProps extends Omit<FetcherOptions<unknown, unknown, GetAllLayoutsQueryHeaderParams>, 'url'> {
10
10
  }
@@ -12,4 +12,4 @@ export declare function getAllLayouts(props: GetAllLayoutsProps): Promise<GetAll
12
12
  /**
13
13
  * Get all layouts
14
14
  */
15
- export declare function useGetAllLayoutsQuery(props: GetAllLayoutsProps, options?: Omit<UseQueryOptions<GetAllLayoutsOkResponse, GetAllLayoutsErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<import("..").GeneralResponse, unknown>;
15
+ export declare function useGetAllLayoutsQuery(props: GetAllLayoutsProps, options?: Omit<UseQueryOptions<GetAllLayoutsOkResponse, GetAllLayoutsErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<import("..").LayoutResponse, unknown>;
@@ -1,5 +1,5 @@
1
1
  import { UseQueryOptions } from '@tanstack/react-query';
2
- import type { GeneralResponseResponse } from '../responses/GeneralResponseResponse';
2
+ import type { LayoutResponseResponse } from '../responses/LayoutResponseResponse';
3
3
  import { FetcherOptions } from './../../fetcher';
4
4
  export interface GetLayoutQueryPathParams {
5
5
  'layout-identifier': string;
@@ -7,7 +7,7 @@ export interface GetLayoutQueryPathParams {
7
7
  export interface GetLayoutQueryHeaderParams {
8
8
  'Harness-Account'?: string;
9
9
  }
10
- export type GetLayoutOkResponse = GeneralResponseResponse;
10
+ export type GetLayoutOkResponse = LayoutResponseResponse;
11
11
  export type GetLayoutErrorResponse = unknown;
12
12
  export interface GetLayoutProps extends GetLayoutQueryPathParams, Omit<FetcherOptions<unknown, unknown, GetLayoutQueryHeaderParams>, 'url'> {
13
13
  }
@@ -15,4 +15,4 @@ export declare function getLayout(props: GetLayoutProps): Promise<GetLayoutOkRes
15
15
  /**
16
16
  * Get Layout
17
17
  */
18
- export declare function useGetLayoutQuery(props: GetLayoutProps, options?: Omit<UseQueryOptions<GetLayoutOkResponse, GetLayoutErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<import("..").GeneralResponse, unknown>;
18
+ export declare function useGetLayoutQuery(props: GetLayoutProps, options?: Omit<UseQueryOptions<GetLayoutOkResponse, GetLayoutErrorResponse>, 'queryKey' | 'queryFn'>): import("@tanstack/react-query").UseQueryResult<import("..").LayoutResponse, unknown>;
@@ -1,6 +1,6 @@
1
1
  export type { CreateBackstagePermissionsErrorResponse, CreateBackstagePermissionsMutationProps, CreateBackstagePermissionsOkResponse, CreateBackstagePermissionsProps, CreateBackstagePermissionsRequestBody, } from './hooks/useCreateBackstagePermissionsMutation';
2
2
  export { createBackstagePermissions, useCreateBackstagePermissionsMutation, } from './hooks/useCreateBackstagePermissionsMutation';
3
- export type { CreateLayoutErrorResponse, CreateLayoutMutationProps, CreateLayoutOkResponse, CreateLayoutProps, } from './hooks/useCreateLayoutMutation';
3
+ export type { CreateLayoutErrorResponse, CreateLayoutMutationProps, CreateLayoutOkResponse, CreateLayoutProps, CreateLayoutRequestBody, } from './hooks/useCreateLayoutMutation';
4
4
  export { createLayout, useCreateLayoutMutation } from './hooks/useCreateLayoutMutation';
5
5
  export type { GetAllLayoutsErrorResponse, GetAllLayoutsOkResponse, GetAllLayoutsProps, } from './hooks/useGetAllLayoutsQuery';
6
6
  export { getAllLayouts, useGetAllLayoutsQuery } from './hooks/useGetAllLayoutsQuery';
@@ -22,14 +22,15 @@ export type { BackstagePermissionsRequestRequestBody } from './requestBodies/Bac
22
22
  export type { EnvironmentSecretRequestListRequestBody } from './requestBodies/EnvironmentSecretRequestListRequestBody';
23
23
  export type { EnvironmentSecretRequestRequestBody } from './requestBodies/EnvironmentSecretRequestRequestBody';
24
24
  export type { ImportHarnessEntitiesRequestRequestBody } from './requestBodies/ImportHarnessEntitiesRequestRequestBody';
25
+ export type { LayoutRequestRequestBody } from './requestBodies/LayoutRequestRequestBody';
25
26
  export type { ManualImportEntityRequestRequestBody } from './requestBodies/ManualImportEntityRequestRequestBody';
26
27
  export type { StatusInfoRequestRequestBody } from './requestBodies/StatusInfoRequestRequestBody';
27
28
  export type { BackstagePermissionsResponseResponse } from './responses/BackstagePermissionsResponseResponse';
28
29
  export type { EnvironmentSecretResponseListResponse } from './responses/EnvironmentSecretResponseListResponse';
29
30
  export type { EnvironmentSecretResponseResponse } from './responses/EnvironmentSecretResponseResponse';
30
- export type { GeneralResponseResponse } from './responses/GeneralResponseResponse';
31
31
  export type { HarnessEntitiesResponseResponse } from './responses/HarnessEntitiesResponseResponse';
32
32
  export type { ImportEntitiesResponseResponse } from './responses/ImportEntitiesResponseResponse';
33
+ export type { LayoutResponseResponse } from './responses/LayoutResponseResponse';
33
34
  export type { NamespaceResponseResponse } from './responses/NamespaceResponseResponse';
34
35
  export type { OnboardingAccessCheckResponseResponse } from './responses/OnboardingAccessCheckResponseResponse';
35
36
  export type { StatusInfoResponseResponse } from './responses/StatusInfoResponseResponse';
@@ -42,11 +43,12 @@ export type { EntitiesForImport } from './schemas/EntitiesForImport';
42
43
  export type { EnvironmentSecret } from './schemas/EnvironmentSecret';
43
44
  export type { EnvironmentSecretRequest } from './schemas/EnvironmentSecretRequest';
44
45
  export type { EnvironmentSecretResponse } from './schemas/EnvironmentSecretResponse';
45
- export type { GeneralResponse } from './schemas/GeneralResponse';
46
46
  export type { HarnessBackstageEntities } from './schemas/HarnessBackstageEntities';
47
47
  export type { HarnessEntitiesResponse } from './schemas/HarnessEntitiesResponse';
48
48
  export type { ImportEntitiesResponse } from './schemas/ImportEntitiesResponse';
49
49
  export type { ImportHarnessEntitiesRequest } from './schemas/ImportHarnessEntitiesRequest';
50
+ export type { LayoutRequest } from './schemas/LayoutRequest';
51
+ export type { LayoutResponse } from './schemas/LayoutResponse';
50
52
  export type { ManualImportEntityRequest } from './schemas/ManualImportEntityRequest';
51
53
  export type { NamepsaceResponse } from './schemas/NamepsaceResponse';
52
54
  export type { NamespaceInfo } from './schemas/NamespaceInfo';
@@ -0,0 +1,2 @@
1
+ import type { LayoutRequest } from '../schemas/LayoutRequest';
2
+ export type LayoutRequestRequestBody = LayoutRequest;
@@ -0,0 +1,2 @@
1
+ import type { LayoutResponse } from '../schemas/LayoutResponse';
2
+ export type LayoutResponseResponse = LayoutResponse;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,11 @@
1
+ /**
2
+ * LayoutRequest
3
+ */
4
+ export interface LayoutRequest {
5
+ defaultYaml?: string;
6
+ displayName?: string;
7
+ id?: string;
8
+ name?: string;
9
+ type?: string;
10
+ yaml?: string;
11
+ }
@@ -0,0 +1,3 @@
1
+ export interface LayoutResponse {
2
+ [key: string]: any;
3
+ }
@@ -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-idp-service-client",
3
- "version": "0.6.0",
3
+ "version": "0.7.0",
4
4
  "description": "Harness React idp service client - IDP APIs integrated with react hooks",
5
5
  "author": "Harness Inc",
6
6
  "license": "MIT",
@@ -1,2 +0,0 @@
1
- import type { GeneralResponse } from '../schemas/GeneralResponse';
2
- export type GeneralResponseResponse = GeneralResponse;
@@ -1,3 +0,0 @@
1
- export interface GeneralResponse {
2
- [key: string]: any;
3
- }