@harnessio/react-integration-manager-client 0.4.17 → 0.5.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,44 @@
1
+ import { UseMutationOptions } from '@tanstack/react-query';
2
+ import type { EntityGetEntitiesResponse } from '../schemas/EntityGetEntitiesResponse';
3
+ import type { ApierrorsErrorResponse } from '../schemas/ApierrorsErrorResponse';
4
+ import type { OpenapiGetEntitiesOrgRequest } from '../schemas/OpenapiGetEntitiesOrgRequest';
5
+ import type { ResponseWithPagination } from '../helpers';
6
+ import { FetcherOptions } from '../../../../fetcher/index.js';
7
+ export interface GetEntitiesOrgMutationPathParams {
8
+ accountIdentifier: string;
9
+ orgIdentifier: string;
10
+ }
11
+ export type GetEntitiesOrgRequestBody = OpenapiGetEntitiesOrgRequest;
12
+ export type GetEntitiesOrgOkResponse = ResponseWithPagination<EntityGetEntitiesResponse>;
13
+ export type GetEntitiesOrgErrorResponse = ApierrorsErrorResponse;
14
+ export interface GetEntitiesOrgProps extends GetEntitiesOrgMutationPathParams, Omit<FetcherOptions<unknown, GetEntitiesOrgRequestBody>, 'url'> {
15
+ body: GetEntitiesOrgRequestBody;
16
+ }
17
+ export declare function getEntitiesOrg(props: GetEntitiesOrgProps): Promise<GetEntitiesOrgOkResponse>;
18
+ /**
19
+ * Get entities from multiple integrations with linked secondary entities.
20
+ *
21
+ * Request Body (required):
22
+ * - integrations: Required array of integration queries. Each entry includes:
23
+ * - integration_id: Required - integration config identifier.
24
+ * - secondary_kinds: Optional - array of secondary entity kinds to fetch via EntityRelation linkage.
25
+ * Each secondary kind can include field_val_filters for filtering.
26
+ * - sort_by: Sort field - "created" (default), "last_updated", "name", or "identifier".
27
+ * - order: Sort order - "asc" or "desc" (default: "desc").
28
+ * - page: Pagination page number (default: 1, 1-based).
29
+ * - limit: Page size (default: 50, max: 2000).
30
+ * - skip_count: When true, skips expensive count and returns -1 as total (default: true).
31
+ * - exclude_primary: When true, excludes primary entities from the response (default: false).
32
+ *
33
+ * For each integration, the primary entity is fetched, then linked secondary entities
34
+ * are resolved via EntityRelation definitions.
35
+ *
36
+ * Response:
37
+ * - primaries: Array of primary entities (omitted when exclude_primary is true).
38
+ * - items: Array of secondary entities (paginated by page/limit/order).
39
+ * - pagination: Pagination metadata for secondary entities (page, size, total, total_pages).
40
+ *
41
+ * Pagination (page, limit, order) applies only to secondary entities. When exclude_primary is false,
42
+ * primary entities are always included in addition to up to limit secondary entities.
43
+ */
44
+ export declare function useGetEntitiesOrgMutation(options?: Omit<UseMutationOptions<GetEntitiesOrgOkResponse, GetEntitiesOrgErrorResponse, GetEntitiesOrgProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<GetEntitiesOrgOkResponse, ApierrorsErrorResponse, GetEntitiesOrgProps, unknown>;
@@ -0,0 +1,37 @@
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 getEntitiesOrg(props) {
7
+ return fetcher(Object.assign({ url: `/api/v1/accounts/${props.accountIdentifier}/orgs/${props.orgIdentifier}/entities`, method: 'POST' }, props));
8
+ }
9
+ /**
10
+ * Get entities from multiple integrations with linked secondary entities.
11
+ *
12
+ * Request Body (required):
13
+ * - integrations: Required array of integration queries. Each entry includes:
14
+ * - integration_id: Required - integration config identifier.
15
+ * - secondary_kinds: Optional - array of secondary entity kinds to fetch via EntityRelation linkage.
16
+ * Each secondary kind can include field_val_filters for filtering.
17
+ * - sort_by: Sort field - "created" (default), "last_updated", "name", or "identifier".
18
+ * - order: Sort order - "asc" or "desc" (default: "desc").
19
+ * - page: Pagination page number (default: 1, 1-based).
20
+ * - limit: Page size (default: 50, max: 2000).
21
+ * - skip_count: When true, skips expensive count and returns -1 as total (default: true).
22
+ * - exclude_primary: When true, excludes primary entities from the response (default: false).
23
+ *
24
+ * For each integration, the primary entity is fetched, then linked secondary entities
25
+ * are resolved via EntityRelation definitions.
26
+ *
27
+ * Response:
28
+ * - primaries: Array of primary entities (omitted when exclude_primary is true).
29
+ * - items: Array of secondary entities (paginated by page/limit/order).
30
+ * - pagination: Pagination metadata for secondary entities (page, size, total, total_pages).
31
+ *
32
+ * Pagination (page, limit, order) applies only to secondary entities. When exclude_primary is false,
33
+ * primary entities are always included in addition to up to limit secondary entities.
34
+ */
35
+ export function useGetEntitiesOrgMutation(options) {
36
+ return useMutation((mutateProps) => getEntitiesOrg(mutateProps), options);
37
+ }
@@ -0,0 +1,45 @@
1
+ import { UseMutationOptions } from '@tanstack/react-query';
2
+ import type { EntityGetEntitiesResponse } from '../schemas/EntityGetEntitiesResponse';
3
+ import type { ApierrorsErrorResponse } from '../schemas/ApierrorsErrorResponse';
4
+ import type { OpenapiGetEntitiesProjectRequest } from '../schemas/OpenapiGetEntitiesProjectRequest';
5
+ import type { ResponseWithPagination } from '../helpers';
6
+ import { FetcherOptions } from '../../../../fetcher/index.js';
7
+ export interface GetEntitiesProjectMutationPathParams {
8
+ accountIdentifier: string;
9
+ orgIdentifier: string;
10
+ projectIdentifier: string;
11
+ }
12
+ export type GetEntitiesProjectRequestBody = OpenapiGetEntitiesProjectRequest;
13
+ export type GetEntitiesProjectOkResponse = ResponseWithPagination<EntityGetEntitiesResponse>;
14
+ export type GetEntitiesProjectErrorResponse = ApierrorsErrorResponse;
15
+ export interface GetEntitiesProjectProps extends GetEntitiesProjectMutationPathParams, Omit<FetcherOptions<unknown, GetEntitiesProjectRequestBody>, 'url'> {
16
+ body: GetEntitiesProjectRequestBody;
17
+ }
18
+ export declare function getEntitiesProject(props: GetEntitiesProjectProps): Promise<GetEntitiesProjectOkResponse>;
19
+ /**
20
+ * Get entities from multiple integrations with linked secondary entities.
21
+ *
22
+ * Request Body (required):
23
+ * - integrations: Required array of integration queries. Each entry includes:
24
+ * - integration_id: Required - integration config identifier.
25
+ * - secondary_kinds: Optional - array of secondary entity kinds to fetch via EntityRelation linkage.
26
+ * Each secondary kind can include field_val_filters for filtering.
27
+ * - sort_by: Sort field - "created" (default), "last_updated", "name", or "identifier".
28
+ * - order: Sort order - "asc" or "desc" (default: "desc").
29
+ * - page: Pagination page number (default: 1, 1-based).
30
+ * - limit: Page size (default: 50, max: 2000).
31
+ * - skip_count: When true, skips expensive count and returns -1 as total (default: true).
32
+ * - exclude_primary: When true, excludes primary entities from the response (default: false).
33
+ *
34
+ * For each integration, the primary entity is fetched, then linked secondary entities
35
+ * are resolved via EntityRelation definitions.
36
+ *
37
+ * Response:
38
+ * - primaries: Array of primary entities (omitted when exclude_primary is true).
39
+ * - items: Array of secondary entities (paginated by page/limit/order).
40
+ * - pagination: Pagination metadata for secondary entities (page, size, total, total_pages).
41
+ *
42
+ * Pagination (page, limit, order) applies only to secondary entities. When exclude_primary is false,
43
+ * primary entities are always included in addition to up to limit secondary entities.
44
+ */
45
+ export declare function useGetEntitiesProjectMutation(options?: Omit<UseMutationOptions<GetEntitiesProjectOkResponse, GetEntitiesProjectErrorResponse, GetEntitiesProjectProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<GetEntitiesProjectOkResponse, ApierrorsErrorResponse, GetEntitiesProjectProps, unknown>;
@@ -0,0 +1,37 @@
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 getEntitiesProject(props) {
7
+ return fetcher(Object.assign({ url: `/api/v1/accounts/${props.accountIdentifier}/orgs/${props.orgIdentifier}/projects/${props.projectIdentifier}/entities`, method: 'POST' }, props));
8
+ }
9
+ /**
10
+ * Get entities from multiple integrations with linked secondary entities.
11
+ *
12
+ * Request Body (required):
13
+ * - integrations: Required array of integration queries. Each entry includes:
14
+ * - integration_id: Required - integration config identifier.
15
+ * - secondary_kinds: Optional - array of secondary entity kinds to fetch via EntityRelation linkage.
16
+ * Each secondary kind can include field_val_filters for filtering.
17
+ * - sort_by: Sort field - "created" (default), "last_updated", "name", or "identifier".
18
+ * - order: Sort order - "asc" or "desc" (default: "desc").
19
+ * - page: Pagination page number (default: 1, 1-based).
20
+ * - limit: Page size (default: 50, max: 2000).
21
+ * - skip_count: When true, skips expensive count and returns -1 as total (default: true).
22
+ * - exclude_primary: When true, excludes primary entities from the response (default: false).
23
+ *
24
+ * For each integration, the primary entity is fetched, then linked secondary entities
25
+ * are resolved via EntityRelation definitions.
26
+ *
27
+ * Response:
28
+ * - primaries: Array of primary entities (omitted when exclude_primary is true).
29
+ * - items: Array of secondary entities (paginated by page/limit/order).
30
+ * - pagination: Pagination metadata for secondary entities (page, size, total, total_pages).
31
+ *
32
+ * Pagination (page, limit, order) applies only to secondary entities. When exclude_primary is false,
33
+ * primary entities are always included in addition to up to limit secondary entities.
34
+ */
35
+ export function useGetEntitiesProjectMutation(options) {
36
+ return useMutation((mutateProps) => getEntitiesProject(mutateProps), options);
37
+ }
@@ -43,6 +43,10 @@ export type { GetAirbyteIntegrationConfigErrorResponse, GetAirbyteIntegrationCon
43
43
  export { getAirbyteIntegrationConfig, useGetAirbyteIntegrationConfigQuery, } from './hooks/useGetAirbyteIntegrationConfigQuery';
44
44
  export type { GetEntitiesErrorResponse, GetEntitiesMutationPathParams, GetEntitiesOkResponse, GetEntitiesProps, GetEntitiesRequestBody, } from './hooks/useGetEntitiesMutation';
45
45
  export { getEntities, useGetEntitiesMutation } from './hooks/useGetEntitiesMutation';
46
+ export type { GetEntitiesOrgErrorResponse, GetEntitiesOrgMutationPathParams, GetEntitiesOrgOkResponse, GetEntitiesOrgProps, GetEntitiesOrgRequestBody, } from './hooks/useGetEntitiesOrgMutation';
47
+ export { getEntitiesOrg, useGetEntitiesOrgMutation } from './hooks/useGetEntitiesOrgMutation';
48
+ export type { GetEntitiesProjectErrorResponse, GetEntitiesProjectMutationPathParams, GetEntitiesProjectOkResponse, GetEntitiesProjectProps, GetEntitiesProjectRequestBody, } from './hooks/useGetEntitiesProjectMutation';
49
+ export { getEntitiesProject, useGetEntitiesProjectMutation, } from './hooks/useGetEntitiesProjectMutation';
46
50
  export type { GetHealthErrorResponse, GetHealthOkResponse, GetHealthProps, } from './hooks/useGetHealthQuery';
47
51
  export { getHealth, useGetHealthQuery } from './hooks/useGetHealthQuery';
48
52
  export type { GetIntegrationConfigOrgErrorResponse, GetIntegrationConfigOrgOkResponse, GetIntegrationConfigOrgProps, GetIntegrationConfigOrgQueryPathParams, } from './hooks/useGetIntegrationConfigOrgQuery';
@@ -149,6 +153,8 @@ export type { OpenapiCreateIntegrationConfigProjectRequest } from './schemas/Ope
149
153
  export type { OpenapiCreateIntegrationConfigRequest } from './schemas/OpenapiCreateIntegrationConfigRequest';
150
154
  export type { OpenapiFieldValFilterRequest } from './schemas/OpenapiFieldValFilterRequest';
151
155
  export type { OpenapiGetAirbyteConnectorCatalogRequest } from './schemas/OpenapiGetAirbyteConnectorCatalogRequest';
156
+ export type { OpenapiGetEntitiesOrgRequest } from './schemas/OpenapiGetEntitiesOrgRequest';
157
+ export type { OpenapiGetEntitiesProjectRequest } from './schemas/OpenapiGetEntitiesProjectRequest';
152
158
  export type { OpenapiGetEntitiesRequest } from './schemas/OpenapiGetEntitiesRequest';
153
159
  export type { OpenapiIntegrationRequestOpenApi } from './schemas/OpenapiIntegrationRequestOpenApi';
154
160
  export type { OpenapiSecondaryKindRequestOpenApi } from './schemas/OpenapiSecondaryKindRequestOpenApi';
@@ -20,6 +20,8 @@ export { getAirbyteIntegrationConfigOrg, useGetAirbyteIntegrationConfigOrgQuery,
20
20
  export { getAirbyteIntegrationConfigProject, useGetAirbyteIntegrationConfigProjectQuery, } from './hooks/useGetAirbyteIntegrationConfigProjectQuery';
21
21
  export { getAirbyteIntegrationConfig, useGetAirbyteIntegrationConfigQuery, } from './hooks/useGetAirbyteIntegrationConfigQuery';
22
22
  export { getEntities, useGetEntitiesMutation } from './hooks/useGetEntitiesMutation';
23
+ export { getEntitiesOrg, useGetEntitiesOrgMutation } from './hooks/useGetEntitiesOrgMutation';
24
+ export { getEntitiesProject, useGetEntitiesProjectMutation, } from './hooks/useGetEntitiesProjectMutation';
23
25
  export { getHealth, useGetHealthQuery } from './hooks/useGetHealthQuery';
24
26
  export { getIntegrationConfigOrg, useGetIntegrationConfigOrgQuery, } from './hooks/useGetIntegrationConfigOrgQuery';
25
27
  export { getIntegrationConfigProject, useGetIntegrationConfigProjectQuery, } from './hooks/useGetIntegrationConfigProjectQuery';
@@ -0,0 +1,10 @@
1
+ import type { OpenapiIntegrationRequestOpenApi } from '../schemas/OpenapiIntegrationRequestOpenApi';
2
+ export interface OpenapiGetEntitiesOrgRequest {
3
+ exclude_primary?: boolean;
4
+ integrations?: OpenapiIntegrationRequestOpenApi[] | null;
5
+ limit?: number;
6
+ order?: string;
7
+ page?: number;
8
+ skip_count?: boolean | null;
9
+ sort_by?: string;
10
+ }
@@ -0,0 +1,10 @@
1
+ import type { OpenapiIntegrationRequestOpenApi } from '../schemas/OpenapiIntegrationRequestOpenApi';
2
+ export interface OpenapiGetEntitiesProjectRequest {
3
+ exclude_primary?: boolean;
4
+ integrations?: OpenapiIntegrationRequestOpenApi[] | null;
5
+ limit?: number;
6
+ order?: string;
7
+ page?: number;
8
+ skip_count?: boolean | null;
9
+ sort_by?: string;
10
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@harnessio/react-integration-manager-client",
3
- "version": "0.4.17",
3
+ "version": "0.5.0",
4
4
  "description": "Harness React integration manager client - Integration Manager APIs integrated with react hooks",
5
5
  "author": "Harness Inc",
6
6
  "license": "MIT",