@bluecopa/react 0.1.4 → 0.1.6

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/README.md CHANGED
@@ -6,38 +6,48 @@ A React library providing opinionated custom hooks for TanStack React Query inte
6
6
 
7
7
  ## Table of Contents
8
8
 
9
- 1. [Features](#features)
10
- 2. [Installation](#installation)
11
- 3. [Usage](#usage)
12
- - [Query Provider Setup](#query-provider-setup)
13
- - [Boilerplate Integration](#boilerplate-integration)
14
- - [Hook Examples](#hook-examples)
15
- 4. [API Documentation](#api-documentation)
16
- - [`useUser`](#useuser)
17
- - [`useDataset`](#usedataset)
18
- - [`useDatasetSample`](#usedatasetsample)
19
- - [`useMetric`](#usemetric)
20
- - [`useInputTable`](#useinputtable)
21
- - [`useGetFileUrlByFileId`](#usegetfileurlbyfileid)
22
- - [`useGetPublishedWorkbookById`](#usegetpublishedworkbookbyid)
23
- - [`useGetTableById`](#usegettablebyid)
24
- - [`useGetWorkbooksByType`](#usegetworkbooksbytype)
25
- - [`useGetWorkflowInstanceStatusById`](#usegetworkflowinstancestatusbyid)
26
- - [`useGetWorksheets`](#usegetworksheets)
27
- - [`useGetWorksheetsByType`](#usegetworksheetsbytype)
28
- - [`useRunDefinition`](#userundefinition)
29
- - [`useRunPublishedDefinition`](#userunpublisheddefinition)
30
- - [`useRunSampleDefinition`](#userunsampledefinition)
31
- - [`useTriggerHttpWorkflow`](#usetriggerhttpworkflow)
32
- - [`useTriggerWorkflow`](#usetriggerworkflow)
33
- - [`useWorkbook`](#useworkbook)
34
- - [`useWorkflow`](#useworkflow)
35
- - [`useWorksheet`](#useworksheet)
36
- 5. [Configuration](#configuration)
37
- 6. [TypeScript Support](#typescript-support)
38
- 7. [Development](#development)
39
- 8. [Contributing](#contributing)
40
- 9. [License](#license)
9
+ - [@bluecopa/react ](#bluecopareact--)
10
+ - [A Comprehensive React Query Integration for Bluecopa](#a-comprehensive-react-query-integration-for-bluecopa)
11
+ - [Table of Contents](#table-of-contents)
12
+ - [Features](#features)
13
+ - [Installation](#installation)
14
+ - [Peer Dependencies](#peer-dependencies)
15
+ - [Usage](#usage)
16
+ - [Query Provider Setup](#query-provider-setup)
17
+ - [Boilerplate Integration](#boilerplate-integration)
18
+ - [Hook Examples](#hook-examples)
19
+ - [`useUser` - Fetch authenticated user](#useuser---fetch-authenticated-user)
20
+ - [`useDataset` - Fetch dataset with query controls](#usedataset---fetch-dataset-with-query-controls)
21
+ - [API Documentation](#api-documentation)
22
+ - [`useUser(options?)`](#useuseroptions)
23
+ - [`useDataset(datasetId, options?)`](#usedatasetdatasetid-options)
24
+ - [`useDatasetSample(datasetId, options?)`](#usedatasetsampledatasetid-options)
25
+ - [`useMetric(metricId, options?)`](#usemetricmetricid-options)
26
+ - [`useInputTable(inputTableId, options?)`](#useinputtableinputtableid-options)
27
+ - [`useGetFileUrlByFileId(fileId, options?)`](#usegetfileurlbyfileidfileid-options)
28
+ - [`useGetPublishedWorkbookById(workbookId, options?)`](#usegetpublishedworkbookbyidworkbookid-options)
29
+ - [`useGetTableById(tableId, options?)`](#usegettablebyidtableid-options)
30
+ - [`useGetWorkbooksByType(workbookType, options?)`](#usegetworkbooksbytypeworkbooktype-options)
31
+ - [`useGetWorkflowInstanceStatusById(instanceId, options?)`](#usegetworkflowinstancestatusbyidinstanceid-options)
32
+ - [`useGetWorksheets(options?)`](#usegetworksheetsoptions)
33
+ - [`useGetWorksheetsByType(worksheetType, options?)`](#usegetworksheetsbytypeworksheettype-options)
34
+ - [`useRunDefinition(definitionId, options?)`](#userundefinitiondefinitionid-options)
35
+ - [`useRunPublishedDefinition(publishedDefinitionId, options?)`](#userunpublisheddefinitionpublisheddefinitionid-options)
36
+ - [`useRunSampleDefinition(sampleDefinitionId, options?)`](#userunsampledefinitionsampledefinitionid-options)
37
+ - [`useTriggerHttpWorkflow(workflowId, payload, options?)`](#usetriggerhttpworkflowworkflowid-payload-options)
38
+ - [`useTriggerWorkflow(workflowId, options?)`](#usetriggerworkflowworkflowid-options)
39
+ - [`useWorkbook(workbookId, options?)`](#useworkbookworkbookid-options)
40
+ - [`useWorkflow(workflowId, options?)`](#useworkflowworkflowid-options)
41
+ - [`useWorksheet(worksheetId, options?)`](#useworksheetworksheetid-options)
42
+ - [Configuration](#configuration)
43
+ - [Default Query Configuration](#default-query-configuration)
44
+ - [Customizable Parameters](#customizable-parameters)
45
+ - [Advanced Usage](#advanced-usage)
46
+ - [Error Handling](#error-handling)
47
+ - [Manual Refetching](#manual-refetching)
48
+ - [Re-exports](#re-exports)
49
+ - [TypeScript Support](#typescript-support)
50
+ - [Development](#development)
41
51
 
42
52
  ## Features
43
53
 
@@ -146,13 +156,13 @@ export default function QueryProvider({ children }: { children: React.ReactNode
146
156
 
147
157
  | Variable | Description | Example |
148
158
  |----------|-------------|---------|
149
- | `VITE_BLUECOPA_API_URL` | Base URL for Bluecopa API | `https://api.bluecopa.com` |
159
+ | `VITE_BLUECOPA_API_URL` | Base URL for Bluecopa API | `https://develop.bluecopa.com` |
150
160
  | `VITE_BLUECOPA_WORKSPACE_ID` | Your workspace identifier | `my-workspace-123` |
151
161
  | `VITE_BLUECOPA_API_TOKEN` | Base64-encoded JSON string containing `accessToken` | `eyJhY2Nlc3NUb2tlbiI6IjEyMzQ1In0=` |
152
162
 
153
163
  **Example `.env` file:**
154
164
  ```
155
- VITE_BLUECOPA_API_URL=https://api.bluecopa.com
165
+ VITE_BLUECOPA_API_URL=https://develop.bluecopa.com
156
166
  VITE_BLUECOPA_WORKSPACE_ID=your-workspace-id
157
167
  VITE_BLUECOPA_API_TOKEN=base64-encoded-json-here
158
168
  ```
@@ -1,5 +1,5 @@
1
- import { c, T as l, P as m, a as u, D as v, Q as i } from "./VREWMQAW-Cr9gkBCt.js";
2
- import { g as d, c as f, a as e } from "./index-BBZbg2TO.js";
1
+ import { c, T as l, P as m, a as u, D as v, Q as i } from "./VREWMQAW-BhT_9cpE.js";
2
+ import { g as d, c as f, a as e } from "./index-D5og7-RT.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-Cr9gkBCt.js";
2
- import { g as v, c as C, a as e } from "./index-BBZbg2TO.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-BhT_9cpE.js";
2
+ import { g as v, c as C, a as e } from "./index-D5og7-RT.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-BBZbg2TO.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-D5og7-RT.js";
5
5
  var _s = (e) => e != null, qs = (e) => e.filter(_s);
6
6
  function Rs(e) {
7
7
  return (...t) => {