@malloy-publisher/sdk 0.14.0 → 0.16.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.
- package/dist/{RenderedResult-C9PiHrGC.cjs.js → RenderedResult-DTM9o4Ql.cjs.js} +1 -1
- package/dist/{RenderedResult-D0kAzSrP.es.js → RenderedResult-vyM2wQbC.es.js} +9 -9
- package/dist/ServerProvider-DpOy4_Kf.cjs.js +1 -0
- package/dist/{ServerProvider-BHM9y5l0.es.js → ServerProvider-lAZ5ZdQS.es.js} +1182 -1034
- package/dist/builder/index.cjs.js +1 -1
- package/dist/builder/index.es.js +335 -335
- package/dist/client/api.d.ts +324 -82
- package/dist/client/index.cjs.js +1 -1
- package/dist/client/index.es.js +110 -104
- package/dist/components/Materializations/DeleteMaterializationDialog.d.ts +1 -1
- package/dist/components/Materializations/MaterializationRunsList.d.ts +1 -1
- package/dist/components/Materializations/utils.d.ts +7 -4
- package/dist/components/Package/PackageProblems.d.ts +6 -0
- package/dist/index.cjs.js +38 -38
- package/dist/index.es.js +6176 -6665
- package/dist/{useCompiledDocument-Co-INO6B.cjs.js → useCompiledDocument-2huaKTJN.cjs.js} +20 -20
- package/dist/{useCompiledDocument-CF5s0cXj.es.js → useCompiledDocument-CSXZufFO.es.js} +56 -60
- package/package.json +1 -1
- package/src/components/Materializations/DeleteMaterializationDialog.tsx +5 -16
- package/src/components/Materializations/MaterializationRunsList.tsx +3 -5
- package/src/components/Materializations/Materializations.tsx +3 -13
- package/src/components/Materializations/Materializations.versions.spec.tsx +6 -3
- package/src/components/Materializations/TriggerLabel.tsx +2 -2
- package/src/components/Materializations/utils.spec.ts +6 -1
- package/src/components/Materializations/utils.ts +11 -5
- package/src/components/Package/PackageProblems.spec.tsx +25 -1
- package/src/components/Package/PackageProblems.tsx +30 -12
- package/src/components/RenderedResult/RenderedResult.lifecycle.spec.tsx +15 -1
- package/dist/ServerProvider-D97_rUv5.cjs.js +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as z } from "react/jsx-runtime";
|
|
2
2
|
import { QueryClient as ye, QueryClientProvider as Ce, useQuery as Ie } from "@tanstack/react-query";
|
|
3
3
|
import u from "axios";
|
|
4
|
-
import { useContext as le, useMemo as B, createContext as
|
|
4
|
+
import { useContext as le, useMemo as B, createContext as ce, useState as oe, useEffect as Re, useCallback as xe } from "react";
|
|
5
5
|
import { styled as j, Card as Ne, CardContent as Ue, CardMedia as Te } from "@mui/material";
|
|
6
6
|
const se = "ui-monospace, SFMono-Regular, Menlo, Consolas, monospace", U = {
|
|
7
7
|
radius: { control: "6px", tile: "8px", menu: "10px", dialog: "12px" },
|
|
@@ -35,7 +35,7 @@ function Ee(l) {
|
|
|
35
35
|
shadow: { ...U.shadow, ...l.shadow }
|
|
36
36
|
};
|
|
37
37
|
}
|
|
38
|
-
const
|
|
38
|
+
const R = {
|
|
39
39
|
blue: "#2563eb",
|
|
40
40
|
indigo: "#4f46e5",
|
|
41
41
|
violet: "#7c3aed",
|
|
@@ -49,9 +49,9 @@ const x = {
|
|
|
49
49
|
cyan: "#0e7490",
|
|
50
50
|
slate: "#475569"
|
|
51
51
|
}, Ma = {
|
|
52
|
-
environment:
|
|
53
|
-
package:
|
|
54
|
-
connection:
|
|
52
|
+
environment: R.emerald,
|
|
53
|
+
package: R.teal,
|
|
54
|
+
connection: R.orange
|
|
55
55
|
}, Fa = '"JetBrains Mono", "ui-monospace", "SFMono-Regular", "Menlo", monospace', Ba = j(Ne)({
|
|
56
56
|
display: "flex",
|
|
57
57
|
flexDirection: "column",
|
|
@@ -74,15 +74,15 @@ const x = {
|
|
|
74
74
|
border: "none",
|
|
75
75
|
boxShadow: "none",
|
|
76
76
|
marginBottom: "0"
|
|
77
|
-
}),
|
|
77
|
+
}), za = j("div")({
|
|
78
78
|
height: "100%"
|
|
79
|
-
}),
|
|
79
|
+
}), Qa = j("div")({
|
|
80
80
|
height: "75vh",
|
|
81
81
|
width: "100%",
|
|
82
82
|
overflowY: "auto"
|
|
83
83
|
}), fe = {
|
|
84
84
|
light: {
|
|
85
|
-
accent:
|
|
85
|
+
accent: R.blue,
|
|
86
86
|
accentHover: "#1d4ed8",
|
|
87
87
|
accentContrast: "#ffffff"
|
|
88
88
|
},
|
|
@@ -94,7 +94,7 @@ const x = {
|
|
|
94
94
|
}, we = {
|
|
95
95
|
light: "#ffffff",
|
|
96
96
|
dark: "#0f172a"
|
|
97
|
-
}, Me = 3,
|
|
97
|
+
}, Me = 3, f = (l) => {
|
|
98
98
|
const r = /^#?([0-9a-f]{3}|[0-9a-f]{6})$/i.exec(l.trim());
|
|
99
99
|
if (!r) return;
|
|
100
100
|
const a = r[1].length === 3 ? [...r[1]].map((n) => n + n).join("") : r[1];
|
|
@@ -105,46 +105,46 @@ const x = {
|
|
|
105
105
|
return t <= 0.03928 ? t / 12.92 : ((t + 0.055) / 1.055) ** 2.4;
|
|
106
106
|
});
|
|
107
107
|
return 0.2126 * r + 0.7152 * a + 0.0722 * n;
|
|
108
|
-
},
|
|
108
|
+
}, Q = (l, r) => {
|
|
109
109
|
const [a, n] = [K(l), K(r)].sort((e, t) => t - e);
|
|
110
110
|
return (a + 0.05) / (n + 0.05);
|
|
111
111
|
};
|
|
112
|
-
function
|
|
113
|
-
const a =
|
|
114
|
-
return a && n ?
|
|
112
|
+
function _a(l, r) {
|
|
113
|
+
const a = f(l), n = f(r);
|
|
114
|
+
return a && n ? Q(a, n) : void 0;
|
|
115
115
|
}
|
|
116
116
|
const Fe = [15, 23, 42];
|
|
117
117
|
function $(l, r, a = Me) {
|
|
118
|
-
const n =
|
|
119
|
-
if (!n || !e ||
|
|
118
|
+
const n = f(l), e = f(r);
|
|
119
|
+
if (!n || !e || Q(n, e) >= a) return l;
|
|
120
120
|
const t = K(e) < 0.5 ? 255 : 0;
|
|
121
121
|
for (let s = 0.05; s < 1; s += 0.05) {
|
|
122
|
-
const o =
|
|
123
|
-
if (o &&
|
|
122
|
+
const o = f(W(n, t, s));
|
|
123
|
+
if (o && Q(o, e) >= a) return pe(o);
|
|
124
124
|
}
|
|
125
125
|
return t === 255 ? "#ffffff" : "#000000";
|
|
126
126
|
}
|
|
127
|
-
function
|
|
127
|
+
function ie(l, r, a = we[r]) {
|
|
128
128
|
const n = fe[r];
|
|
129
|
-
if (!l || l.toLowerCase() ===
|
|
130
|
-
if (!
|
|
129
|
+
if (!l || l.toLowerCase() === R.blue) return n;
|
|
130
|
+
if (!f(l))
|
|
131
131
|
return r === "light" ? { ...n, accent: l, accentHover: l } : n;
|
|
132
|
-
const e = $(l, a), t =
|
|
132
|
+
const e = $(l, a), t = f(e), s = r === "dark" ? W(t, 255, 0.25) : W(t, 0, 0.2), o = Q(t, [255, 255, 255]), i = Q(t, Fe);
|
|
133
133
|
return {
|
|
134
134
|
accent: e,
|
|
135
135
|
accentHover: s,
|
|
136
|
-
accentContrast: o >=
|
|
136
|
+
accentContrast: o >= i ? "#ffffff" : "#0f172a"
|
|
137
137
|
};
|
|
138
138
|
}
|
|
139
139
|
const Be = [
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
140
|
+
R.blue,
|
|
141
|
+
R.orange,
|
|
142
|
+
R.emerald,
|
|
143
|
+
R.pink,
|
|
144
|
+
R.violet,
|
|
145
|
+
R.amber,
|
|
146
|
+
R.cyan,
|
|
147
|
+
R.lime
|
|
148
148
|
], je = "Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif", Y = {
|
|
149
149
|
defaultMode: "light",
|
|
150
150
|
allowUserToggle: !0,
|
|
@@ -196,8 +196,8 @@ const Be = [
|
|
|
196
196
|
// pairs this with a near-neutral low end. Matches the first series
|
|
197
197
|
// colour, so a map and a chart on one page ramp to the same hue.
|
|
198
198
|
mapColor: {
|
|
199
|
-
light:
|
|
200
|
-
dark:
|
|
199
|
+
light: R.blue,
|
|
200
|
+
dark: R.blue
|
|
201
201
|
},
|
|
202
202
|
// Table gridlines and row rules: a hairline, because a table has dozens
|
|
203
203
|
// of them and they only have to separate rows.
|
|
@@ -259,7 +259,7 @@ function de(l, r) {
|
|
|
259
259
|
size: 12
|
|
260
260
|
};
|
|
261
261
|
let e = [...a.series ?? []], t = !1, s = n.family ?? "sans-serif", o = n.size ?? 12;
|
|
262
|
-
const
|
|
262
|
+
const i = {
|
|
263
263
|
background: { ...a.background ?? {} },
|
|
264
264
|
tableHeader: { ...a.tableHeader ?? {} },
|
|
265
265
|
tableHeaderBackground: {
|
|
@@ -275,7 +275,7 @@ function de(l, r) {
|
|
|
275
275
|
gridline: { ...a.gridline ?? {} },
|
|
276
276
|
chartText: { ...a.chartText ?? {} },
|
|
277
277
|
value: { ...a.value ?? {} }
|
|
278
|
-
},
|
|
278
|
+
}, c = {
|
|
279
279
|
light: /* @__PURE__ */ new Set(),
|
|
280
280
|
dark: /* @__PURE__ */ new Set()
|
|
281
281
|
};
|
|
@@ -284,11 +284,11 @@ function de(l, r) {
|
|
|
284
284
|
Array.isArray(O.palette?.series) && (e = [...O.palette.series], t = !0);
|
|
285
285
|
for (const y of De) {
|
|
286
286
|
const N = O.palette?.[y];
|
|
287
|
-
N && (
|
|
287
|
+
N && (i[y] = { ...i[y], ...N }, N.light !== void 0 && c.light.add(y), N.dark !== void 0 && c.dark.add(y));
|
|
288
288
|
}
|
|
289
289
|
typeof O.font?.family == "string" && (s = O.font.family), typeof O.font?.size == "number" && (o = O.font.size);
|
|
290
290
|
}
|
|
291
|
-
const p = r === "dark", d = (O) =>
|
|
291
|
+
const p = r === "dark", d = (O) => i[O][r] ?? a[O]?.[r], h = d("background"), k = p && c.light.has("mapColor") && !c.dark.has("mapColor") ? $(i.mapColor.light, h) : d("mapColor");
|
|
292
292
|
return {
|
|
293
293
|
mode: r,
|
|
294
294
|
// The host's chrome tokens are laid over this by `ThemeProvider`.
|
|
@@ -297,7 +297,7 @@ function de(l, r) {
|
|
|
297
297
|
// an operator's colour too dark to see on the canvas is lifted until it
|
|
298
298
|
// reads. The defaults are drawn as they always were.
|
|
299
299
|
series: p && t ? e.map((O) => $(O, h)) : e,
|
|
300
|
-
...
|
|
300
|
+
...ie(e[0], r, h),
|
|
301
301
|
font: { family: s, size: o },
|
|
302
302
|
background: h,
|
|
303
303
|
tableHeader: d("tableHeader"),
|
|
@@ -345,32 +345,32 @@ function de(l, r) {
|
|
|
345
345
|
// contrast on the slate panel.
|
|
346
346
|
// The Console's default accent, not the palette's: a drill reads as a
|
|
347
347
|
// link whatever the operator picked for the data.
|
|
348
|
-
drillLink:
|
|
348
|
+
drillLink: ie(void 0, r).accent
|
|
349
349
|
};
|
|
350
350
|
}
|
|
351
|
-
function
|
|
351
|
+
function qa(l, r) {
|
|
352
352
|
const a = r.palette?.series;
|
|
353
353
|
if (!Array.isArray(a) || a.length !== 1) return r;
|
|
354
354
|
const n = a[0], e = l.reduce(
|
|
355
|
-
(
|
|
355
|
+
(c, p) => Array.isArray(p?.palette?.series) ? p.palette.series : c,
|
|
356
356
|
Y.palette?.series ?? []
|
|
357
|
-
), t = (
|
|
357
|
+
), t = (c) => c.toLowerCase() === n.toLowerCase(), [s, ...o] = e, i = o.length > 0 ? o.map((c) => t(c) ? s : c) : (
|
|
358
358
|
// A one-colour host palette has no second slot, so its one colour is the second series.
|
|
359
359
|
[s].filter(
|
|
360
|
-
(
|
|
360
|
+
(c) => c !== void 0 && !t(c)
|
|
361
361
|
)
|
|
362
362
|
);
|
|
363
363
|
return {
|
|
364
364
|
...r,
|
|
365
|
-
palette: { ...r.palette, series: [n, ...
|
|
365
|
+
palette: { ...r.palette, series: [n, ...i] }
|
|
366
366
|
};
|
|
367
367
|
}
|
|
368
368
|
function Le(l, r, a) {
|
|
369
369
|
const n = r ?? l ?? "light";
|
|
370
370
|
return n === "auto" ? a ? "dark" : "light" : n;
|
|
371
371
|
}
|
|
372
|
-
const me =
|
|
373
|
-
function
|
|
372
|
+
const me = ce(void 0);
|
|
373
|
+
function ze({
|
|
374
374
|
layers: l,
|
|
375
375
|
mode: r,
|
|
376
376
|
userChoice: a,
|
|
@@ -379,20 +379,20 @@ function Qe({
|
|
|
379
379
|
ui: t,
|
|
380
380
|
children: s
|
|
381
381
|
}) {
|
|
382
|
-
const o = JSON.stringify(t ?? null),
|
|
382
|
+
const o = JSON.stringify(t ?? null), i = B(
|
|
383
383
|
() => Ee(t),
|
|
384
384
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
385
385
|
[o]
|
|
386
|
-
),
|
|
387
|
-
() => ({ ...de(l, r), ui:
|
|
388
|
-
[l, r,
|
|
386
|
+
), c = B(
|
|
387
|
+
() => ({ ...de(l, r), ui: i }),
|
|
388
|
+
[l, r, i]
|
|
389
389
|
), p = B(
|
|
390
|
-
() => ({ theme:
|
|
391
|
-
[
|
|
390
|
+
() => ({ theme: c, layers: l, mode: r, userChoice: a, setMode: n, allowUserToggle: e }),
|
|
391
|
+
[c, l, r, a, n, e]
|
|
392
392
|
);
|
|
393
|
-
return /* @__PURE__ */
|
|
393
|
+
return /* @__PURE__ */ z(me.Provider, { value: p, children: s });
|
|
394
394
|
}
|
|
395
|
-
function
|
|
395
|
+
function Ha() {
|
|
396
396
|
const l = le(me);
|
|
397
397
|
return l || {
|
|
398
398
|
theme: de([], "light"),
|
|
@@ -411,14 +411,14 @@ class I {
|
|
|
411
411
|
}
|
|
412
412
|
configuration;
|
|
413
413
|
}
|
|
414
|
-
class
|
|
414
|
+
class Qe extends Error {
|
|
415
415
|
constructor(r, a) {
|
|
416
416
|
super(a), this.field = r, this.name = "RequiredError";
|
|
417
417
|
}
|
|
418
418
|
}
|
|
419
|
-
const P = {},
|
|
419
|
+
const P = {}, b = "https://example.com", m = function(l, r, a) {
|
|
420
420
|
if (a == null)
|
|
421
|
-
throw new
|
|
421
|
+
throw new Qe(r, `Required parameter ${r} was null or undefined when calling ${l}.`);
|
|
422
422
|
};
|
|
423
423
|
function J(l, r, a = "") {
|
|
424
424
|
r != null && (typeof r == "object" ? Array.isArray(r) || r instanceof Set ? r.forEach((n) => J(l, n, a)) : Object.keys(r).forEach(
|
|
@@ -428,12 +428,12 @@ function J(l, r, a = "") {
|
|
|
428
428
|
const v = function(l, ...r) {
|
|
429
429
|
const a = new URLSearchParams(l.search);
|
|
430
430
|
J(a, r), l.search = a.toString();
|
|
431
|
-
},
|
|
431
|
+
}, _e = function(l, r) {
|
|
432
432
|
return r instanceof Set ? Array.from(r) : r;
|
|
433
433
|
}, A = function(l, r, a) {
|
|
434
434
|
const n = typeof l != "string";
|
|
435
|
-
return (n && a && a.isJsonMime ? a.isJsonMime(r.headers["Content-Type"]) : n) ? JSON.stringify(l !== void 0 ? l : {},
|
|
436
|
-
},
|
|
435
|
+
return (n && a && a.isJsonMime ? a.isJsonMime(r.headers["Content-Type"]) : n) ? JSON.stringify(l !== void 0 ? l : {}, _e) : l || "";
|
|
436
|
+
}, V = function(l) {
|
|
437
437
|
return l.pathname + l.search + l.hash;
|
|
438
438
|
}, S = function(l, r, a, n) {
|
|
439
439
|
return (e = r, t = a) => {
|
|
@@ -498,7 +498,7 @@ const v = function(l, ...r) {
|
|
|
498
498
|
}, st = {
|
|
499
499
|
Embedded: "embedded",
|
|
500
500
|
Materialized: "materialized"
|
|
501
|
-
},
|
|
501
|
+
}, it = {
|
|
502
502
|
Equal: "equal",
|
|
503
503
|
In: "in",
|
|
504
504
|
Like: "like",
|
|
@@ -508,7 +508,7 @@ const v = function(l, ...r) {
|
|
|
508
508
|
Live: "live",
|
|
509
509
|
StaleOk: "stale_ok",
|
|
510
510
|
Fail: "fail"
|
|
511
|
-
},
|
|
511
|
+
}, ct = {
|
|
512
512
|
Select: "select",
|
|
513
513
|
Multiselect: "multiselect"
|
|
514
514
|
}, pt = {
|
|
@@ -521,6 +521,10 @@ const v = function(l, ...r) {
|
|
|
521
521
|
Error: "error"
|
|
522
522
|
}, mt = {
|
|
523
523
|
Persist: "persist",
|
|
524
|
+
Materialize: "materialize",
|
|
525
|
+
View: "view",
|
|
526
|
+
Query: "query",
|
|
527
|
+
Rollup: "rollup",
|
|
524
528
|
Preaggregate: "preaggregate"
|
|
525
529
|
}, ht = {
|
|
526
530
|
Reused: "reused",
|
|
@@ -534,42 +538,47 @@ const v = function(l, ...r) {
|
|
|
534
538
|
Full: "full",
|
|
535
539
|
None: "none"
|
|
536
540
|
}, Pt = {
|
|
541
|
+
AuthorName: "author_name",
|
|
542
|
+
DestinationMissing: "destination_missing",
|
|
543
|
+
MayBeServed: "may_be_served"
|
|
544
|
+
}, bt = {
|
|
537
545
|
Pending: "PENDING",
|
|
538
546
|
ManifestRowsReady: "MANIFEST_ROWS_READY",
|
|
539
547
|
ManifestFileReady: "MANIFEST_FILE_READY",
|
|
540
548
|
Failed: "FAILED",
|
|
541
549
|
Cancelled: "CANCELLED"
|
|
542
|
-
},
|
|
550
|
+
}, vt = {
|
|
543
551
|
Compile: "compile",
|
|
544
552
|
Extraction: "extraction"
|
|
545
|
-
},
|
|
553
|
+
}, Vt = {
|
|
546
554
|
Markdown: "markdown",
|
|
547
555
|
Code: "code"
|
|
548
|
-
},
|
|
556
|
+
}, St = {
|
|
549
557
|
Markdown: "markdown",
|
|
550
558
|
Query: "query",
|
|
551
559
|
Definition: "definition"
|
|
552
|
-
},
|
|
560
|
+
}, kt = {
|
|
553
561
|
Markdown: "markdown",
|
|
554
562
|
Code: "code"
|
|
555
|
-
},
|
|
563
|
+
}, Ot = {
|
|
556
564
|
Markdown: "markdown",
|
|
557
565
|
Query: "query",
|
|
558
566
|
Definition: "definition"
|
|
559
|
-
},
|
|
567
|
+
}, At = {
|
|
560
568
|
Archive: "archive",
|
|
561
569
|
Unarchive: "unarchive"
|
|
562
|
-
},
|
|
570
|
+
}, yt = {
|
|
563
571
|
Version: "version",
|
|
564
572
|
Package: "package"
|
|
565
|
-
},
|
|
573
|
+
}, Ct = {
|
|
566
574
|
Declared: "declared",
|
|
567
575
|
All: "all"
|
|
568
|
-
},
|
|
576
|
+
}, It = {
|
|
569
577
|
Unbound: "unbound",
|
|
570
578
|
Bound: "bound",
|
|
579
|
+
BindFailed: "bind_failed",
|
|
571
580
|
LiveFallback: "live_fallback"
|
|
572
|
-
},
|
|
581
|
+
}, Rt = {
|
|
573
582
|
Lexical: "lexical",
|
|
574
583
|
Indexing: "indexing",
|
|
575
584
|
Ready: "ready",
|
|
@@ -579,87 +588,123 @@ const v = function(l, ...r) {
|
|
|
579
588
|
}, xt = {
|
|
580
589
|
Cooldown: "cooldown",
|
|
581
590
|
TooManyEntities: "too-many-entities"
|
|
582
|
-
},
|
|
591
|
+
}, Nt = {
|
|
583
592
|
Keyphrase: "keyphrase",
|
|
584
593
|
SourceSummary: "source_summary"
|
|
585
|
-
},
|
|
594
|
+
}, Ut = {
|
|
586
595
|
Archive: "archive",
|
|
587
596
|
Unarchive: "unarchive"
|
|
588
|
-
},
|
|
597
|
+
}, Tt = {
|
|
589
598
|
Unbound: "unbound",
|
|
590
599
|
Bound: "bound",
|
|
600
|
+
BindFailed: "bind_failed",
|
|
591
601
|
LiveFallback: "live_fallback"
|
|
592
|
-
},
|
|
602
|
+
}, Et = {
|
|
593
603
|
Archive: "archive",
|
|
594
604
|
Unarchive: "unarchive"
|
|
595
|
-
},
|
|
605
|
+
}, ft = {
|
|
596
606
|
Version: "version",
|
|
597
607
|
Package: "package"
|
|
598
|
-
},
|
|
608
|
+
}, wt = {
|
|
599
609
|
Declared: "declared",
|
|
600
610
|
All: "all"
|
|
601
|
-
},
|
|
611
|
+
}, Mt = {
|
|
602
612
|
Unbound: "unbound",
|
|
603
613
|
Bound: "bound",
|
|
614
|
+
BindFailed: "bind_failed",
|
|
604
615
|
LiveFallback: "live_fallback"
|
|
605
|
-
},
|
|
616
|
+
}, Ft = {
|
|
606
617
|
Archive: "archive",
|
|
607
618
|
Unarchive: "unarchive"
|
|
608
|
-
},
|
|
619
|
+
}, Bt = {
|
|
609
620
|
Unbound: "unbound",
|
|
610
621
|
Bound: "bound",
|
|
622
|
+
BindFailed: "bind_failed",
|
|
611
623
|
LiveFallback: "live_fallback"
|
|
612
|
-
}, Bt = {
|
|
613
|
-
Archive: "archive",
|
|
614
|
-
Unarchive: "unarchive"
|
|
615
624
|
}, jt = {
|
|
616
625
|
Archive: "archive",
|
|
617
626
|
Unarchive: "unarchive"
|
|
618
627
|
}, Dt = {
|
|
628
|
+
Archive: "archive",
|
|
629
|
+
Unarchive: "unarchive"
|
|
630
|
+
}, Lt = {
|
|
619
631
|
Error: "error",
|
|
620
632
|
Warn: "warn"
|
|
621
|
-
},
|
|
633
|
+
}, zt = {
|
|
622
634
|
Persist: "persist",
|
|
635
|
+
Materialize: "materialize",
|
|
636
|
+
View: "view",
|
|
637
|
+
Query: "query",
|
|
638
|
+
Rollup: "rollup",
|
|
623
639
|
Preaggregate: "preaggregate"
|
|
624
640
|
}, Qt = {
|
|
625
641
|
Disable: "disable",
|
|
626
642
|
NoVerify: "no-verify",
|
|
627
643
|
VerifyCa: "verify-ca",
|
|
628
644
|
VerifyFull: "verify-full"
|
|
629
|
-
},
|
|
645
|
+
}, _t = {
|
|
630
646
|
Interactive: "interactive",
|
|
631
647
|
Materialize: "materialize",
|
|
632
648
|
Index: "index",
|
|
633
649
|
Ops: "ops"
|
|
634
|
-
},
|
|
650
|
+
}, qt = {
|
|
651
|
+
Persist: "persist",
|
|
652
|
+
Materialize: "materialize",
|
|
653
|
+
View: "view",
|
|
654
|
+
Query: "query",
|
|
655
|
+
Rollup: "rollup"
|
|
656
|
+
}, Ht = {
|
|
635
657
|
Used: "used",
|
|
636
658
|
Skipped: "skipped"
|
|
637
|
-
},
|
|
659
|
+
}, Gt = {
|
|
660
|
+
Persist: "persist",
|
|
661
|
+
Materialize: "materialize",
|
|
662
|
+
View: "view",
|
|
663
|
+
Query: "query",
|
|
664
|
+
Rollup: "rollup"
|
|
665
|
+
}, Wt = {
|
|
638
666
|
Sibling: "sibling",
|
|
639
667
|
Below: "below"
|
|
640
|
-
},
|
|
668
|
+
}, Kt = {
|
|
669
|
+
Persist: "persist",
|
|
670
|
+
Materialize: "materialize",
|
|
671
|
+
View: "view",
|
|
672
|
+
Query: "query",
|
|
673
|
+
Rollup: "rollup"
|
|
674
|
+
}, $t = {
|
|
675
|
+
Database: "database",
|
|
676
|
+
Storage: "storage"
|
|
677
|
+
}, Yt = {
|
|
641
678
|
View: "view",
|
|
642
679
|
Query: "query",
|
|
643
680
|
Rollup: "rollup",
|
|
644
681
|
Materialized: "materialized",
|
|
645
682
|
Live: "live"
|
|
646
|
-
},
|
|
683
|
+
}, Jt = {
|
|
647
684
|
Query: "query",
|
|
648
685
|
ServerDefault: "server_default"
|
|
649
|
-
},
|
|
686
|
+
}, Zt = {
|
|
650
687
|
Storage: "storage",
|
|
688
|
+
Database: "database",
|
|
651
689
|
LiveFallback: "live_fallback"
|
|
652
|
-
},
|
|
690
|
+
}, Xt = {
|
|
653
691
|
Malloynb: "malloynb",
|
|
654
692
|
Malloy: "malloy"
|
|
655
|
-
},
|
|
693
|
+
}, en = {
|
|
656
694
|
Snapshot: "SNAPSHOT",
|
|
657
695
|
Copy: "COPY"
|
|
658
|
-
},
|
|
696
|
+
}, an = {
|
|
697
|
+
Persist: "persist",
|
|
698
|
+
Materialize: "materialize",
|
|
699
|
+
View: "view",
|
|
700
|
+
Query: "query",
|
|
701
|
+
Rollup: "rollup"
|
|
702
|
+
}, tn = {
|
|
659
703
|
Storage: "storage",
|
|
660
|
-
|
|
661
|
-
Preaggregate: "preaggregate"
|
|
662
|
-
|
|
704
|
+
Database: "database",
|
|
705
|
+
Preaggregate: "preaggregate",
|
|
706
|
+
Colocated: "colocated"
|
|
707
|
+
}, nn = {
|
|
663
708
|
FreeParameter: "free_parameter",
|
|
664
709
|
Given: "given",
|
|
665
710
|
GivenInPersistedQuery: "given_in_persisted_query",
|
|
@@ -676,70 +721,100 @@ const v = function(l, ...r) {
|
|
|
676
721
|
NotDuckdbPortable: "not_duckdb_portable",
|
|
677
722
|
PublicSurfaceUnknown: "public_surface_unknown",
|
|
678
723
|
ReadOnlyDialect: "read_only_dialect",
|
|
724
|
+
ConnectionCannotHoldTable: "connection_cannot_hold_table",
|
|
679
725
|
StorageSourceUnsupported: "storage_source_unsupported",
|
|
680
726
|
EnvReference: "env_reference",
|
|
681
727
|
RollupNameCollision: "rollup_name_collision",
|
|
682
728
|
EmptyStorage: "empty_storage",
|
|
683
729
|
TableNameCollision: "table_name_collision",
|
|
684
|
-
CurrentTime: "current_time"
|
|
685
|
-
|
|
730
|
+
CurrentTime: "current_time",
|
|
731
|
+
ReadsGiven: "reads_given",
|
|
732
|
+
IncrementalUnsupported: "incremental_unsupported",
|
|
733
|
+
MaterializationOff: "materialization_off",
|
|
734
|
+
MultiLineAnnotation: "multi_line_annotation",
|
|
735
|
+
BuildNameCollision: "build_name_collision",
|
|
736
|
+
RunTargetUnsupported: "run_target_unsupported",
|
|
737
|
+
NestedResult: "nested_result",
|
|
738
|
+
InheritedPersist: "inherited_persist",
|
|
739
|
+
InlineUnsupported: "inline_unsupported",
|
|
740
|
+
NoStoredColumns: "no_stored_columns",
|
|
741
|
+
NeedsQualifiedName: "needs_qualified_name",
|
|
742
|
+
GeneratedBuildFailed: "generated_build_failed",
|
|
743
|
+
HiddenField: "hidden_field",
|
|
744
|
+
AccessFilter: "access_filter",
|
|
745
|
+
TimeZone: "time_zone",
|
|
746
|
+
UnreadableMeasure: "unreadable_measure",
|
|
747
|
+
JoinNotInGrain: "join_not_in_grain",
|
|
748
|
+
PartialNameCollision: "partial_name_collision",
|
|
749
|
+
GivenWhereOverUnstoredField: "given_where_over_unstored_field",
|
|
750
|
+
UnreadableGrain: "unreadable_grain"
|
|
751
|
+
}, rn = {
|
|
686
752
|
Grid: "grid",
|
|
687
753
|
Linear: "linear"
|
|
688
|
-
},
|
|
754
|
+
}, on = {
|
|
689
755
|
Malloynb: "malloynb",
|
|
690
756
|
Malloy: "malloy"
|
|
691
|
-
},
|
|
757
|
+
}, sn = {
|
|
692
758
|
Grid: "grid",
|
|
693
759
|
Linear: "linear"
|
|
694
|
-
},
|
|
760
|
+
}, ln = {
|
|
695
761
|
Query: "query",
|
|
696
762
|
Text: "text"
|
|
697
|
-
},
|
|
763
|
+
}, cn = {
|
|
698
764
|
Publish: "publish",
|
|
699
765
|
OnDemand: "on_demand",
|
|
700
766
|
Scheduler: "scheduler"
|
|
701
|
-
},
|
|
767
|
+
}, pn = {
|
|
702
768
|
Config: "config",
|
|
703
769
|
CredentialChain: "credential_chain"
|
|
704
|
-
},
|
|
770
|
+
}, dn = {
|
|
705
771
|
Initializing: "initializing",
|
|
706
772
|
Serving: "serving",
|
|
707
773
|
Draining: "draining",
|
|
708
774
|
Throttled: "throttled"
|
|
709
|
-
},
|
|
775
|
+
}, mn = {
|
|
710
776
|
Off: "off",
|
|
711
777
|
On: "on"
|
|
712
|
-
},
|
|
778
|
+
}, hn = {
|
|
713
779
|
OnPublish: "on-publish",
|
|
714
780
|
Explicit: "explicit"
|
|
715
|
-
},
|
|
781
|
+
}, un = {
|
|
716
782
|
Explorer: "explorer",
|
|
717
783
|
Viewer: "viewer"
|
|
718
|
-
},
|
|
784
|
+
}, gn = {
|
|
719
785
|
Bundled: "bundled",
|
|
720
786
|
Package: "package"
|
|
721
|
-
},
|
|
787
|
+
}, Pn = {
|
|
722
788
|
Bundled: "bundled",
|
|
723
789
|
Package: "package"
|
|
724
|
-
},
|
|
790
|
+
}, bn = {
|
|
725
791
|
NotBuilt: "NOT_BUILT",
|
|
726
|
-
|
|
792
|
+
NotServed: "NOT_SERVED",
|
|
793
|
+
OptedOut: "OPTED_OUT",
|
|
727
794
|
MissingField: "MISSING_FIELD",
|
|
728
|
-
|
|
795
|
+
ShapeMismatch: "SHAPE_MISMATCH",
|
|
796
|
+
RowLevelGate: "ROW_LEVEL_GATE",
|
|
729
797
|
GrainTooCoarse: "GRAIN_TOO_COARSE",
|
|
730
798
|
TimeZone: "TIME_ZONE",
|
|
731
799
|
CrossConnection: "CROSS_CONNECTION",
|
|
732
800
|
CountSemantics: "COUNT_SEMANTICS",
|
|
733
801
|
Stale: "STALE",
|
|
802
|
+
ReadFailed: "READ_FAILED",
|
|
803
|
+
Warned: "WARNED",
|
|
804
|
+
Contract: "CONTRACT",
|
|
734
805
|
RunFailed: "RUN_FAILED"
|
|
735
|
-
},
|
|
806
|
+
}, vn = {
|
|
736
807
|
Persist: "persist",
|
|
808
|
+
Materialize: "materialize",
|
|
809
|
+
View: "view",
|
|
810
|
+
Query: "query",
|
|
811
|
+
Rollup: "rollup",
|
|
737
812
|
Preaggregate: "preaggregate"
|
|
738
|
-
},
|
|
813
|
+
}, Vn = {
|
|
739
814
|
Light: "light",
|
|
740
815
|
Dark: "dark",
|
|
741
816
|
Auto: "auto"
|
|
742
|
-
},
|
|
817
|
+
}, qe = function(l) {
|
|
743
818
|
return {
|
|
744
819
|
/**
|
|
745
820
|
* Returns one agent with its instructions, its own skill files and each schedule\'s task text, plus `source`, which pins the package load and the agent\'s own content so a runner can prove which bytes ran. Publisher serves the definition and runs nothing: the caller\'s own harness executes it, and schedules are never fired by the server. 404 when no agent of that name is served.
|
|
@@ -754,14 +829,14 @@ const v = function(l, ...r) {
|
|
|
754
829
|
*/
|
|
755
830
|
getAgent: async (r, a, n, e, t, s = {}) => {
|
|
756
831
|
m("getAgent", "environmentName", r), m("getAgent", "packageName", a), m("getAgent", "agentName", n);
|
|
757
|
-
const o = "/environments/{environmentName}/packages/{packageName}/agents/{agentName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{agentName}", encodeURIComponent(String(n))),
|
|
758
|
-
let
|
|
759
|
-
l && (
|
|
760
|
-
const p = { method: "GET", ...
|
|
761
|
-
e !== void 0 && (h.skills = e), t !== void 0 && (h.versionId = t), d.Accept = "application/json", v(
|
|
762
|
-
let k =
|
|
832
|
+
const o = "/environments/{environmentName}/packages/{packageName}/agents/{agentName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{agentName}", encodeURIComponent(String(n))), i = new URL(o, b);
|
|
833
|
+
let c;
|
|
834
|
+
l && (c = l.baseOptions);
|
|
835
|
+
const p = { method: "GET", ...c, ...s }, d = {}, h = {};
|
|
836
|
+
e !== void 0 && (h.skills = e), t !== void 0 && (h.versionId = t), d.Accept = "application/json", v(i, h);
|
|
837
|
+
let k = c && c.headers ? c.headers : {};
|
|
763
838
|
return p.headers = { ...d, ...k, ...s.headers }, {
|
|
764
|
-
url:
|
|
839
|
+
url: V(i),
|
|
765
840
|
options: p
|
|
766
841
|
};
|
|
767
842
|
},
|
|
@@ -778,14 +853,14 @@ const v = function(l, ...r) {
|
|
|
778
853
|
*/
|
|
779
854
|
getAgentSkillFile: async (r, a, n, e, t, s = {}) => {
|
|
780
855
|
m("getAgentSkillFile", "environmentName", r), m("getAgentSkillFile", "packageName", a), m("getAgentSkillFile", "agentName", n), m("getAgentSkillFile", "relativeFilepath", e);
|
|
781
|
-
const o = "/environments/{environmentName}/packages/{packageName}/agents/{agentName}/skills/{relativeFilepath}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{agentName}", encodeURIComponent(String(n))).replace("{relativeFilepath}", encodeURIComponent(String(e))),
|
|
782
|
-
let
|
|
783
|
-
l && (
|
|
784
|
-
const p = { method: "GET", ...
|
|
785
|
-
t !== void 0 && (h.versionId = t), d.Accept = "application/json", v(
|
|
786
|
-
let k =
|
|
856
|
+
const o = "/environments/{environmentName}/packages/{packageName}/agents/{agentName}/skills/{relativeFilepath}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{agentName}", encodeURIComponent(String(n))).replace("{relativeFilepath}", encodeURIComponent(String(e))), i = new URL(o, b);
|
|
857
|
+
let c;
|
|
858
|
+
l && (c = l.baseOptions);
|
|
859
|
+
const p = { method: "GET", ...c, ...s }, d = {}, h = {};
|
|
860
|
+
t !== void 0 && (h.versionId = t), d.Accept = "application/json", v(i, h);
|
|
861
|
+
let k = c && c.headers ? c.headers : {};
|
|
787
862
|
return p.headers = { ...d, ...k, ...s.headers }, {
|
|
788
|
-
url:
|
|
863
|
+
url: V(i),
|
|
789
864
|
options: p
|
|
790
865
|
};
|
|
791
866
|
},
|
|
@@ -800,20 +875,20 @@ const v = function(l, ...r) {
|
|
|
800
875
|
*/
|
|
801
876
|
listAgents: async (r, a, n, e = {}) => {
|
|
802
877
|
m("listAgents", "environmentName", r), m("listAgents", "packageName", a);
|
|
803
|
-
const t = "/environments/{environmentName}/packages/{packageName}/agents".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
878
|
+
const t = "/environments/{environmentName}/packages/{packageName}/agents".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
804
879
|
let o;
|
|
805
880
|
l && (o = l.baseOptions);
|
|
806
|
-
const
|
|
807
|
-
n !== void 0 && (p.versionId = n),
|
|
881
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
882
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
808
883
|
let d = o && o.headers ? o.headers : {};
|
|
809
|
-
return
|
|
810
|
-
url:
|
|
811
|
-
options:
|
|
884
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
885
|
+
url: V(s),
|
|
886
|
+
options: i
|
|
812
887
|
};
|
|
813
888
|
}
|
|
814
889
|
};
|
|
815
|
-
},
|
|
816
|
-
const r =
|
|
890
|
+
}, _ = function(l) {
|
|
891
|
+
const r = qe(l);
|
|
817
892
|
return {
|
|
818
893
|
/**
|
|
819
894
|
* Returns one agent with its instructions, its own skill files and each schedule\'s task text, plus `source`, which pins the package load and the agent\'s own content so a runner can prove which bytes ran. Publisher serves the definition and runs nothing: the caller\'s own harness executes it, and schedules are never fired by the server. 404 when no agent of that name is served.
|
|
@@ -827,8 +902,8 @@ const v = function(l, ...r) {
|
|
|
827
902
|
* @throws {RequiredError}
|
|
828
903
|
*/
|
|
829
904
|
async getAgent(a, n, e, t, s, o) {
|
|
830
|
-
const
|
|
831
|
-
return (d, h) => S(
|
|
905
|
+
const i = await r.getAgent(a, n, e, t, s, o), c = l?.serverIndex ?? 0, p = P["AgentsApi.getAgent"]?.[c]?.url;
|
|
906
|
+
return (d, h) => S(i, u, g, l)(d, p || h);
|
|
832
907
|
},
|
|
833
908
|
/**
|
|
834
909
|
* Returns one file from the agent\'s resolved skill set, named by a `relative_filepath` from `GET .../agents/{agentName}?skills=summary` (for example `analyst-conventions/SKILL.md`), with the same `source` pin as the full definition. The path is looked up in the resolved set, never joined onto the filesystem. A `relative_filepath` from the agent\'s `assets` listing (`<skill>/assets/...`, full view only) is matched exactly against the listing, then read from disk as UTF-8 text and served only if it still hashes to its listed `sha256`; one that changed, or became a link, since the load is a 404. 404 when the agent or the file is not served.
|
|
@@ -842,8 +917,8 @@ const v = function(l, ...r) {
|
|
|
842
917
|
* @throws {RequiredError}
|
|
843
918
|
*/
|
|
844
919
|
async getAgentSkillFile(a, n, e, t, s, o) {
|
|
845
|
-
const
|
|
846
|
-
return (d, h) => S(
|
|
920
|
+
const i = await r.getAgentSkillFile(a, n, e, t, s, o), c = l?.serverIndex ?? 0, p = P["AgentsApi.getAgentSkillFile"]?.[c]?.url;
|
|
921
|
+
return (d, h) => S(i, u, g, l)(d, p || h);
|
|
847
922
|
},
|
|
848
923
|
/**
|
|
849
924
|
* Lists the agents declared under `agents` in the package\'s `publisher.json` that passed validation, without instructions or skills. An agent that failed validation is not listed; the package\'s `warnings` say why. Empty when the manifest declares none. The REST half of the `get_agent` MCP tool.
|
|
@@ -855,12 +930,12 @@ const v = function(l, ...r) {
|
|
|
855
930
|
* @throws {RequiredError}
|
|
856
931
|
*/
|
|
857
932
|
async listAgents(a, n, e, t) {
|
|
858
|
-
const s = await r.listAgents(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
859
|
-
return (
|
|
933
|
+
const s = await r.listAgents(a, n, e, t), o = l?.serverIndex ?? 0, i = P["AgentsApi.listAgents"]?.[o]?.url;
|
|
934
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
860
935
|
}
|
|
861
936
|
};
|
|
862
|
-
},
|
|
863
|
-
const n =
|
|
937
|
+
}, Sn = function(l, r, a) {
|
|
938
|
+
const n = _(l);
|
|
864
939
|
return {
|
|
865
940
|
/**
|
|
866
941
|
* Returns one agent with its instructions, its own skill files and each schedule\'s task text, plus `source`, which pins the package load and the agent\'s own content so a runner can prove which bytes ran. Publisher serves the definition and runs nothing: the caller\'s own harness executes it, and schedules are never fired by the server. 404 when no agent of that name is served.
|
|
@@ -873,8 +948,8 @@ const v = function(l, ...r) {
|
|
|
873
948
|
* @param {*} [options] Override http request option.
|
|
874
949
|
* @throws {RequiredError}
|
|
875
950
|
*/
|
|
876
|
-
getAgent(e, t, s, o,
|
|
877
|
-
return n.getAgent(e, t, s, o,
|
|
951
|
+
getAgent(e, t, s, o, i, c) {
|
|
952
|
+
return n.getAgent(e, t, s, o, i, c).then((p) => p(a, r));
|
|
878
953
|
},
|
|
879
954
|
/**
|
|
880
955
|
* Returns one file from the agent\'s resolved skill set, named by a `relative_filepath` from `GET .../agents/{agentName}?skills=summary` (for example `analyst-conventions/SKILL.md`), with the same `source` pin as the full definition. The path is looked up in the resolved set, never joined onto the filesystem. A `relative_filepath` from the agent\'s `assets` listing (`<skill>/assets/...`, full view only) is matched exactly against the listing, then read from disk as UTF-8 text and served only if it still hashes to its listed `sha256`; one that changed, or became a link, since the load is a 404. 404 when the agent or the file is not served.
|
|
@@ -887,8 +962,8 @@ const v = function(l, ...r) {
|
|
|
887
962
|
* @param {*} [options] Override http request option.
|
|
888
963
|
* @throws {RequiredError}
|
|
889
964
|
*/
|
|
890
|
-
getAgentSkillFile(e, t, s, o,
|
|
891
|
-
return n.getAgentSkillFile(e, t, s, o,
|
|
965
|
+
getAgentSkillFile(e, t, s, o, i, c) {
|
|
966
|
+
return n.getAgentSkillFile(e, t, s, o, i, c).then((p) => p(a, r));
|
|
892
967
|
},
|
|
893
968
|
/**
|
|
894
969
|
* Lists the agents declared under `agents` in the package\'s `publisher.json` that passed validation, without instructions or skills. An agent that failed validation is not listed; the package\'s `warnings` say why. Empty when the manifest declares none. The REST half of the `get_agent` MCP tool.
|
|
@@ -900,11 +975,11 @@ const v = function(l, ...r) {
|
|
|
900
975
|
* @throws {RequiredError}
|
|
901
976
|
*/
|
|
902
977
|
listAgents(e, t, s, o) {
|
|
903
|
-
return n.listAgents(e, t, s, o).then((
|
|
978
|
+
return n.listAgents(e, t, s, o).then((i) => i(a, r));
|
|
904
979
|
}
|
|
905
980
|
};
|
|
906
981
|
};
|
|
907
|
-
class
|
|
982
|
+
class He extends I {
|
|
908
983
|
/**
|
|
909
984
|
* Returns one agent with its instructions, its own skill files and each schedule\'s task text, plus `source`, which pins the package load and the agent\'s own content so a runner can prove which bytes ran. Publisher serves the definition and runs nothing: the caller\'s own harness executes it, and schedules are never fired by the server. 404 when no agent of that name is served.
|
|
910
985
|
* @summary Get one agent, resolved
|
|
@@ -917,7 +992,7 @@ class _e extends I {
|
|
|
917
992
|
* @throws {RequiredError}
|
|
918
993
|
*/
|
|
919
994
|
getAgent(r, a, n, e, t, s) {
|
|
920
|
-
return
|
|
995
|
+
return _(this.configuration).getAgent(r, a, n, e, t, s).then((o) => o(this.axios, this.basePath));
|
|
921
996
|
}
|
|
922
997
|
/**
|
|
923
998
|
* Returns one file from the agent\'s resolved skill set, named by a `relative_filepath` from `GET .../agents/{agentName}?skills=summary` (for example `analyst-conventions/SKILL.md`), with the same `source` pin as the full definition. The path is looked up in the resolved set, never joined onto the filesystem. A `relative_filepath` from the agent\'s `assets` listing (`<skill>/assets/...`, full view only) is matched exactly against the listing, then read from disk as UTF-8 text and served only if it still hashes to its listed `sha256`; one that changed, or became a link, since the load is a 404. 404 when the agent or the file is not served.
|
|
@@ -931,7 +1006,7 @@ class _e extends I {
|
|
|
931
1006
|
* @throws {RequiredError}
|
|
932
1007
|
*/
|
|
933
1008
|
getAgentSkillFile(r, a, n, e, t, s) {
|
|
934
|
-
return
|
|
1009
|
+
return _(this.configuration).getAgentSkillFile(r, a, n, e, t, s).then((o) => o(this.axios, this.basePath));
|
|
935
1010
|
}
|
|
936
1011
|
/**
|
|
937
1012
|
* Lists the agents declared under `agents` in the package\'s `publisher.json` that passed validation, without instructions or skills. An agent that failed validation is not listed; the package\'s `warnings` say why. Empty when the manifest declares none. The REST half of the `get_agent` MCP tool.
|
|
@@ -943,10 +1018,10 @@ class _e extends I {
|
|
|
943
1018
|
* @throws {RequiredError}
|
|
944
1019
|
*/
|
|
945
1020
|
listAgents(r, a, n, e) {
|
|
946
|
-
return
|
|
1021
|
+
return _(this.configuration).listAgents(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
947
1022
|
}
|
|
948
1023
|
}
|
|
949
|
-
const
|
|
1024
|
+
const kn = {
|
|
950
1025
|
Full: "full",
|
|
951
1026
|
Summary: "summary"
|
|
952
1027
|
}, Ge = function(l) {
|
|
@@ -962,15 +1037,15 @@ const gn = {
|
|
|
962
1037
|
*/
|
|
963
1038
|
createConnection: async (r, a, n, e = {}) => {
|
|
964
1039
|
m("createConnection", "environmentName", r), m("createConnection", "connectionName", a), m("createConnection", "connection", n);
|
|
965
|
-
const t = "/environments/{environmentName}/connections/{connectionName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
1040
|
+
const t = "/environments/{environmentName}/connections/{connectionName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
966
1041
|
let o;
|
|
967
1042
|
l && (o = l.baseOptions);
|
|
968
|
-
const
|
|
969
|
-
|
|
1043
|
+
const i = { method: "POST", ...o, ...e }, c = {}, p = {};
|
|
1044
|
+
c["Content-Type"] = "application/json", c.Accept = "application/json", v(s, p);
|
|
970
1045
|
let d = o && o.headers ? o.headers : {};
|
|
971
|
-
return
|
|
972
|
-
url:
|
|
973
|
-
options:
|
|
1046
|
+
return i.headers = { ...c, ...d, ...e.headers }, i.data = A(n, i, l), {
|
|
1047
|
+
url: V(s),
|
|
1048
|
+
options: i
|
|
974
1049
|
};
|
|
975
1050
|
},
|
|
976
1051
|
/**
|
|
@@ -983,14 +1058,14 @@ const gn = {
|
|
|
983
1058
|
*/
|
|
984
1059
|
deleteConnection: async (r, a, n = {}) => {
|
|
985
1060
|
m("deleteConnection", "environmentName", r), m("deleteConnection", "connectionName", a);
|
|
986
|
-
const e = "/environments/{environmentName}/connections/{connectionName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), t = new URL(e,
|
|
1061
|
+
const e = "/environments/{environmentName}/connections/{connectionName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), t = new URL(e, b);
|
|
987
1062
|
let s;
|
|
988
1063
|
l && (s = l.baseOptions);
|
|
989
|
-
const o = { method: "DELETE", ...s, ...n },
|
|
990
|
-
|
|
1064
|
+
const o = { method: "DELETE", ...s, ...n }, i = {}, c = {};
|
|
1065
|
+
i.Accept = "application/json", v(t, c);
|
|
991
1066
|
let p = s && s.headers ? s.headers : {};
|
|
992
|
-
return o.headers = { ...
|
|
993
|
-
url:
|
|
1067
|
+
return o.headers = { ...i, ...p, ...n.headers }, {
|
|
1068
|
+
url: V(t),
|
|
994
1069
|
options: o
|
|
995
1070
|
};
|
|
996
1071
|
},
|
|
@@ -1004,14 +1079,14 @@ const gn = {
|
|
|
1004
1079
|
*/
|
|
1005
1080
|
getConnection: async (r, a, n = {}) => {
|
|
1006
1081
|
m("getConnection", "environmentName", r), m("getConnection", "connectionName", a);
|
|
1007
|
-
const e = "/environments/{environmentName}/connections/{connectionName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), t = new URL(e,
|
|
1082
|
+
const e = "/environments/{environmentName}/connections/{connectionName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), t = new URL(e, b);
|
|
1008
1083
|
let s;
|
|
1009
1084
|
l && (s = l.baseOptions);
|
|
1010
|
-
const o = { method: "GET", ...s, ...n },
|
|
1011
|
-
|
|
1085
|
+
const o = { method: "GET", ...s, ...n }, i = {}, c = {};
|
|
1086
|
+
i.Accept = "application/json", v(t, c);
|
|
1012
1087
|
let p = s && s.headers ? s.headers : {};
|
|
1013
|
-
return o.headers = { ...
|
|
1014
|
-
url:
|
|
1088
|
+
return o.headers = { ...i, ...p, ...n.headers }, {
|
|
1089
|
+
url: V(t),
|
|
1015
1090
|
options: o
|
|
1016
1091
|
};
|
|
1017
1092
|
},
|
|
@@ -1027,15 +1102,15 @@ const gn = {
|
|
|
1027
1102
|
*/
|
|
1028
1103
|
getTable: async (r, a, n, e, t = {}) => {
|
|
1029
1104
|
m("getTable", "environmentName", r), m("getTable", "connectionName", a), m("getTable", "schemaName", n), m("getTable", "tablePath", e);
|
|
1030
|
-
const s = "/environments/{environmentName}/connections/{connectionName}/schemas/{schemaName}/tables/{tablePath}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))).replace("{schemaName}", encodeURIComponent(String(n))).replace("{tablePath}", encodeURIComponent(String(e))), o = new URL(s,
|
|
1031
|
-
let
|
|
1032
|
-
l && (
|
|
1033
|
-
const
|
|
1105
|
+
const s = "/environments/{environmentName}/connections/{connectionName}/schemas/{schemaName}/tables/{tablePath}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))).replace("{schemaName}", encodeURIComponent(String(n))).replace("{tablePath}", encodeURIComponent(String(e))), o = new URL(s, b);
|
|
1106
|
+
let i;
|
|
1107
|
+
l && (i = l.baseOptions);
|
|
1108
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
1034
1109
|
p.Accept = "application/json", v(o, d);
|
|
1035
|
-
let h =
|
|
1036
|
-
return
|
|
1037
|
-
url:
|
|
1038
|
-
options:
|
|
1110
|
+
let h = i && i.headers ? i.headers : {};
|
|
1111
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
1112
|
+
url: V(o),
|
|
1113
|
+
options: c
|
|
1039
1114
|
};
|
|
1040
1115
|
},
|
|
1041
1116
|
/**
|
|
@@ -1052,14 +1127,14 @@ const gn = {
|
|
|
1052
1127
|
*/
|
|
1053
1128
|
getTableInPackage: async (r, a, n, e, t, s, o = {}) => {
|
|
1054
1129
|
m("getTableInPackage", "environmentName", r), m("getTableInPackage", "packageName", a), m("getTableInPackage", "connectionName", n), m("getTableInPackage", "schemaName", e), m("getTableInPackage", "tablePath", t);
|
|
1055
|
-
const
|
|
1130
|
+
const i = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/schemas/{schemaName}/tables/{tablePath}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))).replace("{schemaName}", encodeURIComponent(String(e))).replace("{tablePath}", encodeURIComponent(String(t))), c = new URL(i, b);
|
|
1056
1131
|
let p;
|
|
1057
1132
|
l && (p = l.baseOptions);
|
|
1058
1133
|
const d = { method: "GET", ...p, ...o }, h = {}, k = {};
|
|
1059
|
-
s !== void 0 && (k.versionId = s), h.Accept = "application/json", v(
|
|
1134
|
+
s !== void 0 && (k.versionId = s), h.Accept = "application/json", v(c, k);
|
|
1060
1135
|
let O = p && p.headers ? p.headers : {};
|
|
1061
1136
|
return d.headers = { ...h, ...O, ...o.headers }, {
|
|
1062
|
-
url:
|
|
1137
|
+
url: V(c),
|
|
1063
1138
|
options: d
|
|
1064
1139
|
};
|
|
1065
1140
|
},
|
|
@@ -1072,14 +1147,14 @@ const gn = {
|
|
|
1072
1147
|
*/
|
|
1073
1148
|
listConnections: async (r, a = {}) => {
|
|
1074
1149
|
m("listConnections", "environmentName", r);
|
|
1075
|
-
const n = "/environments/{environmentName}/connections".replace("{environmentName}", encodeURIComponent(String(r))), e = new URL(n,
|
|
1150
|
+
const n = "/environments/{environmentName}/connections".replace("{environmentName}", encodeURIComponent(String(r))), e = new URL(n, b);
|
|
1076
1151
|
let t;
|
|
1077
1152
|
l && (t = l.baseOptions);
|
|
1078
|
-
const s = { method: "GET", ...t, ...a }, o = {},
|
|
1079
|
-
o.Accept = "application/json", v(e,
|
|
1080
|
-
let
|
|
1081
|
-
return s.headers = { ...o, ...
|
|
1082
|
-
url:
|
|
1153
|
+
const s = { method: "GET", ...t, ...a }, o = {}, i = {};
|
|
1154
|
+
o.Accept = "application/json", v(e, i);
|
|
1155
|
+
let c = t && t.headers ? t.headers : {};
|
|
1156
|
+
return s.headers = { ...o, ...c, ...a.headers }, {
|
|
1157
|
+
url: V(e),
|
|
1083
1158
|
options: s
|
|
1084
1159
|
};
|
|
1085
1160
|
},
|
|
@@ -1093,14 +1168,14 @@ const gn = {
|
|
|
1093
1168
|
*/
|
|
1094
1169
|
listSchemas: async (r, a, n = {}) => {
|
|
1095
1170
|
m("listSchemas", "environmentName", r), m("listSchemas", "connectionName", a);
|
|
1096
|
-
const e = "/environments/{environmentName}/connections/{connectionName}/schemas".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), t = new URL(e,
|
|
1171
|
+
const e = "/environments/{environmentName}/connections/{connectionName}/schemas".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), t = new URL(e, b);
|
|
1097
1172
|
let s;
|
|
1098
1173
|
l && (s = l.baseOptions);
|
|
1099
|
-
const o = { method: "GET", ...s, ...n },
|
|
1100
|
-
|
|
1174
|
+
const o = { method: "GET", ...s, ...n }, i = {}, c = {};
|
|
1175
|
+
i.Accept = "application/json", v(t, c);
|
|
1101
1176
|
let p = s && s.headers ? s.headers : {};
|
|
1102
|
-
return o.headers = { ...
|
|
1103
|
-
url:
|
|
1177
|
+
return o.headers = { ...i, ...p, ...n.headers }, {
|
|
1178
|
+
url: V(t),
|
|
1104
1179
|
options: o
|
|
1105
1180
|
};
|
|
1106
1181
|
},
|
|
@@ -1116,15 +1191,15 @@ const gn = {
|
|
|
1116
1191
|
*/
|
|
1117
1192
|
listSchemasInPackage: async (r, a, n, e, t = {}) => {
|
|
1118
1193
|
m("listSchemasInPackage", "environmentName", r), m("listSchemasInPackage", "packageName", a), m("listSchemasInPackage", "connectionName", n);
|
|
1119
|
-
const s = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/schemas".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))), o = new URL(s,
|
|
1120
|
-
let
|
|
1121
|
-
l && (
|
|
1122
|
-
const
|
|
1194
|
+
const s = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/schemas".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))), o = new URL(s, b);
|
|
1195
|
+
let i;
|
|
1196
|
+
l && (i = l.baseOptions);
|
|
1197
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
1123
1198
|
e !== void 0 && (d.versionId = e), p.Accept = "application/json", v(o, d);
|
|
1124
|
-
let h =
|
|
1125
|
-
return
|
|
1126
|
-
url:
|
|
1127
|
-
options:
|
|
1199
|
+
let h = i && i.headers ? i.headers : {};
|
|
1200
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
1201
|
+
url: V(o),
|
|
1202
|
+
options: c
|
|
1128
1203
|
};
|
|
1129
1204
|
},
|
|
1130
1205
|
/**
|
|
@@ -1139,15 +1214,15 @@ const gn = {
|
|
|
1139
1214
|
*/
|
|
1140
1215
|
listTables: async (r, a, n, e, t = {}) => {
|
|
1141
1216
|
m("listTables", "environmentName", r), m("listTables", "connectionName", a), m("listTables", "schemaName", n);
|
|
1142
|
-
const s = "/environments/{environmentName}/connections/{connectionName}/schemas/{schemaName}/tables".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))).replace("{schemaName}", encodeURIComponent(String(n))), o = new URL(s,
|
|
1143
|
-
let
|
|
1144
|
-
l && (
|
|
1145
|
-
const
|
|
1217
|
+
const s = "/environments/{environmentName}/connections/{connectionName}/schemas/{schemaName}/tables".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))).replace("{schemaName}", encodeURIComponent(String(n))), o = new URL(s, b);
|
|
1218
|
+
let i;
|
|
1219
|
+
l && (i = l.baseOptions);
|
|
1220
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
1146
1221
|
e && (d.tableNames = e), p.Accept = "application/json", v(o, d);
|
|
1147
|
-
let h =
|
|
1148
|
-
return
|
|
1149
|
-
url:
|
|
1150
|
-
options:
|
|
1222
|
+
let h = i && i.headers ? i.headers : {};
|
|
1223
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
1224
|
+
url: V(o),
|
|
1225
|
+
options: c
|
|
1151
1226
|
};
|
|
1152
1227
|
},
|
|
1153
1228
|
/**
|
|
@@ -1164,19 +1239,19 @@ const gn = {
|
|
|
1164
1239
|
*/
|
|
1165
1240
|
listTablesInPackage: async (r, a, n, e, t, s, o = {}) => {
|
|
1166
1241
|
m("listTablesInPackage", "environmentName", r), m("listTablesInPackage", "packageName", a), m("listTablesInPackage", "connectionName", n), m("listTablesInPackage", "schemaName", e);
|
|
1167
|
-
const
|
|
1242
|
+
const i = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/schemas/{schemaName}/tables".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))).replace("{schemaName}", encodeURIComponent(String(e))), c = new URL(i, b);
|
|
1168
1243
|
let p;
|
|
1169
1244
|
l && (p = l.baseOptions);
|
|
1170
1245
|
const d = { method: "GET", ...p, ...o }, h = {}, k = {};
|
|
1171
|
-
t && (k.tableNames = t), s !== void 0 && (k.versionId = s), h.Accept = "application/json", v(
|
|
1246
|
+
t && (k.tableNames = t), s !== void 0 && (k.versionId = s), h.Accept = "application/json", v(c, k);
|
|
1172
1247
|
let O = p && p.headers ? p.headers : {};
|
|
1173
1248
|
return d.headers = { ...h, ...O, ...o.headers }, {
|
|
1174
|
-
url:
|
|
1249
|
+
url: V(c),
|
|
1175
1250
|
options: d
|
|
1176
1251
|
};
|
|
1177
1252
|
},
|
|
1178
1253
|
/**
|
|
1179
|
-
* Executes a SQL statement against the specified database connection and returns the results. The results include data, metadata, and execution information. Rows returned are capped at PUBLISHER_MAX_QUERY_ROWS (default 100,000). The cap is forwarded to the connector as a rowLimit on RunSQLOptions; queries that return more rows than the cap fail with HTTP 413 rather than serializing the response. Set PUBLISHER_MAX_QUERY_ROWS=0 to disable the cap. A caller-supplied rowLimit smaller than the cap is preserved; larger values are clamped down to cap+1.
|
|
1254
|
+
* Executes a SQL statement against the specified database connection and returns the results. The results include data, metadata, and execution information. Rows returned are capped at PUBLISHER_MAX_QUERY_ROWS (default 100,000). The cap is forwarded to the connector as a rowLimit on RunSQLOptions; queries that return more rows than the cap fail with HTTP 413 rather than serializing the response. Set PUBLISHER_MAX_QUERY_ROWS=0 to disable the cap. A caller-supplied rowLimit smaller than the cap is preserved; larger values are clamped down to cap+1. On a DuckDB-backed connection (`duckdb`, including a package\'s `duckdb` sandbox, `ducklake` and `motherduck`), `sqlStatement` runs only as a single SELECT. Any other statement, more than one statement, or SQL that does not parse answers 400 before anything runs. `sqlSource` and `sqlTemporaryTable` apply the same rule to the caller\'s SQL.
|
|
1180
1255
|
* @summary Execute SQL query
|
|
1181
1256
|
* @param {string} environmentName Name of the environment
|
|
1182
1257
|
* @param {string} connectionName Name of the connection
|
|
@@ -1186,19 +1261,19 @@ const gn = {
|
|
|
1186
1261
|
*/
|
|
1187
1262
|
postQuerydata: async (r, a, n, e = {}) => {
|
|
1188
1263
|
m("postQuerydata", "environmentName", r), m("postQuerydata", "connectionName", a), m("postQuerydata", "postQuerydataRequest", n);
|
|
1189
|
-
const t = "/environments/{environmentName}/connections/{connectionName}/sqlQuery".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
1264
|
+
const t = "/environments/{environmentName}/connections/{connectionName}/sqlQuery".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
1190
1265
|
let o;
|
|
1191
1266
|
l && (o = l.baseOptions);
|
|
1192
|
-
const
|
|
1193
|
-
|
|
1267
|
+
const i = { method: "POST", ...o, ...e }, c = {}, p = {};
|
|
1268
|
+
c["Content-Type"] = "application/json", c.Accept = "application/json", v(s, p);
|
|
1194
1269
|
let d = o && o.headers ? o.headers : {};
|
|
1195
|
-
return
|
|
1196
|
-
url:
|
|
1197
|
-
options:
|
|
1270
|
+
return i.headers = { ...c, ...d, ...e.headers }, i.data = A(n, i, l), {
|
|
1271
|
+
url: V(s),
|
|
1272
|
+
options: i
|
|
1198
1273
|
};
|
|
1199
1274
|
},
|
|
1200
1275
|
/**
|
|
1201
|
-
* Executes a SQL statement against the specified database connection, resolved in the context of the named package, and returns the results. Subject to the same PUBLISHER_MAX_QUERY_ROWS row cap as the environment-level sqlQuery endpoint.
|
|
1276
|
+
* Executes a SQL statement against the specified database connection, resolved in the context of the named package, and returns the results. Subject to the same PUBLISHER_MAX_QUERY_ROWS row cap as the environment-level sqlQuery endpoint, and to the same single-SELECT rule on a DuckDB-backed connection: any other statement answers 400.
|
|
1202
1277
|
* @summary Execute SQL query (per-package)
|
|
1203
1278
|
* @param {string} environmentName Name of the environment
|
|
1204
1279
|
* @param {string} packageName Name of the package whose connection context to use
|
|
@@ -1210,14 +1285,14 @@ const gn = {
|
|
|
1210
1285
|
*/
|
|
1211
1286
|
postQuerydataInPackage: async (r, a, n, e, t, s = {}) => {
|
|
1212
1287
|
m("postQuerydataInPackage", "environmentName", r), m("postQuerydataInPackage", "packageName", a), m("postQuerydataInPackage", "connectionName", n), m("postQuerydataInPackage", "postQuerydataRequest", e);
|
|
1213
|
-
const o = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/sqlQuery".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))),
|
|
1214
|
-
let
|
|
1215
|
-
l && (
|
|
1216
|
-
const p = { method: "POST", ...
|
|
1217
|
-
t !== void 0 && (h.versionId = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(
|
|
1218
|
-
let k =
|
|
1288
|
+
const o = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/sqlQuery".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))), i = new URL(o, b);
|
|
1289
|
+
let c;
|
|
1290
|
+
l && (c = l.baseOptions);
|
|
1291
|
+
const p = { method: "POST", ...c, ...s }, d = {}, h = {};
|
|
1292
|
+
t !== void 0 && (h.versionId = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(i, h);
|
|
1293
|
+
let k = c && c.headers ? c.headers : {};
|
|
1219
1294
|
return p.headers = { ...d, ...k, ...s.headers }, p.data = A(e, p, l), {
|
|
1220
|
-
url:
|
|
1295
|
+
url: V(i),
|
|
1221
1296
|
options: p
|
|
1222
1297
|
};
|
|
1223
1298
|
},
|
|
@@ -1232,15 +1307,15 @@ const gn = {
|
|
|
1232
1307
|
*/
|
|
1233
1308
|
postSqlsource: async (r, a, n, e = {}) => {
|
|
1234
1309
|
m("postSqlsource", "environmentName", r), m("postSqlsource", "connectionName", a), m("postSqlsource", "postSqlsourceRequest", n);
|
|
1235
|
-
const t = "/environments/{environmentName}/connections/{connectionName}/sqlSource".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
1310
|
+
const t = "/environments/{environmentName}/connections/{connectionName}/sqlSource".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
1236
1311
|
let o;
|
|
1237
1312
|
l && (o = l.baseOptions);
|
|
1238
|
-
const
|
|
1239
|
-
|
|
1313
|
+
const i = { method: "POST", ...o, ...e }, c = {}, p = {};
|
|
1314
|
+
c["Content-Type"] = "application/json", c.Accept = "application/json", v(s, p);
|
|
1240
1315
|
let d = o && o.headers ? o.headers : {};
|
|
1241
|
-
return
|
|
1242
|
-
url:
|
|
1243
|
-
options:
|
|
1316
|
+
return i.headers = { ...c, ...d, ...e.headers }, i.data = A(n, i, l), {
|
|
1317
|
+
url: V(s),
|
|
1318
|
+
options: i
|
|
1244
1319
|
};
|
|
1245
1320
|
},
|
|
1246
1321
|
/**
|
|
@@ -1256,14 +1331,14 @@ const gn = {
|
|
|
1256
1331
|
*/
|
|
1257
1332
|
postSqlsourceInPackage: async (r, a, n, e, t, s = {}) => {
|
|
1258
1333
|
m("postSqlsourceInPackage", "environmentName", r), m("postSqlsourceInPackage", "packageName", a), m("postSqlsourceInPackage", "connectionName", n), m("postSqlsourceInPackage", "postSqlsourceRequest", e);
|
|
1259
|
-
const o = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/sqlSource".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))),
|
|
1260
|
-
let
|
|
1261
|
-
l && (
|
|
1262
|
-
const p = { method: "POST", ...
|
|
1263
|
-
t !== void 0 && (h.versionId = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(
|
|
1264
|
-
let k =
|
|
1334
|
+
const o = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/sqlSource".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))), i = new URL(o, b);
|
|
1335
|
+
let c;
|
|
1336
|
+
l && (c = l.baseOptions);
|
|
1337
|
+
const p = { method: "POST", ...c, ...s }, d = {}, h = {};
|
|
1338
|
+
t !== void 0 && (h.versionId = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(i, h);
|
|
1339
|
+
let k = c && c.headers ? c.headers : {};
|
|
1265
1340
|
return p.headers = { ...d, ...k, ...s.headers }, p.data = A(e, p, l), {
|
|
1266
|
-
url:
|
|
1341
|
+
url: V(i),
|
|
1267
1342
|
options: p
|
|
1268
1343
|
};
|
|
1269
1344
|
},
|
|
@@ -1278,15 +1353,15 @@ const gn = {
|
|
|
1278
1353
|
*/
|
|
1279
1354
|
postTemporarytable: async (r, a, n, e = {}) => {
|
|
1280
1355
|
m("postTemporarytable", "environmentName", r), m("postTemporarytable", "connectionName", a), m("postTemporarytable", "postSqlsourceRequest", n);
|
|
1281
|
-
const t = "/environments/{environmentName}/connections/{connectionName}/sqlTemporaryTable".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
1356
|
+
const t = "/environments/{environmentName}/connections/{connectionName}/sqlTemporaryTable".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
1282
1357
|
let o;
|
|
1283
1358
|
l && (o = l.baseOptions);
|
|
1284
|
-
const
|
|
1285
|
-
|
|
1359
|
+
const i = { method: "POST", ...o, ...e }, c = {}, p = {};
|
|
1360
|
+
c["Content-Type"] = "application/json", c.Accept = "application/json", v(s, p);
|
|
1286
1361
|
let d = o && o.headers ? o.headers : {};
|
|
1287
|
-
return
|
|
1288
|
-
url:
|
|
1289
|
-
options:
|
|
1362
|
+
return i.headers = { ...c, ...d, ...e.headers }, i.data = A(n, i, l), {
|
|
1363
|
+
url: V(s),
|
|
1364
|
+
options: i
|
|
1290
1365
|
};
|
|
1291
1366
|
},
|
|
1292
1367
|
/**
|
|
@@ -1302,14 +1377,14 @@ const gn = {
|
|
|
1302
1377
|
*/
|
|
1303
1378
|
postTemporarytableInPackage: async (r, a, n, e, t, s = {}) => {
|
|
1304
1379
|
m("postTemporarytableInPackage", "environmentName", r), m("postTemporarytableInPackage", "packageName", a), m("postTemporarytableInPackage", "connectionName", n), m("postTemporarytableInPackage", "postSqlsourceRequest", e);
|
|
1305
|
-
const o = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/sqlTemporaryTable".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))),
|
|
1306
|
-
let
|
|
1307
|
-
l && (
|
|
1308
|
-
const p = { method: "POST", ...
|
|
1309
|
-
t !== void 0 && (h.versionId = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(
|
|
1310
|
-
let k =
|
|
1380
|
+
const o = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/sqlTemporaryTable".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))), i = new URL(o, b);
|
|
1381
|
+
let c;
|
|
1382
|
+
l && (c = l.baseOptions);
|
|
1383
|
+
const p = { method: "POST", ...c, ...s }, d = {}, h = {};
|
|
1384
|
+
t !== void 0 && (h.versionId = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(i, h);
|
|
1385
|
+
let k = c && c.headers ? c.headers : {};
|
|
1311
1386
|
return p.headers = { ...d, ...k, ...s.headers }, p.data = A(e, p, l), {
|
|
1312
|
-
url:
|
|
1387
|
+
url: V(i),
|
|
1313
1388
|
options: p
|
|
1314
1389
|
};
|
|
1315
1390
|
},
|
|
@@ -1324,15 +1399,15 @@ const gn = {
|
|
|
1324
1399
|
*/
|
|
1325
1400
|
updateConnection: async (r, a, n, e = {}) => {
|
|
1326
1401
|
m("updateConnection", "environmentName", r), m("updateConnection", "connectionName", a), m("updateConnection", "updateConnectionRequest", n);
|
|
1327
|
-
const t = "/environments/{environmentName}/connections/{connectionName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
1402
|
+
const t = "/environments/{environmentName}/connections/{connectionName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{connectionName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
1328
1403
|
let o;
|
|
1329
1404
|
l && (o = l.baseOptions);
|
|
1330
|
-
const
|
|
1331
|
-
|
|
1405
|
+
const i = { method: "PATCH", ...o, ...e }, c = {}, p = {};
|
|
1406
|
+
c["Content-Type"] = "application/json", c.Accept = "application/json", v(s, p);
|
|
1332
1407
|
let d = o && o.headers ? o.headers : {};
|
|
1333
|
-
return
|
|
1334
|
-
url:
|
|
1335
|
-
options:
|
|
1408
|
+
return i.headers = { ...c, ...d, ...e.headers }, i.data = A(n, i, l), {
|
|
1409
|
+
url: V(s),
|
|
1410
|
+
options: i
|
|
1336
1411
|
};
|
|
1337
1412
|
}
|
|
1338
1413
|
};
|
|
@@ -1349,8 +1424,8 @@ const gn = {
|
|
|
1349
1424
|
* @throws {RequiredError}
|
|
1350
1425
|
*/
|
|
1351
1426
|
async createConnection(a, n, e, t) {
|
|
1352
|
-
const s = await r.createConnection(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
1353
|
-
return (
|
|
1427
|
+
const s = await r.createConnection(a, n, e, t), o = l?.serverIndex ?? 0, i = P["ConnectionsApi.createConnection"]?.[o]?.url;
|
|
1428
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
1354
1429
|
},
|
|
1355
1430
|
/**
|
|
1356
1431
|
* Permanently deletes a database connection from the environment.
|
|
@@ -1362,7 +1437,7 @@ const gn = {
|
|
|
1362
1437
|
*/
|
|
1363
1438
|
async deleteConnection(a, n, e) {
|
|
1364
1439
|
const t = await r.deleteConnection(a, n, e), s = l?.serverIndex ?? 0, o = P["ConnectionsApi.deleteConnection"]?.[s]?.url;
|
|
1365
|
-
return (
|
|
1440
|
+
return (i, c) => S(t, u, g, l)(i, o || c);
|
|
1366
1441
|
},
|
|
1367
1442
|
/**
|
|
1368
1443
|
* Retrieves detailed information about a specific database connection within an environment. This includes connection configuration, credentials (if accessible), and metadata. Useful for inspecting connection settings and troubleshooting connectivity issues.
|
|
@@ -1374,7 +1449,7 @@ const gn = {
|
|
|
1374
1449
|
*/
|
|
1375
1450
|
async getConnection(a, n, e) {
|
|
1376
1451
|
const t = await r.getConnection(a, n, e), s = l?.serverIndex ?? 0, o = P["ConnectionsApi.getConnection"]?.[s]?.url;
|
|
1377
|
-
return (
|
|
1452
|
+
return (i, c) => S(t, u, g, l)(i, o || c);
|
|
1378
1453
|
},
|
|
1379
1454
|
/**
|
|
1380
1455
|
* Retrieves a table from the specified database schema. This endpoint is useful for discovering available data sources and exploring the database structure. The schema must exist in the connection for this operation to succeed. The tablePath is the full path to the table, including the schema name. On a DuckLake connection, a bare tablePath equal to schemaName reads the catalog\'s default schema.
|
|
@@ -1387,8 +1462,8 @@ const gn = {
|
|
|
1387
1462
|
* @throws {RequiredError}
|
|
1388
1463
|
*/
|
|
1389
1464
|
async getTable(a, n, e, t, s) {
|
|
1390
|
-
const o = await r.getTable(a, n, e, t, s),
|
|
1391
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
1465
|
+
const o = await r.getTable(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["ConnectionsApi.getTable"]?.[i]?.url;
|
|
1466
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
1392
1467
|
},
|
|
1393
1468
|
/**
|
|
1394
1469
|
* Retrieves a table from the specified database schema, resolved in the context of the named package.
|
|
@@ -1402,9 +1477,9 @@ const gn = {
|
|
|
1402
1477
|
* @param {*} [options] Override http request option.
|
|
1403
1478
|
* @throws {RequiredError}
|
|
1404
1479
|
*/
|
|
1405
|
-
async getTableInPackage(a, n, e, t, s, o,
|
|
1406
|
-
const
|
|
1407
|
-
return (h, k) => S(
|
|
1480
|
+
async getTableInPackage(a, n, e, t, s, o, i) {
|
|
1481
|
+
const c = await r.getTableInPackage(a, n, e, t, s, o, i), p = l?.serverIndex ?? 0, d = P["ConnectionsApi.getTableInPackage"]?.[p]?.url;
|
|
1482
|
+
return (h, k) => S(c, u, g, l)(h, d || k);
|
|
1408
1483
|
},
|
|
1409
1484
|
/**
|
|
1410
1485
|
* Retrieves a list of all database connections configured for the specified environment. Each connection includes its configuration, type, and status information. This endpoint is useful for discovering available data sources within an environment.
|
|
@@ -1415,7 +1490,7 @@ const gn = {
|
|
|
1415
1490
|
*/
|
|
1416
1491
|
async listConnections(a, n) {
|
|
1417
1492
|
const e = await r.listConnections(a, n), t = l?.serverIndex ?? 0, s = P["ConnectionsApi.listConnections"]?.[t]?.url;
|
|
1418
|
-
return (o,
|
|
1493
|
+
return (o, i) => S(e, u, g, l)(o, s || i);
|
|
1419
1494
|
},
|
|
1420
1495
|
/**
|
|
1421
1496
|
* Retrieves a list of all schemas (databases) available in the specified connection. Each schema includes metadata such as name, description, and whether it\'s the default schema. This endpoint is useful for exploring the database structure and discovering available data sources.
|
|
@@ -1427,7 +1502,7 @@ const gn = {
|
|
|
1427
1502
|
*/
|
|
1428
1503
|
async listSchemas(a, n, e) {
|
|
1429
1504
|
const t = await r.listSchemas(a, n, e), s = l?.serverIndex ?? 0, o = P["ConnectionsApi.listSchemas"]?.[s]?.url;
|
|
1430
|
-
return (
|
|
1505
|
+
return (i, c) => S(t, u, g, l)(i, o || c);
|
|
1431
1506
|
},
|
|
1432
1507
|
/**
|
|
1433
1508
|
* Retrieves a list of all schemas (databases) available in the specified connection, resolved in the context of the named package. Required for `connectionName=\"duckdb\"`, which is per-package; works for any other connection name as well (resolution falls through to the environment).
|
|
@@ -1440,8 +1515,8 @@ const gn = {
|
|
|
1440
1515
|
* @throws {RequiredError}
|
|
1441
1516
|
*/
|
|
1442
1517
|
async listSchemasInPackage(a, n, e, t, s) {
|
|
1443
|
-
const o = await r.listSchemasInPackage(a, n, e, t, s),
|
|
1444
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
1518
|
+
const o = await r.listSchemasInPackage(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["ConnectionsApi.listSchemasInPackage"]?.[i]?.url;
|
|
1519
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
1445
1520
|
},
|
|
1446
1521
|
/**
|
|
1447
1522
|
* Retrieves a list of all tables and views available in the specified database schema. This endpoint is useful for discovering available data sources and exploring the database structure. The schema must exist in the connection for this operation to succeed.
|
|
@@ -1454,8 +1529,8 @@ const gn = {
|
|
|
1454
1529
|
* @throws {RequiredError}
|
|
1455
1530
|
*/
|
|
1456
1531
|
async listTables(a, n, e, t, s) {
|
|
1457
|
-
const o = await r.listTables(a, n, e, t, s),
|
|
1458
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
1532
|
+
const o = await r.listTables(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["ConnectionsApi.listTables"]?.[i]?.url;
|
|
1533
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
1459
1534
|
},
|
|
1460
1535
|
/**
|
|
1461
1536
|
* Retrieves a list of all tables and views available in the specified database schema, resolved in the context of the named package.
|
|
@@ -1469,12 +1544,12 @@ const gn = {
|
|
|
1469
1544
|
* @param {*} [options] Override http request option.
|
|
1470
1545
|
* @throws {RequiredError}
|
|
1471
1546
|
*/
|
|
1472
|
-
async listTablesInPackage(a, n, e, t, s, o,
|
|
1473
|
-
const
|
|
1474
|
-
return (h, k) => S(
|
|
1547
|
+
async listTablesInPackage(a, n, e, t, s, o, i) {
|
|
1548
|
+
const c = await r.listTablesInPackage(a, n, e, t, s, o, i), p = l?.serverIndex ?? 0, d = P["ConnectionsApi.listTablesInPackage"]?.[p]?.url;
|
|
1549
|
+
return (h, k) => S(c, u, g, l)(h, d || k);
|
|
1475
1550
|
},
|
|
1476
1551
|
/**
|
|
1477
|
-
* Executes a SQL statement against the specified database connection and returns the results. The results include data, metadata, and execution information. Rows returned are capped at PUBLISHER_MAX_QUERY_ROWS (default 100,000). The cap is forwarded to the connector as a rowLimit on RunSQLOptions; queries that return more rows than the cap fail with HTTP 413 rather than serializing the response. Set PUBLISHER_MAX_QUERY_ROWS=0 to disable the cap. A caller-supplied rowLimit smaller than the cap is preserved; larger values are clamped down to cap+1.
|
|
1552
|
+
* Executes a SQL statement against the specified database connection and returns the results. The results include data, metadata, and execution information. Rows returned are capped at PUBLISHER_MAX_QUERY_ROWS (default 100,000). The cap is forwarded to the connector as a rowLimit on RunSQLOptions; queries that return more rows than the cap fail with HTTP 413 rather than serializing the response. Set PUBLISHER_MAX_QUERY_ROWS=0 to disable the cap. A caller-supplied rowLimit smaller than the cap is preserved; larger values are clamped down to cap+1. On a DuckDB-backed connection (`duckdb`, including a package\'s `duckdb` sandbox, `ducklake` and `motherduck`), `sqlStatement` runs only as a single SELECT. Any other statement, more than one statement, or SQL that does not parse answers 400 before anything runs. `sqlSource` and `sqlTemporaryTable` apply the same rule to the caller\'s SQL.
|
|
1478
1553
|
* @summary Execute SQL query
|
|
1479
1554
|
* @param {string} environmentName Name of the environment
|
|
1480
1555
|
* @param {string} connectionName Name of the connection
|
|
@@ -1483,11 +1558,11 @@ const gn = {
|
|
|
1483
1558
|
* @throws {RequiredError}
|
|
1484
1559
|
*/
|
|
1485
1560
|
async postQuerydata(a, n, e, t) {
|
|
1486
|
-
const s = await r.postQuerydata(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
1487
|
-
return (
|
|
1561
|
+
const s = await r.postQuerydata(a, n, e, t), o = l?.serverIndex ?? 0, i = P["ConnectionsApi.postQuerydata"]?.[o]?.url;
|
|
1562
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
1488
1563
|
},
|
|
1489
1564
|
/**
|
|
1490
|
-
* Executes a SQL statement against the specified database connection, resolved in the context of the named package, and returns the results. Subject to the same PUBLISHER_MAX_QUERY_ROWS row cap as the environment-level sqlQuery endpoint.
|
|
1565
|
+
* Executes a SQL statement against the specified database connection, resolved in the context of the named package, and returns the results. Subject to the same PUBLISHER_MAX_QUERY_ROWS row cap as the environment-level sqlQuery endpoint, and to the same single-SELECT rule on a DuckDB-backed connection: any other statement answers 400.
|
|
1491
1566
|
* @summary Execute SQL query (per-package)
|
|
1492
1567
|
* @param {string} environmentName Name of the environment
|
|
1493
1568
|
* @param {string} packageName Name of the package whose connection context to use
|
|
@@ -1498,8 +1573,8 @@ const gn = {
|
|
|
1498
1573
|
* @throws {RequiredError}
|
|
1499
1574
|
*/
|
|
1500
1575
|
async postQuerydataInPackage(a, n, e, t, s, o) {
|
|
1501
|
-
const
|
|
1502
|
-
return (d, h) => S(
|
|
1576
|
+
const i = await r.postQuerydataInPackage(a, n, e, t, s, o), c = l?.serverIndex ?? 0, p = P["ConnectionsApi.postQuerydataInPackage"]?.[c]?.url;
|
|
1577
|
+
return (d, h) => S(i, u, g, l)(d, p || h);
|
|
1503
1578
|
},
|
|
1504
1579
|
/**
|
|
1505
1580
|
* Creates a Malloy source from a SQL statement using the specified database connection. The SQL statement is executed to generate a source definition that can be used in Malloy models.
|
|
@@ -1511,8 +1586,8 @@ const gn = {
|
|
|
1511
1586
|
* @throws {RequiredError}
|
|
1512
1587
|
*/
|
|
1513
1588
|
async postSqlsource(a, n, e, t) {
|
|
1514
|
-
const s = await r.postSqlsource(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
1515
|
-
return (
|
|
1589
|
+
const s = await r.postSqlsource(a, n, e, t), o = l?.serverIndex ?? 0, i = P["ConnectionsApi.postSqlsource"]?.[o]?.url;
|
|
1590
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
1516
1591
|
},
|
|
1517
1592
|
/**
|
|
1518
1593
|
* Creates a Malloy source from a SQL statement using the specified connection, resolved in the context of the named package.
|
|
@@ -1526,8 +1601,8 @@ const gn = {
|
|
|
1526
1601
|
* @throws {RequiredError}
|
|
1527
1602
|
*/
|
|
1528
1603
|
async postSqlsourceInPackage(a, n, e, t, s, o) {
|
|
1529
|
-
const
|
|
1530
|
-
return (d, h) => S(
|
|
1604
|
+
const i = await r.postSqlsourceInPackage(a, n, e, t, s, o), c = l?.serverIndex ?? 0, p = P["ConnectionsApi.postSqlsourceInPackage"]?.[c]?.url;
|
|
1605
|
+
return (d, h) => S(i, u, g, l)(d, p || h);
|
|
1531
1606
|
},
|
|
1532
1607
|
/**
|
|
1533
1608
|
* Creates a temporary table from a SQL statement using the specified database connection. Temporary tables are useful for storing intermediate results during complex queries and data processing workflows.
|
|
@@ -1539,8 +1614,8 @@ const gn = {
|
|
|
1539
1614
|
* @throws {RequiredError}
|
|
1540
1615
|
*/
|
|
1541
1616
|
async postTemporarytable(a, n, e, t) {
|
|
1542
|
-
const s = await r.postTemporarytable(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
1543
|
-
return (
|
|
1617
|
+
const s = await r.postTemporarytable(a, n, e, t), o = l?.serverIndex ?? 0, i = P["ConnectionsApi.postTemporarytable"]?.[o]?.url;
|
|
1618
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
1544
1619
|
},
|
|
1545
1620
|
/**
|
|
1546
1621
|
* Creates a temporary table from a SQL statement using the specified database connection, resolved in the context of the named package.
|
|
@@ -1554,8 +1629,8 @@ const gn = {
|
|
|
1554
1629
|
* @throws {RequiredError}
|
|
1555
1630
|
*/
|
|
1556
1631
|
async postTemporarytableInPackage(a, n, e, t, s, o) {
|
|
1557
|
-
const
|
|
1558
|
-
return (d, h) => S(
|
|
1632
|
+
const i = await r.postTemporarytableInPackage(a, n, e, t, s, o), c = l?.serverIndex ?? 0, p = P["ConnectionsApi.postTemporarytableInPackage"]?.[c]?.url;
|
|
1633
|
+
return (d, h) => S(i, u, g, l)(d, p || h);
|
|
1559
1634
|
},
|
|
1560
1635
|
/**
|
|
1561
1636
|
* Updates the configuration of an existing database connection.
|
|
@@ -1567,11 +1642,11 @@ const gn = {
|
|
|
1567
1642
|
* @throws {RequiredError}
|
|
1568
1643
|
*/
|
|
1569
1644
|
async updateConnection(a, n, e, t) {
|
|
1570
|
-
const s = await r.updateConnection(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
1571
|
-
return (
|
|
1645
|
+
const s = await r.updateConnection(a, n, e, t), o = l?.serverIndex ?? 0, i = P["ConnectionsApi.updateConnection"]?.[o]?.url;
|
|
1646
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
1572
1647
|
}
|
|
1573
1648
|
};
|
|
1574
|
-
},
|
|
1649
|
+
}, On = function(l, r, a) {
|
|
1575
1650
|
const n = C(l);
|
|
1576
1651
|
return {
|
|
1577
1652
|
/**
|
|
@@ -1584,7 +1659,7 @@ const gn = {
|
|
|
1584
1659
|
* @throws {RequiredError}
|
|
1585
1660
|
*/
|
|
1586
1661
|
createConnection(e, t, s, o) {
|
|
1587
|
-
return n.createConnection(e, t, s, o).then((
|
|
1662
|
+
return n.createConnection(e, t, s, o).then((i) => i(a, r));
|
|
1588
1663
|
},
|
|
1589
1664
|
/**
|
|
1590
1665
|
* Permanently deletes a database connection from the environment.
|
|
@@ -1618,8 +1693,8 @@ const gn = {
|
|
|
1618
1693
|
* @param {*} [options] Override http request option.
|
|
1619
1694
|
* @throws {RequiredError}
|
|
1620
1695
|
*/
|
|
1621
|
-
getTable(e, t, s, o,
|
|
1622
|
-
return n.getTable(e, t, s, o,
|
|
1696
|
+
getTable(e, t, s, o, i) {
|
|
1697
|
+
return n.getTable(e, t, s, o, i).then((c) => c(a, r));
|
|
1623
1698
|
},
|
|
1624
1699
|
/**
|
|
1625
1700
|
* Retrieves a table from the specified database schema, resolved in the context of the named package.
|
|
@@ -1633,8 +1708,8 @@ const gn = {
|
|
|
1633
1708
|
* @param {*} [options] Override http request option.
|
|
1634
1709
|
* @throws {RequiredError}
|
|
1635
1710
|
*/
|
|
1636
|
-
getTableInPackage(e, t, s, o,
|
|
1637
|
-
return n.getTableInPackage(e, t, s, o,
|
|
1711
|
+
getTableInPackage(e, t, s, o, i, c, p) {
|
|
1712
|
+
return n.getTableInPackage(e, t, s, o, i, c, p).then((d) => d(a, r));
|
|
1638
1713
|
},
|
|
1639
1714
|
/**
|
|
1640
1715
|
* Retrieves a list of all database connections configured for the specified environment. Each connection includes its configuration, type, and status information. This endpoint is useful for discovering available data sources within an environment.
|
|
@@ -1667,8 +1742,8 @@ const gn = {
|
|
|
1667
1742
|
* @param {*} [options] Override http request option.
|
|
1668
1743
|
* @throws {RequiredError}
|
|
1669
1744
|
*/
|
|
1670
|
-
listSchemasInPackage(e, t, s, o,
|
|
1671
|
-
return n.listSchemasInPackage(e, t, s, o,
|
|
1745
|
+
listSchemasInPackage(e, t, s, o, i) {
|
|
1746
|
+
return n.listSchemasInPackage(e, t, s, o, i).then((c) => c(a, r));
|
|
1672
1747
|
},
|
|
1673
1748
|
/**
|
|
1674
1749
|
* Retrieves a list of all tables and views available in the specified database schema. This endpoint is useful for discovering available data sources and exploring the database structure. The schema must exist in the connection for this operation to succeed.
|
|
@@ -1680,8 +1755,8 @@ const gn = {
|
|
|
1680
1755
|
* @param {*} [options] Override http request option.
|
|
1681
1756
|
* @throws {RequiredError}
|
|
1682
1757
|
*/
|
|
1683
|
-
listTables(e, t, s, o,
|
|
1684
|
-
return n.listTables(e, t, s, o,
|
|
1758
|
+
listTables(e, t, s, o, i) {
|
|
1759
|
+
return n.listTables(e, t, s, o, i).then((c) => c(a, r));
|
|
1685
1760
|
},
|
|
1686
1761
|
/**
|
|
1687
1762
|
* Retrieves a list of all tables and views available in the specified database schema, resolved in the context of the named package.
|
|
@@ -1695,11 +1770,11 @@ const gn = {
|
|
|
1695
1770
|
* @param {*} [options] Override http request option.
|
|
1696
1771
|
* @throws {RequiredError}
|
|
1697
1772
|
*/
|
|
1698
|
-
listTablesInPackage(e, t, s, o,
|
|
1699
|
-
return n.listTablesInPackage(e, t, s, o,
|
|
1773
|
+
listTablesInPackage(e, t, s, o, i, c, p) {
|
|
1774
|
+
return n.listTablesInPackage(e, t, s, o, i, c, p).then((d) => d(a, r));
|
|
1700
1775
|
},
|
|
1701
1776
|
/**
|
|
1702
|
-
* Executes a SQL statement against the specified database connection and returns the results. The results include data, metadata, and execution information. Rows returned are capped at PUBLISHER_MAX_QUERY_ROWS (default 100,000). The cap is forwarded to the connector as a rowLimit on RunSQLOptions; queries that return more rows than the cap fail with HTTP 413 rather than serializing the response. Set PUBLISHER_MAX_QUERY_ROWS=0 to disable the cap. A caller-supplied rowLimit smaller than the cap is preserved; larger values are clamped down to cap+1.
|
|
1777
|
+
* Executes a SQL statement against the specified database connection and returns the results. The results include data, metadata, and execution information. Rows returned are capped at PUBLISHER_MAX_QUERY_ROWS (default 100,000). The cap is forwarded to the connector as a rowLimit on RunSQLOptions; queries that return more rows than the cap fail with HTTP 413 rather than serializing the response. Set PUBLISHER_MAX_QUERY_ROWS=0 to disable the cap. A caller-supplied rowLimit smaller than the cap is preserved; larger values are clamped down to cap+1. On a DuckDB-backed connection (`duckdb`, including a package\'s `duckdb` sandbox, `ducklake` and `motherduck`), `sqlStatement` runs only as a single SELECT. Any other statement, more than one statement, or SQL that does not parse answers 400 before anything runs. `sqlSource` and `sqlTemporaryTable` apply the same rule to the caller\'s SQL.
|
|
1703
1778
|
* @summary Execute SQL query
|
|
1704
1779
|
* @param {string} environmentName Name of the environment
|
|
1705
1780
|
* @param {string} connectionName Name of the connection
|
|
@@ -1708,10 +1783,10 @@ const gn = {
|
|
|
1708
1783
|
* @throws {RequiredError}
|
|
1709
1784
|
*/
|
|
1710
1785
|
postQuerydata(e, t, s, o) {
|
|
1711
|
-
return n.postQuerydata(e, t, s, o).then((
|
|
1786
|
+
return n.postQuerydata(e, t, s, o).then((i) => i(a, r));
|
|
1712
1787
|
},
|
|
1713
1788
|
/**
|
|
1714
|
-
* Executes a SQL statement against the specified database connection, resolved in the context of the named package, and returns the results. Subject to the same PUBLISHER_MAX_QUERY_ROWS row cap as the environment-level sqlQuery endpoint.
|
|
1789
|
+
* Executes a SQL statement against the specified database connection, resolved in the context of the named package, and returns the results. Subject to the same PUBLISHER_MAX_QUERY_ROWS row cap as the environment-level sqlQuery endpoint, and to the same single-SELECT rule on a DuckDB-backed connection: any other statement answers 400.
|
|
1715
1790
|
* @summary Execute SQL query (per-package)
|
|
1716
1791
|
* @param {string} environmentName Name of the environment
|
|
1717
1792
|
* @param {string} packageName Name of the package whose connection context to use
|
|
@@ -1721,8 +1796,8 @@ const gn = {
|
|
|
1721
1796
|
* @param {*} [options] Override http request option.
|
|
1722
1797
|
* @throws {RequiredError}
|
|
1723
1798
|
*/
|
|
1724
|
-
postQuerydataInPackage(e, t, s, o,
|
|
1725
|
-
return n.postQuerydataInPackage(e, t, s, o,
|
|
1799
|
+
postQuerydataInPackage(e, t, s, o, i, c) {
|
|
1800
|
+
return n.postQuerydataInPackage(e, t, s, o, i, c).then((p) => p(a, r));
|
|
1726
1801
|
},
|
|
1727
1802
|
/**
|
|
1728
1803
|
* Creates a Malloy source from a SQL statement using the specified database connection. The SQL statement is executed to generate a source definition that can be used in Malloy models.
|
|
@@ -1734,7 +1809,7 @@ const gn = {
|
|
|
1734
1809
|
* @throws {RequiredError}
|
|
1735
1810
|
*/
|
|
1736
1811
|
postSqlsource(e, t, s, o) {
|
|
1737
|
-
return n.postSqlsource(e, t, s, o).then((
|
|
1812
|
+
return n.postSqlsource(e, t, s, o).then((i) => i(a, r));
|
|
1738
1813
|
},
|
|
1739
1814
|
/**
|
|
1740
1815
|
* Creates a Malloy source from a SQL statement using the specified connection, resolved in the context of the named package.
|
|
@@ -1747,8 +1822,8 @@ const gn = {
|
|
|
1747
1822
|
* @param {*} [options] Override http request option.
|
|
1748
1823
|
* @throws {RequiredError}
|
|
1749
1824
|
*/
|
|
1750
|
-
postSqlsourceInPackage(e, t, s, o,
|
|
1751
|
-
return n.postSqlsourceInPackage(e, t, s, o,
|
|
1825
|
+
postSqlsourceInPackage(e, t, s, o, i, c) {
|
|
1826
|
+
return n.postSqlsourceInPackage(e, t, s, o, i, c).then((p) => p(a, r));
|
|
1752
1827
|
},
|
|
1753
1828
|
/**
|
|
1754
1829
|
* Creates a temporary table from a SQL statement using the specified database connection. Temporary tables are useful for storing intermediate results during complex queries and data processing workflows.
|
|
@@ -1760,7 +1835,7 @@ const gn = {
|
|
|
1760
1835
|
* @throws {RequiredError}
|
|
1761
1836
|
*/
|
|
1762
1837
|
postTemporarytable(e, t, s, o) {
|
|
1763
|
-
return n.postTemporarytable(e, t, s, o).then((
|
|
1838
|
+
return n.postTemporarytable(e, t, s, o).then((i) => i(a, r));
|
|
1764
1839
|
},
|
|
1765
1840
|
/**
|
|
1766
1841
|
* Creates a temporary table from a SQL statement using the specified database connection, resolved in the context of the named package.
|
|
@@ -1773,8 +1848,8 @@ const gn = {
|
|
|
1773
1848
|
* @param {*} [options] Override http request option.
|
|
1774
1849
|
* @throws {RequiredError}
|
|
1775
1850
|
*/
|
|
1776
|
-
postTemporarytableInPackage(e, t, s, o,
|
|
1777
|
-
return n.postTemporarytableInPackage(e, t, s, o,
|
|
1851
|
+
postTemporarytableInPackage(e, t, s, o, i, c) {
|
|
1852
|
+
return n.postTemporarytableInPackage(e, t, s, o, i, c).then((p) => p(a, r));
|
|
1778
1853
|
},
|
|
1779
1854
|
/**
|
|
1780
1855
|
* Updates the configuration of an existing database connection.
|
|
@@ -1786,7 +1861,7 @@ const gn = {
|
|
|
1786
1861
|
* @throws {RequiredError}
|
|
1787
1862
|
*/
|
|
1788
1863
|
updateConnection(e, t, s, o) {
|
|
1789
|
-
return n.updateConnection(e, t, s, o).then((
|
|
1864
|
+
return n.updateConnection(e, t, s, o).then((i) => i(a, r));
|
|
1790
1865
|
}
|
|
1791
1866
|
};
|
|
1792
1867
|
};
|
|
@@ -1851,7 +1926,7 @@ class We extends I {
|
|
|
1851
1926
|
* @throws {RequiredError}
|
|
1852
1927
|
*/
|
|
1853
1928
|
getTableInPackage(r, a, n, e, t, s, o) {
|
|
1854
|
-
return C(this.configuration).getTableInPackage(r, a, n, e, t, s, o).then((
|
|
1929
|
+
return C(this.configuration).getTableInPackage(r, a, n, e, t, s, o).then((i) => i(this.axios, this.basePath));
|
|
1855
1930
|
}
|
|
1856
1931
|
/**
|
|
1857
1932
|
* Retrieves a list of all database connections configured for the specified environment. Each connection includes its configuration, type, and status information. This endpoint is useful for discovering available data sources within an environment.
|
|
@@ -1913,10 +1988,10 @@ class We extends I {
|
|
|
1913
1988
|
* @throws {RequiredError}
|
|
1914
1989
|
*/
|
|
1915
1990
|
listTablesInPackage(r, a, n, e, t, s, o) {
|
|
1916
|
-
return C(this.configuration).listTablesInPackage(r, a, n, e, t, s, o).then((
|
|
1991
|
+
return C(this.configuration).listTablesInPackage(r, a, n, e, t, s, o).then((i) => i(this.axios, this.basePath));
|
|
1917
1992
|
}
|
|
1918
1993
|
/**
|
|
1919
|
-
* Executes a SQL statement against the specified database connection and returns the results. The results include data, metadata, and execution information. Rows returned are capped at PUBLISHER_MAX_QUERY_ROWS (default 100,000). The cap is forwarded to the connector as a rowLimit on RunSQLOptions; queries that return more rows than the cap fail with HTTP 413 rather than serializing the response. Set PUBLISHER_MAX_QUERY_ROWS=0 to disable the cap. A caller-supplied rowLimit smaller than the cap is preserved; larger values are clamped down to cap+1.
|
|
1994
|
+
* Executes a SQL statement against the specified database connection and returns the results. The results include data, metadata, and execution information. Rows returned are capped at PUBLISHER_MAX_QUERY_ROWS (default 100,000). The cap is forwarded to the connector as a rowLimit on RunSQLOptions; queries that return more rows than the cap fail with HTTP 413 rather than serializing the response. Set PUBLISHER_MAX_QUERY_ROWS=0 to disable the cap. A caller-supplied rowLimit smaller than the cap is preserved; larger values are clamped down to cap+1. On a DuckDB-backed connection (`duckdb`, including a package\'s `duckdb` sandbox, `ducklake` and `motherduck`), `sqlStatement` runs only as a single SELECT. Any other statement, more than one statement, or SQL that does not parse answers 400 before anything runs. `sqlSource` and `sqlTemporaryTable` apply the same rule to the caller\'s SQL.
|
|
1920
1995
|
* @summary Execute SQL query
|
|
1921
1996
|
* @param {string} environmentName Name of the environment
|
|
1922
1997
|
* @param {string} connectionName Name of the connection
|
|
@@ -1928,7 +2003,7 @@ class We extends I {
|
|
|
1928
2003
|
return C(this.configuration).postQuerydata(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
1929
2004
|
}
|
|
1930
2005
|
/**
|
|
1931
|
-
* Executes a SQL statement against the specified database connection, resolved in the context of the named package, and returns the results. Subject to the same PUBLISHER_MAX_QUERY_ROWS row cap as the environment-level sqlQuery endpoint.
|
|
2006
|
+
* Executes a SQL statement against the specified database connection, resolved in the context of the named package, and returns the results. Subject to the same PUBLISHER_MAX_QUERY_ROWS row cap as the environment-level sqlQuery endpoint, and to the same single-SELECT rule on a DuckDB-backed connection: any other statement answers 400.
|
|
1932
2007
|
* @summary Execute SQL query (per-package)
|
|
1933
2008
|
* @param {string} environmentName Name of the environment
|
|
1934
2009
|
* @param {string} packageName Name of the package whose connection context to use
|
|
@@ -2017,14 +2092,14 @@ const Ke = function(l) {
|
|
|
2017
2092
|
*/
|
|
2018
2093
|
testConnectionConfiguration: async (r, a = {}) => {
|
|
2019
2094
|
m("testConnectionConfiguration", "connection", r);
|
|
2020
|
-
const n = "/connections/test", e = new URL(n,
|
|
2095
|
+
const n = "/connections/test", e = new URL(n, b);
|
|
2021
2096
|
let t;
|
|
2022
2097
|
l && (t = l.baseOptions);
|
|
2023
|
-
const s = { method: "POST", ...t, ...a }, o = {},
|
|
2024
|
-
o["Content-Type"] = "application/json", o.Accept = "application/json", v(e,
|
|
2025
|
-
let
|
|
2026
|
-
return s.headers = { ...o, ...
|
|
2027
|
-
url:
|
|
2098
|
+
const s = { method: "POST", ...t, ...a }, o = {}, i = {};
|
|
2099
|
+
o["Content-Type"] = "application/json", o.Accept = "application/json", v(e, i);
|
|
2100
|
+
let c = t && t.headers ? t.headers : {};
|
|
2101
|
+
return s.headers = { ...o, ...c, ...a.headers }, s.data = A(r, s, l), {
|
|
2102
|
+
url: V(e),
|
|
2028
2103
|
options: s
|
|
2029
2104
|
};
|
|
2030
2105
|
}
|
|
@@ -2041,10 +2116,10 @@ const Ke = function(l) {
|
|
|
2041
2116
|
*/
|
|
2042
2117
|
async testConnectionConfiguration(a, n) {
|
|
2043
2118
|
const e = await r.testConnectionConfiguration(a, n), t = l?.serverIndex ?? 0, s = P["ConnectionsTestApi.testConnectionConfiguration"]?.[t]?.url;
|
|
2044
|
-
return (o,
|
|
2119
|
+
return (o, i) => S(e, u, g, l)(o, s || i);
|
|
2045
2120
|
}
|
|
2046
2121
|
};
|
|
2047
|
-
},
|
|
2122
|
+
}, An = function(l, r, a) {
|
|
2048
2123
|
const n = he(l);
|
|
2049
2124
|
return {
|
|
2050
2125
|
/**
|
|
@@ -2059,7 +2134,7 @@ const Ke = function(l) {
|
|
|
2059
2134
|
}
|
|
2060
2135
|
};
|
|
2061
2136
|
};
|
|
2062
|
-
class
|
|
2137
|
+
class yn extends I {
|
|
2063
2138
|
/**
|
|
2064
2139
|
* Validates a database connection configuration without adding it to any environment. This endpoint allows you to test connection parameters, credentials, and network connectivity before committing the connection to an environment. Useful for troubleshooting connection issues and validating configurations during setup.
|
|
2065
2140
|
* @summary Test database connection configuration
|
|
@@ -2086,15 +2161,15 @@ const $e = function(l) {
|
|
|
2086
2161
|
*/
|
|
2087
2162
|
getDashboard: async (r, a, n, e, t = {}) => {
|
|
2088
2163
|
m("getDashboard", "environmentName", r), m("getDashboard", "packageName", a), m("getDashboard", "dashboardName", n);
|
|
2089
|
-
const s = "/environments/{environmentName}/packages/{packageName}/dashboards/{dashboardName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{dashboardName}", encodeURIComponent(String(n))), o = new URL(s,
|
|
2090
|
-
let
|
|
2091
|
-
l && (
|
|
2092
|
-
const
|
|
2164
|
+
const s = "/environments/{environmentName}/packages/{packageName}/dashboards/{dashboardName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{dashboardName}", encodeURIComponent(String(n))), o = new URL(s, b);
|
|
2165
|
+
let i;
|
|
2166
|
+
l && (i = l.baseOptions);
|
|
2167
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
2093
2168
|
e !== void 0 && (d.versionId = e), p.Accept = "application/json", v(o, d);
|
|
2094
|
-
let h =
|
|
2095
|
-
return
|
|
2096
|
-
url:
|
|
2097
|
-
options:
|
|
2169
|
+
let h = i && i.headers ? i.headers : {};
|
|
2170
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
2171
|
+
url: V(o),
|
|
2172
|
+
options: c
|
|
2098
2173
|
};
|
|
2099
2174
|
},
|
|
2100
2175
|
/**
|
|
@@ -2109,15 +2184,15 @@ const $e = function(l) {
|
|
|
2109
2184
|
*/
|
|
2110
2185
|
listDashboards: async (r, a, n, e = {}) => {
|
|
2111
2186
|
m("listDashboards", "environmentName", r), m("listDashboards", "packageName", a);
|
|
2112
|
-
const t = "/environments/{environmentName}/packages/{packageName}/dashboards".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
2187
|
+
const t = "/environments/{environmentName}/packages/{packageName}/dashboards".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
2113
2188
|
let o;
|
|
2114
2189
|
l && (o = l.baseOptions);
|
|
2115
|
-
const
|
|
2116
|
-
n !== void 0 && (p.versionId = n),
|
|
2190
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
2191
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
2117
2192
|
let d = o && o.headers ? o.headers : {};
|
|
2118
|
-
return
|
|
2119
|
-
url:
|
|
2120
|
-
options:
|
|
2193
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
2194
|
+
url: V(s),
|
|
2195
|
+
options: i
|
|
2121
2196
|
};
|
|
2122
2197
|
}
|
|
2123
2198
|
};
|
|
@@ -2136,8 +2211,8 @@ const $e = function(l) {
|
|
|
2136
2211
|
* @throws {RequiredError}
|
|
2137
2212
|
*/
|
|
2138
2213
|
async getDashboard(a, n, e, t, s) {
|
|
2139
|
-
const o = await r.getDashboard(a, n, e, t, s),
|
|
2140
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
2214
|
+
const o = await r.getDashboard(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["DashboardsApi.getDashboard"]?.[i]?.url;
|
|
2215
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
2141
2216
|
},
|
|
2142
2217
|
/**
|
|
2143
2218
|
* **DEPRECATED**: use list-reports, which lists every report of either layout by path. This route lists the package\'s grid reports (see list-reports for what makes a file a report and which layout it has), wherever they live in the package. Two may share a `name`; their `path` tells them apart. A file with no artifact tag is an ordinary model and is not listed, whether or not it compiles. **Contract change since reports.** This route used to list only `.malloy` files directly under `dashboards/`, so every `name` was unique and every `path` was `dashboards/<name>.malloy`. It now lists grid reports from anywhere in the package (`sales/q3.malloy`, `notebooks/x.malloy`, `a/b/c.malloy`), so `path` may have any depth and `name` may repeat. Key on `path`. A tagged dashboard that failed to compile is listed carrying its `error` where that state can arise at all, so a broken dashboard is visibly broken rather than silently absent. In practice it rarely does: a package whose model fails to compile is not loaded, and a reload that would break one is refused and leaves the previously loaded package serving, so `error` is only reachable on the paths that keep per-model placeholders. Treat it as present-but-uncommon rather than the normal way a broken dashboard surfaces. Every tagged dashboard is listed, whatever the package\'s surface. To hide one, remove its `# artifact` tag. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a dashboard\'s tiles, its single query and its filter `suggest` queries may read only sources the surface exports. A source the dashboard declares on top of a surface source may be read; one over a hidden source may not. The dashboard file\'s own `export {}` and named queries add nothing to the surface. A tile over a hidden source answers 404 when it runs, and the package\'s `warnings` report each such tile, single query and suggest, with severity `error`, as of the last load, naming the source and the fix. Under `\"all\"` nothing is refused, so the situation does not arise.
|
|
@@ -2150,11 +2225,11 @@ const $e = function(l) {
|
|
|
2150
2225
|
* @throws {RequiredError}
|
|
2151
2226
|
*/
|
|
2152
2227
|
async listDashboards(a, n, e, t) {
|
|
2153
|
-
const s = await r.listDashboards(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
2154
|
-
return (
|
|
2228
|
+
const s = await r.listDashboards(a, n, e, t), o = l?.serverIndex ?? 0, i = P["DashboardsApi.listDashboards"]?.[o]?.url;
|
|
2229
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
2155
2230
|
}
|
|
2156
2231
|
};
|
|
2157
|
-
},
|
|
2232
|
+
}, Cn = function(l, r, a) {
|
|
2158
2233
|
const n = Z(l);
|
|
2159
2234
|
return {
|
|
2160
2235
|
/**
|
|
@@ -2168,8 +2243,8 @@ const $e = function(l) {
|
|
|
2168
2243
|
* @deprecated
|
|
2169
2244
|
* @throws {RequiredError}
|
|
2170
2245
|
*/
|
|
2171
|
-
getDashboard(e, t, s, o,
|
|
2172
|
-
return n.getDashboard(e, t, s, o,
|
|
2246
|
+
getDashboard(e, t, s, o, i) {
|
|
2247
|
+
return n.getDashboard(e, t, s, o, i).then((c) => c(a, r));
|
|
2173
2248
|
},
|
|
2174
2249
|
/**
|
|
2175
2250
|
* **DEPRECATED**: use list-reports, which lists every report of either layout by path. This route lists the package\'s grid reports (see list-reports for what makes a file a report and which layout it has), wherever they live in the package. Two may share a `name`; their `path` tells them apart. A file with no artifact tag is an ordinary model and is not listed, whether or not it compiles. **Contract change since reports.** This route used to list only `.malloy` files directly under `dashboards/`, so every `name` was unique and every `path` was `dashboards/<name>.malloy`. It now lists grid reports from anywhere in the package (`sales/q3.malloy`, `notebooks/x.malloy`, `a/b/c.malloy`), so `path` may have any depth and `name` may repeat. Key on `path`. A tagged dashboard that failed to compile is listed carrying its `error` where that state can arise at all, so a broken dashboard is visibly broken rather than silently absent. In practice it rarely does: a package whose model fails to compile is not loaded, and a reload that would break one is refused and leaves the previously loaded package serving, so `error` is only reachable on the paths that keep per-model placeholders. Treat it as present-but-uncommon rather than the normal way a broken dashboard surfaces. Every tagged dashboard is listed, whatever the package\'s surface. To hide one, remove its `# artifact` tag. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a dashboard\'s tiles, its single query and its filter `suggest` queries may read only sources the surface exports. A source the dashboard declares on top of a surface source may be read; one over a hidden source may not. The dashboard file\'s own `export {}` and named queries add nothing to the surface. A tile over a hidden source answers 404 when it runs, and the package\'s `warnings` report each such tile, single query and suggest, with severity `error`, as of the last load, naming the source and the fix. Under `\"all\"` nothing is refused, so the situation does not arise.
|
|
@@ -2182,7 +2257,7 @@ const $e = function(l) {
|
|
|
2182
2257
|
* @throws {RequiredError}
|
|
2183
2258
|
*/
|
|
2184
2259
|
listDashboards(e, t, s, o) {
|
|
2185
|
-
return n.listDashboards(e, t, s, o).then((
|
|
2260
|
+
return n.listDashboards(e, t, s, o).then((i) => i(a, r));
|
|
2186
2261
|
}
|
|
2187
2262
|
};
|
|
2188
2263
|
};
|
|
@@ -2228,15 +2303,15 @@ const Je = function(l) {
|
|
|
2228
2303
|
*/
|
|
2229
2304
|
listDataApps: async (r, a, n, e = {}) => {
|
|
2230
2305
|
m("listDataApps", "environmentName", r), m("listDataApps", "packageName", a);
|
|
2231
|
-
const t = "/environments/{environmentName}/packages/{packageName}/data-apps".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
2306
|
+
const t = "/environments/{environmentName}/packages/{packageName}/data-apps".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
2232
2307
|
let o;
|
|
2233
2308
|
l && (o = l.baseOptions);
|
|
2234
|
-
const
|
|
2235
|
-
n !== void 0 && (p.versionId = n),
|
|
2309
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
2310
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
2236
2311
|
let d = o && o.headers ? o.headers : {};
|
|
2237
|
-
return
|
|
2238
|
-
url:
|
|
2239
|
-
options:
|
|
2312
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
2313
|
+
url: V(s),
|
|
2314
|
+
options: i
|
|
2240
2315
|
};
|
|
2241
2316
|
}
|
|
2242
2317
|
};
|
|
@@ -2253,11 +2328,11 @@ const Je = function(l) {
|
|
|
2253
2328
|
* @throws {RequiredError}
|
|
2254
2329
|
*/
|
|
2255
2330
|
async listDataApps(a, n, e, t) {
|
|
2256
|
-
const s = await r.listDataApps(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
2257
|
-
return (
|
|
2331
|
+
const s = await r.listDataApps(a, n, e, t), o = l?.serverIndex ?? 0, i = P["DataAppsApi.listDataApps"]?.[o]?.url;
|
|
2332
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
2258
2333
|
}
|
|
2259
2334
|
};
|
|
2260
|
-
},
|
|
2335
|
+
}, In = function(l, r, a) {
|
|
2261
2336
|
const n = ue(l);
|
|
2262
2337
|
return {
|
|
2263
2338
|
/**
|
|
@@ -2270,7 +2345,7 @@ const Je = function(l) {
|
|
|
2270
2345
|
* @throws {RequiredError}
|
|
2271
2346
|
*/
|
|
2272
2347
|
listDataApps(e, t, s, o) {
|
|
2273
|
-
return n.listDataApps(e, t, s, o).then((
|
|
2348
|
+
return n.listDataApps(e, t, s, o).then((i) => i(a, r));
|
|
2274
2349
|
}
|
|
2275
2350
|
};
|
|
2276
2351
|
};
|
|
@@ -2301,15 +2376,15 @@ const Xe = function(l) {
|
|
|
2301
2376
|
*/
|
|
2302
2377
|
listDatabases: async (r, a, n, e = {}) => {
|
|
2303
2378
|
m("listDatabases", "environmentName", r), m("listDatabases", "packageName", a);
|
|
2304
|
-
const t = "/environments/{environmentName}/packages/{packageName}/databases".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
2379
|
+
const t = "/environments/{environmentName}/packages/{packageName}/databases".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
2305
2380
|
let o;
|
|
2306
2381
|
l && (o = l.baseOptions);
|
|
2307
|
-
const
|
|
2308
|
-
n !== void 0 && (p.versionId = n),
|
|
2382
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
2383
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
2309
2384
|
let d = o && o.headers ? o.headers : {};
|
|
2310
|
-
return
|
|
2311
|
-
url:
|
|
2312
|
-
options:
|
|
2385
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
2386
|
+
url: V(s),
|
|
2387
|
+
options: i
|
|
2313
2388
|
};
|
|
2314
2389
|
}
|
|
2315
2390
|
};
|
|
@@ -2326,11 +2401,11 @@ const Xe = function(l) {
|
|
|
2326
2401
|
* @throws {RequiredError}
|
|
2327
2402
|
*/
|
|
2328
2403
|
async listDatabases(a, n, e, t) {
|
|
2329
|
-
const s = await r.listDatabases(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
2330
|
-
return (
|
|
2404
|
+
const s = await r.listDatabases(a, n, e, t), o = l?.serverIndex ?? 0, i = P["DatabasesApi.listDatabases"]?.[o]?.url;
|
|
2405
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
2331
2406
|
}
|
|
2332
2407
|
};
|
|
2333
|
-
},
|
|
2408
|
+
}, Rn = function(l, r, a) {
|
|
2334
2409
|
const n = ge(l);
|
|
2335
2410
|
return {
|
|
2336
2411
|
/**
|
|
@@ -2343,7 +2418,7 @@ const Xe = function(l) {
|
|
|
2343
2418
|
* @throws {RequiredError}
|
|
2344
2419
|
*/
|
|
2345
2420
|
listDatabases(e, t, s, o) {
|
|
2346
|
-
return n.listDatabases(e, t, s, o).then((
|
|
2421
|
+
return n.listDatabases(e, t, s, o).then((i) => i(a, r));
|
|
2347
2422
|
}
|
|
2348
2423
|
};
|
|
2349
2424
|
};
|
|
@@ -2372,14 +2447,14 @@ const aa = function(l) {
|
|
|
2372
2447
|
*/
|
|
2373
2448
|
createEnvironment: async (r, a = {}) => {
|
|
2374
2449
|
m("createEnvironment", "environment", r);
|
|
2375
|
-
const n = "/environments", e = new URL(n,
|
|
2450
|
+
const n = "/environments", e = new URL(n, b);
|
|
2376
2451
|
let t;
|
|
2377
2452
|
l && (t = l.baseOptions);
|
|
2378
|
-
const s = { method: "POST", ...t, ...a }, o = {},
|
|
2379
|
-
o["Content-Type"] = "application/json", o.Accept = "application/json", v(e,
|
|
2380
|
-
let
|
|
2381
|
-
return s.headers = { ...o, ...
|
|
2382
|
-
url:
|
|
2453
|
+
const s = { method: "POST", ...t, ...a }, o = {}, i = {};
|
|
2454
|
+
o["Content-Type"] = "application/json", o.Accept = "application/json", v(e, i);
|
|
2455
|
+
let c = t && t.headers ? t.headers : {};
|
|
2456
|
+
return s.headers = { ...o, ...c, ...a.headers }, s.data = A(r, s, l), {
|
|
2457
|
+
url: V(e),
|
|
2383
2458
|
options: s
|
|
2384
2459
|
};
|
|
2385
2460
|
},
|
|
@@ -2392,14 +2467,14 @@ const aa = function(l) {
|
|
|
2392
2467
|
*/
|
|
2393
2468
|
deleteEnvironment: async (r, a = {}) => {
|
|
2394
2469
|
m("deleteEnvironment", "environmentName", r);
|
|
2395
|
-
const n = "/environments/{environmentName}".replace("{environmentName}", encodeURIComponent(String(r))), e = new URL(n,
|
|
2470
|
+
const n = "/environments/{environmentName}".replace("{environmentName}", encodeURIComponent(String(r))), e = new URL(n, b);
|
|
2396
2471
|
let t;
|
|
2397
2472
|
l && (t = l.baseOptions);
|
|
2398
|
-
const s = { method: "DELETE", ...t, ...a }, o = {},
|
|
2399
|
-
o.Accept = "application/json", v(e,
|
|
2400
|
-
let
|
|
2401
|
-
return s.headers = { ...o, ...
|
|
2402
|
-
url:
|
|
2473
|
+
const s = { method: "DELETE", ...t, ...a }, o = {}, i = {};
|
|
2474
|
+
o.Accept = "application/json", v(e, i);
|
|
2475
|
+
let c = t && t.headers ? t.headers : {};
|
|
2476
|
+
return s.headers = { ...o, ...c, ...a.headers }, {
|
|
2477
|
+
url: V(e),
|
|
2403
2478
|
options: s
|
|
2404
2479
|
};
|
|
2405
2480
|
},
|
|
@@ -2413,14 +2488,14 @@ const aa = function(l) {
|
|
|
2413
2488
|
*/
|
|
2414
2489
|
getEnvironment: async (r, a, n = {}) => {
|
|
2415
2490
|
m("getEnvironment", "environmentName", r);
|
|
2416
|
-
const e = "/environments/{environmentName}".replace("{environmentName}", encodeURIComponent(String(r))), t = new URL(e,
|
|
2491
|
+
const e = "/environments/{environmentName}".replace("{environmentName}", encodeURIComponent(String(r))), t = new URL(e, b);
|
|
2417
2492
|
let s;
|
|
2418
2493
|
l && (s = l.baseOptions);
|
|
2419
|
-
const o = { method: "GET", ...s, ...n },
|
|
2420
|
-
a !== void 0 && (
|
|
2494
|
+
const o = { method: "GET", ...s, ...n }, i = {}, c = {};
|
|
2495
|
+
a !== void 0 && (c.reload = a), i.Accept = "application/json", v(t, c);
|
|
2421
2496
|
let p = s && s.headers ? s.headers : {};
|
|
2422
|
-
return o.headers = { ...
|
|
2423
|
-
url:
|
|
2497
|
+
return o.headers = { ...i, ...p, ...n.headers }, {
|
|
2498
|
+
url: V(t),
|
|
2424
2499
|
options: o
|
|
2425
2500
|
};
|
|
2426
2501
|
},
|
|
@@ -2431,14 +2506,14 @@ const aa = function(l) {
|
|
|
2431
2506
|
* @throws {RequiredError}
|
|
2432
2507
|
*/
|
|
2433
2508
|
listEnvironments: async (r = {}) => {
|
|
2434
|
-
const a = "/environments", n = new URL(a,
|
|
2509
|
+
const a = "/environments", n = new URL(a, b);
|
|
2435
2510
|
let e;
|
|
2436
2511
|
l && (e = l.baseOptions);
|
|
2437
2512
|
const t = { method: "GET", ...e, ...r }, s = {}, o = {};
|
|
2438
2513
|
s.Accept = "application/json", v(n, o);
|
|
2439
|
-
let
|
|
2440
|
-
return t.headers = { ...s, ...
|
|
2441
|
-
url:
|
|
2514
|
+
let i = e && e.headers ? e.headers : {};
|
|
2515
|
+
return t.headers = { ...s, ...i, ...r.headers }, {
|
|
2516
|
+
url: V(n),
|
|
2442
2517
|
options: t
|
|
2443
2518
|
};
|
|
2444
2519
|
},
|
|
@@ -2452,19 +2527,19 @@ const aa = function(l) {
|
|
|
2452
2527
|
*/
|
|
2453
2528
|
updateEnvironment: async (r, a, n = {}) => {
|
|
2454
2529
|
m("updateEnvironment", "environmentName", r), m("updateEnvironment", "environment", a);
|
|
2455
|
-
const e = "/environments/{environmentName}".replace("{environmentName}", encodeURIComponent(String(r))), t = new URL(e,
|
|
2530
|
+
const e = "/environments/{environmentName}".replace("{environmentName}", encodeURIComponent(String(r))), t = new URL(e, b);
|
|
2456
2531
|
let s;
|
|
2457
2532
|
l && (s = l.baseOptions);
|
|
2458
|
-
const o = { method: "PATCH", ...s, ...n },
|
|
2459
|
-
|
|
2533
|
+
const o = { method: "PATCH", ...s, ...n }, i = {}, c = {};
|
|
2534
|
+
i["Content-Type"] = "application/json", i.Accept = "application/json", v(t, c);
|
|
2460
2535
|
let p = s && s.headers ? s.headers : {};
|
|
2461
|
-
return o.headers = { ...
|
|
2462
|
-
url:
|
|
2536
|
+
return o.headers = { ...i, ...p, ...n.headers }, o.data = A(a, o, l), {
|
|
2537
|
+
url: V(t),
|
|
2463
2538
|
options: o
|
|
2464
2539
|
};
|
|
2465
2540
|
}
|
|
2466
2541
|
};
|
|
2467
|
-
},
|
|
2542
|
+
}, M = function(l) {
|
|
2468
2543
|
const r = aa(l);
|
|
2469
2544
|
return {
|
|
2470
2545
|
/**
|
|
@@ -2476,7 +2551,7 @@ const aa = function(l) {
|
|
|
2476
2551
|
*/
|
|
2477
2552
|
async createEnvironment(a, n) {
|
|
2478
2553
|
const e = await r.createEnvironment(a, n), t = l?.serverIndex ?? 0, s = P["EnvironmentsApi.createEnvironment"]?.[t]?.url;
|
|
2479
|
-
return (o,
|
|
2554
|
+
return (o, i) => S(e, u, g, l)(o, s || i);
|
|
2480
2555
|
},
|
|
2481
2556
|
/**
|
|
2482
2557
|
* Permanently deletes an environment and all its associated resources including packages, connections, and metadata. This operation cannot be undone, so use with caution. The environment must exist and be accessible for deletion.
|
|
@@ -2487,7 +2562,7 @@ const aa = function(l) {
|
|
|
2487
2562
|
*/
|
|
2488
2563
|
async deleteEnvironment(a, n) {
|
|
2489
2564
|
const e = await r.deleteEnvironment(a, n), t = l?.serverIndex ?? 0, s = P["EnvironmentsApi.deleteEnvironment"]?.[t]?.url;
|
|
2490
|
-
return (o,
|
|
2565
|
+
return (o, i) => S(e, u, g, l)(o, s || i);
|
|
2491
2566
|
},
|
|
2492
2567
|
/**
|
|
2493
2568
|
* Retrieves detailed information about a specific environment, including its packages, connections, configuration, and metadata. The reload parameter can be used to refresh the environment state from disk before returning the information.
|
|
@@ -2499,7 +2574,7 @@ const aa = function(l) {
|
|
|
2499
2574
|
*/
|
|
2500
2575
|
async getEnvironment(a, n, e) {
|
|
2501
2576
|
const t = await r.getEnvironment(a, n, e), s = l?.serverIndex ?? 0, o = P["EnvironmentsApi.getEnvironment"]?.[s]?.url;
|
|
2502
|
-
return (
|
|
2577
|
+
return (i, c) => S(t, u, g, l)(i, o || c);
|
|
2503
2578
|
},
|
|
2504
2579
|
/**
|
|
2505
2580
|
* Retrieves a list of all environments currently hosted on this Malloy Publisher server. Each environment contains metadata about its packages, connections, and configuration. This endpoint is typically used to discover available environments and their basic information. This endpoint does not reload. A `reload` query parameter is rejected with 400 rather than ignored, because answering 200 here reads as a reload that worked. Reload is per-environment: use `GET /environments/{environmentName}?reload=true`.
|
|
@@ -2521,11 +2596,11 @@ const aa = function(l) {
|
|
|
2521
2596
|
*/
|
|
2522
2597
|
async updateEnvironment(a, n, e) {
|
|
2523
2598
|
const t = await r.updateEnvironment(a, n, e), s = l?.serverIndex ?? 0, o = P["EnvironmentsApi.updateEnvironment"]?.[s]?.url;
|
|
2524
|
-
return (
|
|
2599
|
+
return (i, c) => S(t, u, g, l)(i, o || c);
|
|
2525
2600
|
}
|
|
2526
2601
|
};
|
|
2527
|
-
},
|
|
2528
|
-
const n =
|
|
2602
|
+
}, xn = function(l, r, a) {
|
|
2603
|
+
const n = M(l);
|
|
2529
2604
|
return {
|
|
2530
2605
|
/**
|
|
2531
2606
|
* Creates a new Malloy environment with the specified configuration. An environment serves as a container for packages, connections, and other resources. The environment will be initialized with the provided metadata and can immediately accept packages and connections.
|
|
@@ -2589,7 +2664,7 @@ class ta extends I {
|
|
|
2589
2664
|
* @throws {RequiredError}
|
|
2590
2665
|
*/
|
|
2591
2666
|
createEnvironment(r, a) {
|
|
2592
|
-
return
|
|
2667
|
+
return M(this.configuration).createEnvironment(r, a).then((n) => n(this.axios, this.basePath));
|
|
2593
2668
|
}
|
|
2594
2669
|
/**
|
|
2595
2670
|
* Permanently deletes an environment and all its associated resources including packages, connections, and metadata. This operation cannot be undone, so use with caution. The environment must exist and be accessible for deletion.
|
|
@@ -2599,7 +2674,7 @@ class ta extends I {
|
|
|
2599
2674
|
* @throws {RequiredError}
|
|
2600
2675
|
*/
|
|
2601
2676
|
deleteEnvironment(r, a) {
|
|
2602
|
-
return
|
|
2677
|
+
return M(this.configuration).deleteEnvironment(r, a).then((n) => n(this.axios, this.basePath));
|
|
2603
2678
|
}
|
|
2604
2679
|
/**
|
|
2605
2680
|
* Retrieves detailed information about a specific environment, including its packages, connections, configuration, and metadata. The reload parameter can be used to refresh the environment state from disk before returning the information.
|
|
@@ -2610,7 +2685,7 @@ class ta extends I {
|
|
|
2610
2685
|
* @throws {RequiredError}
|
|
2611
2686
|
*/
|
|
2612
2687
|
getEnvironment(r, a, n) {
|
|
2613
|
-
return
|
|
2688
|
+
return M(this.configuration).getEnvironment(r, a, n).then((e) => e(this.axios, this.basePath));
|
|
2614
2689
|
}
|
|
2615
2690
|
/**
|
|
2616
2691
|
* Retrieves a list of all environments currently hosted on this Malloy Publisher server. Each environment contains metadata about its packages, connections, and configuration. This endpoint is typically used to discover available environments and their basic information. This endpoint does not reload. A `reload` query parameter is rejected with 400 rather than ignored, because answering 200 here reads as a reload that worked. Reload is per-environment: use `GET /environments/{environmentName}?reload=true`.
|
|
@@ -2619,7 +2694,7 @@ class ta extends I {
|
|
|
2619
2694
|
* @throws {RequiredError}
|
|
2620
2695
|
*/
|
|
2621
2696
|
listEnvironments(r) {
|
|
2622
|
-
return
|
|
2697
|
+
return M(this.configuration).listEnvironments(r).then((a) => a(this.axios, this.basePath));
|
|
2623
2698
|
}
|
|
2624
2699
|
/**
|
|
2625
2700
|
* Updates the configuration and metadata of an existing environment. This allows you to modify environment settings, update the README, change the location, or update other environment-level properties. The environment must exist and be accessible.
|
|
@@ -2630,7 +2705,7 @@ class ta extends I {
|
|
|
2630
2705
|
* @throws {RequiredError}
|
|
2631
2706
|
*/
|
|
2632
2707
|
updateEnvironment(r, a, n) {
|
|
2633
|
-
return
|
|
2708
|
+
return M(this.configuration).updateEnvironment(r, a, n).then((e) => e(this.axios, this.basePath));
|
|
2634
2709
|
}
|
|
2635
2710
|
}
|
|
2636
2711
|
const na = function(l) {
|
|
@@ -2646,39 +2721,63 @@ const na = function(l) {
|
|
|
2646
2721
|
*/
|
|
2647
2722
|
createMaterialization: async (r, a, n, e = {}) => {
|
|
2648
2723
|
m("createMaterialization", "environmentName", r), m("createMaterialization", "packageName", a);
|
|
2649
|
-
const t = "/environments/{environmentName}/packages/{packageName}/materializations".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
2724
|
+
const t = "/environments/{environmentName}/packages/{packageName}/materializations".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
2650
2725
|
let o;
|
|
2651
2726
|
l && (o = l.baseOptions);
|
|
2652
|
-
const
|
|
2653
|
-
|
|
2727
|
+
const i = { method: "POST", ...o, ...e }, c = {}, p = {};
|
|
2728
|
+
c["Content-Type"] = "application/json", c.Accept = "application/json", v(s, p);
|
|
2654
2729
|
let d = o && o.headers ? o.headers : {};
|
|
2655
|
-
return
|
|
2656
|
-
url:
|
|
2657
|
-
options:
|
|
2730
|
+
return i.headers = { ...c, ...d, ...e.headers }, i.data = A(n, i, l), {
|
|
2731
|
+
url: V(s),
|
|
2732
|
+
options: i
|
|
2658
2733
|
};
|
|
2659
2734
|
},
|
|
2660
2735
|
/**
|
|
2661
|
-
* Deletes a terminal (MANIFEST_FILE_READY, FAILED, or CANCELLED) materialization record.
|
|
2736
|
+
* Deletes a terminal (MANIFEST_FILE_READY, FAILED, or CANCELLED) materialization record. A delete is record-only: it never drops a table, and the caller owns table GC. To drop a database table this run produced, use `drop-materialized-table` (`DELETE …/connections/{connectionName}/materializedTables/{tableName}`), which checks that no remaining run, of any version, names a table with that name in any place; a table built before 0.16.0 carries no ownership mark, so drop it first, passing this run\'s id, then delete the run. `dropTables=true` is refused with 400 and deletes nothing, as is any value other than `true` or `false` (the fix is to omit it); `dropTables=false`, which older clients send, is accepted and ignored.
|
|
2662
2737
|
* @summary Delete a materialization
|
|
2663
2738
|
* @param {string} environmentName Name of the environment
|
|
2664
2739
|
* @param {string} packageName Name of the package
|
|
2665
2740
|
* @param {string} materializationId ID of the materialization
|
|
2666
|
-
* @param {boolean} [dropTables] When true, also drop the physical tables recorded in the materialization\'s manifest before deleting the record. Defaults to false (record-only delete; the caller owns table GC). Only `true` and `false` are accepted. Any other value is refused with 400 rather than read as `false`, which would delete the record, leave the tables on disk, and still answer 204.
|
|
2667
2741
|
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space.
|
|
2668
2742
|
* @param {*} [options] Override http request option.
|
|
2669
2743
|
* @throws {RequiredError}
|
|
2670
2744
|
*/
|
|
2671
|
-
deleteMaterialization: async (r, a, n, e, t
|
|
2745
|
+
deleteMaterialization: async (r, a, n, e, t = {}) => {
|
|
2672
2746
|
m("deleteMaterialization", "environmentName", r), m("deleteMaterialization", "packageName", a), m("deleteMaterialization", "materializationId", n);
|
|
2673
|
-
const
|
|
2747
|
+
const s = "/environments/{environmentName}/packages/{packageName}/materializations/{materializationId}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{materializationId}", encodeURIComponent(String(n))), o = new URL(s, b);
|
|
2674
2748
|
let i;
|
|
2675
2749
|
l && (i = l.baseOptions);
|
|
2676
|
-
const
|
|
2677
|
-
e !== void 0 && (
|
|
2678
|
-
let
|
|
2679
|
-
return
|
|
2680
|
-
url:
|
|
2681
|
-
options:
|
|
2750
|
+
const c = { method: "DELETE", ...i, ...t }, p = {}, d = {};
|
|
2751
|
+
e !== void 0 && (d.versionId = e), p.Accept = "application/json", v(o, d);
|
|
2752
|
+
let h = i && i.headers ? i.headers : {};
|
|
2753
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
2754
|
+
url: V(o),
|
|
2755
|
+
options: c
|
|
2756
|
+
};
|
|
2757
|
+
},
|
|
2758
|
+
/**
|
|
2759
|
+
* Drops one database-tier table a materialization of this package built on one of the package\'s connections, with the staging and backup copies a crashed build can leave beside it when a run record names the table. This is the drop a caller makes after (or before) deleting a run\'s record, which never drops a table. A `storage=` table lives in a storage destination, which this route does not reach; the admin API\'s catalog routes drop those. Publisher does not authenticate the caller: the gateway in front of it decides who may call this route, and should allow only the operator that owns the package\'s materialization lifecycle. The route itself refuses any table it cannot prove is this package\'s and unused, under the package\'s run lock and the table name\'s lock, so no run starts, commits or claims the name between the checks and the drop: * 400: the name cannot be quoted in the connection\'s dialect, or it is the staging or backup copy a build makes of a table a run of the package records, which is dropped only with that table. * 404, with no `reason`: the package does not reach a connection by that name (or the environment, package or `materializationId` does not exist). * 409 `MATERIALIZATION_CONFLICT`: a run of the package is active. Retry once it settles. * 409 `TABLE_IN_USE`: a committed run of the package, of any version, other than the one `materializationId` names, names a table with this name in any place; the run `materializationId` names is the one a version or the package serves; or a loaded copy of any package in the environment is bound to a table with this name; or the warehouse refused the drop because other objects depend on the table (Postgres 2BP01). Delete or replace that run, or those objects, first. * 409 `TABLE_OWNED_ELSEWHERE`: the table carries another package\'s ownership mark, or the name is held by a view Publisher did not create or another package\'s view; or the warehouse refused the drop because the connection may not drop it (42501) or the name holds something other than a table (42809). The answer does not name the holder. * 409 `TABLE_OWNERSHIP_UNVERIFIED`: the table carries no ownership mark this route accepts, and the run `materializationId` names (terminal, of this package) does not record it on this connection; or who holds the name could not be read. A mark is accepted only when it names this package and the very place the warehouse\'s catalog says the name resolves to now (its fully qualified location, recorded when the mark was written): a comment travels with a renamed, moved or cloned table, so such a copy, or another schema\'s table a search path finds first, is treated as unmarked, as is a mark written before 0.16.0 (it names no place). Drop such a table passing the id of the run that records it, before deleting that run\'s record. * 404 `TABLE_NOT_FOUND`: no table holds the name and no run record of this package names it on this connection, so nothing proves it was ever this package\'s. A table that is already gone answers 204 when a run record of this package still names it on this connection (pass its `materializationId`, or retry before deleting the record), so a retried drop succeeds; otherwise 404 `TABLE_NOT_FOUND`.
|
|
2760
|
+
* @summary Drop a materialized table from a package\'s connection
|
|
2761
|
+
* @param {string} environmentName Name of the environment
|
|
2762
|
+
* @param {string} packageName Name of the package
|
|
2763
|
+
* @param {string} connectionName Name of the connection the table was built on, as the package reaches it
|
|
2764
|
+
* @param {string} tableName The table\'s full name as the run\'s manifest records it (`physicalTableName`: `table`, `schema.table` or `catalog.schema.table`), URL-encoded. It is quoted for the connection\'s dialect as the build quoted it; a name the dialect cannot quote answers 400.
|
|
2765
|
+
* @param {string} [materializationId] The id of the run that built the table, as evidence that it is this package\'s when it carries no ownership mark. That run is not counted as using the table, unless it is the one a version or the package serves. Must be a terminal run of this package (404 otherwise; 409 `MATERIALIZATION_CONFLICT` while it is active).
|
|
2766
|
+
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space.
|
|
2767
|
+
* @param {*} [options] Override http request option.
|
|
2768
|
+
* @throws {RequiredError}
|
|
2769
|
+
*/
|
|
2770
|
+
dropMaterializedTable: async (r, a, n, e, t, s, o = {}) => {
|
|
2771
|
+
m("dropMaterializedTable", "environmentName", r), m("dropMaterializedTable", "packageName", a), m("dropMaterializedTable", "connectionName", n), m("dropMaterializedTable", "tableName", e);
|
|
2772
|
+
const i = "/environments/{environmentName}/packages/{packageName}/connections/{connectionName}/materializedTables/{tableName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{connectionName}", encodeURIComponent(String(n))).replace("{tableName}", encodeURIComponent(String(e))), c = new URL(i, b);
|
|
2773
|
+
let p;
|
|
2774
|
+
l && (p = l.baseOptions);
|
|
2775
|
+
const d = { method: "DELETE", ...p, ...o }, h = {}, k = {};
|
|
2776
|
+
t !== void 0 && (k.materializationId = t), s !== void 0 && (k.versionId = s), h.Accept = "application/json", v(c, k);
|
|
2777
|
+
let O = p && p.headers ? p.headers : {};
|
|
2778
|
+
return d.headers = { ...h, ...O, ...o.headers }, {
|
|
2779
|
+
url: V(c),
|
|
2780
|
+
options: d
|
|
2682
2781
|
};
|
|
2683
2782
|
},
|
|
2684
2783
|
/**
|
|
@@ -2693,15 +2792,15 @@ const na = function(l) {
|
|
|
2693
2792
|
*/
|
|
2694
2793
|
getMaterialization: async (r, a, n, e, t = {}) => {
|
|
2695
2794
|
m("getMaterialization", "environmentName", r), m("getMaterialization", "packageName", a), m("getMaterialization", "materializationId", n);
|
|
2696
|
-
const s = "/environments/{environmentName}/packages/{packageName}/materializations/{materializationId}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{materializationId}", encodeURIComponent(String(n))), o = new URL(s,
|
|
2697
|
-
let
|
|
2698
|
-
l && (
|
|
2699
|
-
const
|
|
2795
|
+
const s = "/environments/{environmentName}/packages/{packageName}/materializations/{materializationId}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{materializationId}", encodeURIComponent(String(n))), o = new URL(s, b);
|
|
2796
|
+
let i;
|
|
2797
|
+
l && (i = l.baseOptions);
|
|
2798
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
2700
2799
|
e !== void 0 && (d.versionId = e), p.Accept = "application/json", v(o, d);
|
|
2701
|
-
let h =
|
|
2702
|
-
return
|
|
2703
|
-
url:
|
|
2704
|
-
options:
|
|
2800
|
+
let h = i && i.headers ? i.headers : {};
|
|
2801
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
2802
|
+
url: V(o),
|
|
2803
|
+
options: c
|
|
2705
2804
|
};
|
|
2706
2805
|
},
|
|
2707
2806
|
/**
|
|
@@ -2717,14 +2816,14 @@ const na = function(l) {
|
|
|
2717
2816
|
*/
|
|
2718
2817
|
listMaterializations: async (r, a, n, e, t, s = {}) => {
|
|
2719
2818
|
m("listMaterializations", "environmentName", r), m("listMaterializations", "packageName", a);
|
|
2720
|
-
const o = "/environments/{environmentName}/packages/{packageName}/materializations".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))),
|
|
2721
|
-
let
|
|
2722
|
-
l && (
|
|
2723
|
-
const p = { method: "GET", ...
|
|
2724
|
-
n !== void 0 && (h.limit = n), e !== void 0 && (h.offset = e), t !== void 0 && (h.versionId = t), d.Accept = "application/json", v(
|
|
2725
|
-
let k =
|
|
2819
|
+
const o = "/environments/{environmentName}/packages/{packageName}/materializations".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), i = new URL(o, b);
|
|
2820
|
+
let c;
|
|
2821
|
+
l && (c = l.baseOptions);
|
|
2822
|
+
const p = { method: "GET", ...c, ...s }, d = {}, h = {};
|
|
2823
|
+
n !== void 0 && (h.limit = n), e !== void 0 && (h.offset = e), t !== void 0 && (h.versionId = t), d.Accept = "application/json", v(i, h);
|
|
2824
|
+
let k = c && c.headers ? c.headers : {};
|
|
2726
2825
|
return p.headers = { ...d, ...k, ...s.headers }, {
|
|
2727
|
-
url:
|
|
2826
|
+
url: V(i),
|
|
2728
2827
|
options: p
|
|
2729
2828
|
};
|
|
2730
2829
|
},
|
|
@@ -2741,19 +2840,19 @@ const na = function(l) {
|
|
|
2741
2840
|
*/
|
|
2742
2841
|
materializationAction: async (r, a, n, e, t, s = {}) => {
|
|
2743
2842
|
m("materializationAction", "environmentName", r), m("materializationAction", "packageName", a), m("materializationAction", "materializationId", n), m("materializationAction", "action", e);
|
|
2744
|
-
const o = "/environments/{environmentName}/packages/{packageName}/materializations/{materializationId}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{materializationId}", encodeURIComponent(String(n))),
|
|
2745
|
-
let
|
|
2746
|
-
l && (
|
|
2747
|
-
const p = { method: "POST", ...
|
|
2748
|
-
e !== void 0 && (h.action = e), t !== void 0 && (h.versionId = t), d.Accept = "application/json", v(
|
|
2749
|
-
let k =
|
|
2843
|
+
const o = "/environments/{environmentName}/packages/{packageName}/materializations/{materializationId}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{materializationId}", encodeURIComponent(String(n))), i = new URL(o, b);
|
|
2844
|
+
let c;
|
|
2845
|
+
l && (c = l.baseOptions);
|
|
2846
|
+
const p = { method: "POST", ...c, ...s }, d = {}, h = {};
|
|
2847
|
+
e !== void 0 && (h.action = e), t !== void 0 && (h.versionId = t), d.Accept = "application/json", v(i, h);
|
|
2848
|
+
let k = c && c.headers ? c.headers : {};
|
|
2750
2849
|
return p.headers = { ...d, ...k, ...s.headers }, {
|
|
2751
|
-
url:
|
|
2850
|
+
url: V(i),
|
|
2752
2851
|
options: p
|
|
2753
2852
|
};
|
|
2754
2853
|
}
|
|
2755
2854
|
};
|
|
2756
|
-
},
|
|
2855
|
+
}, T = function(l) {
|
|
2757
2856
|
const r = na(l);
|
|
2758
2857
|
return {
|
|
2759
2858
|
/**
|
|
@@ -2766,23 +2865,38 @@ const na = function(l) {
|
|
|
2766
2865
|
* @throws {RequiredError}
|
|
2767
2866
|
*/
|
|
2768
2867
|
async createMaterialization(a, n, e, t) {
|
|
2769
|
-
const s = await r.createMaterialization(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
2770
|
-
return (
|
|
2868
|
+
const s = await r.createMaterialization(a, n, e, t), o = l?.serverIndex ?? 0, i = P["MaterializationsApi.createMaterialization"]?.[o]?.url;
|
|
2869
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
2771
2870
|
},
|
|
2772
2871
|
/**
|
|
2773
|
-
* Deletes a terminal (MANIFEST_FILE_READY, FAILED, or CANCELLED) materialization record.
|
|
2872
|
+
* Deletes a terminal (MANIFEST_FILE_READY, FAILED, or CANCELLED) materialization record. A delete is record-only: it never drops a table, and the caller owns table GC. To drop a database table this run produced, use `drop-materialized-table` (`DELETE …/connections/{connectionName}/materializedTables/{tableName}`), which checks that no remaining run, of any version, names a table with that name in any place; a table built before 0.16.0 carries no ownership mark, so drop it first, passing this run\'s id, then delete the run. `dropTables=true` is refused with 400 and deletes nothing, as is any value other than `true` or `false` (the fix is to omit it); `dropTables=false`, which older clients send, is accepted and ignored.
|
|
2774
2873
|
* @summary Delete a materialization
|
|
2775
2874
|
* @param {string} environmentName Name of the environment
|
|
2776
2875
|
* @param {string} packageName Name of the package
|
|
2777
2876
|
* @param {string} materializationId ID of the materialization
|
|
2778
|
-
* @param {boolean} [dropTables] When true, also drop the physical tables recorded in the materialization\'s manifest before deleting the record. Defaults to false (record-only delete; the caller owns table GC). Only `true` and `false` are accepted. Any other value is refused with 400 rather than read as `false`, which would delete the record, leave the tables on disk, and still answer 204.
|
|
2779
2877
|
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space.
|
|
2780
2878
|
* @param {*} [options] Override http request option.
|
|
2781
2879
|
* @throws {RequiredError}
|
|
2782
2880
|
*/
|
|
2783
|
-
async deleteMaterialization(a, n, e, t, s
|
|
2784
|
-
const
|
|
2785
|
-
return (
|
|
2881
|
+
async deleteMaterialization(a, n, e, t, s) {
|
|
2882
|
+
const o = await r.deleteMaterialization(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["MaterializationsApi.deleteMaterialization"]?.[i]?.url;
|
|
2883
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
2884
|
+
},
|
|
2885
|
+
/**
|
|
2886
|
+
* Drops one database-tier table a materialization of this package built on one of the package\'s connections, with the staging and backup copies a crashed build can leave beside it when a run record names the table. This is the drop a caller makes after (or before) deleting a run\'s record, which never drops a table. A `storage=` table lives in a storage destination, which this route does not reach; the admin API\'s catalog routes drop those. Publisher does not authenticate the caller: the gateway in front of it decides who may call this route, and should allow only the operator that owns the package\'s materialization lifecycle. The route itself refuses any table it cannot prove is this package\'s and unused, under the package\'s run lock and the table name\'s lock, so no run starts, commits or claims the name between the checks and the drop: * 400: the name cannot be quoted in the connection\'s dialect, or it is the staging or backup copy a build makes of a table a run of the package records, which is dropped only with that table. * 404, with no `reason`: the package does not reach a connection by that name (or the environment, package or `materializationId` does not exist). * 409 `MATERIALIZATION_CONFLICT`: a run of the package is active. Retry once it settles. * 409 `TABLE_IN_USE`: a committed run of the package, of any version, other than the one `materializationId` names, names a table with this name in any place; the run `materializationId` names is the one a version or the package serves; or a loaded copy of any package in the environment is bound to a table with this name; or the warehouse refused the drop because other objects depend on the table (Postgres 2BP01). Delete or replace that run, or those objects, first. * 409 `TABLE_OWNED_ELSEWHERE`: the table carries another package\'s ownership mark, or the name is held by a view Publisher did not create or another package\'s view; or the warehouse refused the drop because the connection may not drop it (42501) or the name holds something other than a table (42809). The answer does not name the holder. * 409 `TABLE_OWNERSHIP_UNVERIFIED`: the table carries no ownership mark this route accepts, and the run `materializationId` names (terminal, of this package) does not record it on this connection; or who holds the name could not be read. A mark is accepted only when it names this package and the very place the warehouse\'s catalog says the name resolves to now (its fully qualified location, recorded when the mark was written): a comment travels with a renamed, moved or cloned table, so such a copy, or another schema\'s table a search path finds first, is treated as unmarked, as is a mark written before 0.16.0 (it names no place). Drop such a table passing the id of the run that records it, before deleting that run\'s record. * 404 `TABLE_NOT_FOUND`: no table holds the name and no run record of this package names it on this connection, so nothing proves it was ever this package\'s. A table that is already gone answers 204 when a run record of this package still names it on this connection (pass its `materializationId`, or retry before deleting the record), so a retried drop succeeds; otherwise 404 `TABLE_NOT_FOUND`.
|
|
2887
|
+
* @summary Drop a materialized table from a package\'s connection
|
|
2888
|
+
* @param {string} environmentName Name of the environment
|
|
2889
|
+
* @param {string} packageName Name of the package
|
|
2890
|
+
* @param {string} connectionName Name of the connection the table was built on, as the package reaches it
|
|
2891
|
+
* @param {string} tableName The table\'s full name as the run\'s manifest records it (`physicalTableName`: `table`, `schema.table` or `catalog.schema.table`), URL-encoded. It is quoted for the connection\'s dialect as the build quoted it; a name the dialect cannot quote answers 400.
|
|
2892
|
+
* @param {string} [materializationId] The id of the run that built the table, as evidence that it is this package\'s when it carries no ownership mark. That run is not counted as using the table, unless it is the one a version or the package serves. Must be a terminal run of this package (404 otherwise; 409 `MATERIALIZATION_CONFLICT` while it is active).
|
|
2893
|
+
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space.
|
|
2894
|
+
* @param {*} [options] Override http request option.
|
|
2895
|
+
* @throws {RequiredError}
|
|
2896
|
+
*/
|
|
2897
|
+
async dropMaterializedTable(a, n, e, t, s, o, i) {
|
|
2898
|
+
const c = await r.dropMaterializedTable(a, n, e, t, s, o, i), p = l?.serverIndex ?? 0, d = P["MaterializationsApi.dropMaterializedTable"]?.[p]?.url;
|
|
2899
|
+
return (h, k) => S(c, u, g, l)(h, d || k);
|
|
2786
2900
|
},
|
|
2787
2901
|
/**
|
|
2788
2902
|
* A run\'s id is unique, so with no `versionId` the run is found whichever version built it. Naming a version also requires the run to be that version\'s (or one from before the package\'s first versioned publish); the same holds for stopping and deleting a run.
|
|
@@ -2795,8 +2909,8 @@ const na = function(l) {
|
|
|
2795
2909
|
* @throws {RequiredError}
|
|
2796
2910
|
*/
|
|
2797
2911
|
async getMaterialization(a, n, e, t, s) {
|
|
2798
|
-
const o = await r.getMaterialization(a, n, e, t, s),
|
|
2799
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
2912
|
+
const o = await r.getMaterialization(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["MaterializationsApi.getMaterialization"]?.[i]?.url;
|
|
2913
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
2800
2914
|
},
|
|
2801
2915
|
/**
|
|
2802
2916
|
* Returns the materialization history for the package, ordered by most recent first. For a package with published versions, the runs of one version (the one `versionId` names, or `latest`), together with the runs from before the package\'s first versioned publish.
|
|
@@ -2810,8 +2924,8 @@ const na = function(l) {
|
|
|
2810
2924
|
* @throws {RequiredError}
|
|
2811
2925
|
*/
|
|
2812
2926
|
async listMaterializations(a, n, e, t, s, o) {
|
|
2813
|
-
const
|
|
2814
|
-
return (d, h) => S(
|
|
2927
|
+
const i = await r.listMaterializations(a, n, e, t, s, o), c = l?.serverIndex ?? 0, p = P["MaterializationsApi.listMaterializations"]?.[c]?.url;
|
|
2928
|
+
return (d, h) => S(i, u, g, l)(d, p || h);
|
|
2815
2929
|
},
|
|
2816
2930
|
/**
|
|
2817
2931
|
* Performs an action on a materialization. The action is specified via the `action` query parameter: * `stop` - Cancels a PENDING or building materialization. Returns 200.
|
|
@@ -2825,12 +2939,12 @@ const na = function(l) {
|
|
|
2825
2939
|
* @throws {RequiredError}
|
|
2826
2940
|
*/
|
|
2827
2941
|
async materializationAction(a, n, e, t, s, o) {
|
|
2828
|
-
const
|
|
2829
|
-
return (d, h) => S(
|
|
2942
|
+
const i = await r.materializationAction(a, n, e, t, s, o), c = l?.serverIndex ?? 0, p = P["MaterializationsApi.materializationAction"]?.[c]?.url;
|
|
2943
|
+
return (d, h) => S(i, u, g, l)(d, p || h);
|
|
2830
2944
|
}
|
|
2831
2945
|
};
|
|
2832
|
-
},
|
|
2833
|
-
const n =
|
|
2946
|
+
}, Nn = function(l, r, a) {
|
|
2947
|
+
const n = T(l);
|
|
2834
2948
|
return {
|
|
2835
2949
|
/**
|
|
2836
2950
|
* Creates a materialization and starts building. Behavior depends on the request body (see CreateMaterializationRequest): * Orchestrated build — supply `buildInstructions`. The publisher builds directly into the caller-assigned names derived from the package\'s already-compiled build plan (read off `Package.buildPlan`). Returns the materialization already building. * Auto-run (standalone, default) — omit `buildInstructions`; the publisher self-assigns names and runs all phases in one pass.
|
|
@@ -2842,21 +2956,35 @@ const na = function(l) {
|
|
|
2842
2956
|
* @throws {RequiredError}
|
|
2843
2957
|
*/
|
|
2844
2958
|
createMaterialization(e, t, s, o) {
|
|
2845
|
-
return n.createMaterialization(e, t, s, o).then((
|
|
2959
|
+
return n.createMaterialization(e, t, s, o).then((i) => i(a, r));
|
|
2846
2960
|
},
|
|
2847
2961
|
/**
|
|
2848
|
-
* Deletes a terminal (MANIFEST_FILE_READY, FAILED, or CANCELLED) materialization record.
|
|
2962
|
+
* Deletes a terminal (MANIFEST_FILE_READY, FAILED, or CANCELLED) materialization record. A delete is record-only: it never drops a table, and the caller owns table GC. To drop a database table this run produced, use `drop-materialized-table` (`DELETE …/connections/{connectionName}/materializedTables/{tableName}`), which checks that no remaining run, of any version, names a table with that name in any place; a table built before 0.16.0 carries no ownership mark, so drop it first, passing this run\'s id, then delete the run. `dropTables=true` is refused with 400 and deletes nothing, as is any value other than `true` or `false` (the fix is to omit it); `dropTables=false`, which older clients send, is accepted and ignored.
|
|
2849
2963
|
* @summary Delete a materialization
|
|
2850
2964
|
* @param {string} environmentName Name of the environment
|
|
2851
2965
|
* @param {string} packageName Name of the package
|
|
2852
2966
|
* @param {string} materializationId ID of the materialization
|
|
2853
|
-
* @param {boolean} [dropTables] When true, also drop the physical tables recorded in the materialization\'s manifest before deleting the record. Defaults to false (record-only delete; the caller owns table GC). Only `true` and `false` are accepted. Any other value is refused with 400 rather than read as `false`, which would delete the record, leave the tables on disk, and still answer 204.
|
|
2854
2967
|
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space.
|
|
2855
2968
|
* @param {*} [options] Override http request option.
|
|
2856
2969
|
* @throws {RequiredError}
|
|
2857
2970
|
*/
|
|
2858
|
-
deleteMaterialization(e, t, s, o,
|
|
2859
|
-
return n.deleteMaterialization(e, t, s, o,
|
|
2971
|
+
deleteMaterialization(e, t, s, o, i) {
|
|
2972
|
+
return n.deleteMaterialization(e, t, s, o, i).then((c) => c(a, r));
|
|
2973
|
+
},
|
|
2974
|
+
/**
|
|
2975
|
+
* Drops one database-tier table a materialization of this package built on one of the package\'s connections, with the staging and backup copies a crashed build can leave beside it when a run record names the table. This is the drop a caller makes after (or before) deleting a run\'s record, which never drops a table. A `storage=` table lives in a storage destination, which this route does not reach; the admin API\'s catalog routes drop those. Publisher does not authenticate the caller: the gateway in front of it decides who may call this route, and should allow only the operator that owns the package\'s materialization lifecycle. The route itself refuses any table it cannot prove is this package\'s and unused, under the package\'s run lock and the table name\'s lock, so no run starts, commits or claims the name between the checks and the drop: * 400: the name cannot be quoted in the connection\'s dialect, or it is the staging or backup copy a build makes of a table a run of the package records, which is dropped only with that table. * 404, with no `reason`: the package does not reach a connection by that name (or the environment, package or `materializationId` does not exist). * 409 `MATERIALIZATION_CONFLICT`: a run of the package is active. Retry once it settles. * 409 `TABLE_IN_USE`: a committed run of the package, of any version, other than the one `materializationId` names, names a table with this name in any place; the run `materializationId` names is the one a version or the package serves; or a loaded copy of any package in the environment is bound to a table with this name; or the warehouse refused the drop because other objects depend on the table (Postgres 2BP01). Delete or replace that run, or those objects, first. * 409 `TABLE_OWNED_ELSEWHERE`: the table carries another package\'s ownership mark, or the name is held by a view Publisher did not create or another package\'s view; or the warehouse refused the drop because the connection may not drop it (42501) or the name holds something other than a table (42809). The answer does not name the holder. * 409 `TABLE_OWNERSHIP_UNVERIFIED`: the table carries no ownership mark this route accepts, and the run `materializationId` names (terminal, of this package) does not record it on this connection; or who holds the name could not be read. A mark is accepted only when it names this package and the very place the warehouse\'s catalog says the name resolves to now (its fully qualified location, recorded when the mark was written): a comment travels with a renamed, moved or cloned table, so such a copy, or another schema\'s table a search path finds first, is treated as unmarked, as is a mark written before 0.16.0 (it names no place). Drop such a table passing the id of the run that records it, before deleting that run\'s record. * 404 `TABLE_NOT_FOUND`: no table holds the name and no run record of this package names it on this connection, so nothing proves it was ever this package\'s. A table that is already gone answers 204 when a run record of this package still names it on this connection (pass its `materializationId`, or retry before deleting the record), so a retried drop succeeds; otherwise 404 `TABLE_NOT_FOUND`.
|
|
2976
|
+
* @summary Drop a materialized table from a package\'s connection
|
|
2977
|
+
* @param {string} environmentName Name of the environment
|
|
2978
|
+
* @param {string} packageName Name of the package
|
|
2979
|
+
* @param {string} connectionName Name of the connection the table was built on, as the package reaches it
|
|
2980
|
+
* @param {string} tableName The table\'s full name as the run\'s manifest records it (`physicalTableName`: `table`, `schema.table` or `catalog.schema.table`), URL-encoded. It is quoted for the connection\'s dialect as the build quoted it; a name the dialect cannot quote answers 400.
|
|
2981
|
+
* @param {string} [materializationId] The id of the run that built the table, as evidence that it is this package\'s when it carries no ownership mark. That run is not counted as using the table, unless it is the one a version or the package serves. Must be a terminal run of this package (404 otherwise; 409 `MATERIALIZATION_CONFLICT` while it is active).
|
|
2982
|
+
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space.
|
|
2983
|
+
* @param {*} [options] Override http request option.
|
|
2984
|
+
* @throws {RequiredError}
|
|
2985
|
+
*/
|
|
2986
|
+
dropMaterializedTable(e, t, s, o, i, c, p) {
|
|
2987
|
+
return n.dropMaterializedTable(e, t, s, o, i, c, p).then((d) => d(a, r));
|
|
2860
2988
|
},
|
|
2861
2989
|
/**
|
|
2862
2990
|
* A run\'s id is unique, so with no `versionId` the run is found whichever version built it. Naming a version also requires the run to be that version\'s (or one from before the package\'s first versioned publish); the same holds for stopping and deleting a run.
|
|
@@ -2868,8 +2996,8 @@ const na = function(l) {
|
|
|
2868
2996
|
* @param {*} [options] Override http request option.
|
|
2869
2997
|
* @throws {RequiredError}
|
|
2870
2998
|
*/
|
|
2871
|
-
getMaterialization(e, t, s, o,
|
|
2872
|
-
return n.getMaterialization(e, t, s, o,
|
|
2999
|
+
getMaterialization(e, t, s, o, i) {
|
|
3000
|
+
return n.getMaterialization(e, t, s, o, i).then((c) => c(a, r));
|
|
2873
3001
|
},
|
|
2874
3002
|
/**
|
|
2875
3003
|
* Returns the materialization history for the package, ordered by most recent first. For a package with published versions, the runs of one version (the one `versionId` names, or `latest`), together with the runs from before the package\'s first versioned publish.
|
|
@@ -2882,8 +3010,8 @@ const na = function(l) {
|
|
|
2882
3010
|
* @param {*} [options] Override http request option.
|
|
2883
3011
|
* @throws {RequiredError}
|
|
2884
3012
|
*/
|
|
2885
|
-
listMaterializations(e, t, s, o,
|
|
2886
|
-
return n.listMaterializations(e, t, s, o,
|
|
3013
|
+
listMaterializations(e, t, s, o, i, c) {
|
|
3014
|
+
return n.listMaterializations(e, t, s, o, i, c).then((p) => p(a, r));
|
|
2887
3015
|
},
|
|
2888
3016
|
/**
|
|
2889
3017
|
* Performs an action on a materialization. The action is specified via the `action` query parameter: * `stop` - Cancels a PENDING or building materialization. Returns 200.
|
|
@@ -2896,8 +3024,8 @@ const na = function(l) {
|
|
|
2896
3024
|
* @param {*} [options] Override http request option.
|
|
2897
3025
|
* @throws {RequiredError}
|
|
2898
3026
|
*/
|
|
2899
|
-
materializationAction(e, t, s, o,
|
|
2900
|
-
return n.materializationAction(e, t, s, o,
|
|
3027
|
+
materializationAction(e, t, s, o, i, c) {
|
|
3028
|
+
return n.materializationAction(e, t, s, o, i, c).then((p) => p(a, r));
|
|
2901
3029
|
}
|
|
2902
3030
|
};
|
|
2903
3031
|
};
|
|
@@ -2912,21 +3040,35 @@ class ra extends I {
|
|
|
2912
3040
|
* @throws {RequiredError}
|
|
2913
3041
|
*/
|
|
2914
3042
|
createMaterialization(r, a, n, e) {
|
|
2915
|
-
return
|
|
3043
|
+
return T(this.configuration).createMaterialization(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
2916
3044
|
}
|
|
2917
3045
|
/**
|
|
2918
|
-
* Deletes a terminal (MANIFEST_FILE_READY, FAILED, or CANCELLED) materialization record.
|
|
3046
|
+
* Deletes a terminal (MANIFEST_FILE_READY, FAILED, or CANCELLED) materialization record. A delete is record-only: it never drops a table, and the caller owns table GC. To drop a database table this run produced, use `drop-materialized-table` (`DELETE …/connections/{connectionName}/materializedTables/{tableName}`), which checks that no remaining run, of any version, names a table with that name in any place; a table built before 0.16.0 carries no ownership mark, so drop it first, passing this run\'s id, then delete the run. `dropTables=true` is refused with 400 and deletes nothing, as is any value other than `true` or `false` (the fix is to omit it); `dropTables=false`, which older clients send, is accepted and ignored.
|
|
2919
3047
|
* @summary Delete a materialization
|
|
2920
3048
|
* @param {string} environmentName Name of the environment
|
|
2921
3049
|
* @param {string} packageName Name of the package
|
|
2922
3050
|
* @param {string} materializationId ID of the materialization
|
|
2923
|
-
* @param {boolean} [dropTables] When true, also drop the physical tables recorded in the materialization\'s manifest before deleting the record. Defaults to false (record-only delete; the caller owns table GC). Only `true` and `false` are accepted. Any other value is refused with 400 rather than read as `false`, which would delete the record, leave the tables on disk, and still answer 204.
|
|
2924
3051
|
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space.
|
|
2925
3052
|
* @param {*} [options] Override http request option.
|
|
2926
3053
|
* @throws {RequiredError}
|
|
2927
3054
|
*/
|
|
2928
|
-
deleteMaterialization(r, a, n, e, t
|
|
2929
|
-
return
|
|
3055
|
+
deleteMaterialization(r, a, n, e, t) {
|
|
3056
|
+
return T(this.configuration).deleteMaterialization(r, a, n, e, t).then((s) => s(this.axios, this.basePath));
|
|
3057
|
+
}
|
|
3058
|
+
/**
|
|
3059
|
+
* Drops one database-tier table a materialization of this package built on one of the package\'s connections, with the staging and backup copies a crashed build can leave beside it when a run record names the table. This is the drop a caller makes after (or before) deleting a run\'s record, which never drops a table. A `storage=` table lives in a storage destination, which this route does not reach; the admin API\'s catalog routes drop those. Publisher does not authenticate the caller: the gateway in front of it decides who may call this route, and should allow only the operator that owns the package\'s materialization lifecycle. The route itself refuses any table it cannot prove is this package\'s and unused, under the package\'s run lock and the table name\'s lock, so no run starts, commits or claims the name between the checks and the drop: * 400: the name cannot be quoted in the connection\'s dialect, or it is the staging or backup copy a build makes of a table a run of the package records, which is dropped only with that table. * 404, with no `reason`: the package does not reach a connection by that name (or the environment, package or `materializationId` does not exist). * 409 `MATERIALIZATION_CONFLICT`: a run of the package is active. Retry once it settles. * 409 `TABLE_IN_USE`: a committed run of the package, of any version, other than the one `materializationId` names, names a table with this name in any place; the run `materializationId` names is the one a version or the package serves; or a loaded copy of any package in the environment is bound to a table with this name; or the warehouse refused the drop because other objects depend on the table (Postgres 2BP01). Delete or replace that run, or those objects, first. * 409 `TABLE_OWNED_ELSEWHERE`: the table carries another package\'s ownership mark, or the name is held by a view Publisher did not create or another package\'s view; or the warehouse refused the drop because the connection may not drop it (42501) or the name holds something other than a table (42809). The answer does not name the holder. * 409 `TABLE_OWNERSHIP_UNVERIFIED`: the table carries no ownership mark this route accepts, and the run `materializationId` names (terminal, of this package) does not record it on this connection; or who holds the name could not be read. A mark is accepted only when it names this package and the very place the warehouse\'s catalog says the name resolves to now (its fully qualified location, recorded when the mark was written): a comment travels with a renamed, moved or cloned table, so such a copy, or another schema\'s table a search path finds first, is treated as unmarked, as is a mark written before 0.16.0 (it names no place). Drop such a table passing the id of the run that records it, before deleting that run\'s record. * 404 `TABLE_NOT_FOUND`: no table holds the name and no run record of this package names it on this connection, so nothing proves it was ever this package\'s. A table that is already gone answers 204 when a run record of this package still names it on this connection (pass its `materializationId`, or retry before deleting the record), so a retried drop succeeds; otherwise 404 `TABLE_NOT_FOUND`.
|
|
3060
|
+
* @summary Drop a materialized table from a package\'s connection
|
|
3061
|
+
* @param {string} environmentName Name of the environment
|
|
3062
|
+
* @param {string} packageName Name of the package
|
|
3063
|
+
* @param {string} connectionName Name of the connection the table was built on, as the package reaches it
|
|
3064
|
+
* @param {string} tableName The table\'s full name as the run\'s manifest records it (`physicalTableName`: `table`, `schema.table` or `catalog.schema.table`), URL-encoded. It is quoted for the connection\'s dialect as the build quoted it; a name the dialect cannot quote answers 400.
|
|
3065
|
+
* @param {string} [materializationId] The id of the run that built the table, as evidence that it is this package\'s when it carries no ownership mark. That run is not counted as using the table, unless it is the one a version or the package serves. Must be a terminal run of this package (404 otherwise; 409 `MATERIALIZATION_CONFLICT` while it is active).
|
|
3066
|
+
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space.
|
|
3067
|
+
* @param {*} [options] Override http request option.
|
|
3068
|
+
* @throws {RequiredError}
|
|
3069
|
+
*/
|
|
3070
|
+
dropMaterializedTable(r, a, n, e, t, s, o) {
|
|
3071
|
+
return T(this.configuration).dropMaterializedTable(r, a, n, e, t, s, o).then((i) => i(this.axios, this.basePath));
|
|
2930
3072
|
}
|
|
2931
3073
|
/**
|
|
2932
3074
|
* A run\'s id is unique, so with no `versionId` the run is found whichever version built it. Naming a version also requires the run to be that version\'s (or one from before the package\'s first versioned publish); the same holds for stopping and deleting a run.
|
|
@@ -2939,7 +3081,7 @@ class ra extends I {
|
|
|
2939
3081
|
* @throws {RequiredError}
|
|
2940
3082
|
*/
|
|
2941
3083
|
getMaterialization(r, a, n, e, t) {
|
|
2942
|
-
return
|
|
3084
|
+
return T(this.configuration).getMaterialization(r, a, n, e, t).then((s) => s(this.axios, this.basePath));
|
|
2943
3085
|
}
|
|
2944
3086
|
/**
|
|
2945
3087
|
* Returns the materialization history for the package, ordered by most recent first. For a package with published versions, the runs of one version (the one `versionId` names, or `latest`), together with the runs from before the package\'s first versioned publish.
|
|
@@ -2953,7 +3095,7 @@ class ra extends I {
|
|
|
2953
3095
|
* @throws {RequiredError}
|
|
2954
3096
|
*/
|
|
2955
3097
|
listMaterializations(r, a, n, e, t, s) {
|
|
2956
|
-
return
|
|
3098
|
+
return T(this.configuration).listMaterializations(r, a, n, e, t, s).then((o) => o(this.axios, this.basePath));
|
|
2957
3099
|
}
|
|
2958
3100
|
/**
|
|
2959
3101
|
* Performs an action on a materialization. The action is specified via the `action` query parameter: * `stop` - Cancels a PENDING or building materialization. Returns 200.
|
|
@@ -2967,10 +3109,10 @@ class ra extends I {
|
|
|
2967
3109
|
* @throws {RequiredError}
|
|
2968
3110
|
*/
|
|
2969
3111
|
materializationAction(r, a, n, e, t, s) {
|
|
2970
|
-
return
|
|
3112
|
+
return T(this.configuration).materializationAction(r, a, n, e, t, s).then((o) => o(this.axios, this.basePath));
|
|
2971
3113
|
}
|
|
2972
3114
|
}
|
|
2973
|
-
const
|
|
3115
|
+
const Un = {
|
|
2974
3116
|
Stop: "stop"
|
|
2975
3117
|
}, oa = function(l) {
|
|
2976
3118
|
return {
|
|
@@ -2987,14 +3129,14 @@ const yn = {
|
|
|
2987
3129
|
*/
|
|
2988
3130
|
compileModelSource: async (r, a, n, e, t, s = {}) => {
|
|
2989
3131
|
m("compileModelSource", "environmentName", r), m("compileModelSource", "packageName", a), m("compileModelSource", "path", n), m("compileModelSource", "compileRequest", e);
|
|
2990
|
-
const o = "/environments/{environmentName}/packages/{packageName}/models/{path}/compile".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))),
|
|
2991
|
-
let
|
|
2992
|
-
l && (
|
|
2993
|
-
const p = { method: "POST", ...
|
|
2994
|
-
t !== void 0 && (h.versionId = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(
|
|
2995
|
-
let k =
|
|
3132
|
+
const o = "/environments/{environmentName}/packages/{packageName}/models/{path}/compile".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))), i = new URL(o, b);
|
|
3133
|
+
let c;
|
|
3134
|
+
l && (c = l.baseOptions);
|
|
3135
|
+
const p = { method: "POST", ...c, ...s }, d = {}, h = {};
|
|
3136
|
+
t !== void 0 && (h.versionId = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(i, h);
|
|
3137
|
+
let k = c && c.headers ? c.headers : {};
|
|
2996
3138
|
return p.headers = { ...d, ...k, ...s.headers }, p.data = A(e, p, l), {
|
|
2997
|
-
url:
|
|
3139
|
+
url: V(i),
|
|
2998
3140
|
options: p
|
|
2999
3141
|
};
|
|
3000
3142
|
},
|
|
@@ -3011,14 +3153,14 @@ const yn = {
|
|
|
3011
3153
|
*/
|
|
3012
3154
|
executeQueryModel: async (r, a, n, e, t, s = {}) => {
|
|
3013
3155
|
m("executeQueryModel", "environmentName", r), m("executeQueryModel", "packageName", a), m("executeQueryModel", "path", n), m("executeQueryModel", "queryRequest", e);
|
|
3014
|
-
const o = "/environments/{environmentName}/packages/{packageName}/models/{path}/query".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))),
|
|
3015
|
-
let
|
|
3016
|
-
l && (
|
|
3017
|
-
const p = { method: "POST", ...
|
|
3018
|
-
t !== void 0 && (h.includeHiddenFilesAndSources = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(
|
|
3019
|
-
let k =
|
|
3156
|
+
const o = "/environments/{environmentName}/packages/{packageName}/models/{path}/query".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))), i = new URL(o, b);
|
|
3157
|
+
let c;
|
|
3158
|
+
l && (c = l.baseOptions);
|
|
3159
|
+
const p = { method: "POST", ...c, ...s }, d = {}, h = {};
|
|
3160
|
+
t !== void 0 && (h.includeHiddenFilesAndSources = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(i, h);
|
|
3161
|
+
let k = c && c.headers ? c.headers : {};
|
|
3020
3162
|
return p.headers = { ...d, ...k, ...s.headers }, p.data = A(e, p, l), {
|
|
3021
|
-
url:
|
|
3163
|
+
url: V(i),
|
|
3022
3164
|
options: p
|
|
3023
3165
|
};
|
|
3024
3166
|
},
|
|
@@ -3036,14 +3178,14 @@ const yn = {
|
|
|
3036
3178
|
*/
|
|
3037
3179
|
getModel: async (r, a, n, e, t, s, o = {}) => {
|
|
3038
3180
|
m("getModel", "environmentName", r), m("getModel", "packageName", a), m("getModel", "path", n);
|
|
3039
|
-
const
|
|
3181
|
+
const i = "/environments/{environmentName}/packages/{packageName}/models/{path}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))), c = new URL(i, b);
|
|
3040
3182
|
let p;
|
|
3041
3183
|
l && (p = l.baseOptions);
|
|
3042
3184
|
const d = { method: "GET", ...p, ...o }, h = {}, k = {};
|
|
3043
|
-
e !== void 0 && (k.versionId = e), t !== void 0 && (k.includeHiddenFilesAndSources = t), s !== void 0 && (k.givens = s), h.Accept = "application/json", v(
|
|
3185
|
+
e !== void 0 && (k.versionId = e), t !== void 0 && (k.includeHiddenFilesAndSources = t), s !== void 0 && (k.givens = s), h.Accept = "application/json", v(c, k);
|
|
3044
3186
|
let O = p && p.headers ? p.headers : {};
|
|
3045
3187
|
return d.headers = { ...h, ...O, ...o.headers }, {
|
|
3046
|
-
url:
|
|
3188
|
+
url: V(c),
|
|
3047
3189
|
options: d
|
|
3048
3190
|
};
|
|
3049
3191
|
},
|
|
@@ -3059,15 +3201,15 @@ const yn = {
|
|
|
3059
3201
|
*/
|
|
3060
3202
|
listModels: async (r, a, n, e, t = {}) => {
|
|
3061
3203
|
m("listModels", "environmentName", r), m("listModels", "packageName", a);
|
|
3062
|
-
const s = "/environments/{environmentName}/packages/{packageName}/models".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), o = new URL(s,
|
|
3063
|
-
let
|
|
3064
|
-
l && (
|
|
3065
|
-
const
|
|
3204
|
+
const s = "/environments/{environmentName}/packages/{packageName}/models".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), o = new URL(s, b);
|
|
3205
|
+
let i;
|
|
3206
|
+
l && (i = l.baseOptions);
|
|
3207
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
3066
3208
|
n !== void 0 && (d.versionId = n), e !== void 0 && (d.includeHiddenFilesAndSources = e), p.Accept = "application/json", v(o, d);
|
|
3067
|
-
let h =
|
|
3068
|
-
return
|
|
3069
|
-
url:
|
|
3070
|
-
options:
|
|
3209
|
+
let h = i && i.headers ? i.headers : {};
|
|
3210
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
3211
|
+
url: V(o),
|
|
3212
|
+
options: c
|
|
3071
3213
|
};
|
|
3072
3214
|
},
|
|
3073
3215
|
/**
|
|
@@ -3083,14 +3225,14 @@ const yn = {
|
|
|
3083
3225
|
*/
|
|
3084
3226
|
updateModelSource: async (r, a, n, e, t, s = {}) => {
|
|
3085
3227
|
m("updateModelSource", "environmentName", r), m("updateModelSource", "packageName", a), m("updateModelSource", "path", n), m("updateModelSource", "modelSourceWriteRequest", e);
|
|
3086
|
-
const o = "/environments/{environmentName}/packages/{packageName}/models/{path}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))),
|
|
3087
|
-
let
|
|
3088
|
-
l && (
|
|
3089
|
-
const p = { method: "PUT", ...
|
|
3090
|
-
t !== void 0 && (h.versionId = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(
|
|
3091
|
-
let k =
|
|
3228
|
+
const o = "/environments/{environmentName}/packages/{packageName}/models/{path}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))), i = new URL(o, b);
|
|
3229
|
+
let c;
|
|
3230
|
+
l && (c = l.baseOptions);
|
|
3231
|
+
const p = { method: "PUT", ...c, ...s }, d = {}, h = {};
|
|
3232
|
+
t !== void 0 && (h.versionId = t), d["Content-Type"] = "application/json", d.Accept = "application/json", v(i, h);
|
|
3233
|
+
let k = c && c.headers ? c.headers : {};
|
|
3092
3234
|
return p.headers = { ...d, ...k, ...s.headers }, p.data = A(e, p, l), {
|
|
3093
|
-
url:
|
|
3235
|
+
url: V(i),
|
|
3094
3236
|
options: p
|
|
3095
3237
|
};
|
|
3096
3238
|
}
|
|
@@ -3110,8 +3252,8 @@ const yn = {
|
|
|
3110
3252
|
* @throws {RequiredError}
|
|
3111
3253
|
*/
|
|
3112
3254
|
async compileModelSource(a, n, e, t, s, o) {
|
|
3113
|
-
const
|
|
3114
|
-
return (d, h) => S(
|
|
3255
|
+
const i = await r.compileModelSource(a, n, e, t, s, o), c = l?.serverIndex ?? 0, p = P["ModelsApi.compileModelSource"]?.[c]?.url;
|
|
3256
|
+
return (d, h) => S(i, u, g, l)(d, p || h);
|
|
3115
3257
|
},
|
|
3116
3258
|
/**
|
|
3117
3259
|
* Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets. Text that fails only at the grammar and names no source to run (for example `run` with no colon) is also a 400, because a grammar error says nothing about the model, unless the model carries any `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface.
|
|
@@ -3125,8 +3267,8 @@ const yn = {
|
|
|
3125
3267
|
* @throws {RequiredError}
|
|
3126
3268
|
*/
|
|
3127
3269
|
async executeQueryModel(a, n, e, t, s, o) {
|
|
3128
|
-
const
|
|
3129
|
-
return (d, h) => S(
|
|
3270
|
+
const i = await r.executeQueryModel(a, n, e, t, s, o), c = l?.serverIndex ?? 0, p = P["ModelsApi.executeQueryModel"]?.[c]?.url;
|
|
3271
|
+
return (d, h) => S(i, u, g, l)(d, p || h);
|
|
3130
3272
|
},
|
|
3131
3273
|
/**
|
|
3132
3274
|
* Retrieves a compiled Malloy model with its source information, queries, and metadata. The model is compiled using the specified version of the Malloy compiler. This endpoint provides access to the model\'s structure, sources, and named queries for use in applications. On a package with a surface (a root `index.malloy`, or a legacy `explores`), a file off that surface answers 404 with the same message a query to it gets, unless `includeHiddenFilesAndSources` is true. With it, the file is returned with its `sourceText`, whatever sources the text names. Reports (see list-reports), wherever they live in the package, are always returned. A package with no surface, or with `queryableSources: \"all\"`, returns every file. For a file it returns, `modelDef.contents` and `modelDef.exports`, `modelInfo`, `sources` and `sourceInfos` are limited to the names the file publishes, so the surface file does not carry the hidden sources it imports. A join to a hidden source keeps only its name and the names and types of its fields. `sourceText` is left out when the text names a source the file does not publish, unless `includeHiddenFilesAndSources` is true; the text of a report is always returned.
|
|
@@ -3140,9 +3282,9 @@ const yn = {
|
|
|
3140
3282
|
* @param {*} [options] Override http request option.
|
|
3141
3283
|
* @throws {RequiredError}
|
|
3142
3284
|
*/
|
|
3143
|
-
async getModel(a, n, e, t, s, o,
|
|
3144
|
-
const
|
|
3145
|
-
return (h, k) => S(
|
|
3285
|
+
async getModel(a, n, e, t, s, o, i) {
|
|
3286
|
+
const c = await r.getModel(a, n, e, t, s, o, i), p = l?.serverIndex ?? 0, d = P["ModelsApi.getModel"]?.[p]?.url;
|
|
3287
|
+
return (h, k) => S(c, u, g, l)(h, d || k);
|
|
3146
3288
|
},
|
|
3147
3289
|
/**
|
|
3148
3290
|
* Retrieves the Malloy models within the specified package. Each model entry includes the relative path, package name, whether the package hides the file, and any compilation errors. On a package with a surface (a root `index.malloy`, or a legacy `explores`), only the files on that surface are listed, unless `includeHiddenFilesAndSources` is true. With it, every model file is listed, and `isHidden` marks the ones the package hides. Reports (any `.malloy` outside `public/` carrying an artifact tag, other than the root `index.malloy`; see list-reports) are listed by list-reports. A grid report is not a model here on a package with a surface; a linear report is not a model here with or without one.
|
|
@@ -3155,8 +3297,8 @@ const yn = {
|
|
|
3155
3297
|
* @throws {RequiredError}
|
|
3156
3298
|
*/
|
|
3157
3299
|
async listModels(a, n, e, t, s) {
|
|
3158
|
-
const o = await r.listModels(a, n, e, t, s),
|
|
3159
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
3300
|
+
const o = await r.listModels(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["ModelsApi.listModels"]?.[i]?.url;
|
|
3301
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
3160
3302
|
},
|
|
3161
3303
|
/**
|
|
3162
3304
|
* Writes the Malloy text of a report into the package, and reloads the package in place so it is served from the new text. This is the report builder\'s save. A report is any `.malloy` file carrying an artifact tag (see list-reports), of either layout, wherever it lives in the package. What it accepts: - CREATE (no `expectedHash`): any `.malloy` path in the package that does not exist yet, outside `public/`, and never the root `index.malloy`. Missing directories are created, inside the package root only. The text must carry an artifact tag (`## artifact`, or the deprecated query-level `# artifact`): an `artifact` property anywhere on a tag line, outside a string. Text without one is refused with 400. - REPLACE (with `expectedHash`): only a file the package currently reads as an editable report: a tagged `.malloy` report of either layout, including a tagged grid report that has no tiles yet, and a file whose tag makes no report (a `kind=` tag, or the retired `run:` cell format), so it can be rewritten as tiles. A model, an untagged file, a `.malloynb`, the root `index.malloy` and anything in `public/` cannot be overwritten, wherever they live, and answer 400. Two reports may share a basename in different directories; a report is identified by its path, so a taken basename is not refused. The text is compiled first, as the file, and refused with its problems when it does not compile, or when its tag makes no report (for example a linear tag with no `tiles`, `report-cells-removed`); nothing is written. The write is atomic (a sibling temporary file renamed over the target). If the reload that follows fails to compile the package, the previous text is restored (or a new file removed) and the package reloaded again, so a save never leaves the package serving less than it did. `expectedHash` is the SHA-256 (hex) of the file\'s text as the caller opened it, as `GET …/models/{path}` returned it in `sourceText`. On a package with a surface, that GET withholds `sourceText` only when the text names a source the file does not publish, and returns it anyway with `includeHiddenFilesAndSources=true`. When the file on disk no longer hashes to it, the write is refused with 409 and nothing is merged: the caller re-opens and reapplies its change. Omit it to CREATE the file: a file that already exists is then refused with 409 too, `reason` `FILE_EXISTS`, so a caller choosing a name can try the next, and an unconditional overwrite is not something a caller can ask for by leaving a field out. A path over an existing file the package does not read as a report answers 400 instead, with or without a hash, because that check comes before the hash. The check, the write, the reload and the restore all happen under one hold of the package lock, so two saves racing on one file cannot both pass the check, and a rollback cannot revert the other writer\'s text instead of its own. A tag only inside a block comment passes the tag check but the compiled model carries none, so it is rolled back and answers 500. A tagged grid report with no tiles saves but is not served until it has one. A create answers 201 and an update 200; `created` in the body says the same thing. Refused with 403 when `publisher.config.json` has `frozenConfig: true`. Like every write on this server, it is unauthenticated and meant to sit behind an authenticating gateway; see docs/security-posture.md. A published version is immutable, so a package with versions refuses this write with 409 (`reason` `PACKAGE_IS_VERSIONED`), whatever `versionId` names: change the file in the package\'s source and publish a new version. A `versionId` on a package with no versions answers 404 (`reason` `VERSION_NOT_FOUND`). A package installed from a `location` is fetched again from there on reload, which replaces its files, so it refuses this write with 409 (`reason` `PACKAGE_INSTALLED_FROM_LOCATION`): add the report to the package\'s source and reload it, or publish it as a version.
|
|
@@ -3170,11 +3312,11 @@ const yn = {
|
|
|
3170
3312
|
* @throws {RequiredError}
|
|
3171
3313
|
*/
|
|
3172
3314
|
async updateModelSource(a, n, e, t, s, o) {
|
|
3173
|
-
const
|
|
3174
|
-
return (d, h) => S(
|
|
3315
|
+
const i = await r.updateModelSource(a, n, e, t, s, o), c = l?.serverIndex ?? 0, p = P["ModelsApi.updateModelSource"]?.[c]?.url;
|
|
3316
|
+
return (d, h) => S(i, u, g, l)(d, p || h);
|
|
3175
3317
|
}
|
|
3176
3318
|
};
|
|
3177
|
-
},
|
|
3319
|
+
}, Tn = function(l, r, a) {
|
|
3178
3320
|
const n = F(l);
|
|
3179
3321
|
return {
|
|
3180
3322
|
/**
|
|
@@ -3188,8 +3330,8 @@ const yn = {
|
|
|
3188
3330
|
* @param {*} [options] Override http request option.
|
|
3189
3331
|
* @throws {RequiredError}
|
|
3190
3332
|
*/
|
|
3191
|
-
compileModelSource(e, t, s, o,
|
|
3192
|
-
return n.compileModelSource(e, t, s, o,
|
|
3333
|
+
compileModelSource(e, t, s, o, i, c) {
|
|
3334
|
+
return n.compileModelSource(e, t, s, o, i, c).then((p) => p(a, r));
|
|
3193
3335
|
},
|
|
3194
3336
|
/**
|
|
3195
3337
|
* Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets. Text that fails only at the grammar and names no source to run (for example `run` with no colon) is also a 400, because a grammar error says nothing about the model, unless the model carries any `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface.
|
|
@@ -3202,8 +3344,8 @@ const yn = {
|
|
|
3202
3344
|
* @param {*} [options] Override http request option.
|
|
3203
3345
|
* @throws {RequiredError}
|
|
3204
3346
|
*/
|
|
3205
|
-
executeQueryModel(e, t, s, o,
|
|
3206
|
-
return n.executeQueryModel(e, t, s, o,
|
|
3347
|
+
executeQueryModel(e, t, s, o, i, c) {
|
|
3348
|
+
return n.executeQueryModel(e, t, s, o, i, c).then((p) => p(a, r));
|
|
3207
3349
|
},
|
|
3208
3350
|
/**
|
|
3209
3351
|
* Retrieves a compiled Malloy model with its source information, queries, and metadata. The model is compiled using the specified version of the Malloy compiler. This endpoint provides access to the model\'s structure, sources, and named queries for use in applications. On a package with a surface (a root `index.malloy`, or a legacy `explores`), a file off that surface answers 404 with the same message a query to it gets, unless `includeHiddenFilesAndSources` is true. With it, the file is returned with its `sourceText`, whatever sources the text names. Reports (see list-reports), wherever they live in the package, are always returned. A package with no surface, or with `queryableSources: \"all\"`, returns every file. For a file it returns, `modelDef.contents` and `modelDef.exports`, `modelInfo`, `sources` and `sourceInfos` are limited to the names the file publishes, so the surface file does not carry the hidden sources it imports. A join to a hidden source keeps only its name and the names and types of its fields. `sourceText` is left out when the text names a source the file does not publish, unless `includeHiddenFilesAndSources` is true; the text of a report is always returned.
|
|
@@ -3217,8 +3359,8 @@ const yn = {
|
|
|
3217
3359
|
* @param {*} [options] Override http request option.
|
|
3218
3360
|
* @throws {RequiredError}
|
|
3219
3361
|
*/
|
|
3220
|
-
getModel(e, t, s, o,
|
|
3221
|
-
return n.getModel(e, t, s, o,
|
|
3362
|
+
getModel(e, t, s, o, i, c, p) {
|
|
3363
|
+
return n.getModel(e, t, s, o, i, c, p).then((d) => d(a, r));
|
|
3222
3364
|
},
|
|
3223
3365
|
/**
|
|
3224
3366
|
* Retrieves the Malloy models within the specified package. Each model entry includes the relative path, package name, whether the package hides the file, and any compilation errors. On a package with a surface (a root `index.malloy`, or a legacy `explores`), only the files on that surface are listed, unless `includeHiddenFilesAndSources` is true. With it, every model file is listed, and `isHidden` marks the ones the package hides. Reports (any `.malloy` outside `public/` carrying an artifact tag, other than the root `index.malloy`; see list-reports) are listed by list-reports. A grid report is not a model here on a package with a surface; a linear report is not a model here with or without one.
|
|
@@ -3230,8 +3372,8 @@ const yn = {
|
|
|
3230
3372
|
* @param {*} [options] Override http request option.
|
|
3231
3373
|
* @throws {RequiredError}
|
|
3232
3374
|
*/
|
|
3233
|
-
listModels(e, t, s, o,
|
|
3234
|
-
return n.listModels(e, t, s, o,
|
|
3375
|
+
listModels(e, t, s, o, i) {
|
|
3376
|
+
return n.listModels(e, t, s, o, i).then((c) => c(a, r));
|
|
3235
3377
|
},
|
|
3236
3378
|
/**
|
|
3237
3379
|
* Writes the Malloy text of a report into the package, and reloads the package in place so it is served from the new text. This is the report builder\'s save. A report is any `.malloy` file carrying an artifact tag (see list-reports), of either layout, wherever it lives in the package. What it accepts: - CREATE (no `expectedHash`): any `.malloy` path in the package that does not exist yet, outside `public/`, and never the root `index.malloy`. Missing directories are created, inside the package root only. The text must carry an artifact tag (`## artifact`, or the deprecated query-level `# artifact`): an `artifact` property anywhere on a tag line, outside a string. Text without one is refused with 400. - REPLACE (with `expectedHash`): only a file the package currently reads as an editable report: a tagged `.malloy` report of either layout, including a tagged grid report that has no tiles yet, and a file whose tag makes no report (a `kind=` tag, or the retired `run:` cell format), so it can be rewritten as tiles. A model, an untagged file, a `.malloynb`, the root `index.malloy` and anything in `public/` cannot be overwritten, wherever they live, and answer 400. Two reports may share a basename in different directories; a report is identified by its path, so a taken basename is not refused. The text is compiled first, as the file, and refused with its problems when it does not compile, or when its tag makes no report (for example a linear tag with no `tiles`, `report-cells-removed`); nothing is written. The write is atomic (a sibling temporary file renamed over the target). If the reload that follows fails to compile the package, the previous text is restored (or a new file removed) and the package reloaded again, so a save never leaves the package serving less than it did. `expectedHash` is the SHA-256 (hex) of the file\'s text as the caller opened it, as `GET …/models/{path}` returned it in `sourceText`. On a package with a surface, that GET withholds `sourceText` only when the text names a source the file does not publish, and returns it anyway with `includeHiddenFilesAndSources=true`. When the file on disk no longer hashes to it, the write is refused with 409 and nothing is merged: the caller re-opens and reapplies its change. Omit it to CREATE the file: a file that already exists is then refused with 409 too, `reason` `FILE_EXISTS`, so a caller choosing a name can try the next, and an unconditional overwrite is not something a caller can ask for by leaving a field out. A path over an existing file the package does not read as a report answers 400 instead, with or without a hash, because that check comes before the hash. The check, the write, the reload and the restore all happen under one hold of the package lock, so two saves racing on one file cannot both pass the check, and a rollback cannot revert the other writer\'s text instead of its own. A tag only inside a block comment passes the tag check but the compiled model carries none, so it is rolled back and answers 500. A tagged grid report with no tiles saves but is not served until it has one. A create answers 201 and an update 200; `created` in the body says the same thing. Refused with 403 when `publisher.config.json` has `frozenConfig: true`. Like every write on this server, it is unauthenticated and meant to sit behind an authenticating gateway; see docs/security-posture.md. A published version is immutable, so a package with versions refuses this write with 409 (`reason` `PACKAGE_IS_VERSIONED`), whatever `versionId` names: change the file in the package\'s source and publish a new version. A `versionId` on a package with no versions answers 404 (`reason` `VERSION_NOT_FOUND`). A package installed from a `location` is fetched again from there on reload, which replaces its files, so it refuses this write with 409 (`reason` `PACKAGE_INSTALLED_FROM_LOCATION`): add the report to the package\'s source and reload it, or publish it as a version.
|
|
@@ -3244,8 +3386,8 @@ const yn = {
|
|
|
3244
3386
|
* @param {*} [options] Override http request option.
|
|
3245
3387
|
* @throws {RequiredError}
|
|
3246
3388
|
*/
|
|
3247
|
-
updateModelSource(e, t, s, o,
|
|
3248
|
-
return n.updateModelSource(e, t, s, o,
|
|
3389
|
+
updateModelSource(e, t, s, o, i, c) {
|
|
3390
|
+
return n.updateModelSource(e, t, s, o, i, c).then((p) => p(a, r));
|
|
3249
3391
|
}
|
|
3250
3392
|
};
|
|
3251
3393
|
};
|
|
@@ -3291,7 +3433,7 @@ class sa extends I {
|
|
|
3291
3433
|
* @throws {RequiredError}
|
|
3292
3434
|
*/
|
|
3293
3435
|
getModel(r, a, n, e, t, s, o) {
|
|
3294
|
-
return F(this.configuration).getModel(r, a, n, e, t, s, o).then((
|
|
3436
|
+
return F(this.configuration).getModel(r, a, n, e, t, s, o).then((i) => i(this.axios, this.basePath));
|
|
3295
3437
|
}
|
|
3296
3438
|
/**
|
|
3297
3439
|
* Retrieves the Malloy models within the specified package. Each model entry includes the relative path, package name, whether the package hides the file, and any compilation errors. On a package with a surface (a root `index.malloy`, or a legacy `explores`), only the files on that surface are listed, unless `includeHiddenFilesAndSources` is true. With it, every model file is listed, and `isHidden` marks the ones the package hides. Reports (any `.malloy` outside `public/` carrying an artifact tag, other than the root `index.malloy`; see list-reports) are listed by list-reports. A grid report is not a model here on a package with a surface; a linear report is not a model here with or without one.
|
|
@@ -3321,7 +3463,7 @@ class sa extends I {
|
|
|
3321
3463
|
return F(this.configuration).updateModelSource(r, a, n, e, t, s).then((o) => o(this.axios, this.basePath));
|
|
3322
3464
|
}
|
|
3323
3465
|
}
|
|
3324
|
-
const
|
|
3466
|
+
const ia = function(l) {
|
|
3325
3467
|
return {
|
|
3326
3468
|
/**
|
|
3327
3469
|
* **DEPRECATED**: removed with the other notebook routes. For a `.malloy` report, run a cell through the model query endpoint instead: the report\'s path as the model, the cell\'s `text` (from get-report) as `query`, and `givens` in the body, which applies the same surface, `#(authorize)` and row-level gates. A `.malloynb` has no other route. Executes a specific cell in a linear report by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content. A linear `.malloy` report, wherever it lives, answers here as well as a `.malloynb`. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a code cell may read only sources the surface exports. A cell over a hidden source answers 404, and 404 rather than 403 even when the source is also `#(authorize)`-gated. A source an earlier cell declares on top of a published source still works. A cell\'s own source over a raw table (`duckdb.table(...)` or `.sql(...)`) has no published source under it, so it is refused. The response shows only the sources the notebook may read.
|
|
@@ -3338,16 +3480,16 @@ const ca = function(l) {
|
|
|
3338
3480
|
* @deprecated
|
|
3339
3481
|
* @throws {RequiredError}
|
|
3340
3482
|
*/
|
|
3341
|
-
executeNotebookCell: async (r, a, n, e, t, s, o,
|
|
3483
|
+
executeNotebookCell: async (r, a, n, e, t, s, o, i, c = {}) => {
|
|
3342
3484
|
m("executeNotebookCell", "environmentName", r), m("executeNotebookCell", "packageName", a), m("executeNotebookCell", "path", n), m("executeNotebookCell", "cellIndex", e);
|
|
3343
|
-
const p = "/environments/{environmentName}/packages/{packageName}/notebooks/{path}/cells/{cellIndex}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))).replace("{cellIndex}", encodeURIComponent(String(e))), d = new URL(p,
|
|
3485
|
+
const p = "/environments/{environmentName}/packages/{packageName}/notebooks/{path}/cells/{cellIndex}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))).replace("{cellIndex}", encodeURIComponent(String(e))), d = new URL(p, b);
|
|
3344
3486
|
let h;
|
|
3345
3487
|
l && (h = l.baseOptions);
|
|
3346
|
-
const k = { method: "GET", ...h, ...
|
|
3347
|
-
t !== void 0 && (y.versionId = t), s !== void 0 && (y.filter_params = s), o !== void 0 && (y.bypass_filters = o),
|
|
3488
|
+
const k = { method: "GET", ...h, ...c }, O = {}, y = {};
|
|
3489
|
+
t !== void 0 && (y.versionId = t), s !== void 0 && (y.filter_params = s), o !== void 0 && (y.bypass_filters = o), i !== void 0 && (y.givens = i), O.Accept = "application/json", v(d, y);
|
|
3348
3490
|
let N = h && h.headers ? h.headers : {};
|
|
3349
|
-
return k.headers = { ...O, ...N, ...
|
|
3350
|
-
url:
|
|
3491
|
+
return k.headers = { ...O, ...N, ...c.headers }, {
|
|
3492
|
+
url: V(d),
|
|
3351
3493
|
options: k
|
|
3352
3494
|
};
|
|
3353
3495
|
},
|
|
@@ -3364,15 +3506,15 @@ const ca = function(l) {
|
|
|
3364
3506
|
*/
|
|
3365
3507
|
getNotebook: async (r, a, n, e, t = {}) => {
|
|
3366
3508
|
m("getNotebook", "environmentName", r), m("getNotebook", "packageName", a), m("getNotebook", "path", n);
|
|
3367
|
-
const s = "/environments/{environmentName}/packages/{packageName}/notebooks/{path}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))), o = new URL(s,
|
|
3368
|
-
let
|
|
3369
|
-
l && (
|
|
3370
|
-
const
|
|
3509
|
+
const s = "/environments/{environmentName}/packages/{packageName}/notebooks/{path}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))), o = new URL(s, b);
|
|
3510
|
+
let i;
|
|
3511
|
+
l && (i = l.baseOptions);
|
|
3512
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
3371
3513
|
e !== void 0 && (d.versionId = e), p.Accept = "application/json", v(o, d);
|
|
3372
|
-
let h =
|
|
3373
|
-
return
|
|
3374
|
-
url:
|
|
3375
|
-
options:
|
|
3514
|
+
let h = i && i.headers ? i.headers : {};
|
|
3515
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
3516
|
+
url: V(o),
|
|
3517
|
+
options: c
|
|
3376
3518
|
};
|
|
3377
3519
|
},
|
|
3378
3520
|
/**
|
|
@@ -3387,20 +3529,20 @@ const ca = function(l) {
|
|
|
3387
3529
|
*/
|
|
3388
3530
|
listNotebooks: async (r, a, n, e = {}) => {
|
|
3389
3531
|
m("listNotebooks", "environmentName", r), m("listNotebooks", "packageName", a);
|
|
3390
|
-
const t = "/environments/{environmentName}/packages/{packageName}/notebooks".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
3532
|
+
const t = "/environments/{environmentName}/packages/{packageName}/notebooks".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
3391
3533
|
let o;
|
|
3392
3534
|
l && (o = l.baseOptions);
|
|
3393
|
-
const
|
|
3394
|
-
n !== void 0 && (p.versionId = n),
|
|
3535
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
3536
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
3395
3537
|
let d = o && o.headers ? o.headers : {};
|
|
3396
|
-
return
|
|
3397
|
-
url:
|
|
3398
|
-
options:
|
|
3538
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
3539
|
+
url: V(s),
|
|
3540
|
+
options: i
|
|
3399
3541
|
};
|
|
3400
3542
|
}
|
|
3401
3543
|
};
|
|
3402
|
-
},
|
|
3403
|
-
const r =
|
|
3544
|
+
}, q = function(l) {
|
|
3545
|
+
const r = ia(l);
|
|
3404
3546
|
return {
|
|
3405
3547
|
/**
|
|
3406
3548
|
* **DEPRECATED**: removed with the other notebook routes. For a `.malloy` report, run a cell through the model query endpoint instead: the report\'s path as the model, the cell\'s `text` (from get-report) as `query`, and `givens` in the body, which applies the same surface, `#(authorize)` and row-level gates. A `.malloynb` has no other route. Executes a specific cell in a linear report by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content. A linear `.malloy` report, wherever it lives, answers here as well as a `.malloynb`. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a code cell may read only sources the surface exports. A cell over a hidden source answers 404, and 404 rather than 403 even when the source is also `#(authorize)`-gated. A source an earlier cell declares on top of a published source still works. A cell\'s own source over a raw table (`duckdb.table(...)` or `.sql(...)`) has no published source under it, so it is refused. The response shows only the sources the notebook may read.
|
|
@@ -3417,8 +3559,8 @@ const ca = function(l) {
|
|
|
3417
3559
|
* @deprecated
|
|
3418
3560
|
* @throws {RequiredError}
|
|
3419
3561
|
*/
|
|
3420
|
-
async executeNotebookCell(a, n, e, t, s, o,
|
|
3421
|
-
const d = await r.executeNotebookCell(a, n, e, t, s, o,
|
|
3562
|
+
async executeNotebookCell(a, n, e, t, s, o, i, c, p) {
|
|
3563
|
+
const d = await r.executeNotebookCell(a, n, e, t, s, o, i, c, p), h = l?.serverIndex ?? 0, k = P["NotebooksApi.executeNotebookCell"]?.[h]?.url;
|
|
3422
3564
|
return (O, y) => S(d, u, g, l)(O, k || y);
|
|
3423
3565
|
},
|
|
3424
3566
|
/**
|
|
@@ -3433,8 +3575,8 @@ const ca = function(l) {
|
|
|
3433
3575
|
* @throws {RequiredError}
|
|
3434
3576
|
*/
|
|
3435
3577
|
async getNotebook(a, n, e, t, s) {
|
|
3436
|
-
const o = await r.getNotebook(a, n, e, t, s),
|
|
3437
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
3578
|
+
const o = await r.getNotebook(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["NotebooksApi.getNotebook"]?.[i]?.url;
|
|
3579
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
3438
3580
|
},
|
|
3439
3581
|
/**
|
|
3440
3582
|
* **DEPRECATED**: use list-reports. Lists the package\'s linear reports (see list-reports): every `.malloynb` file outside `public/`, and every tagged `.malloy` report whose layout is linear, wherever it lives. Each entry includes the relative path, package name, title, description, and any compilation or reading error. **Contract change since reports.** This route used to list `.malloy` notebooks only directly under `notebooks/`. It now lists linear reports from anywhere in the package, including `dashboards/` and nested directories, and no longer lists a kindless tiled file in `notebooks/`, which is now grid.
|
|
@@ -3447,12 +3589,12 @@ const ca = function(l) {
|
|
|
3447
3589
|
* @throws {RequiredError}
|
|
3448
3590
|
*/
|
|
3449
3591
|
async listNotebooks(a, n, e, t) {
|
|
3450
|
-
const s = await r.listNotebooks(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
3451
|
-
return (
|
|
3592
|
+
const s = await r.listNotebooks(a, n, e, t), o = l?.serverIndex ?? 0, i = P["NotebooksApi.listNotebooks"]?.[o]?.url;
|
|
3593
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
3452
3594
|
}
|
|
3453
3595
|
};
|
|
3454
|
-
},
|
|
3455
|
-
const n =
|
|
3596
|
+
}, En = function(l, r, a) {
|
|
3597
|
+
const n = q(l);
|
|
3456
3598
|
return {
|
|
3457
3599
|
/**
|
|
3458
3600
|
* **DEPRECATED**: removed with the other notebook routes. For a `.malloy` report, run a cell through the model query endpoint instead: the report\'s path as the model, the cell\'s `text` (from get-report) as `query`, and `givens` in the body, which applies the same surface, `#(authorize)` and row-level gates. A `.malloynb` has no other route. Executes a specific cell in a linear report by index. For code cells, this compiles and runs the Malloy code, returning query results and any new sources defined. For markdown cells, this simply returns the cell content. A linear `.malloy` report, wherever it lives, answers here as well as a `.malloynb`. On a package with a surface (a root `index.malloy`, or a legacy `explores`) with `queryableSources` left at `\"declared\"`, a code cell may read only sources the surface exports. A cell over a hidden source answers 404, and 404 rather than 403 even when the source is also `#(authorize)`-gated. A source an earlier cell declares on top of a published source still works. A cell\'s own source over a raw table (`duckdb.table(...)` or `.sql(...)`) has no published source under it, so it is refused. The response shows only the sources the notebook may read.
|
|
@@ -3469,8 +3611,8 @@ const ca = function(l) {
|
|
|
3469
3611
|
* @deprecated
|
|
3470
3612
|
* @throws {RequiredError}
|
|
3471
3613
|
*/
|
|
3472
|
-
executeNotebookCell(e, t, s, o,
|
|
3473
|
-
return n.executeNotebookCell(e, t, s, o,
|
|
3614
|
+
executeNotebookCell(e, t, s, o, i, c, p, d, h) {
|
|
3615
|
+
return n.executeNotebookCell(e, t, s, o, i, c, p, d, h).then((k) => k(a, r));
|
|
3474
3616
|
},
|
|
3475
3617
|
/**
|
|
3476
3618
|
* **DEPRECATED**: use get-report. Retrieves a linear report with its raw cell contents (markdown and code). A `.malloy` report\'s cells run through the model query endpoint (each cell\'s `text` as the query); a `.malloynb`\'s through execute-notebook-cell. A linear `.malloy` report, wherever it lives, answers here as well as a `.malloynb`. On a package with a surface, the response shows only the sources the notebook may read.
|
|
@@ -3483,8 +3625,8 @@ const ca = function(l) {
|
|
|
3483
3625
|
* @deprecated
|
|
3484
3626
|
* @throws {RequiredError}
|
|
3485
3627
|
*/
|
|
3486
|
-
getNotebook(e, t, s, o,
|
|
3487
|
-
return n.getNotebook(e, t, s, o,
|
|
3628
|
+
getNotebook(e, t, s, o, i) {
|
|
3629
|
+
return n.getNotebook(e, t, s, o, i).then((c) => c(a, r));
|
|
3488
3630
|
},
|
|
3489
3631
|
/**
|
|
3490
3632
|
* **DEPRECATED**: use list-reports. Lists the package\'s linear reports (see list-reports): every `.malloynb` file outside `public/`, and every tagged `.malloy` report whose layout is linear, wherever it lives. Each entry includes the relative path, package name, title, description, and any compilation or reading error. **Contract change since reports.** This route used to list `.malloy` notebooks only directly under `notebooks/`. It now lists linear reports from anywhere in the package, including `dashboards/` and nested directories, and no longer lists a kindless tiled file in `notebooks/`, which is now grid.
|
|
@@ -3497,7 +3639,7 @@ const ca = function(l) {
|
|
|
3497
3639
|
* @throws {RequiredError}
|
|
3498
3640
|
*/
|
|
3499
3641
|
listNotebooks(e, t, s, o) {
|
|
3500
|
-
return n.listNotebooks(e, t, s, o).then((
|
|
3642
|
+
return n.listNotebooks(e, t, s, o).then((i) => i(a, r));
|
|
3501
3643
|
}
|
|
3502
3644
|
};
|
|
3503
3645
|
};
|
|
@@ -3517,8 +3659,8 @@ class la extends I {
|
|
|
3517
3659
|
* @deprecated
|
|
3518
3660
|
* @throws {RequiredError}
|
|
3519
3661
|
*/
|
|
3520
|
-
executeNotebookCell(r, a, n, e, t, s, o,
|
|
3521
|
-
return
|
|
3662
|
+
executeNotebookCell(r, a, n, e, t, s, o, i, c) {
|
|
3663
|
+
return q(this.configuration).executeNotebookCell(r, a, n, e, t, s, o, i, c).then((p) => p(this.axios, this.basePath));
|
|
3522
3664
|
}
|
|
3523
3665
|
/**
|
|
3524
3666
|
* **DEPRECATED**: use get-report. Retrieves a linear report with its raw cell contents (markdown and code). A `.malloy` report\'s cells run through the model query endpoint (each cell\'s `text` as the query); a `.malloynb`\'s through execute-notebook-cell. A linear `.malloy` report, wherever it lives, answers here as well as a `.malloynb`. On a package with a surface, the response shows only the sources the notebook may read.
|
|
@@ -3532,7 +3674,7 @@ class la extends I {
|
|
|
3532
3674
|
* @throws {RequiredError}
|
|
3533
3675
|
*/
|
|
3534
3676
|
getNotebook(r, a, n, e, t) {
|
|
3535
|
-
return
|
|
3677
|
+
return q(this.configuration).getNotebook(r, a, n, e, t).then((s) => s(this.axios, this.basePath));
|
|
3536
3678
|
}
|
|
3537
3679
|
/**
|
|
3538
3680
|
* **DEPRECATED**: use list-reports. Lists the package\'s linear reports (see list-reports): every `.malloynb` file outside `public/`, and every tagged `.malloy` report whose layout is linear, wherever it lives. Each entry includes the relative path, package name, title, description, and any compilation or reading error. **Contract change since reports.** This route used to list `.malloy` notebooks only directly under `notebooks/`. It now lists linear reports from anywhere in the package, including `dashboards/` and nested directories, and no longer lists a kindless tiled file in `notebooks/`, which is now grid.
|
|
@@ -3545,13 +3687,13 @@ class la extends I {
|
|
|
3545
3687
|
* @throws {RequiredError}
|
|
3546
3688
|
*/
|
|
3547
3689
|
listNotebooks(r, a, n, e) {
|
|
3548
|
-
return
|
|
3690
|
+
return q(this.configuration).listNotebooks(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
3549
3691
|
}
|
|
3550
3692
|
}
|
|
3551
|
-
const
|
|
3693
|
+
const fn = {
|
|
3552
3694
|
True: "true",
|
|
3553
3695
|
False: "false"
|
|
3554
|
-
},
|
|
3696
|
+
}, ca = function(l) {
|
|
3555
3697
|
return {
|
|
3556
3698
|
/**
|
|
3557
3699
|
* Creates a new Malloy package within the specified environment. A package serves as a container for models, notebooks, embedded databases, and other resources. The package will be initialized with the provided metadata and can immediately accept content. ## Dry run With `?dryRun=true` the request needs a `location`. The tree there is downloaded and loaded, and the publish checks run, exactly as a publish would run them, and then it is discarded: nothing is installed, served or listed, the package already served under the name (if any) is untouched, no version is recorded, and the load\'s connections are closed. The answer is what a publish would answer for the tree itself: the same 400 or 424 refusal, or 200 with the package as it would load, its `warnings` included, plus the `location` it was loaded from. The 200 also carries what a publish would build and serve: the `buildPlan`, and `serveVerdicts`, each materialized source\'s serve verdict with each stored source\'s named views compiled against a compile-only served copy (no table is built). With package versioning on, the tree\'s `publisher.json` must declare a valid version, as a versioned publish requires (400 `MANIFEST_VERSION_MISSING` or `MANIFEST_VERSION_INVALID`), and the 200 names it as `versionId`. Version lifecycle checks (a version that already exists, `latest`) are not part of it, and the 200 carries no `latestVersion` or `status`, which describe the package being served. A frozen configuration refuses a dry run as it refuses a publish, since the server still downloads and loads the caller\'s content; so does memory backpressure (503). A server runs at most 2 dry runs at once and refuses more with 503. With package versioning on, a `description` that is not a string or a `manifestLocation` that names no manifest is the 400 a versioned publish answers. ## Versioned publish Package versioning is a server setting, `PUBLISHER_PACKAGE_VERSIONING` (`on` by default; `ServerStatus.packageVersioning` reports it), and a transition: a later release removes the setting and always publishes versions. With it off, a request that carries a `location` installs the package in place, replacing the previous publish, as before versions, whatever its `publisher.json` declares; the package has no versions, and the server logs a warning that names it. A package that already has published versions refuses that with 409 (`reason` `PACKAGE_IS_VERSIONED`). With it on, a request that carries a `location` publishes an immutable version of the package: the one its own `publisher.json` declares. The request takes no version parameter: the version is that field, the way `npm publish` reads `package.json`, so bumping it is the release action. - A `publisher.json` with no `version` is refused with 400 (`reason` `MANIFEST_VERSION_MISSING`), and one whose `version` is not a semantic version with 400 (`reason` `MANIFEST_VERSION_INVALID`). Nothing is written. - Publishing a version the package already has, with different content, is refused with 409 (`reason` `VERSION_CONFLICT`). The same content again succeeds and writes no files, so re-loading a version onto a server that already holds it is safe to retry; a non-null `manifestLocation` on that request binds the version to it. A re-load leaves `latest` where it is, so a retried publish never undoes a rollback; it sets `latest` only for a package that has none. Re-publishing an archived version is refused with 410 (`reason` `VERSION_ARCHIVED`): unarchive it instead. - A version that does not pass the publish checks (the same ones an unversioned publish applies) is refused with 400, and the versions already published keep serving. - Under `versionPromotion: \"on-publish\"` (the default), the new version becomes the package\'s `latest` unless a higher version already is. Under `\"explicit\"`, publish never moves `latest`; `PUT .../packages/{packageName}/latest` does. - A package mounted for watch mode is the author\'s own source directory, so it cannot hold immutable versions: publishing a version of it is refused with 400. - The request\'s `description`, when sent, is the package\'s description. Each version keeps the `description` from its own publisher.json. A request without a `location` registers a directory already in the environment as a single unversioned package, as packages loaded from `publisher.config.json` are with versioning off. A package that already has versions refuses that with 409 (`reason` `PACKAGE_IS_VERSIONED`).
|
|
@@ -3564,15 +3706,15 @@ const xn = {
|
|
|
3564
3706
|
*/
|
|
3565
3707
|
createPackage: async (r, a, n, e = {}) => {
|
|
3566
3708
|
m("createPackage", "environmentName", r), m("createPackage", "_package", a);
|
|
3567
|
-
const t = "/environments/{environmentName}/packages".replace("{environmentName}", encodeURIComponent(String(r))), s = new URL(t,
|
|
3709
|
+
const t = "/environments/{environmentName}/packages".replace("{environmentName}", encodeURIComponent(String(r))), s = new URL(t, b);
|
|
3568
3710
|
let o;
|
|
3569
3711
|
l && (o = l.baseOptions);
|
|
3570
|
-
const
|
|
3571
|
-
n !== void 0 && (p.dryRun = n),
|
|
3712
|
+
const i = { method: "POST", ...o, ...e }, c = {}, p = {};
|
|
3713
|
+
n !== void 0 && (p.dryRun = n), c["Content-Type"] = "application/json", c.Accept = "application/json", v(s, p);
|
|
3572
3714
|
let d = o && o.headers ? o.headers : {};
|
|
3573
|
-
return
|
|
3574
|
-
url:
|
|
3575
|
-
options:
|
|
3715
|
+
return i.headers = { ...c, ...d, ...e.headers }, i.data = A(a, i, l), {
|
|
3716
|
+
url: V(s),
|
|
3717
|
+
options: i
|
|
3576
3718
|
};
|
|
3577
3719
|
},
|
|
3578
3720
|
/**
|
|
@@ -3585,14 +3727,14 @@ const xn = {
|
|
|
3585
3727
|
*/
|
|
3586
3728
|
deletePackage: async (r, a, n = {}) => {
|
|
3587
3729
|
m("deletePackage", "environmentName", r), m("deletePackage", "packageName", a);
|
|
3588
|
-
const e = "/environments/{environmentName}/packages/{packageName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), t = new URL(e,
|
|
3730
|
+
const e = "/environments/{environmentName}/packages/{packageName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), t = new URL(e, b);
|
|
3589
3731
|
let s;
|
|
3590
3732
|
l && (s = l.baseOptions);
|
|
3591
|
-
const o = { method: "DELETE", ...s, ...n },
|
|
3592
|
-
|
|
3733
|
+
const o = { method: "DELETE", ...s, ...n }, i = {}, c = {};
|
|
3734
|
+
i.Accept = "application/json", v(t, c);
|
|
3593
3735
|
let p = s && s.headers ? s.headers : {};
|
|
3594
|
-
return o.headers = { ...
|
|
3595
|
-
url:
|
|
3736
|
+
return o.headers = { ...i, ...p, ...n.headers }, {
|
|
3737
|
+
url: V(t),
|
|
3596
3738
|
options: o
|
|
3597
3739
|
};
|
|
3598
3740
|
},
|
|
@@ -3608,15 +3750,15 @@ const xn = {
|
|
|
3608
3750
|
*/
|
|
3609
3751
|
getPackage: async (r, a, n, e, t = {}) => {
|
|
3610
3752
|
m("getPackage", "environmentName", r), m("getPackage", "packageName", a);
|
|
3611
|
-
const s = "/environments/{environmentName}/packages/{packageName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), o = new URL(s,
|
|
3612
|
-
let
|
|
3613
|
-
l && (
|
|
3614
|
-
const
|
|
3753
|
+
const s = "/environments/{environmentName}/packages/{packageName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), o = new URL(s, b);
|
|
3754
|
+
let i;
|
|
3755
|
+
l && (i = l.baseOptions);
|
|
3756
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
3615
3757
|
n !== void 0 && (d.versionId = n), e !== void 0 && (d.reload = e), p.Accept = "application/json", v(o, d);
|
|
3616
|
-
let h =
|
|
3617
|
-
return
|
|
3618
|
-
url:
|
|
3619
|
-
options:
|
|
3758
|
+
let h = i && i.headers ? i.headers : {};
|
|
3759
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
3760
|
+
url: V(o),
|
|
3761
|
+
options: c
|
|
3620
3762
|
};
|
|
3621
3763
|
},
|
|
3622
3764
|
/**
|
|
@@ -3630,15 +3772,15 @@ const xn = {
|
|
|
3630
3772
|
*/
|
|
3631
3773
|
getPackageBuildPlan: async (r, a, n, e = {}) => {
|
|
3632
3774
|
m("getPackageBuildPlan", "environmentName", r), m("getPackageBuildPlan", "packageName", a);
|
|
3633
|
-
const t = "/environments/{environmentName}/packages/{packageName}/build-plan".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
3775
|
+
const t = "/environments/{environmentName}/packages/{packageName}/build-plan".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
3634
3776
|
let o;
|
|
3635
3777
|
l && (o = l.baseOptions);
|
|
3636
|
-
const
|
|
3637
|
-
n !== void 0 && (p.versionId = n),
|
|
3778
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
3779
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
3638
3780
|
let d = o && o.headers ? o.headers : {};
|
|
3639
|
-
return
|
|
3640
|
-
url:
|
|
3641
|
-
options:
|
|
3781
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
3782
|
+
url: V(s),
|
|
3783
|
+
options: i
|
|
3642
3784
|
};
|
|
3643
3785
|
},
|
|
3644
3786
|
/**
|
|
@@ -3652,15 +3794,15 @@ const xn = {
|
|
|
3652
3794
|
*/
|
|
3653
3795
|
getPackageClassification: async (r, a, n, e = {}) => {
|
|
3654
3796
|
m("getPackageClassification", "environmentName", r), m("getPackageClassification", "packageName", a);
|
|
3655
|
-
const t = "/environments/{environmentName}/packages/{packageName}/classification".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
3797
|
+
const t = "/environments/{environmentName}/packages/{packageName}/classification".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
3656
3798
|
let o;
|
|
3657
3799
|
l && (o = l.baseOptions);
|
|
3658
|
-
const
|
|
3659
|
-
n !== void 0 && (p.versionId = n),
|
|
3800
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
3801
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
3660
3802
|
let d = o && o.headers ? o.headers : {};
|
|
3661
|
-
return
|
|
3662
|
-
url:
|
|
3663
|
-
options:
|
|
3803
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
3804
|
+
url: V(s),
|
|
3805
|
+
options: i
|
|
3664
3806
|
};
|
|
3665
3807
|
},
|
|
3666
3808
|
/**
|
|
@@ -3674,15 +3816,15 @@ const xn = {
|
|
|
3674
3816
|
*/
|
|
3675
3817
|
getPackageEmbeddingIndex: async (r, a, n, e = {}) => {
|
|
3676
3818
|
m("getPackageEmbeddingIndex", "environmentName", r), m("getPackageEmbeddingIndex", "packageName", a);
|
|
3677
|
-
const t = "/environments/{environmentName}/packages/{packageName}/embedding-index".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
3819
|
+
const t = "/environments/{environmentName}/packages/{packageName}/embedding-index".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
3678
3820
|
let o;
|
|
3679
3821
|
l && (o = l.baseOptions);
|
|
3680
|
-
const
|
|
3681
|
-
n !== void 0 && (p.versionId = n),
|
|
3822
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
3823
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
3682
3824
|
let d = o && o.headers ? o.headers : {};
|
|
3683
|
-
return
|
|
3684
|
-
url:
|
|
3685
|
-
options:
|
|
3825
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
3826
|
+
url: V(s),
|
|
3827
|
+
options: i
|
|
3686
3828
|
};
|
|
3687
3829
|
},
|
|
3688
3830
|
/**
|
|
@@ -3697,15 +3839,15 @@ const xn = {
|
|
|
3697
3839
|
*/
|
|
3698
3840
|
getPackageEntities: async (r, a, n, e, t = {}) => {
|
|
3699
3841
|
m("getPackageEntities", "environmentName", r), m("getPackageEntities", "packageName", a);
|
|
3700
|
-
const s = "/environments/{environmentName}/packages/{packageName}/entities".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), o = new URL(s,
|
|
3701
|
-
let
|
|
3702
|
-
l && (
|
|
3703
|
-
const
|
|
3842
|
+
const s = "/environments/{environmentName}/packages/{packageName}/entities".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), o = new URL(s, b);
|
|
3843
|
+
let i;
|
|
3844
|
+
l && (i = l.baseOptions);
|
|
3845
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
3704
3846
|
n !== void 0 && (d.versionId = n), e !== void 0 && (d.includeHiddenFilesAndSources = e), p.Accept = "application/json", v(o, d);
|
|
3705
|
-
let h =
|
|
3706
|
-
return
|
|
3707
|
-
url:
|
|
3708
|
-
options:
|
|
3847
|
+
let h = i && i.headers ? i.headers : {};
|
|
3848
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
3849
|
+
url: V(o),
|
|
3850
|
+
options: c
|
|
3709
3851
|
};
|
|
3710
3852
|
},
|
|
3711
3853
|
/**
|
|
@@ -3719,15 +3861,15 @@ const xn = {
|
|
|
3719
3861
|
*/
|
|
3720
3862
|
getPackageStatus: async (r, a, n, e = {}) => {
|
|
3721
3863
|
m("getPackageStatus", "environmentName", r), m("getPackageStatus", "packageName", a);
|
|
3722
|
-
const t = "/environments/{environmentName}/packages/{packageName}/status".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
3864
|
+
const t = "/environments/{environmentName}/packages/{packageName}/status".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
3723
3865
|
let o;
|
|
3724
3866
|
l && (o = l.baseOptions);
|
|
3725
|
-
const
|
|
3726
|
-
n !== void 0 && (p.versionId = n),
|
|
3867
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
3868
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
3727
3869
|
let d = o && o.headers ? o.headers : {};
|
|
3728
|
-
return
|
|
3729
|
-
url:
|
|
3730
|
-
options:
|
|
3870
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
3871
|
+
url: V(s),
|
|
3872
|
+
options: i
|
|
3731
3873
|
};
|
|
3732
3874
|
},
|
|
3733
3875
|
/**
|
|
@@ -3739,14 +3881,14 @@ const xn = {
|
|
|
3739
3881
|
*/
|
|
3740
3882
|
listPackages: async (r, a = {}) => {
|
|
3741
3883
|
m("listPackages", "environmentName", r);
|
|
3742
|
-
const n = "/environments/{environmentName}/packages".replace("{environmentName}", encodeURIComponent(String(r))), e = new URL(n,
|
|
3884
|
+
const n = "/environments/{environmentName}/packages".replace("{environmentName}", encodeURIComponent(String(r))), e = new URL(n, b);
|
|
3743
3885
|
let t;
|
|
3744
3886
|
l && (t = l.baseOptions);
|
|
3745
|
-
const s = { method: "GET", ...t, ...a }, o = {},
|
|
3746
|
-
o.Accept = "application/json", v(e,
|
|
3747
|
-
let
|
|
3748
|
-
return s.headers = { ...o, ...
|
|
3749
|
-
url:
|
|
3887
|
+
const s = { method: "GET", ...t, ...a }, o = {}, i = {};
|
|
3888
|
+
o.Accept = "application/json", v(e, i);
|
|
3889
|
+
let c = t && t.headers ? t.headers : {};
|
|
3890
|
+
return s.headers = { ...o, ...c, ...a.headers }, {
|
|
3891
|
+
url: V(e),
|
|
3750
3892
|
options: s
|
|
3751
3893
|
};
|
|
3752
3894
|
},
|
|
@@ -3762,20 +3904,20 @@ const xn = {
|
|
|
3762
3904
|
*/
|
|
3763
3905
|
updatePackage: async (r, a, n, e = {}) => {
|
|
3764
3906
|
m("updatePackage", "environmentName", r), m("updatePackage", "packageName", a), m("updatePackage", "_package", n);
|
|
3765
|
-
const t = "/environments/{environmentName}/packages/{packageName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
3907
|
+
const t = "/environments/{environmentName}/packages/{packageName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
3766
3908
|
let o;
|
|
3767
3909
|
l && (o = l.baseOptions);
|
|
3768
|
-
const
|
|
3769
|
-
|
|
3910
|
+
const i = { method: "PATCH", ...o, ...e }, c = {}, p = {};
|
|
3911
|
+
c["Content-Type"] = "application/json", c.Accept = "application/json", v(s, p);
|
|
3770
3912
|
let d = o && o.headers ? o.headers : {};
|
|
3771
|
-
return
|
|
3772
|
-
url:
|
|
3773
|
-
options:
|
|
3913
|
+
return i.headers = { ...c, ...d, ...e.headers }, i.data = A(n, i, l), {
|
|
3914
|
+
url: V(s),
|
|
3915
|
+
options: i
|
|
3774
3916
|
};
|
|
3775
3917
|
}
|
|
3776
3918
|
};
|
|
3777
|
-
},
|
|
3778
|
-
const r =
|
|
3919
|
+
}, x = function(l) {
|
|
3920
|
+
const r = ca(l);
|
|
3779
3921
|
return {
|
|
3780
3922
|
/**
|
|
3781
3923
|
* Creates a new Malloy package within the specified environment. A package serves as a container for models, notebooks, embedded databases, and other resources. The package will be initialized with the provided metadata and can immediately accept content. ## Dry run With `?dryRun=true` the request needs a `location`. The tree there is downloaded and loaded, and the publish checks run, exactly as a publish would run them, and then it is discarded: nothing is installed, served or listed, the package already served under the name (if any) is untouched, no version is recorded, and the load\'s connections are closed. The answer is what a publish would answer for the tree itself: the same 400 or 424 refusal, or 200 with the package as it would load, its `warnings` included, plus the `location` it was loaded from. The 200 also carries what a publish would build and serve: the `buildPlan`, and `serveVerdicts`, each materialized source\'s serve verdict with each stored source\'s named views compiled against a compile-only served copy (no table is built). With package versioning on, the tree\'s `publisher.json` must declare a valid version, as a versioned publish requires (400 `MANIFEST_VERSION_MISSING` or `MANIFEST_VERSION_INVALID`), and the 200 names it as `versionId`. Version lifecycle checks (a version that already exists, `latest`) are not part of it, and the 200 carries no `latestVersion` or `status`, which describe the package being served. A frozen configuration refuses a dry run as it refuses a publish, since the server still downloads and loads the caller\'s content; so does memory backpressure (503). A server runs at most 2 dry runs at once and refuses more with 503. With package versioning on, a `description` that is not a string or a `manifestLocation` that names no manifest is the 400 a versioned publish answers. ## Versioned publish Package versioning is a server setting, `PUBLISHER_PACKAGE_VERSIONING` (`on` by default; `ServerStatus.packageVersioning` reports it), and a transition: a later release removes the setting and always publishes versions. With it off, a request that carries a `location` installs the package in place, replacing the previous publish, as before versions, whatever its `publisher.json` declares; the package has no versions, and the server logs a warning that names it. A package that already has published versions refuses that with 409 (`reason` `PACKAGE_IS_VERSIONED`). With it on, a request that carries a `location` publishes an immutable version of the package: the one its own `publisher.json` declares. The request takes no version parameter: the version is that field, the way `npm publish` reads `package.json`, so bumping it is the release action. - A `publisher.json` with no `version` is refused with 400 (`reason` `MANIFEST_VERSION_MISSING`), and one whose `version` is not a semantic version with 400 (`reason` `MANIFEST_VERSION_INVALID`). Nothing is written. - Publishing a version the package already has, with different content, is refused with 409 (`reason` `VERSION_CONFLICT`). The same content again succeeds and writes no files, so re-loading a version onto a server that already holds it is safe to retry; a non-null `manifestLocation` on that request binds the version to it. A re-load leaves `latest` where it is, so a retried publish never undoes a rollback; it sets `latest` only for a package that has none. Re-publishing an archived version is refused with 410 (`reason` `VERSION_ARCHIVED`): unarchive it instead. - A version that does not pass the publish checks (the same ones an unversioned publish applies) is refused with 400, and the versions already published keep serving. - Under `versionPromotion: \"on-publish\"` (the default), the new version becomes the package\'s `latest` unless a higher version already is. Under `\"explicit\"`, publish never moves `latest`; `PUT .../packages/{packageName}/latest` does. - A package mounted for watch mode is the author\'s own source directory, so it cannot hold immutable versions: publishing a version of it is refused with 400. - The request\'s `description`, when sent, is the package\'s description. Each version keeps the `description` from its own publisher.json. A request without a `location` registers a directory already in the environment as a single unversioned package, as packages loaded from `publisher.config.json` are with versioning off. A package that already has versions refuses that with 409 (`reason` `PACKAGE_IS_VERSIONED`).
|
|
@@ -3787,8 +3929,8 @@ const xn = {
|
|
|
3787
3929
|
* @throws {RequiredError}
|
|
3788
3930
|
*/
|
|
3789
3931
|
async createPackage(a, n, e, t) {
|
|
3790
|
-
const s = await r.createPackage(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
3791
|
-
return (
|
|
3932
|
+
const s = await r.createPackage(a, n, e, t), o = l?.serverIndex ?? 0, i = P["PackagesApi.createPackage"]?.[o]?.url;
|
|
3933
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
3792
3934
|
},
|
|
3793
3935
|
/**
|
|
3794
3936
|
* Permanently deletes a package and all its associated resources including models, notebooks, databases, and metadata. This operation cannot be undone, so use with caution. The package must exist and be accessible for deletion. On a versioned package this deletes every published version and its files, then, in the background, cleans up each version as deleting it alone does: its own auto-runs still running are stopped and its own `scope: version` tables reclaimed. To take one version out of service while keeping the rest, archive it with `PATCH .../packages/{packageName}/versions/{version}`; to remove one version for good, delete it with `DELETE .../packages/{packageName}/versions/{version}`.
|
|
@@ -3800,7 +3942,7 @@ const xn = {
|
|
|
3800
3942
|
*/
|
|
3801
3943
|
async deletePackage(a, n, e) {
|
|
3802
3944
|
const t = await r.deletePackage(a, n, e), s = l?.serverIndex ?? 0, o = P["PackagesApi.deletePackage"]?.[s]?.url;
|
|
3803
|
-
return (
|
|
3945
|
+
return (i, c) => S(t, u, g, l)(i, o || c);
|
|
3804
3946
|
},
|
|
3805
3947
|
/**
|
|
3806
3948
|
* Retrieves detailed information about a specific package, including its models, notebooks, databases, and metadata. The reload parameter can be used to refresh the package state from disk before returning the information. The versionId parameter selects one published version of a versioned package; without it, the package\'s `latest` version is returned.
|
|
@@ -3813,8 +3955,8 @@ const xn = {
|
|
|
3813
3955
|
* @throws {RequiredError}
|
|
3814
3956
|
*/
|
|
3815
3957
|
async getPackage(a, n, e, t, s) {
|
|
3816
|
-
const o = await r.getPackage(a, n, e, t, s),
|
|
3817
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
3958
|
+
const o = await r.getPackage(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["PackagesApi.getPackage"]?.[i]?.url;
|
|
3959
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
3818
3960
|
},
|
|
3819
3961
|
/**
|
|
3820
3962
|
* The persist build plan of the load: per persist source its `sourceEntityId`, output columns and build SQL, the dependency graphs, and the sources refused a build. A caller assigns physical names and identity per source from it and issues one build call (see `CreateMaterializationRequest.buildInstructions`). A package that declares no persist source has an empty plan. When the plan could not be derived at load, the read answers 409 with `reason` BUILD_PLAN_UNAVAILABLE; reloading the package derives it again, and retrying the read does not. After an edit to a connection the package\'s persisted sources build on, the plan is re-derived (a content address folds in its connection\'s digest) and the read waits for it; past 10 seconds it answers 503 with `reason` BUILD_PLAN_REFRESHING and a `Retry-After` header. A failed re-derivation answers 409 BUILD_PLAN_UNAVAILABLE, as at load, and run creation with `buildInstructions` is refused the same way rather than checked against the plan from before the edit.
|
|
@@ -3826,8 +3968,8 @@ const xn = {
|
|
|
3826
3968
|
* @throws {RequiredError}
|
|
3827
3969
|
*/
|
|
3828
3970
|
async getPackageBuildPlan(a, n, e, t) {
|
|
3829
|
-
const s = await r.getPackageBuildPlan(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
3830
|
-
return (
|
|
3971
|
+
const s = await r.getPackageBuildPlan(a, n, e, t), o = l?.serverIndex ?? 0, i = P["PackagesApi.getPackageBuildPlan"]?.[o]?.url;
|
|
3972
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
3831
3973
|
},
|
|
3832
3974
|
/**
|
|
3833
3975
|
* For each published entry point of the package, the classes its `#(carries)` declares and how many of its fields carry each class, inherited classes included, with the count left unclassified. It covers only what discovery shows. `sources` is empty when nothing published is classified.
|
|
@@ -3839,8 +3981,8 @@ const xn = {
|
|
|
3839
3981
|
* @throws {RequiredError}
|
|
3840
3982
|
*/
|
|
3841
3983
|
async getPackageClassification(a, n, e, t) {
|
|
3842
|
-
const s = await r.getPackageClassification(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
3843
|
-
return (
|
|
3984
|
+
const s = await r.getPackageClassification(a, n, e, t), o = l?.serverIndex ?? 0, i = P["PackagesApi.getPackageClassification"]?.[o]?.url;
|
|
3985
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
3844
3986
|
},
|
|
3845
3987
|
/**
|
|
3846
3988
|
* The state of the package\'s semantic discovery index, which is what `get_context` ranks against when an embedding provider is configured. `status: lexical` when the server has no provider, because there is no index to describe. Poll it after a load or reload until `status` is terminal (`ready`, `lexical` or `error`).
|
|
@@ -3852,8 +3994,8 @@ const xn = {
|
|
|
3852
3994
|
* @throws {RequiredError}
|
|
3853
3995
|
*/
|
|
3854
3996
|
async getPackageEmbeddingIndex(a, n, e, t) {
|
|
3855
|
-
const s = await r.getPackageEmbeddingIndex(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
3856
|
-
return (
|
|
3997
|
+
const s = await r.getPackageEmbeddingIndex(a, n, e, t), o = l?.serverIndex ?? 0, i = P["PackagesApi.getPackageEmbeddingIndex"]?.[o]?.url;
|
|
3998
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
3857
3999
|
},
|
|
3858
4000
|
/**
|
|
3859
4001
|
* What every `.malloy` model of the package declares, in the form an indexer reads: each source\'s public fields (kind, type, declaring code, annotations, `#(doc)`, table, join target, and an `#(index)` dimension\'s fingerprint), the facts the model states about each source (doc, visibility, queryability, filters, access gates), the model\'s givens and each source\'s schema. One entry per `.malloy` file, sorted by `modelPath`. Shown under the rules of `GET …/models/{path}`: only the files on the package\'s discovery surface, and no source locked with `#(authorize) false`. With `includeHiddenFilesAndSources`, every `.malloy` file and every source, for a host that indexes them; as with the model routes, a gateway admits that flag only for such a host. Computed once, when the package loads, from the models as they compiled before any materialization manifest is bound, so a later bind does not change it. A model that failed has an entry with `error` and `errorKind` and nothing else. An `#(index)` or required `#(filter)` an index cannot honor is left out (no fingerprint, no filter) and reported as a package warning whose `code` starts with `entities-`.
|
|
@@ -3866,8 +4008,8 @@ const xn = {
|
|
|
3866
4008
|
* @throws {RequiredError}
|
|
3867
4009
|
*/
|
|
3868
4010
|
async getPackageEntities(a, n, e, t, s) {
|
|
3869
|
-
const o = await r.getPackageEntities(a, n, e, t, s),
|
|
3870
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
4011
|
+
const o = await r.getPackageEntities(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["PackagesApi.getPackageEntities"]?.[i]?.url;
|
|
4012
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
3871
4013
|
},
|
|
3872
4014
|
/**
|
|
3873
4015
|
* The package\'s serving state on this server: whether a compiled copy serves and whether a load is in progress, which load it serves (`servedRevision`) and the content of that load (`sourceContentSha`), and which materialized tables are bound (`manifestBindingStatus`, `manifestEntryCount`, `boundManifestUri`, `storageServeBindings`). For a versioned package, the named version\'s, or its `latest`\'s. Reading it never loads the package. A package this server knows but does not hold in memory reports `status.serving` false and none of the load fields. `GET /status` carries the part of this an orchestrator reconciles from, for every package at once.
|
|
@@ -3879,8 +4021,8 @@ const xn = {
|
|
|
3879
4021
|
* @throws {RequiredError}
|
|
3880
4022
|
*/
|
|
3881
4023
|
async getPackageStatus(a, n, e, t) {
|
|
3882
|
-
const s = await r.getPackageStatus(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
3883
|
-
return (
|
|
4024
|
+
const s = await r.getPackageStatus(a, n, e, t), o = l?.serverIndex ?? 0, i = P["PackagesApi.getPackageStatus"]?.[o]?.url;
|
|
4025
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
3884
4026
|
},
|
|
3885
4027
|
/**
|
|
3886
4028
|
* Retrieves a list of all Malloy packages within the specified environment. Each package contains models, notebooks, databases, and other resources. This endpoint is useful for discovering available packages and their basic metadata. This endpoint does not reload. A `reload` query parameter is rejected with 400 rather than ignored, because answering 200 here reads as a reload that worked. Reload is per-package: use `GET /environments/{environmentName}/packages/{packageName}?reload=true`. A package with published versions is listed once, as its `latest` version. A `versionId` other than empty or `latest` is rejected with 400: read one version with `GET /environments/{environmentName}/packages/{packageName}?versionId=`.
|
|
@@ -3891,7 +4033,7 @@ const xn = {
|
|
|
3891
4033
|
*/
|
|
3892
4034
|
async listPackages(a, n) {
|
|
3893
4035
|
const e = await r.listPackages(a, n), t = l?.serverIndex ?? 0, s = P["PackagesApi.listPackages"]?.[t]?.url;
|
|
3894
|
-
return (o,
|
|
4036
|
+
return (o, i) => S(e, u, g, l)(o, s || i);
|
|
3895
4037
|
},
|
|
3896
4038
|
/**
|
|
3897
4039
|
* DEPRECATED. In-place mutation of a package contradicts immutable versions, so this operation will be removed. On a package that has published versions it changes only what is not content: a `manifestLocation` URI is bound to the package\'s `latest` version (as `PUT .../packages/{packageName}/versions/{version}/manifest` does for any version), while a null or empty one leaves the binding as it is (clear it with that route), and `description` is the package\'s. `name` and the `location` the version was published from may be sent back unchanged. Any other change is refused with 409 (`reason` `PACKAGE_IS_VERSIONED`), as is a package with no `latest` yet: publish a new version to change content. It keeps working, so that callers which predate versions do not break, and says it is deprecated: every response carries `Deprecation: true` and a `Link` to the package versions reference, every request is counted in `publisher_deprecated_usage_total` (`feature` `package_patch`), and the server logs a warning, once per package per run, naming the route that replaces it. Updates the configuration and metadata of an existing package. This allows you to modify package settings, update the description, change the location, or update other package-level properties. The package must exist and be accessible. A supplied `materialization` block REPLACES the one on disk, so re-send every field of it you want to keep. Two exceptions are preserved when omitted: `scope`, which is a top-level field and not expressible in the block at all, and `queryMetadata`, which is orthogonal to the schedule and freshness policy this call usually carries — a client setting a schedule has no reason to re-send the package\'s tags, and dropping them silently untags every statement the package issues. `queryMetadata` has two homes: the top-level field, which is canonical, and `materialization.queryMetadata`, which is DEPRECATED and still accepted. The canonical field wins if a request sends both, and both are populated on read. At EITHER home, omitting it preserves the package\'s tags and so does sending null — a client that serializes unset fields as null must not untag a package by accident. Send an empty object to clear. A package fetched from a `location` keeps none of these on reload: a reload fetches it again and replaces its files, `publisher.json` included, keeping only its `location` and manifest binding. So when the package will be fetched from a location once this request is applied (the `location` it sends, or else the one it was installed from), a change to `description`, `explores`, `queryableSources`, `scope`, `queryMetadata` or `materialization` is refused with 409 (`reason` `PACKAGE_INSTALLED_FROM_LOCATION`). A change is judged by the value the request would leave in force: clearing a set field is a change, a null is omitted, and a value equal to the current one (`explores` normalized as stored) is not. A request that names a new `location` is judged against the tree fetched from it, and a refusal leaves the previous install serving. When the package it replaces was itself installed from a location, a field sent with that package\'s value is the package sent back, not a change: it is left out and the new tree\'s value serves, so a whole package read back with only its `location` changed is accepted. Make the change in the package\'s source and reload it, or publish it as a version.
|
|
@@ -3904,12 +4046,12 @@ const xn = {
|
|
|
3904
4046
|
* @throws {RequiredError}
|
|
3905
4047
|
*/
|
|
3906
4048
|
async updatePackage(a, n, e, t) {
|
|
3907
|
-
const s = await r.updatePackage(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
3908
|
-
return (
|
|
4049
|
+
const s = await r.updatePackage(a, n, e, t), o = l?.serverIndex ?? 0, i = P["PackagesApi.updatePackage"]?.[o]?.url;
|
|
4050
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
3909
4051
|
}
|
|
3910
4052
|
};
|
|
3911
|
-
},
|
|
3912
|
-
const n =
|
|
4053
|
+
}, wn = function(l, r, a) {
|
|
4054
|
+
const n = x(l);
|
|
3913
4055
|
return {
|
|
3914
4056
|
/**
|
|
3915
4057
|
* Creates a new Malloy package within the specified environment. A package serves as a container for models, notebooks, embedded databases, and other resources. The package will be initialized with the provided metadata and can immediately accept content. ## Dry run With `?dryRun=true` the request needs a `location`. The tree there is downloaded and loaded, and the publish checks run, exactly as a publish would run them, and then it is discarded: nothing is installed, served or listed, the package already served under the name (if any) is untouched, no version is recorded, and the load\'s connections are closed. The answer is what a publish would answer for the tree itself: the same 400 or 424 refusal, or 200 with the package as it would load, its `warnings` included, plus the `location` it was loaded from. The 200 also carries what a publish would build and serve: the `buildPlan`, and `serveVerdicts`, each materialized source\'s serve verdict with each stored source\'s named views compiled against a compile-only served copy (no table is built). With package versioning on, the tree\'s `publisher.json` must declare a valid version, as a versioned publish requires (400 `MANIFEST_VERSION_MISSING` or `MANIFEST_VERSION_INVALID`), and the 200 names it as `versionId`. Version lifecycle checks (a version that already exists, `latest`) are not part of it, and the 200 carries no `latestVersion` or `status`, which describe the package being served. A frozen configuration refuses a dry run as it refuses a publish, since the server still downloads and loads the caller\'s content; so does memory backpressure (503). A server runs at most 2 dry runs at once and refuses more with 503. With package versioning on, a `description` that is not a string or a `manifestLocation` that names no manifest is the 400 a versioned publish answers. ## Versioned publish Package versioning is a server setting, `PUBLISHER_PACKAGE_VERSIONING` (`on` by default; `ServerStatus.packageVersioning` reports it), and a transition: a later release removes the setting and always publishes versions. With it off, a request that carries a `location` installs the package in place, replacing the previous publish, as before versions, whatever its `publisher.json` declares; the package has no versions, and the server logs a warning that names it. A package that already has published versions refuses that with 409 (`reason` `PACKAGE_IS_VERSIONED`). With it on, a request that carries a `location` publishes an immutable version of the package: the one its own `publisher.json` declares. The request takes no version parameter: the version is that field, the way `npm publish` reads `package.json`, so bumping it is the release action. - A `publisher.json` with no `version` is refused with 400 (`reason` `MANIFEST_VERSION_MISSING`), and one whose `version` is not a semantic version with 400 (`reason` `MANIFEST_VERSION_INVALID`). Nothing is written. - Publishing a version the package already has, with different content, is refused with 409 (`reason` `VERSION_CONFLICT`). The same content again succeeds and writes no files, so re-loading a version onto a server that already holds it is safe to retry; a non-null `manifestLocation` on that request binds the version to it. A re-load leaves `latest` where it is, so a retried publish never undoes a rollback; it sets `latest` only for a package that has none. Re-publishing an archived version is refused with 410 (`reason` `VERSION_ARCHIVED`): unarchive it instead. - A version that does not pass the publish checks (the same ones an unversioned publish applies) is refused with 400, and the versions already published keep serving. - Under `versionPromotion: \"on-publish\"` (the default), the new version becomes the package\'s `latest` unless a higher version already is. Under `\"explicit\"`, publish never moves `latest`; `PUT .../packages/{packageName}/latest` does. - A package mounted for watch mode is the author\'s own source directory, so it cannot hold immutable versions: publishing a version of it is refused with 400. - The request\'s `description`, when sent, is the package\'s description. Each version keeps the `description` from its own publisher.json. A request without a `location` registers a directory already in the environment as a single unversioned package, as packages loaded from `publisher.config.json` are with versioning off. A package that already has versions refuses that with 409 (`reason` `PACKAGE_IS_VERSIONED`).
|
|
@@ -3921,7 +4063,7 @@ const xn = {
|
|
|
3921
4063
|
* @throws {RequiredError}
|
|
3922
4064
|
*/
|
|
3923
4065
|
createPackage(e, t, s, o) {
|
|
3924
|
-
return n.createPackage(e, t, s, o).then((
|
|
4066
|
+
return n.createPackage(e, t, s, o).then((i) => i(a, r));
|
|
3925
4067
|
},
|
|
3926
4068
|
/**
|
|
3927
4069
|
* Permanently deletes a package and all its associated resources including models, notebooks, databases, and metadata. This operation cannot be undone, so use with caution. The package must exist and be accessible for deletion. On a versioned package this deletes every published version and its files, then, in the background, cleans up each version as deleting it alone does: its own auto-runs still running are stopped and its own `scope: version` tables reclaimed. To take one version out of service while keeping the rest, archive it with `PATCH .../packages/{packageName}/versions/{version}`; to remove one version for good, delete it with `DELETE .../packages/{packageName}/versions/{version}`.
|
|
@@ -3944,8 +4086,8 @@ const xn = {
|
|
|
3944
4086
|
* @param {*} [options] Override http request option.
|
|
3945
4087
|
* @throws {RequiredError}
|
|
3946
4088
|
*/
|
|
3947
|
-
getPackage(e, t, s, o,
|
|
3948
|
-
return n.getPackage(e, t, s, o,
|
|
4089
|
+
getPackage(e, t, s, o, i) {
|
|
4090
|
+
return n.getPackage(e, t, s, o, i).then((c) => c(a, r));
|
|
3949
4091
|
},
|
|
3950
4092
|
/**
|
|
3951
4093
|
* The persist build plan of the load: per persist source its `sourceEntityId`, output columns and build SQL, the dependency graphs, and the sources refused a build. A caller assigns physical names and identity per source from it and issues one build call (see `CreateMaterializationRequest.buildInstructions`). A package that declares no persist source has an empty plan. When the plan could not be derived at load, the read answers 409 with `reason` BUILD_PLAN_UNAVAILABLE; reloading the package derives it again, and retrying the read does not. After an edit to a connection the package\'s persisted sources build on, the plan is re-derived (a content address folds in its connection\'s digest) and the read waits for it; past 10 seconds it answers 503 with `reason` BUILD_PLAN_REFRESHING and a `Retry-After` header. A failed re-derivation answers 409 BUILD_PLAN_UNAVAILABLE, as at load, and run creation with `buildInstructions` is refused the same way rather than checked against the plan from before the edit.
|
|
@@ -3957,7 +4099,7 @@ const xn = {
|
|
|
3957
4099
|
* @throws {RequiredError}
|
|
3958
4100
|
*/
|
|
3959
4101
|
getPackageBuildPlan(e, t, s, o) {
|
|
3960
|
-
return n.getPackageBuildPlan(e, t, s, o).then((
|
|
4102
|
+
return n.getPackageBuildPlan(e, t, s, o).then((i) => i(a, r));
|
|
3961
4103
|
},
|
|
3962
4104
|
/**
|
|
3963
4105
|
* For each published entry point of the package, the classes its `#(carries)` declares and how many of its fields carry each class, inherited classes included, with the count left unclassified. It covers only what discovery shows. `sources` is empty when nothing published is classified.
|
|
@@ -3969,7 +4111,7 @@ const xn = {
|
|
|
3969
4111
|
* @throws {RequiredError}
|
|
3970
4112
|
*/
|
|
3971
4113
|
getPackageClassification(e, t, s, o) {
|
|
3972
|
-
return n.getPackageClassification(e, t, s, o).then((
|
|
4114
|
+
return n.getPackageClassification(e, t, s, o).then((i) => i(a, r));
|
|
3973
4115
|
},
|
|
3974
4116
|
/**
|
|
3975
4117
|
* The state of the package\'s semantic discovery index, which is what `get_context` ranks against when an embedding provider is configured. `status: lexical` when the server has no provider, because there is no index to describe. Poll it after a load or reload until `status` is terminal (`ready`, `lexical` or `error`).
|
|
@@ -3981,7 +4123,7 @@ const xn = {
|
|
|
3981
4123
|
* @throws {RequiredError}
|
|
3982
4124
|
*/
|
|
3983
4125
|
getPackageEmbeddingIndex(e, t, s, o) {
|
|
3984
|
-
return n.getPackageEmbeddingIndex(e, t, s, o).then((
|
|
4126
|
+
return n.getPackageEmbeddingIndex(e, t, s, o).then((i) => i(a, r));
|
|
3985
4127
|
},
|
|
3986
4128
|
/**
|
|
3987
4129
|
* What every `.malloy` model of the package declares, in the form an indexer reads: each source\'s public fields (kind, type, declaring code, annotations, `#(doc)`, table, join target, and an `#(index)` dimension\'s fingerprint), the facts the model states about each source (doc, visibility, queryability, filters, access gates), the model\'s givens and each source\'s schema. One entry per `.malloy` file, sorted by `modelPath`. Shown under the rules of `GET …/models/{path}`: only the files on the package\'s discovery surface, and no source locked with `#(authorize) false`. With `includeHiddenFilesAndSources`, every `.malloy` file and every source, for a host that indexes them; as with the model routes, a gateway admits that flag only for such a host. Computed once, when the package loads, from the models as they compiled before any materialization manifest is bound, so a later bind does not change it. A model that failed has an entry with `error` and `errorKind` and nothing else. An `#(index)` or required `#(filter)` an index cannot honor is left out (no fingerprint, no filter) and reported as a package warning whose `code` starts with `entities-`.
|
|
@@ -3993,8 +4135,8 @@ const xn = {
|
|
|
3993
4135
|
* @param {*} [options] Override http request option.
|
|
3994
4136
|
* @throws {RequiredError}
|
|
3995
4137
|
*/
|
|
3996
|
-
getPackageEntities(e, t, s, o,
|
|
3997
|
-
return n.getPackageEntities(e, t, s, o,
|
|
4138
|
+
getPackageEntities(e, t, s, o, i) {
|
|
4139
|
+
return n.getPackageEntities(e, t, s, o, i).then((c) => c(a, r));
|
|
3998
4140
|
},
|
|
3999
4141
|
/**
|
|
4000
4142
|
* The package\'s serving state on this server: whether a compiled copy serves and whether a load is in progress, which load it serves (`servedRevision`) and the content of that load (`sourceContentSha`), and which materialized tables are bound (`manifestBindingStatus`, `manifestEntryCount`, `boundManifestUri`, `storageServeBindings`). For a versioned package, the named version\'s, or its `latest`\'s. Reading it never loads the package. A package this server knows but does not hold in memory reports `status.serving` false and none of the load fields. `GET /status` carries the part of this an orchestrator reconciles from, for every package at once.
|
|
@@ -4006,7 +4148,7 @@ const xn = {
|
|
|
4006
4148
|
* @throws {RequiredError}
|
|
4007
4149
|
*/
|
|
4008
4150
|
getPackageStatus(e, t, s, o) {
|
|
4009
|
-
return n.getPackageStatus(e, t, s, o).then((
|
|
4151
|
+
return n.getPackageStatus(e, t, s, o).then((i) => i(a, r));
|
|
4010
4152
|
},
|
|
4011
4153
|
/**
|
|
4012
4154
|
* Retrieves a list of all Malloy packages within the specified environment. Each package contains models, notebooks, databases, and other resources. This endpoint is useful for discovering available packages and their basic metadata. This endpoint does not reload. A `reload` query parameter is rejected with 400 rather than ignored, because answering 200 here reads as a reload that worked. Reload is per-package: use `GET /environments/{environmentName}/packages/{packageName}?reload=true`. A package with published versions is listed once, as its `latest` version. A `versionId` other than empty or `latest` is rejected with 400: read one version with `GET /environments/{environmentName}/packages/{packageName}?versionId=`.
|
|
@@ -4029,7 +4171,7 @@ const xn = {
|
|
|
4029
4171
|
* @throws {RequiredError}
|
|
4030
4172
|
*/
|
|
4031
4173
|
updatePackage(e, t, s, o) {
|
|
4032
|
-
return n.updatePackage(e, t, s, o).then((
|
|
4174
|
+
return n.updatePackage(e, t, s, o).then((i) => i(a, r));
|
|
4033
4175
|
}
|
|
4034
4176
|
};
|
|
4035
4177
|
};
|
|
@@ -4044,7 +4186,7 @@ class pa extends I {
|
|
|
4044
4186
|
* @throws {RequiredError}
|
|
4045
4187
|
*/
|
|
4046
4188
|
createPackage(r, a, n, e) {
|
|
4047
|
-
return
|
|
4189
|
+
return x(this.configuration).createPackage(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
4048
4190
|
}
|
|
4049
4191
|
/**
|
|
4050
4192
|
* Permanently deletes a package and all its associated resources including models, notebooks, databases, and metadata. This operation cannot be undone, so use with caution. The package must exist and be accessible for deletion. On a versioned package this deletes every published version and its files, then, in the background, cleans up each version as deleting it alone does: its own auto-runs still running are stopped and its own `scope: version` tables reclaimed. To take one version out of service while keeping the rest, archive it with `PATCH .../packages/{packageName}/versions/{version}`; to remove one version for good, delete it with `DELETE .../packages/{packageName}/versions/{version}`.
|
|
@@ -4055,7 +4197,7 @@ class pa extends I {
|
|
|
4055
4197
|
* @throws {RequiredError}
|
|
4056
4198
|
*/
|
|
4057
4199
|
deletePackage(r, a, n) {
|
|
4058
|
-
return
|
|
4200
|
+
return x(this.configuration).deletePackage(r, a, n).then((e) => e(this.axios, this.basePath));
|
|
4059
4201
|
}
|
|
4060
4202
|
/**
|
|
4061
4203
|
* Retrieves detailed information about a specific package, including its models, notebooks, databases, and metadata. The reload parameter can be used to refresh the package state from disk before returning the information. The versionId parameter selects one published version of a versioned package; without it, the package\'s `latest` version is returned.
|
|
@@ -4068,7 +4210,7 @@ class pa extends I {
|
|
|
4068
4210
|
* @throws {RequiredError}
|
|
4069
4211
|
*/
|
|
4070
4212
|
getPackage(r, a, n, e, t) {
|
|
4071
|
-
return
|
|
4213
|
+
return x(this.configuration).getPackage(r, a, n, e, t).then((s) => s(this.axios, this.basePath));
|
|
4072
4214
|
}
|
|
4073
4215
|
/**
|
|
4074
4216
|
* The persist build plan of the load: per persist source its `sourceEntityId`, output columns and build SQL, the dependency graphs, and the sources refused a build. A caller assigns physical names and identity per source from it and issues one build call (see `CreateMaterializationRequest.buildInstructions`). A package that declares no persist source has an empty plan. When the plan could not be derived at load, the read answers 409 with `reason` BUILD_PLAN_UNAVAILABLE; reloading the package derives it again, and retrying the read does not. After an edit to a connection the package\'s persisted sources build on, the plan is re-derived (a content address folds in its connection\'s digest) and the read waits for it; past 10 seconds it answers 503 with `reason` BUILD_PLAN_REFRESHING and a `Retry-After` header. A failed re-derivation answers 409 BUILD_PLAN_UNAVAILABLE, as at load, and run creation with `buildInstructions` is refused the same way rather than checked against the plan from before the edit.
|
|
@@ -4080,7 +4222,7 @@ class pa extends I {
|
|
|
4080
4222
|
* @throws {RequiredError}
|
|
4081
4223
|
*/
|
|
4082
4224
|
getPackageBuildPlan(r, a, n, e) {
|
|
4083
|
-
return
|
|
4225
|
+
return x(this.configuration).getPackageBuildPlan(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
4084
4226
|
}
|
|
4085
4227
|
/**
|
|
4086
4228
|
* For each published entry point of the package, the classes its `#(carries)` declares and how many of its fields carry each class, inherited classes included, with the count left unclassified. It covers only what discovery shows. `sources` is empty when nothing published is classified.
|
|
@@ -4092,7 +4234,7 @@ class pa extends I {
|
|
|
4092
4234
|
* @throws {RequiredError}
|
|
4093
4235
|
*/
|
|
4094
4236
|
getPackageClassification(r, a, n, e) {
|
|
4095
|
-
return
|
|
4237
|
+
return x(this.configuration).getPackageClassification(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
4096
4238
|
}
|
|
4097
4239
|
/**
|
|
4098
4240
|
* The state of the package\'s semantic discovery index, which is what `get_context` ranks against when an embedding provider is configured. `status: lexical` when the server has no provider, because there is no index to describe. Poll it after a load or reload until `status` is terminal (`ready`, `lexical` or `error`).
|
|
@@ -4104,7 +4246,7 @@ class pa extends I {
|
|
|
4104
4246
|
* @throws {RequiredError}
|
|
4105
4247
|
*/
|
|
4106
4248
|
getPackageEmbeddingIndex(r, a, n, e) {
|
|
4107
|
-
return
|
|
4249
|
+
return x(this.configuration).getPackageEmbeddingIndex(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
4108
4250
|
}
|
|
4109
4251
|
/**
|
|
4110
4252
|
* What every `.malloy` model of the package declares, in the form an indexer reads: each source\'s public fields (kind, type, declaring code, annotations, `#(doc)`, table, join target, and an `#(index)` dimension\'s fingerprint), the facts the model states about each source (doc, visibility, queryability, filters, access gates), the model\'s givens and each source\'s schema. One entry per `.malloy` file, sorted by `modelPath`. Shown under the rules of `GET …/models/{path}`: only the files on the package\'s discovery surface, and no source locked with `#(authorize) false`. With `includeHiddenFilesAndSources`, every `.malloy` file and every source, for a host that indexes them; as with the model routes, a gateway admits that flag only for such a host. Computed once, when the package loads, from the models as they compiled before any materialization manifest is bound, so a later bind does not change it. A model that failed has an entry with `error` and `errorKind` and nothing else. An `#(index)` or required `#(filter)` an index cannot honor is left out (no fingerprint, no filter) and reported as a package warning whose `code` starts with `entities-`.
|
|
@@ -4117,7 +4259,7 @@ class pa extends I {
|
|
|
4117
4259
|
* @throws {RequiredError}
|
|
4118
4260
|
*/
|
|
4119
4261
|
getPackageEntities(r, a, n, e, t) {
|
|
4120
|
-
return
|
|
4262
|
+
return x(this.configuration).getPackageEntities(r, a, n, e, t).then((s) => s(this.axios, this.basePath));
|
|
4121
4263
|
}
|
|
4122
4264
|
/**
|
|
4123
4265
|
* The package\'s serving state on this server: whether a compiled copy serves and whether a load is in progress, which load it serves (`servedRevision`) and the content of that load (`sourceContentSha`), and which materialized tables are bound (`manifestBindingStatus`, `manifestEntryCount`, `boundManifestUri`, `storageServeBindings`). For a versioned package, the named version\'s, or its `latest`\'s. Reading it never loads the package. A package this server knows but does not hold in memory reports `status.serving` false and none of the load fields. `GET /status` carries the part of this an orchestrator reconciles from, for every package at once.
|
|
@@ -4129,7 +4271,7 @@ class pa extends I {
|
|
|
4129
4271
|
* @throws {RequiredError}
|
|
4130
4272
|
*/
|
|
4131
4273
|
getPackageStatus(r, a, n, e) {
|
|
4132
|
-
return
|
|
4274
|
+
return x(this.configuration).getPackageStatus(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
4133
4275
|
}
|
|
4134
4276
|
/**
|
|
4135
4277
|
* Retrieves a list of all Malloy packages within the specified environment. Each package contains models, notebooks, databases, and other resources. This endpoint is useful for discovering available packages and their basic metadata. This endpoint does not reload. A `reload` query parameter is rejected with 400 rather than ignored, because answering 200 here reads as a reload that worked. Reload is per-package: use `GET /environments/{environmentName}/packages/{packageName}?reload=true`. A package with published versions is listed once, as its `latest` version. A `versionId` other than empty or `latest` is rejected with 400: read one version with `GET /environments/{environmentName}/packages/{packageName}?versionId=`.
|
|
@@ -4139,7 +4281,7 @@ class pa extends I {
|
|
|
4139
4281
|
* @throws {RequiredError}
|
|
4140
4282
|
*/
|
|
4141
4283
|
listPackages(r, a) {
|
|
4142
|
-
return
|
|
4284
|
+
return x(this.configuration).listPackages(r, a).then((n) => n(this.axios, this.basePath));
|
|
4143
4285
|
}
|
|
4144
4286
|
/**
|
|
4145
4287
|
* DEPRECATED. In-place mutation of a package contradicts immutable versions, so this operation will be removed. On a package that has published versions it changes only what is not content: a `manifestLocation` URI is bound to the package\'s `latest` version (as `PUT .../packages/{packageName}/versions/{version}/manifest` does for any version), while a null or empty one leaves the binding as it is (clear it with that route), and `description` is the package\'s. `name` and the `location` the version was published from may be sent back unchanged. Any other change is refused with 409 (`reason` `PACKAGE_IS_VERSIONED`), as is a package with no `latest` yet: publish a new version to change content. It keeps working, so that callers which predate versions do not break, and says it is deprecated: every response carries `Deprecation: true` and a `Link` to the package versions reference, every request is counted in `publisher_deprecated_usage_total` (`feature` `package_patch`), and the server logs a warning, once per package per run, naming the route that replaces it. Updates the configuration and metadata of an existing package. This allows you to modify package settings, update the description, change the location, or update other package-level properties. The package must exist and be accessible. A supplied `materialization` block REPLACES the one on disk, so re-send every field of it you want to keep. Two exceptions are preserved when omitted: `scope`, which is a top-level field and not expressible in the block at all, and `queryMetadata`, which is orthogonal to the schedule and freshness policy this call usually carries — a client setting a schedule has no reason to re-send the package\'s tags, and dropping them silently untags every statement the package issues. `queryMetadata` has two homes: the top-level field, which is canonical, and `materialization.queryMetadata`, which is DEPRECATED and still accepted. The canonical field wins if a request sends both, and both are populated on read. At EITHER home, omitting it preserves the package\'s tags and so does sending null — a client that serializes unset fields as null must not untag a package by accident. Send an empty object to clear. A package fetched from a `location` keeps none of these on reload: a reload fetches it again and replaces its files, `publisher.json` included, keeping only its `location` and manifest binding. So when the package will be fetched from a location once this request is applied (the `location` it sends, or else the one it was installed from), a change to `description`, `explores`, `queryableSources`, `scope`, `queryMetadata` or `materialization` is refused with 409 (`reason` `PACKAGE_INSTALLED_FROM_LOCATION`). A change is judged by the value the request would leave in force: clearing a set field is a change, a null is omitted, and a value equal to the current one (`explores` normalized as stored) is not. A request that names a new `location` is judged against the tree fetched from it, and a refusal leaves the previous install serving. When the package it replaces was itself installed from a location, a field sent with that package\'s value is the package sent back, not a change: it is left out and the new tree\'s value serves, so a whole package read back with only its `location` changed is accepted. Make the change in the package\'s source and reload it, or publish it as a version.
|
|
@@ -4152,7 +4294,7 @@ class pa extends I {
|
|
|
4152
4294
|
* @throws {RequiredError}
|
|
4153
4295
|
*/
|
|
4154
4296
|
updatePackage(r, a, n, e) {
|
|
4155
|
-
return
|
|
4297
|
+
return x(this.configuration).updatePackage(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
4156
4298
|
}
|
|
4157
4299
|
}
|
|
4158
4300
|
const da = function(l) {
|
|
@@ -4164,14 +4306,14 @@ const da = function(l) {
|
|
|
4164
4306
|
* @throws {RequiredError}
|
|
4165
4307
|
*/
|
|
4166
4308
|
deleteTheme: async (r = {}) => {
|
|
4167
|
-
const a = "/theme", n = new URL(a,
|
|
4309
|
+
const a = "/theme", n = new URL(a, b);
|
|
4168
4310
|
let e;
|
|
4169
4311
|
l && (e = l.baseOptions);
|
|
4170
4312
|
const t = { method: "DELETE", ...e, ...r }, s = {}, o = {};
|
|
4171
4313
|
s.Accept = "application/json", v(n, o);
|
|
4172
|
-
let
|
|
4173
|
-
return t.headers = { ...s, ...
|
|
4174
|
-
url:
|
|
4314
|
+
let i = e && e.headers ? e.headers : {};
|
|
4315
|
+
return t.headers = { ...s, ...i, ...r.headers }, {
|
|
4316
|
+
url: V(n),
|
|
4175
4317
|
options: t
|
|
4176
4318
|
};
|
|
4177
4319
|
},
|
|
@@ -4183,14 +4325,14 @@ const da = function(l) {
|
|
|
4183
4325
|
* @throws {RequiredError}
|
|
4184
4326
|
*/
|
|
4185
4327
|
getStatus: async (r, a = {}) => {
|
|
4186
|
-
const n = "/status", e = new URL(n,
|
|
4328
|
+
const n = "/status", e = new URL(n, b);
|
|
4187
4329
|
let t;
|
|
4188
4330
|
l && (t = l.baseOptions);
|
|
4189
|
-
const s = { method: "GET", ...t, ...a }, o = {},
|
|
4190
|
-
r !== void 0 && (
|
|
4191
|
-
let
|
|
4192
|
-
return s.headers = { ...o, ...
|
|
4193
|
-
url:
|
|
4331
|
+
const s = { method: "GET", ...t, ...a }, o = {}, i = {};
|
|
4332
|
+
r !== void 0 && (i.includeLoading = r), o.Accept = "application/json", v(e, i);
|
|
4333
|
+
let c = t && t.headers ? t.headers : {};
|
|
4334
|
+
return s.headers = { ...o, ...c, ...a.headers }, {
|
|
4335
|
+
url: V(e),
|
|
4194
4336
|
options: s
|
|
4195
4337
|
};
|
|
4196
4338
|
},
|
|
@@ -4201,14 +4343,14 @@ const da = function(l) {
|
|
|
4201
4343
|
* @throws {RequiredError}
|
|
4202
4344
|
*/
|
|
4203
4345
|
getTheme: async (r = {}) => {
|
|
4204
|
-
const a = "/theme", n = new URL(a,
|
|
4346
|
+
const a = "/theme", n = new URL(a, b);
|
|
4205
4347
|
let e;
|
|
4206
4348
|
l && (e = l.baseOptions);
|
|
4207
4349
|
const t = { method: "GET", ...e, ...r }, s = {}, o = {};
|
|
4208
4350
|
s.Accept = "application/json", v(n, o);
|
|
4209
|
-
let
|
|
4210
|
-
return t.headers = { ...s, ...
|
|
4211
|
-
url:
|
|
4351
|
+
let i = e && e.headers ? e.headers : {};
|
|
4352
|
+
return t.headers = { ...s, ...i, ...r.headers }, {
|
|
4353
|
+
url: V(n),
|
|
4212
4354
|
options: t
|
|
4213
4355
|
};
|
|
4214
4356
|
},
|
|
@@ -4221,14 +4363,14 @@ const da = function(l) {
|
|
|
4221
4363
|
*/
|
|
4222
4364
|
updateTheme: async (r, a = {}) => {
|
|
4223
4365
|
m("updateTheme", "theme", r);
|
|
4224
|
-
const n = "/theme", e = new URL(n,
|
|
4366
|
+
const n = "/theme", e = new URL(n, b);
|
|
4225
4367
|
let t;
|
|
4226
4368
|
l && (t = l.baseOptions);
|
|
4227
|
-
const s = { method: "PUT", ...t, ...a }, o = {},
|
|
4228
|
-
o["Content-Type"] = "application/json", o.Accept = "application/json", v(e,
|
|
4229
|
-
let
|
|
4230
|
-
return s.headers = { ...o, ...
|
|
4231
|
-
url:
|
|
4369
|
+
const s = { method: "PUT", ...t, ...a }, o = {}, i = {};
|
|
4370
|
+
o["Content-Type"] = "application/json", o.Accept = "application/json", v(e, i);
|
|
4371
|
+
let c = t && t.headers ? t.headers : {};
|
|
4372
|
+
return s.headers = { ...o, ...c, ...a.headers }, s.data = A(r, s, l), {
|
|
4373
|
+
url: V(e),
|
|
4232
4374
|
options: s
|
|
4233
4375
|
};
|
|
4234
4376
|
}
|
|
@@ -4255,7 +4397,7 @@ const da = function(l) {
|
|
|
4255
4397
|
*/
|
|
4256
4398
|
async getStatus(a, n) {
|
|
4257
4399
|
const e = await r.getStatus(a, n), t = l?.serverIndex ?? 0, s = P["PublisherApi.getStatus"]?.[t]?.url;
|
|
4258
|
-
return (o,
|
|
4400
|
+
return (o, i) => S(e, u, g, l)(o, s || i);
|
|
4259
4401
|
},
|
|
4260
4402
|
/**
|
|
4261
4403
|
* Returns the theme used by the Malloy renderer for charts/tables/dashboards. Reflects edits made via the in-app Theme Editor (persisted to the server\'s internal DuckDB metadata store via the shared StorageManager). Empty object when no theme has been configured.
|
|
@@ -4276,10 +4418,10 @@ const da = function(l) {
|
|
|
4276
4418
|
*/
|
|
4277
4419
|
async updateTheme(a, n) {
|
|
4278
4420
|
const e = await r.updateTheme(a, n), t = l?.serverIndex ?? 0, s = P["PublisherApi.updateTheme"]?.[t]?.url;
|
|
4279
|
-
return (o,
|
|
4421
|
+
return (o, i) => S(e, u, g, l)(o, s || i);
|
|
4280
4422
|
}
|
|
4281
4423
|
};
|
|
4282
|
-
},
|
|
4424
|
+
}, Mn = function(l, r, a) {
|
|
4283
4425
|
const n = D(l);
|
|
4284
4426
|
return {
|
|
4285
4427
|
/**
|
|
@@ -4376,15 +4518,15 @@ const ha = function(l) {
|
|
|
4376
4518
|
*/
|
|
4377
4519
|
getReport: async (r, a, n, e, t = {}) => {
|
|
4378
4520
|
m("getReport", "environmentName", r), m("getReport", "packageName", a), m("getReport", "path", n);
|
|
4379
|
-
const s = "/environments/{environmentName}/packages/{packageName}/reports/{path}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))), o = new URL(s,
|
|
4380
|
-
let
|
|
4381
|
-
l && (
|
|
4382
|
-
const
|
|
4521
|
+
const s = "/environments/{environmentName}/packages/{packageName}/reports/{path}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{path}", encodeURIComponent(String(n))), o = new URL(s, b);
|
|
4522
|
+
let i;
|
|
4523
|
+
l && (i = l.baseOptions);
|
|
4524
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
4383
4525
|
e !== void 0 && (d.versionId = e), p.Accept = "application/json", v(o, d);
|
|
4384
|
-
let h =
|
|
4385
|
-
return
|
|
4386
|
-
url:
|
|
4387
|
-
options:
|
|
4526
|
+
let h = i && i.headers ? i.headers : {};
|
|
4527
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
4528
|
+
url: V(o),
|
|
4529
|
+
options: c
|
|
4388
4530
|
};
|
|
4389
4531
|
},
|
|
4390
4532
|
/**
|
|
@@ -4398,15 +4540,15 @@ const ha = function(l) {
|
|
|
4398
4540
|
*/
|
|
4399
4541
|
listReports: async (r, a, n, e = {}) => {
|
|
4400
4542
|
m("listReports", "environmentName", r), m("listReports", "packageName", a);
|
|
4401
|
-
const t = "/environments/{environmentName}/packages/{packageName}/reports".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
4543
|
+
const t = "/environments/{environmentName}/packages/{packageName}/reports".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
4402
4544
|
let o;
|
|
4403
4545
|
l && (o = l.baseOptions);
|
|
4404
|
-
const
|
|
4405
|
-
n !== void 0 && (p.versionId = n),
|
|
4546
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
4547
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
4406
4548
|
let d = o && o.headers ? o.headers : {};
|
|
4407
|
-
return
|
|
4408
|
-
url:
|
|
4409
|
-
options:
|
|
4549
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
4550
|
+
url: V(s),
|
|
4551
|
+
options: i
|
|
4410
4552
|
};
|
|
4411
4553
|
}
|
|
4412
4554
|
};
|
|
@@ -4424,8 +4566,8 @@ const ha = function(l) {
|
|
|
4424
4566
|
* @throws {RequiredError}
|
|
4425
4567
|
*/
|
|
4426
4568
|
async getReport(a, n, e, t, s) {
|
|
4427
|
-
const o = await r.getReport(a, n, e, t, s),
|
|
4428
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
4569
|
+
const o = await r.getReport(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["ReportsApi.getReport"]?.[i]?.url;
|
|
4570
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
4429
4571
|
},
|
|
4430
4572
|
/**
|
|
4431
4573
|
* Lists every report in the package, in path order. A report is a `.malloy` file anywhere in the package, outside `public/`, that carries an artifact tag: a model-level `## artifact`, or the deprecated query-level `# artifact` on a `query:`. The package\'s root `index.malloy` is never a report (it is the surface). A legacy `.malloynb` is also a report, linear and read-only. Where a file lives carries no meaning: `dashboards/` and `notebooks/` are ordinary directory names. Everything else is an ordinary model, which a report may import. A report\'s `layout` is decided by its tags, first match wins: the tag\'s `layout=` (`grid` or `linear`); else grid for a query-level `# artifact`; else grid for a model-level tag that lists `tiles` or carries a `dashboard { … }` grid tag; else linear. A tag that sets `kind=` is no report (`report-kind-removed`), and neither is a linear tag that lists no `tiles`: that is the retired `run:` cell format (`report-cells-removed`). An empty `tiles=[]` is a linear report with no tiles yet. A report is identified by its `path`. `name`, its basename, is a display label only: two reports may share one. Every report is listed whatever the package\'s surface; the surface limits what its tiles and cells may read, not whether it is listed. A report that failed to compile is listed with its `error`. A tagged grid report with no tiles yet is not served and not listed.
|
|
@@ -4437,11 +4579,11 @@ const ha = function(l) {
|
|
|
4437
4579
|
* @throws {RequiredError}
|
|
4438
4580
|
*/
|
|
4439
4581
|
async listReports(a, n, e, t) {
|
|
4440
|
-
const s = await r.listReports(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
4441
|
-
return (
|
|
4582
|
+
const s = await r.listReports(a, n, e, t), o = l?.serverIndex ?? 0, i = P["ReportsApi.listReports"]?.[o]?.url;
|
|
4583
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
4442
4584
|
}
|
|
4443
4585
|
};
|
|
4444
|
-
},
|
|
4586
|
+
}, Fn = function(l, r, a) {
|
|
4445
4587
|
const n = X(l);
|
|
4446
4588
|
return {
|
|
4447
4589
|
/**
|
|
@@ -4454,8 +4596,8 @@ const ha = function(l) {
|
|
|
4454
4596
|
* @param {*} [options] Override http request option.
|
|
4455
4597
|
* @throws {RequiredError}
|
|
4456
4598
|
*/
|
|
4457
|
-
getReport(e, t, s, o,
|
|
4458
|
-
return n.getReport(e, t, s, o,
|
|
4599
|
+
getReport(e, t, s, o, i) {
|
|
4600
|
+
return n.getReport(e, t, s, o, i).then((c) => c(a, r));
|
|
4459
4601
|
},
|
|
4460
4602
|
/**
|
|
4461
4603
|
* Lists every report in the package, in path order. A report is a `.malloy` file anywhere in the package, outside `public/`, that carries an artifact tag: a model-level `## artifact`, or the deprecated query-level `# artifact` on a `query:`. The package\'s root `index.malloy` is never a report (it is the surface). A legacy `.malloynb` is also a report, linear and read-only. Where a file lives carries no meaning: `dashboards/` and `notebooks/` are ordinary directory names. Everything else is an ordinary model, which a report may import. A report\'s `layout` is decided by its tags, first match wins: the tag\'s `layout=` (`grid` or `linear`); else grid for a query-level `# artifact`; else grid for a model-level tag that lists `tiles` or carries a `dashboard { … }` grid tag; else linear. A tag that sets `kind=` is no report (`report-kind-removed`), and neither is a linear tag that lists no `tiles`: that is the retired `run:` cell format (`report-cells-removed`). An empty `tiles=[]` is a linear report with no tiles yet. A report is identified by its `path`. `name`, its basename, is a display label only: two reports may share one. Every report is listed whatever the package\'s surface; the surface limits what its tiles and cells may read, not whether it is listed. A report that failed to compile is listed with its `error`. A tagged grid report with no tiles yet is not served and not listed.
|
|
@@ -4467,7 +4609,7 @@ const ha = function(l) {
|
|
|
4467
4609
|
* @throws {RequiredError}
|
|
4468
4610
|
*/
|
|
4469
4611
|
listReports(e, t, s, o) {
|
|
4470
|
-
return n.listReports(e, t, s, o).then((
|
|
4612
|
+
return n.listReports(e, t, s, o).then((i) => i(a, r));
|
|
4471
4613
|
}
|
|
4472
4614
|
};
|
|
4473
4615
|
};
|
|
@@ -4512,15 +4654,15 @@ const ga = function(l) {
|
|
|
4512
4654
|
*/
|
|
4513
4655
|
getSkill: async (r, a, n, e, t = {}) => {
|
|
4514
4656
|
m("getSkill", "environmentName", r), m("getSkill", "packageName", a), m("getSkill", "skillName", n);
|
|
4515
|
-
const s = "/environments/{environmentName}/packages/{packageName}/skills/{skillName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{skillName}", encodeURIComponent(String(n))), o = new URL(s,
|
|
4516
|
-
let
|
|
4517
|
-
l && (
|
|
4518
|
-
const
|
|
4657
|
+
const s = "/environments/{environmentName}/packages/{packageName}/skills/{skillName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{skillName}", encodeURIComponent(String(n))), o = new URL(s, b);
|
|
4658
|
+
let i;
|
|
4659
|
+
l && (i = l.baseOptions);
|
|
4660
|
+
const c = { method: "GET", ...i, ...t }, p = {}, d = {};
|
|
4519
4661
|
e !== void 0 && (d.versionId = e), p.Accept = "application/json", v(o, d);
|
|
4520
|
-
let h =
|
|
4521
|
-
return
|
|
4522
|
-
url:
|
|
4523
|
-
options:
|
|
4662
|
+
let h = i && i.headers ? i.headers : {};
|
|
4663
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
4664
|
+
url: V(o),
|
|
4665
|
+
options: c
|
|
4524
4666
|
};
|
|
4525
4667
|
},
|
|
4526
4668
|
/**
|
|
@@ -4534,15 +4676,15 @@ const ga = function(l) {
|
|
|
4534
4676
|
*/
|
|
4535
4677
|
listSkills: async (r, a, n, e = {}) => {
|
|
4536
4678
|
m("listSkills", "environmentName", r), m("listSkills", "packageName", a);
|
|
4537
|
-
const t = "/environments/{environmentName}/packages/{packageName}/skills".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
4679
|
+
const t = "/environments/{environmentName}/packages/{packageName}/skills".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
4538
4680
|
let o;
|
|
4539
4681
|
l && (o = l.baseOptions);
|
|
4540
|
-
const
|
|
4541
|
-
n !== void 0 && (p.versionId = n),
|
|
4682
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
4683
|
+
n !== void 0 && (p.versionId = n), c.Accept = "application/json", v(s, p);
|
|
4542
4684
|
let d = o && o.headers ? o.headers : {};
|
|
4543
|
-
return
|
|
4544
|
-
url:
|
|
4545
|
-
options:
|
|
4685
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
4686
|
+
url: V(s),
|
|
4687
|
+
options: i
|
|
4546
4688
|
};
|
|
4547
4689
|
}
|
|
4548
4690
|
};
|
|
@@ -4560,8 +4702,8 @@ const ga = function(l) {
|
|
|
4560
4702
|
* @throws {RequiredError}
|
|
4561
4703
|
*/
|
|
4562
4704
|
async getSkill(a, n, e, t, s) {
|
|
4563
|
-
const o = await r.getSkill(a, n, e, t, s),
|
|
4564
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
4705
|
+
const o = await r.getSkill(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["SkillsApi.getSkill"]?.[i]?.url;
|
|
4706
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
4565
4707
|
},
|
|
4566
4708
|
/**
|
|
4567
4709
|
* Lists the agent skills that apply to this package: the guides bundled with this server, plus any the package ships under `skills/`. Resolution is name shadowing. A package skill whose `name` matches a bundled skill REPLACES it for this package; one with a new name is added. Nothing is merged, because the server does not know which guides the calling agent already holds and so cannot patch one. Read `origin` on each entry to tell a replaced skill from the original. Bodies are not returned here. Fetch one with `GET .../skills/{skillName}`. An entry whose `name` contains a slash (`<skill>/<stem>`) is a skill\'s on-demand reference file, addressed by the pointer at the end of its parent\'s body. The REST half of the `get_skill` MCP tool, for callers running unattended.
|
|
@@ -4573,11 +4715,11 @@ const ga = function(l) {
|
|
|
4573
4715
|
* @throws {RequiredError}
|
|
4574
4716
|
*/
|
|
4575
4717
|
async listSkills(a, n, e, t) {
|
|
4576
|
-
const s = await r.listSkills(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
4577
|
-
return (
|
|
4718
|
+
const s = await r.listSkills(a, n, e, t), o = l?.serverIndex ?? 0, i = P["SkillsApi.listSkills"]?.[o]?.url;
|
|
4719
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
4578
4720
|
}
|
|
4579
4721
|
};
|
|
4580
|
-
},
|
|
4722
|
+
}, Bn = function(l, r, a) {
|
|
4581
4723
|
const n = ee(l);
|
|
4582
4724
|
return {
|
|
4583
4725
|
/**
|
|
@@ -4590,8 +4732,8 @@ const ga = function(l) {
|
|
|
4590
4732
|
* @param {*} [options] Override http request option.
|
|
4591
4733
|
* @throws {RequiredError}
|
|
4592
4734
|
*/
|
|
4593
|
-
getSkill(e, t, s, o,
|
|
4594
|
-
return n.getSkill(e, t, s, o,
|
|
4735
|
+
getSkill(e, t, s, o, i) {
|
|
4736
|
+
return n.getSkill(e, t, s, o, i).then((c) => c(a, r));
|
|
4595
4737
|
},
|
|
4596
4738
|
/**
|
|
4597
4739
|
* Lists the agent skills that apply to this package: the guides bundled with this server, plus any the package ships under `skills/`. Resolution is name shadowing. A package skill whose `name` matches a bundled skill REPLACES it for this package; one with a new name is added. Nothing is merged, because the server does not know which guides the calling agent already holds and so cannot patch one. Read `origin` on each entry to tell a replaced skill from the original. Bodies are not returned here. Fetch one with `GET .../skills/{skillName}`. An entry whose `name` contains a slash (`<skill>/<stem>`) is a skill\'s on-demand reference file, addressed by the pointer at the end of its parent\'s body. The REST half of the `get_skill` MCP tool, for callers running unattended.
|
|
@@ -4603,11 +4745,11 @@ const ga = function(l) {
|
|
|
4603
4745
|
* @throws {RequiredError}
|
|
4604
4746
|
*/
|
|
4605
4747
|
listSkills(e, t, s, o) {
|
|
4606
|
-
return n.listSkills(e, t, s, o).then((
|
|
4748
|
+
return n.listSkills(e, t, s, o).then((i) => i(a, r));
|
|
4607
4749
|
}
|
|
4608
4750
|
};
|
|
4609
4751
|
};
|
|
4610
|
-
class
|
|
4752
|
+
class jn extends I {
|
|
4611
4753
|
/**
|
|
4612
4754
|
* Returns one skill in force for this package, including its full Markdown. `skillName` is a name from the listing, exactly as spelled there; a reference file is addressed as `<skill>/<stem>`. The slash may be sent literally or as `%2F`; a literal `%` in a name must be sent as `%25`. 404 when no skill of that name is in force.
|
|
4613
4755
|
* @summary Get one agent skill, with its body
|
|
@@ -4648,15 +4790,15 @@ const Pa = function(l) {
|
|
|
4648
4790
|
*/
|
|
4649
4791
|
createStorageDestinationFileCleanup: async (r, a, n, e = {}) => {
|
|
4650
4792
|
m("createStorageDestinationFileCleanup", "environmentName", r), m("createStorageDestinationFileCleanup", "destinationName", a), m("createStorageDestinationFileCleanup", "storageFileCleanupRequest", n);
|
|
4651
|
-
const t = "/environments/{environmentName}/storageDestinations/{destinationName}/fileCleanups".replace("{environmentName}", encodeURIComponent(String(r))).replace("{destinationName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
4793
|
+
const t = "/environments/{environmentName}/storageDestinations/{destinationName}/fileCleanups".replace("{environmentName}", encodeURIComponent(String(r))).replace("{destinationName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
4652
4794
|
let o;
|
|
4653
4795
|
l && (o = l.baseOptions);
|
|
4654
|
-
const
|
|
4655
|
-
|
|
4796
|
+
const i = { method: "POST", ...o, ...e }, c = {}, p = {};
|
|
4797
|
+
c["Content-Type"] = "application/json", c.Accept = "application/json", v(s, p);
|
|
4656
4798
|
let d = o && o.headers ? o.headers : {};
|
|
4657
|
-
return
|
|
4658
|
-
url:
|
|
4659
|
-
options:
|
|
4799
|
+
return i.headers = { ...c, ...d, ...e.headers }, i.data = A(n, i, l), {
|
|
4800
|
+
url: V(s),
|
|
4801
|
+
options: i
|
|
4660
4802
|
};
|
|
4661
4803
|
},
|
|
4662
4804
|
/**
|
|
@@ -4672,15 +4814,15 @@ const Pa = function(l) {
|
|
|
4672
4814
|
*/
|
|
4673
4815
|
deleteStorageDestinationTable: async (r, a, n, e, t = {}) => {
|
|
4674
4816
|
m("deleteStorageDestinationTable", "environmentName", r), m("deleteStorageDestinationTable", "destinationName", a), m("deleteStorageDestinationTable", "schemaName", n), m("deleteStorageDestinationTable", "tableName", e);
|
|
4675
|
-
const s = "/environments/{environmentName}/storageDestinations/{destinationName}/schemas/{schemaName}/tables/{tableName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{destinationName}", encodeURIComponent(String(a))).replace("{schemaName}", encodeURIComponent(String(n))).replace("{tableName}", encodeURIComponent(String(e))), o = new URL(s,
|
|
4676
|
-
let
|
|
4677
|
-
l && (
|
|
4678
|
-
const
|
|
4817
|
+
const s = "/environments/{environmentName}/storageDestinations/{destinationName}/schemas/{schemaName}/tables/{tableName}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{destinationName}", encodeURIComponent(String(a))).replace("{schemaName}", encodeURIComponent(String(n))).replace("{tableName}", encodeURIComponent(String(e))), o = new URL(s, b);
|
|
4818
|
+
let i;
|
|
4819
|
+
l && (i = l.baseOptions);
|
|
4820
|
+
const c = { method: "DELETE", ...i, ...t }, p = {}, d = {};
|
|
4679
4821
|
p.Accept = "application/json", v(o, d);
|
|
4680
|
-
let h =
|
|
4681
|
-
return
|
|
4682
|
-
url:
|
|
4683
|
-
options:
|
|
4822
|
+
let h = i && i.headers ? i.headers : {};
|
|
4823
|
+
return c.headers = { ...p, ...h, ...t.headers }, {
|
|
4824
|
+
url: V(o),
|
|
4825
|
+
options: c
|
|
4684
4826
|
};
|
|
4685
4827
|
},
|
|
4686
4828
|
/**
|
|
@@ -4695,19 +4837,19 @@ const Pa = function(l) {
|
|
|
4695
4837
|
*/
|
|
4696
4838
|
listStorageDestinationTables: async (r, a, n, e = {}) => {
|
|
4697
4839
|
m("listStorageDestinationTables", "environmentName", r), m("listStorageDestinationTables", "destinationName", a), m("listStorageDestinationTables", "schemaName", n);
|
|
4698
|
-
const t = "/environments/{environmentName}/storageDestinations/{destinationName}/schemas/{schemaName}/tables".replace("{environmentName}", encodeURIComponent(String(r))).replace("{destinationName}", encodeURIComponent(String(a))).replace("{schemaName}", encodeURIComponent(String(n))), s = new URL(t,
|
|
4840
|
+
const t = "/environments/{environmentName}/storageDestinations/{destinationName}/schemas/{schemaName}/tables".replace("{environmentName}", encodeURIComponent(String(r))).replace("{destinationName}", encodeURIComponent(String(a))).replace("{schemaName}", encodeURIComponent(String(n))), s = new URL(t, b);
|
|
4699
4841
|
let o;
|
|
4700
4842
|
l && (o = l.baseOptions);
|
|
4701
|
-
const
|
|
4702
|
-
|
|
4843
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
4844
|
+
c.Accept = "application/json", v(s, p);
|
|
4703
4845
|
let d = o && o.headers ? o.headers : {};
|
|
4704
|
-
return
|
|
4705
|
-
url:
|
|
4706
|
-
options:
|
|
4846
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
4847
|
+
url: V(s),
|
|
4848
|
+
options: i
|
|
4707
4849
|
};
|
|
4708
4850
|
}
|
|
4709
4851
|
};
|
|
4710
|
-
},
|
|
4852
|
+
}, H = function(l) {
|
|
4711
4853
|
const r = Pa(l);
|
|
4712
4854
|
return {
|
|
4713
4855
|
/**
|
|
@@ -4721,8 +4863,8 @@ const Pa = function(l) {
|
|
|
4721
4863
|
* @throws {RequiredError}
|
|
4722
4864
|
*/
|
|
4723
4865
|
async createStorageDestinationFileCleanup(a, n, e, t) {
|
|
4724
|
-
const s = await r.createStorageDestinationFileCleanup(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
4725
|
-
return (
|
|
4866
|
+
const s = await r.createStorageDestinationFileCleanup(a, n, e, t), o = l?.serverIndex ?? 0, i = P["StorageDestinationsApi.createStorageDestinationFileCleanup"]?.[o]?.url;
|
|
4867
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
4726
4868
|
},
|
|
4727
4869
|
/**
|
|
4728
4870
|
* **DEPRECATED**: use the admin API\'s `DELETE /catalogs/{catalogName}/schemas/{schemaName}/tables/{tableName}` (`admin-api-doc.yaml`); this route is removed in a later release. Drops one named table from a storage destination. Idempotent: a table that does not exist answers 204 as well, so a retried drop is free. For a DuckLake destination this retires the table in the catalog; its data files stay in storage until a file cleanup reclaims them (see `create-storage-destination-file-cleanup`), which is also the window in which the table can still be read at an earlier snapshot.
|
|
@@ -4736,8 +4878,8 @@ const Pa = function(l) {
|
|
|
4736
4878
|
* @throws {RequiredError}
|
|
4737
4879
|
*/
|
|
4738
4880
|
async deleteStorageDestinationTable(a, n, e, t, s) {
|
|
4739
|
-
const o = await r.deleteStorageDestinationTable(a, n, e, t, s),
|
|
4740
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
4881
|
+
const o = await r.deleteStorageDestinationTable(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["StorageDestinationsApi.deleteStorageDestinationTable"]?.[i]?.url;
|
|
4882
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
4741
4883
|
},
|
|
4742
4884
|
/**
|
|
4743
4885
|
* **DEPRECATED**: use the admin API\'s `GET /catalogs/{catalogName}/schemas/{schemaName}/tables` (`admin-api-doc.yaml`); this route is removed in a later release. Lists the tables in one schema of a storage destination, in name order. Storage destinations are never reachable through the connection routes, so this is how an orchestrator finds tables it has lost track of. A DuckLake destination is attached read-only for the listing.
|
|
@@ -4750,12 +4892,12 @@ const Pa = function(l) {
|
|
|
4750
4892
|
* @throws {RequiredError}
|
|
4751
4893
|
*/
|
|
4752
4894
|
async listStorageDestinationTables(a, n, e, t) {
|
|
4753
|
-
const s = await r.listStorageDestinationTables(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
4754
|
-
return (
|
|
4895
|
+
const s = await r.listStorageDestinationTables(a, n, e, t), o = l?.serverIndex ?? 0, i = P["StorageDestinationsApi.listStorageDestinationTables"]?.[o]?.url;
|
|
4896
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
4755
4897
|
}
|
|
4756
4898
|
};
|
|
4757
|
-
},
|
|
4758
|
-
const n =
|
|
4899
|
+
}, Dn = function(l, r, a) {
|
|
4900
|
+
const n = H(l);
|
|
4759
4901
|
return {
|
|
4760
4902
|
/**
|
|
4761
4903
|
* **DEPRECATED**: use the admin API\'s `DELETE /catalogs/{catalogName}/snapshots?olderThan=…` (`admin-api-doc.yaml`), whose file-deletion grace is the catalog\'s own setting; this route is removed in a later release. Reclaims the object-storage bytes that dropped and rewritten tables leave behind in a DuckLake destination. Runs, in order: 1. `ducklake_expire_snapshots(older_than => snapshotsOlderThan)` — forgets snapshots older than the cutoff (never the latest) and schedules for deletion the files only they referenced. Snapshots that remain are what time travel can still read, so this cutoff is the recovery window for a dropped table. 2. `ducklake_cleanup_old_files(older_than => filesOlderThan)` — deletes the files scheduled for deletion before the cutoff. The age counts from when step 1 scheduled the file, so this protects readers still scanning a file from a snapshot that was just expired. Only files the catalog itself recorded and then retired are deleted. It does not run `CHECKPOINT` or `ducklake_delete_orphaned_files`, which also delete untracked files — another catalog\'s, when two share a data path, or a concurrent build\'s not-yet-committed output. Synchronous. Refused with 400 for a destination that is not DuckLake.
|
|
@@ -4768,7 +4910,7 @@ const Pa = function(l) {
|
|
|
4768
4910
|
* @throws {RequiredError}
|
|
4769
4911
|
*/
|
|
4770
4912
|
createStorageDestinationFileCleanup(e, t, s, o) {
|
|
4771
|
-
return n.createStorageDestinationFileCleanup(e, t, s, o).then((
|
|
4913
|
+
return n.createStorageDestinationFileCleanup(e, t, s, o).then((i) => i(a, r));
|
|
4772
4914
|
},
|
|
4773
4915
|
/**
|
|
4774
4916
|
* **DEPRECATED**: use the admin API\'s `DELETE /catalogs/{catalogName}/schemas/{schemaName}/tables/{tableName}` (`admin-api-doc.yaml`); this route is removed in a later release. Drops one named table from a storage destination. Idempotent: a table that does not exist answers 204 as well, so a retried drop is free. For a DuckLake destination this retires the table in the catalog; its data files stay in storage until a file cleanup reclaims them (see `create-storage-destination-file-cleanup`), which is also the window in which the table can still be read at an earlier snapshot.
|
|
@@ -4781,8 +4923,8 @@ const Pa = function(l) {
|
|
|
4781
4923
|
* @deprecated
|
|
4782
4924
|
* @throws {RequiredError}
|
|
4783
4925
|
*/
|
|
4784
|
-
deleteStorageDestinationTable(e, t, s, o,
|
|
4785
|
-
return n.deleteStorageDestinationTable(e, t, s, o,
|
|
4926
|
+
deleteStorageDestinationTable(e, t, s, o, i) {
|
|
4927
|
+
return n.deleteStorageDestinationTable(e, t, s, o, i).then((c) => c(a, r));
|
|
4786
4928
|
},
|
|
4787
4929
|
/**
|
|
4788
4930
|
* **DEPRECATED**: use the admin API\'s `GET /catalogs/{catalogName}/schemas/{schemaName}/tables` (`admin-api-doc.yaml`); this route is removed in a later release. Lists the tables in one schema of a storage destination, in name order. Storage destinations are never reachable through the connection routes, so this is how an orchestrator finds tables it has lost track of. A DuckLake destination is attached read-only for the listing.
|
|
@@ -4795,11 +4937,11 @@ const Pa = function(l) {
|
|
|
4795
4937
|
* @throws {RequiredError}
|
|
4796
4938
|
*/
|
|
4797
4939
|
listStorageDestinationTables(e, t, s, o) {
|
|
4798
|
-
return n.listStorageDestinationTables(e, t, s, o).then((
|
|
4940
|
+
return n.listStorageDestinationTables(e, t, s, o).then((i) => i(a, r));
|
|
4799
4941
|
}
|
|
4800
4942
|
};
|
|
4801
4943
|
};
|
|
4802
|
-
class
|
|
4944
|
+
class Ln extends I {
|
|
4803
4945
|
/**
|
|
4804
4946
|
* **DEPRECATED**: use the admin API\'s `DELETE /catalogs/{catalogName}/snapshots?olderThan=…` (`admin-api-doc.yaml`), whose file-deletion grace is the catalog\'s own setting; this route is removed in a later release. Reclaims the object-storage bytes that dropped and rewritten tables leave behind in a DuckLake destination. Runs, in order: 1. `ducklake_expire_snapshots(older_than => snapshotsOlderThan)` — forgets snapshots older than the cutoff (never the latest) and schedules for deletion the files only they referenced. Snapshots that remain are what time travel can still read, so this cutoff is the recovery window for a dropped table. 2. `ducklake_cleanup_old_files(older_than => filesOlderThan)` — deletes the files scheduled for deletion before the cutoff. The age counts from when step 1 scheduled the file, so this protects readers still scanning a file from a snapshot that was just expired. Only files the catalog itself recorded and then retired are deleted. It does not run `CHECKPOINT` or `ducklake_delete_orphaned_files`, which also delete untracked files — another catalog\'s, when two share a data path, or a concurrent build\'s not-yet-committed output. Synchronous. Refused with 400 for a destination that is not DuckLake.
|
|
4805
4947
|
* @summary Reclaim storage behind dropped tables in a DuckLake destination
|
|
@@ -4811,7 +4953,7 @@ class wn extends I {
|
|
|
4811
4953
|
* @throws {RequiredError}
|
|
4812
4954
|
*/
|
|
4813
4955
|
createStorageDestinationFileCleanup(r, a, n, e) {
|
|
4814
|
-
return
|
|
4956
|
+
return H(this.configuration).createStorageDestinationFileCleanup(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
4815
4957
|
}
|
|
4816
4958
|
/**
|
|
4817
4959
|
* **DEPRECATED**: use the admin API\'s `DELETE /catalogs/{catalogName}/schemas/{schemaName}/tables/{tableName}` (`admin-api-doc.yaml`); this route is removed in a later release. Drops one named table from a storage destination. Idempotent: a table that does not exist answers 204 as well, so a retried drop is free. For a DuckLake destination this retires the table in the catalog; its data files stay in storage until a file cleanup reclaims them (see `create-storage-destination-file-cleanup`), which is also the window in which the table can still be read at an earlier snapshot.
|
|
@@ -4825,7 +4967,7 @@ class wn extends I {
|
|
|
4825
4967
|
* @throws {RequiredError}
|
|
4826
4968
|
*/
|
|
4827
4969
|
deleteStorageDestinationTable(r, a, n, e, t) {
|
|
4828
|
-
return
|
|
4970
|
+
return H(this.configuration).deleteStorageDestinationTable(r, a, n, e, t).then((s) => s(this.axios, this.basePath));
|
|
4829
4971
|
}
|
|
4830
4972
|
/**
|
|
4831
4973
|
* **DEPRECATED**: use the admin API\'s `GET /catalogs/{catalogName}/schemas/{schemaName}/tables` (`admin-api-doc.yaml`); this route is removed in a later release. Lists the tables in one schema of a storage destination, in name order. Storage destinations are never reachable through the connection routes, so this is how an orchestrator finds tables it has lost track of. A DuckLake destination is attached read-only for the listing.
|
|
@@ -4838,10 +4980,10 @@ class wn extends I {
|
|
|
4838
4980
|
* @throws {RequiredError}
|
|
4839
4981
|
*/
|
|
4840
4982
|
listStorageDestinationTables(r, a, n, e) {
|
|
4841
|
-
return
|
|
4983
|
+
return H(this.configuration).listStorageDestinationTables(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
4842
4984
|
}
|
|
4843
4985
|
}
|
|
4844
|
-
const
|
|
4986
|
+
const ba = function(l) {
|
|
4845
4987
|
return {
|
|
4846
4988
|
/**
|
|
4847
4989
|
* Removes one version for good, where an archive only takes it out of service. The version is unloaded from memory, and its row and its files are deleted; other versions are untouched. Then, in the background, its own auto-runs still running are stopped and the tables its own auto-runs built under `scope: version` are reclaimed with their run records, as an archive reclaims them. Nothing is dropped before the delete commits, so a refused delete changes nothing. It cannot be undone, and it frees the version id: a later publish of the same version is a new version, with whatever content it carries. An archived version can be deleted too; that is how its files are reclaimed. Deleting the package\'s only version deletes the package with it (its row, run records and ledger), so no package is left with no version; while a publish of another version of the package is running, the package is left to that publish. Each table is tried once: one that could not be dropped is left. Tables another run of the package still references are kept, as is an orchestrated run (its tables, and a build of it still running), which the caller that instructed it owns. A delete is refused with 409 when: - the version is the package\'s `latest` and other versions remain (`reason` `VERSION_IS_LATEST`): move `latest` first; - it is the package\'s last version in service and archived versions remain (`reason` `VERSION_IS_LAST_ACTIVE`): a package that has versions always keeps one in service. Delete the archived versions first, or delete the package.
|
|
@@ -4854,15 +4996,15 @@ const Va = function(l) {
|
|
|
4854
4996
|
*/
|
|
4855
4997
|
deletePackageVersion: async (r, a, n, e = {}) => {
|
|
4856
4998
|
m("deletePackageVersion", "environmentName", r), m("deletePackageVersion", "packageName", a), m("deletePackageVersion", "version", n);
|
|
4857
|
-
const t = "/environments/{environmentName}/packages/{packageName}/versions/{version}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{version}", encodeURIComponent(String(n))), s = new URL(t,
|
|
4999
|
+
const t = "/environments/{environmentName}/packages/{packageName}/versions/{version}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{version}", encodeURIComponent(String(n))), s = new URL(t, b);
|
|
4858
5000
|
let o;
|
|
4859
5001
|
l && (o = l.baseOptions);
|
|
4860
|
-
const
|
|
4861
|
-
|
|
5002
|
+
const i = { method: "DELETE", ...o, ...e }, c = {}, p = {};
|
|
5003
|
+
c.Accept = "application/json", v(s, p);
|
|
4862
5004
|
let d = o && o.headers ? o.headers : {};
|
|
4863
|
-
return
|
|
4864
|
-
url:
|
|
4865
|
-
options:
|
|
5005
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
5006
|
+
url: V(s),
|
|
5007
|
+
options: i
|
|
4866
5008
|
};
|
|
4867
5009
|
},
|
|
4868
5010
|
/**
|
|
@@ -4876,15 +5018,15 @@ const Va = function(l) {
|
|
|
4876
5018
|
*/
|
|
4877
5019
|
getPackageVersion: async (r, a, n, e = {}) => {
|
|
4878
5020
|
m("getPackageVersion", "environmentName", r), m("getPackageVersion", "packageName", a), m("getPackageVersion", "version", n);
|
|
4879
|
-
const t = "/environments/{environmentName}/packages/{packageName}/versions/{version}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{version}", encodeURIComponent(String(n))), s = new URL(t,
|
|
5021
|
+
const t = "/environments/{environmentName}/packages/{packageName}/versions/{version}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{version}", encodeURIComponent(String(n))), s = new URL(t, b);
|
|
4880
5022
|
let o;
|
|
4881
5023
|
l && (o = l.baseOptions);
|
|
4882
|
-
const
|
|
4883
|
-
|
|
5024
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
5025
|
+
c.Accept = "application/json", v(s, p);
|
|
4884
5026
|
let d = o && o.headers ? o.headers : {};
|
|
4885
|
-
return
|
|
4886
|
-
url:
|
|
4887
|
-
options:
|
|
5027
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
5028
|
+
url: V(s),
|
|
5029
|
+
options: i
|
|
4888
5030
|
};
|
|
4889
5031
|
},
|
|
4890
5032
|
/**
|
|
@@ -4897,14 +5039,14 @@ const Va = function(l) {
|
|
|
4897
5039
|
*/
|
|
4898
5040
|
listPackageVersions: async (r, a, n = {}) => {
|
|
4899
5041
|
m("listPackageVersions", "environmentName", r), m("listPackageVersions", "packageName", a);
|
|
4900
|
-
const e = "/environments/{environmentName}/packages/{packageName}/versions".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), t = new URL(e,
|
|
5042
|
+
const e = "/environments/{environmentName}/packages/{packageName}/versions".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), t = new URL(e, b);
|
|
4901
5043
|
let s;
|
|
4902
5044
|
l && (s = l.baseOptions);
|
|
4903
|
-
const o = { method: "GET", ...s, ...n },
|
|
4904
|
-
|
|
5045
|
+
const o = { method: "GET", ...s, ...n }, i = {}, c = {};
|
|
5046
|
+
i.Accept = "application/json", v(t, c);
|
|
4905
5047
|
let p = s && s.headers ? s.headers : {};
|
|
4906
|
-
return o.headers = { ...
|
|
4907
|
-
url:
|
|
5048
|
+
return o.headers = { ...i, ...p, ...n.headers }, {
|
|
5049
|
+
url: V(t),
|
|
4908
5050
|
options: o
|
|
4909
5051
|
};
|
|
4910
5052
|
},
|
|
@@ -4919,19 +5061,19 @@ const Va = function(l) {
|
|
|
4919
5061
|
*/
|
|
4920
5062
|
setPackageLatestVersion: async (r, a, n, e = {}) => {
|
|
4921
5063
|
m("setPackageLatestVersion", "environmentName", r), m("setPackageLatestVersion", "packageName", a), m("setPackageLatestVersion", "packageLatestVersion", n);
|
|
4922
|
-
const t = "/environments/{environmentName}/packages/{packageName}/latest".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
5064
|
+
const t = "/environments/{environmentName}/packages/{packageName}/latest".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
4923
5065
|
let o;
|
|
4924
5066
|
l && (o = l.baseOptions);
|
|
4925
|
-
const
|
|
4926
|
-
|
|
5067
|
+
const i = { method: "PUT", ...o, ...e }, c = {}, p = {};
|
|
5068
|
+
c["Content-Type"] = "application/json", c.Accept = "application/json", v(s, p);
|
|
4927
5069
|
let d = o && o.headers ? o.headers : {};
|
|
4928
|
-
return
|
|
4929
|
-
url:
|
|
4930
|
-
options:
|
|
5070
|
+
return i.headers = { ...c, ...d, ...e.headers }, i.data = A(n, i, l), {
|
|
5071
|
+
url: V(s),
|
|
5072
|
+
options: i
|
|
4931
5073
|
};
|
|
4932
5074
|
},
|
|
4933
5075
|
/**
|
|
4934
|
-
* Sets the version\'s `manifestLocation`, the externally computed build manifest its persist references resolve through, and rebinds that version\'s models to it right away. A null `manifestLocation` clears the binding and the version serves live.
|
|
5076
|
+
* Sets the version\'s `manifestLocation`, the externally computed build manifest its persist references resolve through, and rebinds that version\'s models to it right away. Only this version is affected. A version is owned by the host from then on once a manifest it named, by this route or by a publish, has bound (one whose fetch fails marks nothing), or once a run it instructed with `buildInstructions` has run, even one whose commit failed. The version\'s record keeps that across an unload and a restart. A null `manifestLocation` then clears the binding and the version serves live: this server never binds tables its own runs built for it, so a host can clear the binding before it drops the tables the manifest named. A reload or restart of that version keeps it live until the host binds a manifest again, and the version answers a local run without `buildInstructions` with 409. Its status reports it the way it reports a version with nothing bound: `manifestBindingStatus` `unbound`, `manifestEntryCount` 0 and `boundManifestUri` null. A version no host has bound (standalone, or built only by this server\'s own runs) serves what this server\'s own runs built for it when its binding is cleared, or live when they built nothing, as it does when it loads. This is serving state, not package content, which is why it is the one thing about a published version that can change. It replaces the deprecated `PATCH .../packages/{packageName}` for rebinding a manifest. An absent `manifestLocation` (an empty body, `{}`) clears the binding too, as null does: a PUT replaces the binding, and many generated clients drop a null field from the JSON they send. `manifestLocation` is the body\'s only field, so any other field is refused with 400 naming it, rather than read as a clear.
|
|
4935
5077
|
* @summary Bind a version to a build manifest
|
|
4936
5078
|
* @param {string} environmentName Name of the environment
|
|
4937
5079
|
* @param {string} packageName Name of the package
|
|
@@ -4942,15 +5084,15 @@ const Va = function(l) {
|
|
|
4942
5084
|
*/
|
|
4943
5085
|
setPackageVersionManifest: async (r, a, n, e, t = {}) => {
|
|
4944
5086
|
m("setPackageVersionManifest", "environmentName", r), m("setPackageVersionManifest", "packageName", a), m("setPackageVersionManifest", "version", n), m("setPackageVersionManifest", "packageVersionManifest", e);
|
|
4945
|
-
const s = "/environments/{environmentName}/packages/{packageName}/versions/{version}/manifest".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{version}", encodeURIComponent(String(n))), o = new URL(s,
|
|
4946
|
-
let
|
|
4947
|
-
l && (
|
|
4948
|
-
const
|
|
5087
|
+
const s = "/environments/{environmentName}/packages/{packageName}/versions/{version}/manifest".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{version}", encodeURIComponent(String(n))), o = new URL(s, b);
|
|
5088
|
+
let i;
|
|
5089
|
+
l && (i = l.baseOptions);
|
|
5090
|
+
const c = { method: "PUT", ...i, ...t }, p = {}, d = {};
|
|
4949
5091
|
p["Content-Type"] = "application/json", p.Accept = "application/json", v(o, d);
|
|
4950
|
-
let h =
|
|
4951
|
-
return
|
|
4952
|
-
url:
|
|
4953
|
-
options:
|
|
5092
|
+
let h = i && i.headers ? i.headers : {};
|
|
5093
|
+
return c.headers = { ...p, ...h, ...t.headers }, c.data = A(e, c, l), {
|
|
5094
|
+
url: V(o),
|
|
5095
|
+
options: c
|
|
4954
5096
|
};
|
|
4955
5097
|
},
|
|
4956
5098
|
/**
|
|
@@ -4965,20 +5107,20 @@ const Va = function(l) {
|
|
|
4965
5107
|
*/
|
|
4966
5108
|
updatePackageVersion: async (r, a, n, e, t = {}) => {
|
|
4967
5109
|
m("updatePackageVersion", "environmentName", r), m("updatePackageVersion", "packageName", a), m("updatePackageVersion", "version", n), m("updatePackageVersion", "packageVersionUpdate", e);
|
|
4968
|
-
const s = "/environments/{environmentName}/packages/{packageName}/versions/{version}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{version}", encodeURIComponent(String(n))), o = new URL(s,
|
|
4969
|
-
let
|
|
4970
|
-
l && (
|
|
4971
|
-
const
|
|
5110
|
+
const s = "/environments/{environmentName}/packages/{packageName}/versions/{version}".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))).replace("{version}", encodeURIComponent(String(n))), o = new URL(s, b);
|
|
5111
|
+
let i;
|
|
5112
|
+
l && (i = l.baseOptions);
|
|
5113
|
+
const c = { method: "PATCH", ...i, ...t }, p = {}, d = {};
|
|
4972
5114
|
p["Content-Type"] = "application/json", p.Accept = "application/json", v(o, d);
|
|
4973
|
-
let h =
|
|
4974
|
-
return
|
|
4975
|
-
url:
|
|
4976
|
-
options:
|
|
5115
|
+
let h = i && i.headers ? i.headers : {};
|
|
5116
|
+
return c.headers = { ...p, ...h, ...t.headers }, c.data = A(e, c, l), {
|
|
5117
|
+
url: V(o),
|
|
5118
|
+
options: c
|
|
4977
5119
|
};
|
|
4978
5120
|
}
|
|
4979
5121
|
};
|
|
4980
|
-
},
|
|
4981
|
-
const r =
|
|
5122
|
+
}, E = function(l) {
|
|
5123
|
+
const r = ba(l);
|
|
4982
5124
|
return {
|
|
4983
5125
|
/**
|
|
4984
5126
|
* Removes one version for good, where an archive only takes it out of service. The version is unloaded from memory, and its row and its files are deleted; other versions are untouched. Then, in the background, its own auto-runs still running are stopped and the tables its own auto-runs built under `scope: version` are reclaimed with their run records, as an archive reclaims them. Nothing is dropped before the delete commits, so a refused delete changes nothing. It cannot be undone, and it frees the version id: a later publish of the same version is a new version, with whatever content it carries. An archived version can be deleted too; that is how its files are reclaimed. Deleting the package\'s only version deletes the package with it (its row, run records and ledger), so no package is left with no version; while a publish of another version of the package is running, the package is left to that publish. Each table is tried once: one that could not be dropped is left. Tables another run of the package still references are kept, as is an orchestrated run (its tables, and a build of it still running), which the caller that instructed it owns. A delete is refused with 409 when: - the version is the package\'s `latest` and other versions remain (`reason` `VERSION_IS_LATEST`): move `latest` first; - it is the package\'s last version in service and archived versions remain (`reason` `VERSION_IS_LAST_ACTIVE`): a package that has versions always keeps one in service. Delete the archived versions first, or delete the package.
|
|
@@ -4990,8 +5132,8 @@ const Va = function(l) {
|
|
|
4990
5132
|
* @throws {RequiredError}
|
|
4991
5133
|
*/
|
|
4992
5134
|
async deletePackageVersion(a, n, e, t) {
|
|
4993
|
-
const s = await r.deletePackageVersion(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
4994
|
-
return (
|
|
5135
|
+
const s = await r.deletePackageVersion(a, n, e, t), o = l?.serverIndex ?? 0, i = P["VersionsApi.deletePackageVersion"]?.[o]?.url;
|
|
5136
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
4995
5137
|
},
|
|
4996
5138
|
/**
|
|
4997
5139
|
* Returns one published version, archived or not. An unknown version answers 404 with `reason` `VERSION_NOT_FOUND`.
|
|
@@ -5003,8 +5145,8 @@ const Va = function(l) {
|
|
|
5003
5145
|
* @throws {RequiredError}
|
|
5004
5146
|
*/
|
|
5005
5147
|
async getPackageVersion(a, n, e, t) {
|
|
5006
|
-
const s = await r.getPackageVersion(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
5007
|
-
return (
|
|
5148
|
+
const s = await r.getPackageVersion(a, n, e, t), o = l?.serverIndex ?? 0, i = P["VersionsApi.getPackageVersion"]?.[o]?.url;
|
|
5149
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
5008
5150
|
},
|
|
5009
5151
|
/**
|
|
5010
5152
|
* Lists every version published to the package, highest version first, including archived ones (marked by `archiveStatus`). The entry marked `latest` is the version served when a request names no `versionId`. An unversioned package (one registered from a directory, mounted in a watched environment, or loaded or published with versioning off) has no versions and returns an empty list.
|
|
@@ -5016,7 +5158,7 @@ const Va = function(l) {
|
|
|
5016
5158
|
*/
|
|
5017
5159
|
async listPackageVersions(a, n, e) {
|
|
5018
5160
|
const t = await r.listPackageVersions(a, n, e), s = l?.serverIndex ?? 0, o = P["VersionsApi.listPackageVersions"]?.[s]?.url;
|
|
5019
|
-
return (
|
|
5161
|
+
return (i, c) => S(t, u, g, l)(i, o || c);
|
|
5020
5162
|
},
|
|
5021
5163
|
/**
|
|
5022
5164
|
* Makes the named version the package\'s `latest`: the version served to every request that names no `versionId`. Nothing is rebuilt or re-fetched; the pointer moves. Pointing it at an earlier version is a rollback, and the next publish still moves `latest` under `versionPromotion: \"on-publish\"`. This is the only way `latest` moves when the server runs with `versionPromotion: \"explicit\"`, the mode for an orchestrator that decides when a version is ready to serve. The version must exist and must not be archived (404 `VERSION_NOT_FOUND`, 410 `VERSION_ARCHIVED`), and it is loaded before the pointer moves: a version that fails to load is refused with that load\'s error, and `latest` stays where it was.
|
|
@@ -5028,11 +5170,11 @@ const Va = function(l) {
|
|
|
5028
5170
|
* @throws {RequiredError}
|
|
5029
5171
|
*/
|
|
5030
5172
|
async setPackageLatestVersion(a, n, e, t) {
|
|
5031
|
-
const s = await r.setPackageLatestVersion(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
5032
|
-
return (
|
|
5173
|
+
const s = await r.setPackageLatestVersion(a, n, e, t), o = l?.serverIndex ?? 0, i = P["VersionsApi.setPackageLatestVersion"]?.[o]?.url;
|
|
5174
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
5033
5175
|
},
|
|
5034
5176
|
/**
|
|
5035
|
-
* Sets the version\'s `manifestLocation`, the externally computed build manifest its persist references resolve through, and rebinds that version\'s models to it right away. A null `manifestLocation` clears the binding and the version serves live.
|
|
5177
|
+
* Sets the version\'s `manifestLocation`, the externally computed build manifest its persist references resolve through, and rebinds that version\'s models to it right away. Only this version is affected. A version is owned by the host from then on once a manifest it named, by this route or by a publish, has bound (one whose fetch fails marks nothing), or once a run it instructed with `buildInstructions` has run, even one whose commit failed. The version\'s record keeps that across an unload and a restart. A null `manifestLocation` then clears the binding and the version serves live: this server never binds tables its own runs built for it, so a host can clear the binding before it drops the tables the manifest named. A reload or restart of that version keeps it live until the host binds a manifest again, and the version answers a local run without `buildInstructions` with 409. Its status reports it the way it reports a version with nothing bound: `manifestBindingStatus` `unbound`, `manifestEntryCount` 0 and `boundManifestUri` null. A version no host has bound (standalone, or built only by this server\'s own runs) serves what this server\'s own runs built for it when its binding is cleared, or live when they built nothing, as it does when it loads. This is serving state, not package content, which is why it is the one thing about a published version that can change. It replaces the deprecated `PATCH .../packages/{packageName}` for rebinding a manifest. An absent `manifestLocation` (an empty body, `{}`) clears the binding too, as null does: a PUT replaces the binding, and many generated clients drop a null field from the JSON they send. `manifestLocation` is the body\'s only field, so any other field is refused with 400 naming it, rather than read as a clear.
|
|
5036
5178
|
* @summary Bind a version to a build manifest
|
|
5037
5179
|
* @param {string} environmentName Name of the environment
|
|
5038
5180
|
* @param {string} packageName Name of the package
|
|
@@ -5042,8 +5184,8 @@ const Va = function(l) {
|
|
|
5042
5184
|
* @throws {RequiredError}
|
|
5043
5185
|
*/
|
|
5044
5186
|
async setPackageVersionManifest(a, n, e, t, s) {
|
|
5045
|
-
const o = await r.setPackageVersionManifest(a, n, e, t, s),
|
|
5046
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
5187
|
+
const o = await r.setPackageVersionManifest(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["VersionsApi.setPackageVersionManifest"]?.[i]?.url;
|
|
5188
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
5047
5189
|
},
|
|
5048
5190
|
/**
|
|
5049
5191
|
* Changes a version\'s lifecycle state. Content is never edited here: a published version is immutable. - `archive` takes the version out of service: reads and queries that name it answer 410 with `reason` `VERSION_ARCHIVED`, and it is unloaded from memory. The tables its own auto-runs built under `scope: version` are reclaimed in the background, with their run records; tables another version\'s run still references are kept, and so are an orchestrated run\'s, whose names and lifetime the caller that assigned them owns. Each table is tried once: one that cannot be dropped is left, and its run record goes all the same. Its files stay on disk, so it can be unarchived. To remove them, delete the version with `DELETE .../versions/{version}`. - `unarchive` puts it back in service. It loads again on its next read, and serves live until it is built again. Archiving stops the version\'s materialization schedule, if it has one, and unarchiving starts it again. An archive is refused with 409 when: - the version is the package\'s `latest` (`reason` `VERSION_IS_LATEST`): move `latest` first; - it is the package\'s last version in service (`reason` `VERSION_IS_LAST_ACTIVE`): a package always keeps one. To take the whole package out of service, delete it; - a materialization of that version is running (`reason` `VERSION_BUILDING`), since the archive would reclaim the tables that run is writing. A run that starts after the archive fails, and what it built is reclaimed when it ends. Sending the state the version is already in changes nothing and answers 200.
|
|
@@ -5056,12 +5198,12 @@ const Va = function(l) {
|
|
|
5056
5198
|
* @throws {RequiredError}
|
|
5057
5199
|
*/
|
|
5058
5200
|
async updatePackageVersion(a, n, e, t, s) {
|
|
5059
|
-
const o = await r.updatePackageVersion(a, n, e, t, s),
|
|
5060
|
-
return (p, d) => S(o, u, g, l)(p,
|
|
5201
|
+
const o = await r.updatePackageVersion(a, n, e, t, s), i = l?.serverIndex ?? 0, c = P["VersionsApi.updatePackageVersion"]?.[i]?.url;
|
|
5202
|
+
return (p, d) => S(o, u, g, l)(p, c || d);
|
|
5061
5203
|
}
|
|
5062
5204
|
};
|
|
5063
|
-
},
|
|
5064
|
-
const n =
|
|
5205
|
+
}, zn = function(l, r, a) {
|
|
5206
|
+
const n = E(l);
|
|
5065
5207
|
return {
|
|
5066
5208
|
/**
|
|
5067
5209
|
* Removes one version for good, where an archive only takes it out of service. The version is unloaded from memory, and its row and its files are deleted; other versions are untouched. Then, in the background, its own auto-runs still running are stopped and the tables its own auto-runs built under `scope: version` are reclaimed with their run records, as an archive reclaims them. Nothing is dropped before the delete commits, so a refused delete changes nothing. It cannot be undone, and it frees the version id: a later publish of the same version is a new version, with whatever content it carries. An archived version can be deleted too; that is how its files are reclaimed. Deleting the package\'s only version deletes the package with it (its row, run records and ledger), so no package is left with no version; while a publish of another version of the package is running, the package is left to that publish. Each table is tried once: one that could not be dropped is left. Tables another run of the package still references are kept, as is an orchestrated run (its tables, and a build of it still running), which the caller that instructed it owns. A delete is refused with 409 when: - the version is the package\'s `latest` and other versions remain (`reason` `VERSION_IS_LATEST`): move `latest` first; - it is the package\'s last version in service and archived versions remain (`reason` `VERSION_IS_LAST_ACTIVE`): a package that has versions always keeps one in service. Delete the archived versions first, or delete the package.
|
|
@@ -5073,7 +5215,7 @@ const Va = function(l) {
|
|
|
5073
5215
|
* @throws {RequiredError}
|
|
5074
5216
|
*/
|
|
5075
5217
|
deletePackageVersion(e, t, s, o) {
|
|
5076
|
-
return n.deletePackageVersion(e, t, s, o).then((
|
|
5218
|
+
return n.deletePackageVersion(e, t, s, o).then((i) => i(a, r));
|
|
5077
5219
|
},
|
|
5078
5220
|
/**
|
|
5079
5221
|
* Returns one published version, archived or not. An unknown version answers 404 with `reason` `VERSION_NOT_FOUND`.
|
|
@@ -5085,7 +5227,7 @@ const Va = function(l) {
|
|
|
5085
5227
|
* @throws {RequiredError}
|
|
5086
5228
|
*/
|
|
5087
5229
|
getPackageVersion(e, t, s, o) {
|
|
5088
|
-
return n.getPackageVersion(e, t, s, o).then((
|
|
5230
|
+
return n.getPackageVersion(e, t, s, o).then((i) => i(a, r));
|
|
5089
5231
|
},
|
|
5090
5232
|
/**
|
|
5091
5233
|
* Lists every version published to the package, highest version first, including archived ones (marked by `archiveStatus`). The entry marked `latest` is the version served when a request names no `versionId`. An unversioned package (one registered from a directory, mounted in a watched environment, or loaded or published with versioning off) has no versions and returns an empty list.
|
|
@@ -5108,10 +5250,10 @@ const Va = function(l) {
|
|
|
5108
5250
|
* @throws {RequiredError}
|
|
5109
5251
|
*/
|
|
5110
5252
|
setPackageLatestVersion(e, t, s, o) {
|
|
5111
|
-
return n.setPackageLatestVersion(e, t, s, o).then((
|
|
5253
|
+
return n.setPackageLatestVersion(e, t, s, o).then((i) => i(a, r));
|
|
5112
5254
|
},
|
|
5113
5255
|
/**
|
|
5114
|
-
* Sets the version\'s `manifestLocation`, the externally computed build manifest its persist references resolve through, and rebinds that version\'s models to it right away. A null `manifestLocation` clears the binding and the version serves live.
|
|
5256
|
+
* Sets the version\'s `manifestLocation`, the externally computed build manifest its persist references resolve through, and rebinds that version\'s models to it right away. Only this version is affected. A version is owned by the host from then on once a manifest it named, by this route or by a publish, has bound (one whose fetch fails marks nothing), or once a run it instructed with `buildInstructions` has run, even one whose commit failed. The version\'s record keeps that across an unload and a restart. A null `manifestLocation` then clears the binding and the version serves live: this server never binds tables its own runs built for it, so a host can clear the binding before it drops the tables the manifest named. A reload or restart of that version keeps it live until the host binds a manifest again, and the version answers a local run without `buildInstructions` with 409. Its status reports it the way it reports a version with nothing bound: `manifestBindingStatus` `unbound`, `manifestEntryCount` 0 and `boundManifestUri` null. A version no host has bound (standalone, or built only by this server\'s own runs) serves what this server\'s own runs built for it when its binding is cleared, or live when they built nothing, as it does when it loads. This is serving state, not package content, which is why it is the one thing about a published version that can change. It replaces the deprecated `PATCH .../packages/{packageName}` for rebinding a manifest. An absent `manifestLocation` (an empty body, `{}`) clears the binding too, as null does: a PUT replaces the binding, and many generated clients drop a null field from the JSON they send. `manifestLocation` is the body\'s only field, so any other field is refused with 400 naming it, rather than read as a clear.
|
|
5115
5257
|
* @summary Bind a version to a build manifest
|
|
5116
5258
|
* @param {string} environmentName Name of the environment
|
|
5117
5259
|
* @param {string} packageName Name of the package
|
|
@@ -5120,8 +5262,8 @@ const Va = function(l) {
|
|
|
5120
5262
|
* @param {*} [options] Override http request option.
|
|
5121
5263
|
* @throws {RequiredError}
|
|
5122
5264
|
*/
|
|
5123
|
-
setPackageVersionManifest(e, t, s, o,
|
|
5124
|
-
return n.setPackageVersionManifest(e, t, s, o,
|
|
5265
|
+
setPackageVersionManifest(e, t, s, o, i) {
|
|
5266
|
+
return n.setPackageVersionManifest(e, t, s, o, i).then((c) => c(a, r));
|
|
5125
5267
|
},
|
|
5126
5268
|
/**
|
|
5127
5269
|
* Changes a version\'s lifecycle state. Content is never edited here: a published version is immutable. - `archive` takes the version out of service: reads and queries that name it answer 410 with `reason` `VERSION_ARCHIVED`, and it is unloaded from memory. The tables its own auto-runs built under `scope: version` are reclaimed in the background, with their run records; tables another version\'s run still references are kept, and so are an orchestrated run\'s, whose names and lifetime the caller that assigned them owns. Each table is tried once: one that cannot be dropped is left, and its run record goes all the same. Its files stay on disk, so it can be unarchived. To remove them, delete the version with `DELETE .../versions/{version}`. - `unarchive` puts it back in service. It loads again on its next read, and serves live until it is built again. Archiving stops the version\'s materialization schedule, if it has one, and unarchiving starts it again. An archive is refused with 409 when: - the version is the package\'s `latest` (`reason` `VERSION_IS_LATEST`): move `latest` first; - it is the package\'s last version in service (`reason` `VERSION_IS_LAST_ACTIVE`): a package always keeps one. To take the whole package out of service, delete it; - a materialization of that version is running (`reason` `VERSION_BUILDING`), since the archive would reclaim the tables that run is writing. A run that starts after the archive fails, and what it built is reclaimed when it ends. Sending the state the version is already in changes nothing and answers 200.
|
|
@@ -5133,8 +5275,8 @@ const Va = function(l) {
|
|
|
5133
5275
|
* @param {*} [options] Override http request option.
|
|
5134
5276
|
* @throws {RequiredError}
|
|
5135
5277
|
*/
|
|
5136
|
-
updatePackageVersion(e, t, s, o,
|
|
5137
|
-
return n.updatePackageVersion(e, t, s, o,
|
|
5278
|
+
updatePackageVersion(e, t, s, o, i) {
|
|
5279
|
+
return n.updatePackageVersion(e, t, s, o, i).then((c) => c(a, r));
|
|
5138
5280
|
}
|
|
5139
5281
|
};
|
|
5140
5282
|
};
|
|
@@ -5149,7 +5291,7 @@ class va extends I {
|
|
|
5149
5291
|
* @throws {RequiredError}
|
|
5150
5292
|
*/
|
|
5151
5293
|
deletePackageVersion(r, a, n, e) {
|
|
5152
|
-
return
|
|
5294
|
+
return E(this.configuration).deletePackageVersion(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
5153
5295
|
}
|
|
5154
5296
|
/**
|
|
5155
5297
|
* Returns one published version, archived or not. An unknown version answers 404 with `reason` `VERSION_NOT_FOUND`.
|
|
@@ -5161,7 +5303,7 @@ class va extends I {
|
|
|
5161
5303
|
* @throws {RequiredError}
|
|
5162
5304
|
*/
|
|
5163
5305
|
getPackageVersion(r, a, n, e) {
|
|
5164
|
-
return
|
|
5306
|
+
return E(this.configuration).getPackageVersion(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
5165
5307
|
}
|
|
5166
5308
|
/**
|
|
5167
5309
|
* Lists every version published to the package, highest version first, including archived ones (marked by `archiveStatus`). The entry marked `latest` is the version served when a request names no `versionId`. An unversioned package (one registered from a directory, mounted in a watched environment, or loaded or published with versioning off) has no versions and returns an empty list.
|
|
@@ -5172,7 +5314,7 @@ class va extends I {
|
|
|
5172
5314
|
* @throws {RequiredError}
|
|
5173
5315
|
*/
|
|
5174
5316
|
listPackageVersions(r, a, n) {
|
|
5175
|
-
return
|
|
5317
|
+
return E(this.configuration).listPackageVersions(r, a, n).then((e) => e(this.axios, this.basePath));
|
|
5176
5318
|
}
|
|
5177
5319
|
/**
|
|
5178
5320
|
* Makes the named version the package\'s `latest`: the version served to every request that names no `versionId`. Nothing is rebuilt or re-fetched; the pointer moves. Pointing it at an earlier version is a rollback, and the next publish still moves `latest` under `versionPromotion: \"on-publish\"`. This is the only way `latest` moves when the server runs with `versionPromotion: \"explicit\"`, the mode for an orchestrator that decides when a version is ready to serve. The version must exist and must not be archived (404 `VERSION_NOT_FOUND`, 410 `VERSION_ARCHIVED`), and it is loaded before the pointer moves: a version that fails to load is refused with that load\'s error, and `latest` stays where it was.
|
|
@@ -5184,10 +5326,10 @@ class va extends I {
|
|
|
5184
5326
|
* @throws {RequiredError}
|
|
5185
5327
|
*/
|
|
5186
5328
|
setPackageLatestVersion(r, a, n, e) {
|
|
5187
|
-
return
|
|
5329
|
+
return E(this.configuration).setPackageLatestVersion(r, a, n, e).then((t) => t(this.axios, this.basePath));
|
|
5188
5330
|
}
|
|
5189
5331
|
/**
|
|
5190
|
-
* Sets the version\'s `manifestLocation`, the externally computed build manifest its persist references resolve through, and rebinds that version\'s models to it right away. A null `manifestLocation` clears the binding and the version serves live.
|
|
5332
|
+
* Sets the version\'s `manifestLocation`, the externally computed build manifest its persist references resolve through, and rebinds that version\'s models to it right away. Only this version is affected. A version is owned by the host from then on once a manifest it named, by this route or by a publish, has bound (one whose fetch fails marks nothing), or once a run it instructed with `buildInstructions` has run, even one whose commit failed. The version\'s record keeps that across an unload and a restart. A null `manifestLocation` then clears the binding and the version serves live: this server never binds tables its own runs built for it, so a host can clear the binding before it drops the tables the manifest named. A reload or restart of that version keeps it live until the host binds a manifest again, and the version answers a local run without `buildInstructions` with 409. Its status reports it the way it reports a version with nothing bound: `manifestBindingStatus` `unbound`, `manifestEntryCount` 0 and `boundManifestUri` null. A version no host has bound (standalone, or built only by this server\'s own runs) serves what this server\'s own runs built for it when its binding is cleared, or live when they built nothing, as it does when it loads. This is serving state, not package content, which is why it is the one thing about a published version that can change. It replaces the deprecated `PATCH .../packages/{packageName}` for rebinding a manifest. An absent `manifestLocation` (an empty body, `{}`) clears the binding too, as null does: a PUT replaces the binding, and many generated clients drop a null field from the JSON they send. `manifestLocation` is the body\'s only field, so any other field is refused with 400 naming it, rather than read as a clear.
|
|
5191
5333
|
* @summary Bind a version to a build manifest
|
|
5192
5334
|
* @param {string} environmentName Name of the environment
|
|
5193
5335
|
* @param {string} packageName Name of the package
|
|
@@ -5197,7 +5339,7 @@ class va extends I {
|
|
|
5197
5339
|
* @throws {RequiredError}
|
|
5198
5340
|
*/
|
|
5199
5341
|
setPackageVersionManifest(r, a, n, e, t) {
|
|
5200
|
-
return
|
|
5342
|
+
return E(this.configuration).setPackageVersionManifest(r, a, n, e, t).then((s) => s(this.axios, this.basePath));
|
|
5201
5343
|
}
|
|
5202
5344
|
/**
|
|
5203
5345
|
* Changes a version\'s lifecycle state. Content is never edited here: a published version is immutable. - `archive` takes the version out of service: reads and queries that name it answer 410 with `reason` `VERSION_ARCHIVED`, and it is unloaded from memory. The tables its own auto-runs built under `scope: version` are reclaimed in the background, with their run records; tables another version\'s run still references are kept, and so are an orchestrated run\'s, whose names and lifetime the caller that assigned them owns. Each table is tried once: one that cannot be dropped is left, and its run record goes all the same. Its files stay on disk, so it can be unarchived. To remove them, delete the version with `DELETE .../versions/{version}`. - `unarchive` puts it back in service. It loads again on its next read, and serves live until it is built again. Archiving stops the version\'s materialization schedule, if it has one, and unarchiving starts it again. An archive is refused with 409 when: - the version is the package\'s `latest` (`reason` `VERSION_IS_LATEST`): move `latest` first; - it is the package\'s last version in service (`reason` `VERSION_IS_LAST_ACTIVE`): a package always keeps one. To take the whole package out of service, delete it; - a materialization of that version is running (`reason` `VERSION_BUILDING`), since the archive would reclaim the tables that run is writing. A run that starts after the archive fails, and what it built is reclaimed when it ends. Sending the state the version is already in changes nothing and answers 200.
|
|
@@ -5210,10 +5352,10 @@ class va extends I {
|
|
|
5210
5352
|
* @throws {RequiredError}
|
|
5211
5353
|
*/
|
|
5212
5354
|
updatePackageVersion(r, a, n, e, t) {
|
|
5213
|
-
return
|
|
5355
|
+
return E(this.configuration).updatePackageVersion(r, a, n, e, t).then((s) => s(this.axios, this.basePath));
|
|
5214
5356
|
}
|
|
5215
5357
|
}
|
|
5216
|
-
const
|
|
5358
|
+
const Va = function(l) {
|
|
5217
5359
|
return {
|
|
5218
5360
|
/**
|
|
5219
5361
|
* **DEPRECATED**: use the admin API\'s `GET /watch-mode` (`admin-api-doc.yaml`); watch mode is an operator\'s control, not part of serving. This route is removed in a later release. Retrieves the current status of the file watching system. This includes whether watch mode is enabled, which environment is being watched, and the path being monitored. Useful for monitoring the development workflow and ensuring file changes are being detected.
|
|
@@ -5223,14 +5365,14 @@ const ba = function(l) {
|
|
|
5223
5365
|
* @throws {RequiredError}
|
|
5224
5366
|
*/
|
|
5225
5367
|
getWatchStatus: async (r = {}) => {
|
|
5226
|
-
const a = "/watch-mode/status", n = new URL(a,
|
|
5368
|
+
const a = "/watch-mode/status", n = new URL(a, b);
|
|
5227
5369
|
let e;
|
|
5228
5370
|
l && (e = l.baseOptions);
|
|
5229
5371
|
const t = { method: "GET", ...e, ...r }, s = {}, o = {};
|
|
5230
5372
|
s.Accept = "application/json", v(n, o);
|
|
5231
|
-
let
|
|
5232
|
-
return t.headers = { ...s, ...
|
|
5233
|
-
url:
|
|
5373
|
+
let i = e && e.headers ? e.headers : {};
|
|
5374
|
+
return t.headers = { ...s, ...i, ...r.headers }, {
|
|
5375
|
+
url: V(n),
|
|
5234
5376
|
options: t
|
|
5235
5377
|
};
|
|
5236
5378
|
},
|
|
@@ -5244,14 +5386,14 @@ const ba = function(l) {
|
|
|
5244
5386
|
*/
|
|
5245
5387
|
startWatching: async (r, a = {}) => {
|
|
5246
5388
|
m("startWatching", "startWatchRequest", r);
|
|
5247
|
-
const n = "/watch-mode/start", e = new URL(n,
|
|
5389
|
+
const n = "/watch-mode/start", e = new URL(n, b);
|
|
5248
5390
|
let t;
|
|
5249
5391
|
l && (t = l.baseOptions);
|
|
5250
|
-
const s = { method: "POST", ...t, ...a }, o = {},
|
|
5251
|
-
o["Content-Type"] = "application/json", o.Accept = "application/json", v(e,
|
|
5252
|
-
let
|
|
5253
|
-
return s.headers = { ...o, ...
|
|
5254
|
-
url:
|
|
5392
|
+
const s = { method: "POST", ...t, ...a }, o = {}, i = {};
|
|
5393
|
+
o["Content-Type"] = "application/json", o.Accept = "application/json", v(e, i);
|
|
5394
|
+
let c = t && t.headers ? t.headers : {};
|
|
5395
|
+
return s.headers = { ...o, ...c, ...a.headers }, s.data = A(r, s, l), {
|
|
5396
|
+
url: V(e),
|
|
5255
5397
|
options: s
|
|
5256
5398
|
};
|
|
5257
5399
|
},
|
|
@@ -5263,14 +5405,14 @@ const ba = function(l) {
|
|
|
5263
5405
|
* @throws {RequiredError}
|
|
5264
5406
|
*/
|
|
5265
5407
|
stopWatching: async (r = {}) => {
|
|
5266
|
-
const a = "/watch-mode/stop", n = new URL(a,
|
|
5408
|
+
const a = "/watch-mode/stop", n = new URL(a, b);
|
|
5267
5409
|
let e;
|
|
5268
5410
|
l && (e = l.baseOptions);
|
|
5269
5411
|
const t = { method: "POST", ...e, ...r }, s = {}, o = {};
|
|
5270
5412
|
s.Accept = "application/json", v(n, o);
|
|
5271
|
-
let
|
|
5272
|
-
return t.headers = { ...s, ...
|
|
5273
|
-
url:
|
|
5413
|
+
let i = e && e.headers ? e.headers : {};
|
|
5414
|
+
return t.headers = { ...s, ...i, ...r.headers }, {
|
|
5415
|
+
url: V(n),
|
|
5274
5416
|
options: t
|
|
5275
5417
|
};
|
|
5276
5418
|
},
|
|
@@ -5285,20 +5427,20 @@ const ba = function(l) {
|
|
|
5285
5427
|
*/
|
|
5286
5428
|
streamPackageEvents: async (r, a, n, e = {}) => {
|
|
5287
5429
|
m("streamPackageEvents", "environmentName", r), m("streamPackageEvents", "packageName", a);
|
|
5288
|
-
const t = "/environments/{environmentName}/packages/{packageName}/events".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t,
|
|
5430
|
+
const t = "/environments/{environmentName}/packages/{packageName}/events".replace("{environmentName}", encodeURIComponent(String(r))).replace("{packageName}", encodeURIComponent(String(a))), s = new URL(t, b);
|
|
5289
5431
|
let o;
|
|
5290
5432
|
l && (o = l.baseOptions);
|
|
5291
|
-
const
|
|
5292
|
-
n !== void 0 && (p.versionId = n),
|
|
5433
|
+
const i = { method: "GET", ...o, ...e }, c = {}, p = {};
|
|
5434
|
+
n !== void 0 && (p.versionId = n), c.Accept = "text/event-stream,application/json", v(s, p);
|
|
5293
5435
|
let d = o && o.headers ? o.headers : {};
|
|
5294
|
-
return
|
|
5295
|
-
url:
|
|
5296
|
-
options:
|
|
5436
|
+
return i.headers = { ...c, ...d, ...e.headers }, {
|
|
5437
|
+
url: V(s),
|
|
5438
|
+
options: i
|
|
5297
5439
|
};
|
|
5298
5440
|
}
|
|
5299
5441
|
};
|
|
5300
5442
|
}, L = function(l) {
|
|
5301
|
-
const r =
|
|
5443
|
+
const r = Va(l);
|
|
5302
5444
|
return {
|
|
5303
5445
|
/**
|
|
5304
5446
|
* **DEPRECATED**: use the admin API\'s `GET /watch-mode` (`admin-api-doc.yaml`); watch mode is an operator\'s control, not part of serving. This route is removed in a later release. Retrieves the current status of the file watching system. This includes whether watch mode is enabled, which environment is being watched, and the path being monitored. Useful for monitoring the development workflow and ensuring file changes are being detected.
|
|
@@ -5321,7 +5463,7 @@ const ba = function(l) {
|
|
|
5321
5463
|
*/
|
|
5322
5464
|
async startWatching(a, n) {
|
|
5323
5465
|
const e = await r.startWatching(a, n), t = l?.serverIndex ?? 0, s = P["WatchModeApi.startWatching"]?.[t]?.url;
|
|
5324
|
-
return (o,
|
|
5466
|
+
return (o, i) => S(e, u, g, l)(o, s || i);
|
|
5325
5467
|
},
|
|
5326
5468
|
/**
|
|
5327
5469
|
* **DEPRECATED**: use the admin API\'s `DELETE /watch-mode` (`admin-api-doc.yaml`); watch mode is an operator\'s control, not part of serving. This route is removed in a later release. Stops the current file watching session. This disables real-time monitoring of file changes and releases system resources. Use this when development is complete or when switching to a different environment.
|
|
@@ -5344,11 +5486,11 @@ const ba = function(l) {
|
|
|
5344
5486
|
* @throws {RequiredError}
|
|
5345
5487
|
*/
|
|
5346
5488
|
async streamPackageEvents(a, n, e, t) {
|
|
5347
|
-
const s = await r.streamPackageEvents(a, n, e, t), o = l?.serverIndex ?? 0,
|
|
5348
|
-
return (
|
|
5489
|
+
const s = await r.streamPackageEvents(a, n, e, t), o = l?.serverIndex ?? 0, i = P["WatchModeApi.streamPackageEvents"]?.[o]?.url;
|
|
5490
|
+
return (c, p) => S(s, u, g, l)(c, i || p);
|
|
5349
5491
|
}
|
|
5350
5492
|
};
|
|
5351
|
-
},
|
|
5493
|
+
}, Qn = function(l, r, a) {
|
|
5352
5494
|
const n = L(l);
|
|
5353
5495
|
return {
|
|
5354
5496
|
/**
|
|
@@ -5392,7 +5534,7 @@ const ba = function(l) {
|
|
|
5392
5534
|
* @throws {RequiredError}
|
|
5393
5535
|
*/
|
|
5394
5536
|
streamPackageEvents(e, t, s, o) {
|
|
5395
|
-
return n.streamPackageEvents(e, t, s, o).then((
|
|
5537
|
+
return n.streamPackageEvents(e, t, s, o).then((i) => i(a, r));
|
|
5396
5538
|
}
|
|
5397
5539
|
};
|
|
5398
5540
|
};
|
|
@@ -5533,7 +5675,7 @@ const Oa = new ye({
|
|
|
5533
5675
|
throwOnError: !1
|
|
5534
5676
|
}
|
|
5535
5677
|
}
|
|
5536
|
-
}),
|
|
5678
|
+
}), _n = {
|
|
5537
5679
|
staleTime: 300 * 1e3,
|
|
5538
5680
|
refetchOnWindowFocus: !1,
|
|
5539
5681
|
refetchOnReconnect: !1
|
|
@@ -5566,11 +5708,11 @@ function Ia(l) {
|
|
|
5566
5708
|
} catch {
|
|
5567
5709
|
}
|
|
5568
5710
|
}
|
|
5569
|
-
function
|
|
5711
|
+
function Ra() {
|
|
5570
5712
|
return typeof window > "u" || !window.matchMedia ? !1 : window.matchMedia("(prefers-color-scheme: dark)").matches;
|
|
5571
5713
|
}
|
|
5572
5714
|
u.defaults.baseURL || (u.defaults.baseURL = "IfYouAreSeeingThis_baseURL_IsNotSet");
|
|
5573
|
-
const Pe =
|
|
5715
|
+
const Pe = ce(void 0), xa = (l, r, a) => {
|
|
5574
5716
|
const n = `${window.location.protocol}//${window.location.host}/api/v0`, e = u.create({
|
|
5575
5717
|
baseURL: l || n,
|
|
5576
5718
|
withCredentials: !0,
|
|
@@ -5587,7 +5729,7 @@ const Pe = ie(void 0), Ra = (l, r, a) => {
|
|
|
5587
5729
|
publisher: new ma(t, n, e),
|
|
5588
5730
|
environments: new ta(t, n, e),
|
|
5589
5731
|
packages: new pa(t, n, e),
|
|
5590
|
-
agents: new
|
|
5732
|
+
agents: new He(t, n, e),
|
|
5591
5733
|
dashboards: new Ye(t, n, e),
|
|
5592
5734
|
dataApps: new Ze(t, n, e),
|
|
5593
5735
|
notebooks: new la(t, n, e),
|
|
@@ -5602,7 +5744,7 @@ const Pe = ie(void 0), Ra = (l, r, a) => {
|
|
|
5602
5744
|
watchMode: new Sa(t, n, e),
|
|
5603
5745
|
versions: new va(t, n, e)
|
|
5604
5746
|
};
|
|
5605
|
-
},
|
|
5747
|
+
}, qn = (l) => /* @__PURE__ */ z(Ce, { client: Oa, children: /* @__PURE__ */ z(Na, { ...l }) }), Na = ({
|
|
5606
5748
|
children: l,
|
|
5607
5749
|
getAccessToken: r,
|
|
5608
5750
|
baseURL: a,
|
|
@@ -5612,16 +5754,16 @@ const Pe = ie(void 0), Ra = (l, r, a) => {
|
|
|
5612
5754
|
adapter: s,
|
|
5613
5755
|
mode: o
|
|
5614
5756
|
}) => {
|
|
5615
|
-
const
|
|
5616
|
-
() =>
|
|
5757
|
+
const i = B(
|
|
5758
|
+
() => xa(a, r, s),
|
|
5617
5759
|
[a, r, s]
|
|
5618
|
-
),
|
|
5619
|
-
queryKey: ["status",
|
|
5760
|
+
), c = a || `${window.location.protocol}//${window.location.host}/api/v0`, p = Ie({
|
|
5761
|
+
queryKey: ["status", c],
|
|
5620
5762
|
// Retried, unlike the client's other reads: the model page depends on
|
|
5621
5763
|
// the answer for the whole session, and one dropped request would
|
|
5622
5764
|
// otherwise settle it.
|
|
5623
5765
|
retry: 3,
|
|
5624
|
-
queryFn: async () => (await
|
|
5766
|
+
queryFn: async () => (await i.publisher.getStatus()).data
|
|
5625
5767
|
});
|
|
5626
5768
|
p.error && console.error("Failed to fetch publisher status:", p.error);
|
|
5627
5769
|
const d = p.data?.frozenConfig, h = p.data?.theme, { modelPage: k, isLoadingStatus: O } = ya(p);
|
|
@@ -5630,17 +5772,17 @@ const Pe = ie(void 0), Ra = (l, r, a) => {
|
|
|
5630
5772
|
const N = B(
|
|
5631
5773
|
() => [h, e],
|
|
5632
5774
|
[h, e]
|
|
5633
|
-
), [
|
|
5775
|
+
), [be, ve] = oe(
|
|
5634
5776
|
Ca
|
|
5635
|
-
), [te,
|
|
5636
|
-
|
|
5777
|
+
), [te, Ve] = oe(Ra);
|
|
5778
|
+
Re(() => {
|
|
5637
5779
|
if (typeof window > "u" || !window.matchMedia) return;
|
|
5638
|
-
const
|
|
5639
|
-
return
|
|
5780
|
+
const w = window.matchMedia("(prefers-color-scheme: dark)"), re = (Ae) => Ve(Ae.matches);
|
|
5781
|
+
return w.addEventListener("change", re), () => w.removeEventListener("change", re);
|
|
5640
5782
|
}, []);
|
|
5641
|
-
const Se =
|
|
5642
|
-
ve(
|
|
5643
|
-
}, []), ne = h?.allowUserToggle ?? !0, G = ne ?
|
|
5783
|
+
const Se = xe((w) => {
|
|
5784
|
+
ve(w), Ia(w);
|
|
5785
|
+
}, []), ne = h?.allowUserToggle ?? !0, G = ne ? be : void 0, ke = B(
|
|
5644
5786
|
() => o ?? Le(
|
|
5645
5787
|
h?.defaultMode,
|
|
5646
5788
|
G,
|
|
@@ -5648,16 +5790,16 @@ const Pe = ie(void 0), Ra = (l, r, a) => {
|
|
|
5648
5790
|
),
|
|
5649
5791
|
[o, h?.defaultMode, G, te]
|
|
5650
5792
|
), Oe = {
|
|
5651
|
-
server:
|
|
5793
|
+
server: c,
|
|
5652
5794
|
getAccessToken: r,
|
|
5653
|
-
apiClients:
|
|
5795
|
+
apiClients: i,
|
|
5654
5796
|
mutable: y,
|
|
5655
5797
|
isLoadingStatus: O,
|
|
5656
5798
|
instanceTheme: h,
|
|
5657
5799
|
modelPage: k
|
|
5658
5800
|
};
|
|
5659
|
-
return /* @__PURE__ */
|
|
5660
|
-
|
|
5801
|
+
return /* @__PURE__ */ z(Pe.Provider, { value: Oe, children: /* @__PURE__ */ z(
|
|
5802
|
+
ze,
|
|
5661
5803
|
{
|
|
5662
5804
|
layers: N,
|
|
5663
5805
|
mode: ke,
|
|
@@ -5668,7 +5810,7 @@ const Pe = ie(void 0), Ra = (l, r, a) => {
|
|
|
5668
5810
|
children: l
|
|
5669
5811
|
}
|
|
5670
5812
|
) });
|
|
5671
|
-
},
|
|
5813
|
+
}, Hn = () => {
|
|
5672
5814
|
const l = le(Pe);
|
|
5673
5815
|
if (l === void 0)
|
|
5674
5816
|
throw new Error("useServer must be used within a ServerProvider");
|
|
@@ -5676,153 +5818,159 @@ const Pe = ie(void 0), Ra = (l, r, a) => {
|
|
|
5676
5818
|
};
|
|
5677
5819
|
export {
|
|
5678
5820
|
gt as $,
|
|
5679
|
-
|
|
5821
|
+
He as A,
|
|
5680
5822
|
Z as B,
|
|
5681
5823
|
Ka as C,
|
|
5682
5824
|
nt as D,
|
|
5683
5825
|
ot as E,
|
|
5684
5826
|
Ze as F,
|
|
5685
5827
|
Je as G,
|
|
5686
|
-
|
|
5828
|
+
In as H,
|
|
5687
5829
|
ue as I,
|
|
5688
5830
|
st as J,
|
|
5689
5831
|
ea as K,
|
|
5690
5832
|
Xe as L,
|
|
5691
|
-
|
|
5833
|
+
Rn as M,
|
|
5692
5834
|
ge as N,
|
|
5693
5835
|
ta as O,
|
|
5694
5836
|
aa as P,
|
|
5695
|
-
|
|
5696
|
-
|
|
5697
|
-
|
|
5698
|
-
|
|
5837
|
+
xn as Q,
|
|
5838
|
+
M as R,
|
|
5839
|
+
fn as S,
|
|
5840
|
+
it as T,
|
|
5699
5841
|
lt as U,
|
|
5700
|
-
|
|
5701
|
-
|
|
5842
|
+
kn as V,
|
|
5843
|
+
ct as W,
|
|
5702
5844
|
pt as X,
|
|
5703
5845
|
dt as Y,
|
|
5704
5846
|
ut as Z,
|
|
5705
5847
|
mt as _,
|
|
5706
|
-
|
|
5707
|
-
|
|
5848
|
+
qe as a,
|
|
5849
|
+
tn as a$,
|
|
5708
5850
|
ht as a0,
|
|
5709
|
-
|
|
5851
|
+
Un as a1,
|
|
5710
5852
|
Pt as a2,
|
|
5711
|
-
|
|
5712
|
-
|
|
5713
|
-
|
|
5714
|
-
|
|
5715
|
-
|
|
5716
|
-
|
|
5717
|
-
|
|
5853
|
+
bt as a3,
|
|
5854
|
+
ra as a4,
|
|
5855
|
+
na as a5,
|
|
5856
|
+
Nn as a6,
|
|
5857
|
+
T as a7,
|
|
5858
|
+
vt as a8,
|
|
5859
|
+
sa as a9,
|
|
5718
5860
|
jt as aA,
|
|
5719
5861
|
Dt as aB,
|
|
5720
|
-
|
|
5721
|
-
|
|
5722
|
-
|
|
5723
|
-
|
|
5724
|
-
|
|
5725
|
-
|
|
5726
|
-
|
|
5727
|
-
|
|
5728
|
-
|
|
5729
|
-
|
|
5730
|
-
|
|
5731
|
-
|
|
5732
|
-
|
|
5733
|
-
|
|
5862
|
+
Lt as aC,
|
|
5863
|
+
pa as aD,
|
|
5864
|
+
ca as aE,
|
|
5865
|
+
wn as aF,
|
|
5866
|
+
x as aG,
|
|
5867
|
+
zt as aH,
|
|
5868
|
+
Qt as aI,
|
|
5869
|
+
ma as aJ,
|
|
5870
|
+
da as aK,
|
|
5871
|
+
Mn as aL,
|
|
5872
|
+
D as aM,
|
|
5873
|
+
_t as aN,
|
|
5874
|
+
qt as aO,
|
|
5875
|
+
Ht as aP,
|
|
5734
5876
|
Gt as aQ,
|
|
5735
5877
|
Wt as aR,
|
|
5736
5878
|
Kt as aS,
|
|
5737
5879
|
$t as aT,
|
|
5738
|
-
|
|
5739
|
-
|
|
5740
|
-
|
|
5741
|
-
|
|
5880
|
+
Yt as aU,
|
|
5881
|
+
Jt as aV,
|
|
5882
|
+
Zt as aW,
|
|
5883
|
+
Xt as aX,
|
|
5742
5884
|
en as aY,
|
|
5743
5885
|
an as aZ,
|
|
5744
|
-
|
|
5745
|
-
|
|
5746
|
-
|
|
5747
|
-
|
|
5748
|
-
|
|
5749
|
-
|
|
5750
|
-
|
|
5751
|
-
|
|
5752
|
-
|
|
5753
|
-
|
|
5754
|
-
|
|
5755
|
-
|
|
5756
|
-
|
|
5757
|
-
|
|
5758
|
-
|
|
5759
|
-
|
|
5760
|
-
|
|
5761
|
-
|
|
5762
|
-
|
|
5886
|
+
nn as a_,
|
|
5887
|
+
oa as aa,
|
|
5888
|
+
Tn as ab,
|
|
5889
|
+
F as ac,
|
|
5890
|
+
St as ad,
|
|
5891
|
+
Ot as ae,
|
|
5892
|
+
kt as af,
|
|
5893
|
+
Vt as ag,
|
|
5894
|
+
la as ah,
|
|
5895
|
+
ia as ai,
|
|
5896
|
+
En as aj,
|
|
5897
|
+
q as ak,
|
|
5898
|
+
At as al,
|
|
5899
|
+
xt as am,
|
|
5900
|
+
Nt as an,
|
|
5901
|
+
Rt as ao,
|
|
5902
|
+
It as ap,
|
|
5903
|
+
Ct as aq,
|
|
5904
|
+
yt as ar,
|
|
5763
5905
|
Ut as as,
|
|
5764
5906
|
Tt as at,
|
|
5765
|
-
|
|
5907
|
+
Et as au,
|
|
5766
5908
|
Ft as av,
|
|
5767
|
-
|
|
5768
|
-
|
|
5769
|
-
|
|
5770
|
-
|
|
5771
|
-
|
|
5772
|
-
|
|
5773
|
-
|
|
5774
|
-
|
|
5775
|
-
|
|
5776
|
-
|
|
5777
|
-
|
|
5778
|
-
|
|
5779
|
-
|
|
5780
|
-
|
|
5781
|
-
|
|
5782
|
-
|
|
5783
|
-
|
|
5784
|
-
|
|
5785
|
-
|
|
5786
|
-
|
|
5787
|
-
|
|
5788
|
-
|
|
5789
|
-
|
|
5790
|
-
|
|
5791
|
-
|
|
5792
|
-
|
|
5793
|
-
|
|
5794
|
-
|
|
5795
|
-
|
|
5796
|
-
|
|
5797
|
-
|
|
5798
|
-
|
|
5799
|
-
|
|
5800
|
-
|
|
5801
|
-
|
|
5802
|
-
|
|
5803
|
-
|
|
5804
|
-
|
|
5805
|
-
|
|
5806
|
-
|
|
5807
|
-
|
|
5808
|
-
|
|
5809
|
-
|
|
5810
|
-
|
|
5811
|
-
|
|
5812
|
-
|
|
5813
|
-
|
|
5814
|
-
|
|
5815
|
-
|
|
5816
|
-
|
|
5817
|
-
|
|
5818
|
-
|
|
5819
|
-
|
|
5820
|
-
|
|
5821
|
-
|
|
5822
|
-
|
|
5823
|
-
|
|
5824
|
-
|
|
5825
|
-
|
|
5909
|
+
Bt as aw,
|
|
5910
|
+
Mt as ax,
|
|
5911
|
+
wt as ay,
|
|
5912
|
+
ft as az,
|
|
5913
|
+
Sn as b,
|
|
5914
|
+
on as b0,
|
|
5915
|
+
rn as b1,
|
|
5916
|
+
sn as b2,
|
|
5917
|
+
ln as b3,
|
|
5918
|
+
ua as b4,
|
|
5919
|
+
ha as b5,
|
|
5920
|
+
Fn as b6,
|
|
5921
|
+
X as b7,
|
|
5922
|
+
cn as b8,
|
|
5923
|
+
pn as b9,
|
|
5924
|
+
Oa as bA,
|
|
5925
|
+
Ha as bB,
|
|
5926
|
+
Hn as bC,
|
|
5927
|
+
De as bD,
|
|
5928
|
+
de as bE,
|
|
5929
|
+
qa as bF,
|
|
5930
|
+
U as bG,
|
|
5931
|
+
Fa as bH,
|
|
5932
|
+
Ma as bI,
|
|
5933
|
+
R as bJ,
|
|
5934
|
+
La as bK,
|
|
5935
|
+
Da as bL,
|
|
5936
|
+
za as bM,
|
|
5937
|
+
Qa as bN,
|
|
5938
|
+
Ba as bO,
|
|
5939
|
+
ja as bP,
|
|
5940
|
+
Y as bQ,
|
|
5941
|
+
ze as bR,
|
|
5942
|
+
ie as bS,
|
|
5943
|
+
_a as bT,
|
|
5944
|
+
Ee as bU,
|
|
5945
|
+
Le as bV,
|
|
5946
|
+
_n as bW,
|
|
5947
|
+
qn as ba,
|
|
5948
|
+
un as bb,
|
|
5949
|
+
dn as bc,
|
|
5950
|
+
mn as bd,
|
|
5951
|
+
hn as be,
|
|
5952
|
+
gn as bf,
|
|
5953
|
+
Pn as bg,
|
|
5954
|
+
jn as bh,
|
|
5955
|
+
ga as bi,
|
|
5956
|
+
Bn as bj,
|
|
5957
|
+
ee as bk,
|
|
5958
|
+
bn as bl,
|
|
5959
|
+
Ln as bm,
|
|
5960
|
+
Pa as bn,
|
|
5961
|
+
Dn as bo,
|
|
5962
|
+
H as bp,
|
|
5963
|
+
vn as bq,
|
|
5964
|
+
Vn as br,
|
|
5965
|
+
va as bs,
|
|
5966
|
+
ba as bt,
|
|
5967
|
+
zn as bu,
|
|
5968
|
+
E as bv,
|
|
5969
|
+
Sa as bw,
|
|
5970
|
+
Va as bx,
|
|
5971
|
+
Qn as by,
|
|
5972
|
+
L as bz,
|
|
5973
|
+
_ as c,
|
|
5826
5974
|
Ga as d,
|
|
5827
5975
|
Wa as e,
|
|
5828
5976
|
$a as f,
|
|
@@ -5835,15 +5983,15 @@ export {
|
|
|
5835
5983
|
Xa as m,
|
|
5836
5984
|
We as n,
|
|
5837
5985
|
Ge as o,
|
|
5838
|
-
|
|
5986
|
+
On as p,
|
|
5839
5987
|
C as q,
|
|
5840
|
-
|
|
5988
|
+
yn as r,
|
|
5841
5989
|
Ke as s,
|
|
5842
|
-
|
|
5990
|
+
An as t,
|
|
5843
5991
|
he as u,
|
|
5844
5992
|
tt as v,
|
|
5845
5993
|
rt as w,
|
|
5846
5994
|
Ye as x,
|
|
5847
5995
|
$e as y,
|
|
5848
|
-
|
|
5996
|
+
Cn as z
|
|
5849
5997
|
};
|