@bluecopa/react 0.1.15 → 0.1.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.
Files changed (29) hide show
  1. package/dist/{COOQDZLH-Y_PwE3ez.js → COOQDZLH-Da2mX3ss.js} +2 -2
  2. package/dist/{MU7WGUJF-CH7VXHPX.js → MU7WGUJF-DfMPO9ib.js} +2 -2
  3. package/dist/{VREWMQAW-Cm3eEPri.js → VREWMQAW-C9qDzx3Z.js} +1 -1
  4. package/dist/hooks/useCreateStatementRun.d.ts +20 -0
  5. package/dist/hooks/useCreateStatementRun.d.ts.map +1 -0
  6. package/dist/hooks/useGetRunResultById.d.ts +12 -0
  7. package/dist/hooks/useGetRunResultById.d.ts.map +1 -0
  8. package/dist/hooks/useGetRunsByViewId.d.ts +12 -0
  9. package/dist/hooks/useGetRunsByViewId.d.ts.map +1 -0
  10. package/dist/hooks/useGetStatementData.d.ts +14 -0
  11. package/dist/hooks/useGetStatementData.d.ts.map +1 -0
  12. package/dist/hooks/useGetViewById.d.ts +12 -0
  13. package/dist/hooks/useGetViewById.d.ts.map +1 -0
  14. package/dist/hooks/useGetViewsBySheetId.d.ts +12 -0
  15. package/dist/hooks/useGetViewsBySheetId.d.ts.map +1 -0
  16. package/dist/hooks/useGetWorkflowInstanceStatusById.d.ts +32 -5
  17. package/dist/hooks/useGetWorkflowInstanceStatusById.d.ts.map +1 -1
  18. package/dist/hooks/useInputTable.d.ts.map +1 -1
  19. package/dist/hooks/useTriggerHttpWorkflow.d.ts +12 -5
  20. package/dist/hooks/useTriggerHttpWorkflow.d.ts.map +1 -1
  21. package/dist/hooks/useTriggerWorkflow.d.ts +16 -5
  22. package/dist/hooks/useTriggerWorkflow.d.ts.map +1 -1
  23. package/dist/{index-CAJ9zZWS.js → index-DpZyX0HO.js} +2181 -2099
  24. package/dist/index.d.ts +6 -0
  25. package/dist/index.d.ts.map +1 -1
  26. package/dist/index.es.js +25 -19
  27. package/dist/types/index.d.ts +10 -0
  28. package/dist/types/index.d.ts.map +1 -1
  29. package/package.json +2 -2
