@querypanel/node-sdk 1.0.55 → 1.0.57
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 +9 -1
- package/dist/index.cjs +690 -35
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +459 -10
- package/dist/index.d.ts +459 -10
- package/dist/index.js +688 -35
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -212,7 +212,10 @@ const monthly = await qp.modifyChart({
|
|
|
212
212
|
timeGranularity: "month",
|
|
213
213
|
dateRange: { from: "2024-01-01", to: "2024-12-31" },
|
|
214
214
|
},
|
|
215
|
-
}, {
|
|
215
|
+
}, {
|
|
216
|
+
tenantId: "tenant_123",
|
|
217
|
+
querypanelSessionId: response.querypanelSessionId, // preserve follow-up context
|
|
218
|
+
});
|
|
216
219
|
|
|
217
220
|
console.log(monthly.sql); // New SQL with monthly GROUP BY
|
|
218
221
|
console.log(monthly.modified.sqlChanged); // true
|
|
@@ -275,6 +278,11 @@ const combined = await qp.modifyChart({
|
|
|
275
278
|
|
|
276
279
|
Load a saved chart and modify it:
|
|
277
280
|
|
|
281
|
+
If you do not have a previous `querypanelSessionId` (common for persisted charts),
|
|
282
|
+
the SDK starts a new QueryPanel session and sends the full original question with
|
|
283
|
+
your modification hints. If you have one from an earlier `ask()` call, pass it to
|
|
284
|
+
keep follow-up context.
|
|
285
|
+
|
|
278
286
|
```ts
|
|
279
287
|
// Load a saved chart
|
|
280
288
|
const savedChart = await qp.getChart("chart_id_123", {
|