@@ -1,5 +1,5 @@
1
- import { c, T as l, P as m, a as u, D as v, Q as i } from "./VREWMQAW-Cm3eEPri.js";
2
- import { g as d, c as f, a as e } from "./index-CAJ9zZWS.js";
1
+ import { c, T as l, P as m, a as u, D as v, Q as i } from "./VREWMQAW-C9qDzx3Z.js";
2
+ import { g as d, c as f, a as e } from "./index-DpZyX0HO.js";
3
3
  var p = (a) => {
4
4
  const [r, t] = c({
5
5
  prefix: "TanstackQueryDevtools"
@@ -1,5 +1,5 @@
1
- import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./VREWMQAW-Cm3eEPri.js";
2
- import { g as v, c as C, a as e } from "./index-CAJ9zZWS.js";
1
+ import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./VREWMQAW-C9qDzx3Z.js";
2
+ import { g as v, c as C, a as e } from "./index-DpZyX0HO.js";
3
3
  var h = (t) => {
4
4
  const [r, o] = s({
5
5
  prefix: "TanstackQueryDevtools"
@@ -1,7 +1,7 @@
1
1
  var bs = Object.defineProperty;
2
2
  var ps = (e, t, n) => t in e ? bs(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
3
  var _e = (e, t, n) => ps(e, typeof t != "symbol" ? t + "" : t, n);
4
- import { b as xe, d as z, o as Ft, e as N, c as D, a as m, P as qo, S as B, t as _, i as k, f as V, h as F, j as ws, k as rr, u as $e, l as j, s as Vn, m as Gn, n as ut, p as A, q as xs, r as an, v as Ne, w as $s, x as _t, y as zt, z as Cs, A as Ss, B as xn, F as ks, C as Kr, D as Kt, $ as Ro, E as Es, G as Ds, H as W, I as Br, J as Ms, K as As, L as or, M as Fs, N as Ts, O as Rn, Q as Is, R as Ps, T as oe, U as Ls, V as Os } from "./index-CAJ9zZWS.js";
4
+ import { b as xe, d as z, o as Ft, e as N, c as D, a as m, P as qo, S as B, t as _, i as k, f as V, h as F, j as ws, k as rr, u as $e, l as j, s as Vn, m as Gn, n as ut, p as A, q as xs, r as an, v as Ne, w as $s, x as _t, y as zt, z as Cs, A as Ss, B as xn, F as ks, C as Kr, D as Kt, $ as Ro, E as Es, G as Ds, H as W, I as Br, J as Ms, K as As, L as or, M as Fs, N as Ts, O as Rn, Q as Is, R as Ps, T as oe, U as Ls, V as Os } from "./index-DpZyX0HO.js";
5
5
  var _s = (e) => e != null, qs = (e) => e.filter(_s);
6
6
  function Rs(e) {
7
7
  return (...t) => {
@@ -0,0 +1,20 @@
1
+ import { UseMutationResult } from '@tanstack/react-query';
2
+ export interface CreateStatementRunParams {
3
+ statementId: string;
4
+ viewId?: string;
5
+ runId?: string;
6
+ options?: {
7
+ name?: string;
8
+ columnFilters?: any[];
9
+ };
10
+ }
11
+ export interface CreateStatementRunResult {
12
+ runId: string;
13
+ }
14
+ /**
15
+ * Custom hook for creating a new statement run using TanStack React Query
16
+ * @param options - Mutation options
17
+ * @returns useMutation for creating a new statement run
18
+ */
19
+ export declare function useCreateStatementRun(options?: {}): UseMutationResult<CreateStatementRunResult, Error, CreateStatementRunParams>;
20
+ //# sourceMappingURL=useCreateStatementRun.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useCreateStatementRun.d.ts","sourceRoot":"","sources":["../../src/hooks/useCreateStatementRun.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,KAAK,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAG5E,MAAM,WAAW,wBAAwB;IACvC,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE;QACR,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,aAAa,CAAC,EAAE,GAAG,EAAE,CAAC;KACvB,CAAC;CACH;AAED,MAAM,WAAW,wBAAwB;IACvC,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;;;GAIG;AACH,wBAAgB,qBAAqB,CACnC,OAAO,KAAK,GACX,iBAAiB,CAAC,wBAAwB,EAAE,KAAK,EAAE,wBAAwB,CAAC,CAO9E"}
@@ -0,0 +1,12 @@
1
+ import { UseQueryResult } from '@tanstack/react-query';
2
+ import { BaseQueryOptions } from '../types';
3
+ export interface UseGetRunResultByIdOptions extends BaseQueryOptions {
4
+ }
5
+ /**
6
+ * Custom hook for fetching workflow run result by ID using TanStack React Query
7
+ * @param runId - The ID of the statement run
8
+ * @param options - Query options including enabled state and cache settings
9
+ * @returns UseQueryResult with workflow run result
10
+ */
11
+ export declare function useGetRunResultById(runId: string | null | undefined, options?: UseGetRunResultByIdOptions): UseQueryResult<any, Error>;
12
+ //# sourceMappingURL=useGetRunResultById.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useGetRunResultById.d.ts","sourceRoot":"","sources":["../../src/hooks/useGetRunResultById.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAMtE,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAE5C,MAAM,WAAW,0BAA2B,SAAQ,gBAAgB;CAAG;AAEvE;;;;;GAKG;AACH,wBAAgB,mBAAmB,CACjC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EAChC,OAAO,GAAE,0BAA+B,GACvC,cAAc,CAAC,GAAG,EAAE,KAAK,CAAC,CAmB5B"}
@@ -0,0 +1,12 @@
1
+ import { UseQueryResult } from '@tanstack/react-query';
2
+ import { BaseQueryOptions } from '../types';
3
+ export interface UseGetRunsByViewIdOptions extends BaseQueryOptions {
4
+ }
5
+ /**
6
+ * Custom hook for fetching runs by view ID using TanStack React Query
7
+ * @param viewId - The ID of the statement view
8
+ * @param options - Query options including enabled state and cache settings
9
+ * @returns UseQueryResult with array of runs/results for the view
10
+ */
11
+ export declare function useGetRunsByViewId(viewId: string | null | undefined, options?: UseGetRunsByViewIdOptions): UseQueryResult<any[], Error>;
12
+ //# sourceMappingURL=useGetRunsByViewId.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useGetRunsByViewId.d.ts","sourceRoot":"","sources":["../../src/hooks/useGetRunsByViewId.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAMtE,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAE5C,MAAM,WAAW,yBAA0B,SAAQ,gBAAgB;CAAG;AAEtE;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAChC,MAAM,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EACjC,OAAO,GAAE,yBAA8B,GACtC,cAAc,CAAC,GAAG,EAAE,EAAE,KAAK,CAAC,CAmB9B"}
@@ -0,0 +1,14 @@
1
+ import { UseQueryResult } from '@tanstack/react-query';
2
+ import { BaseQueryOptions } from '../types';
3
+ export interface UseGetStatementDataOptions extends BaseQueryOptions {
4
+ }
5
+ /**
6
+ * Custom hook for fetching statement data using TanStack React Query
7
+ * @param statementId - The ID of the statement workbook
8
+ * @param viewId - Optional view ID. If not provided, uses the default view
9
+ * @param runId - Optional run ID. If not provided, uses the latest run
10
+ * @param options - Query options including enabled state and cache settings
11
+ * @returns UseQueryResult with statement data
12
+ */
13
+ export declare function useGetStatementData(statementId: string | null | undefined, viewId?: string | null | undefined, runId?: string | null | undefined, options?: UseGetStatementDataOptions): UseQueryResult<any, Error>;
14
+ //# sourceMappingURL=useGetStatementData.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useGetStatementData.d.ts","sourceRoot":"","sources":["../../src/hooks/useGetStatementData.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAMtE,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAE5C,MAAM,WAAW,0BAA2B,SAAQ,gBAAgB;CAAG;AAEvE;;;;;;;GAOG;AACH,wBAAgB,mBAAmB,CACjC,WAAW,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EACtC,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EAClC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EACjC,OAAO,GAAE,0BAA+B,GACvC,cAAc,CAAC,GAAG,EAAE,KAAK,CAAC,CAuB5B"}
@@ -0,0 +1,12 @@
1
+ import { UseQueryResult } from '@tanstack/react-query';
2
+ import { BaseQueryOptions } from '../types';
3
+ export interface UseGetViewByIdOptions extends BaseQueryOptions {
4
+ }
5
+ /**
6
+ * Custom hook for fetching statement view by ID using TanStack React Query
7
+ * @param viewId - The ID of the statement view
8
+ * @param options - Query options including enabled state and cache settings
9
+ * @returns UseQueryResult with statement view workflow
10
+ */
11
+ export declare function useGetViewById(viewId: string | null | undefined, options?: UseGetViewByIdOptions): UseQueryResult<any, Error>;
12
+ //# sourceMappingURL=useGetViewById.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useGetViewById.d.ts","sourceRoot":"","sources":["../../src/hooks/useGetViewById.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAMtE,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAE5C,MAAM,WAAW,qBAAsB,SAAQ,gBAAgB;CAAG;AAElE;;;;;GAKG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EACjC,OAAO,GAAE,qBAA0B,GAClC,cAAc,CAAC,GAAG,EAAE,KAAK,CAAC,CAmB5B"}
@@ -0,0 +1,12 @@
1
+ import { UseQueryResult } from '@tanstack/react-query';
2
+ import { BaseQueryOptions } from '../types';
3
+ export interface UseGetViewsBySheetIdOptions extends BaseQueryOptions {
4
+ }
5
+ /**
6
+ * Custom hook for fetching statement views by sheet ID using TanStack React Query
7
+ * @param sheetId - The ID of the statement sheet
8
+ * @param options - Query options including enabled state and cache settings
9
+ * @returns UseQueryResult with array of statement views
10
+ */
11
+ export declare function useGetViewsBySheetId(sheetId: string | null | undefined, options?: UseGetViewsBySheetIdOptions): UseQueryResult<any[], Error>;
12
+ //# sourceMappingURL=useGetViewsBySheetId.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useGetViewsBySheetId.d.ts","sourceRoot":"","sources":["../../src/hooks/useGetViewsBySheetId.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAMtE,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAE5C,MAAM,WAAW,2BAA4B,SAAQ,gBAAgB;CAAG;AAExE;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EAClC,OAAO,GAAE,2BAAgC,GACxC,cAAc,CAAC,GAAG,EAAE,EAAE,KAAK,CAAC,CAmB9B"}
@@ -1,11 +1,38 @@
1
- import { copaApi } from '@bluecopa/core';
1
+ import { UseMutationResult } from '@tanstack/react-query';
2
+ export type WorkflowStatusRequest = ReadonlyArray<{
3
+ instanceId: string;
4
+ parentId: string;
5
+ }>;
6
+ export declare enum WorkflowStatus {
7
+ Succeeded = "Succeeded",
8
+ Failed = "Failed",
9
+ Running = "Running",
10
+ NotFound = "NotFound"
11
+ }
12
+ export type StepInfo = {
13
+ stepId: string;
14
+ name: string;
15
+ stepOutput: Record<string, any>;
16
+ };
17
+ export type WorkflowStatusResponse = {
18
+ instanceId: string;
19
+ processName: string;
20
+ parentId: string;
21
+ status: WorkflowStatus;
22
+ message: string;
23
+ data: {
24
+ completed: StepInfo[];
25
+ running: StepInfo[];
26
+ failed?: StepInfo[];
27
+ };
28
+ completedAt: string;
29
+ error?: string;
30
+ };
31
+ export type WorkflowStatusResponses = ReadonlyArray<WorkflowStatusResponse>;
2
32
  /**
3
33
  * Custom hook for getting workflow instance status using TanStack React Query
4
34
  * @param options - Mutation options
5
35
  * @returns useMutation for getting workflow instance status
6
36
  */
7
- export declare function useGetWorkflowInstanceStatusById(options?: {}): import('@tanstack/react-query').UseMutationResult<copaApi.workflow.WorkflowStatusResponses, Error, {
8
- instanceId: string;
9
- parentId: string;
10
- }[], unknown>;
37
+ export declare function useGetWorkflowInstanceStatusById(options?: {}): UseMutationResult<WorkflowStatusResponses, Error, WorkflowStatusRequest>;
11
38
  //# sourceMappingURL=useGetWorkflowInstanceStatusById.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useGetWorkflowInstanceStatusById.d.ts","sourceRoot":"","sources":["../../src/hooks/useGetWorkflowInstanceStatusById.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAEzC;;;;GAIG;AACH,wBAAgB,gCAAgC,CAAC,OAAO,KAAK;gBAEf,MAAM;cAAY,MAAM;cAOrE"}
1
+ {"version":3,"file":"useGetWorkflowInstanceStatusById.d.ts","sourceRoot":"","sources":["../../src/hooks/useGetWorkflowInstanceStatusById.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,KAAK,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAG5E,MAAM,MAAM,qBAAqB,GAAG,aAAa,CAAC;IAChD,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC,CAAC;AAEH,oBAAY,cAAc;IACxB,SAAS,cAAc;IACvB,MAAM,WAAW;IACjB,OAAO,YAAY;IACnB,QAAQ,aAAa;CACtB;AAED,MAAM,MAAM,QAAQ,GAAG;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;CAAE,CAAC;AAEzF,MAAM,MAAM,sBAAsB,GAAG;IACnC,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,cAAc,CAAC;IACvB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE;QACJ,SAAS,EAAE,QAAQ,EAAE,CAAC;QACtB,OAAO,EAAE,QAAQ,EAAE,CAAC;QACpB,MAAM,CAAC,EAAE,QAAQ,EAAE,CAAC;KACrB,CAAC;IACF,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,MAAM,MAAM,uBAAuB,GAAG,aAAa,CAAC,sBAAsB,CAAC,CAAC;AAE5E;;;;GAIG;AACH,wBAAgB,gCAAgC,CAAC,OAAO,KAAK,GAAG,iBAAiB,CAAC,uBAAuB,EAAE,KAAK,EAAE,qBAAqB,CAAC,CASvI"}
@@ -1 +1 @@
1
- {"version":3,"file":"useInputTable.d.ts","sourceRoot":"","sources":["../../src/hooks/useInputTable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAMtE,OAAO,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAEhD;;;;;;GAMG;AACH,wBAAgB,aAAa,CAC3B,YAAY,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EACvC,gBAAgB,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EAC3C,OAAO,GAAE,oBAAyB,GACjC,cAAc,CAAC,GAAG,EAAE,KAAK,CAAC,CA0B5B;AAGD;;GAEG;AACH,wBAAgB,iBAAiB,wCAchC"}
1
+ {"version":3,"file":"useInputTable.d.ts","sourceRoot":"","sources":["../../src/hooks/useInputTable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAMtE,OAAO,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAEhD;;;;;;GAMG;AACH,wBAAgB,aAAa,CAC3B,YAAY,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EACvC,gBAAgB,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EAC3C,OAAO,GAAE,oBAAyB,GACjC,cAAc,CAAC,GAAG,EAAE,KAAK,CAAC,CA8B5B;AAGD;;GAEG;AACH,wBAAgB,iBAAiB,wCAchC"}
@@ -1,11 +1,18 @@
1
- import { copaApi } from '@bluecopa/core';
1
+ import { UseMutationResult } from '@tanstack/react-query';
2
+ export interface TriggerHttpWorkflowRequest {
3
+ data: Record<string, any>;
4
+ triggerId: string;
5
+ }
6
+ export interface TriggerHttpWorkflowResponse {
7
+ triggeredWorkflows: {
8
+ workflowId: string;
9
+ triggerId: string;
10
+ }[];
11
+ }
2
12
  /**
3
13
  * Custom hook for triggering an HTTP workflow using TanStack React Query
4
14
  * @param options - Mutation options
5
15
  * @returns useMutation for triggering HTTP workflow
6
16
  */
7
- export declare function useTriggerHttpWorkflow(options?: {}): import('@tanstack/react-query').UseMutationResult<copaApi.workflow.TriggerHttpWorkflowResponse, Error, {
8
- data: Record<string, any>;
9
- triggerId: string;
10
- }, unknown>;
17
+ export declare function useTriggerHttpWorkflow(options?: {}): UseMutationResult<TriggerHttpWorkflowResponse, Error, TriggerHttpWorkflowRequest>;
11
18
  //# sourceMappingURL=useTriggerHttpWorkflow.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useTriggerHttpWorkflow.d.ts","sourceRoot":"","sources":["../../src/hooks/useTriggerHttpWorkflow.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAEzC;;;;GAIG;AACH,wBAAgB,sBAAsB,CAAC,OAAO,KAAK;UAEb,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC;eAAa,MAAM;YAO3E"}
1
+ {"version":3,"file":"useTriggerHttpWorkflow.d.ts","sourceRoot":"","sources":["../../src/hooks/useTriggerHttpWorkflow.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,KAAK,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAG5E,MAAM,WAAW,0BAA0B;IACzC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC1B,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,2BAA2B;IAC1C,kBAAkB,EAAE;QAClB,UAAU,EAAE,MAAM,CAAC;QACnB,SAAS,EAAE,MAAM,CAAC;KACnB,EAAE,CAAC;CACL;AAED;;;;GAIG;AACH,wBAAgB,sBAAsB,CAAC,OAAO,KAAK,GAAG,iBAAiB,CAAC,2BAA2B,EAAE,KAAK,EAAE,0BAA0B,CAAC,CAStI"}
@@ -1,11 +1,22 @@
1
- import { copaApi } from '@bluecopa/core';
1
+ import { UseMutationResult } from '@tanstack/react-query';
2
+ export interface TriggerWorkflowRequest {
3
+ parentId: string;
4
+ triggerBy: string;
5
+ }
6
+ export interface TriggerWorkflowResponse {
7
+ workbookId: string;
8
+ triggerBy: string;
9
+ instanceId: string;
10
+ triggerId: string;
11
+ workflowId: string;
12
+ status: string;
13
+ triggeredAt: string;
14
+ message: string;
15
+ }
2
16
  /**
3
17
  * Custom hook for triggering a workflow using TanStack React Query
4
18
  * @param options - Mutation options
5
19
  * @returns useMutation for triggering workflow
6
20
  */
7
- export declare function useTriggerWorkflow(options?: {}): import('@tanstack/react-query').UseMutationResult<copaApi.workflow.TriggerWorkflowResponse, Error, {
8
- parentId: string;
9
- triggerBy: string;
10
- }, unknown>;
21
+ export declare function useTriggerWorkflow(options?: {}): UseMutationResult<TriggerWorkflowResponse, Error, TriggerWorkflowRequest>;
11
22
  //# sourceMappingURL=useTriggerWorkflow.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useTriggerWorkflow.d.ts","sourceRoot":"","sources":["../../src/hooks/useTriggerWorkflow.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAEzC;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,KAAK;cAEL,MAAM;eAAa,MAAM;YAOlE"}
1
+ {"version":3,"file":"useTriggerWorkflow.d.ts","sourceRoot":"","sources":["../../src/hooks/useTriggerWorkflow.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,KAAK,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAG5E,MAAM,WAAW,sBAAsB;IACrC,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,uBAAuB;IACtC,UAAU,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,KAAK,GAAG,iBAAiB,CAAC,uBAAuB,EAAE,KAAK,EAAE,sBAAsB,CAAC,CAS1H"}