@metabase/client 0.1.1 → 0.1.3
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/CHANGELOG.md +11 -0
- package/README.md +5 -3
- package/dist/auth/credential.d.ts +1 -1
- package/dist/auth/oauth-login.d.ts +1 -1
- package/dist/auth/oauth-login.js +1 -1
- package/dist/auth/oauth-session.d.ts +1 -1
- package/dist/{card-BxBzr5Uj.d.ts → card-BBLDmhtp.d.ts} +1 -1
- package/dist/{card-DN0sLkCG.d.ts → card-DkHtPMK4.d.ts} +3 -3
- package/dist/{client-DdXLlH1B.d.ts → client-eOkt3tTd.d.ts} +100 -82
- package/dist/client.d.ts +1 -1
- package/dist/{collection-DGnTvD6R.d.ts → collection-BtjnSckn.d.ts} +10 -10
- package/dist/{collection-fFahL-ub.d.ts → collection-DWjkDrln.d.ts} +4 -4
- package/dist/{credential-6aOEGqMH.d.ts → credential-B6fKSvqp.d.ts} +1 -1
- package/dist/{dashboard-CM7RmNeE.d.ts → dashboard-B4qWeR10.d.ts} +1 -1
- package/dist/{data-action-CkXVrOUH.d.ts → data-action-DqwcRA7B.d.ts} +61 -10
- package/dist/{database-B0JNZjDN.d.ts → database-Cw8ICtQi.d.ts} +3 -3
- package/dist/{database-BxqDmfcj.d.ts → database-DULVEXki.d.ts} +1 -1
- package/dist/{dataset-BUirJ1rO.d.ts → dataset-26H-dH4N.d.ts} +3 -3
- package/dist/{dataset-BBNGPVec.d.ts → dataset-Du1GRHhd.d.ts} +6 -6
- package/dist/{dependency-arB8Cr2H.d.ts → dependency-B8aPt_IM.d.ts} +33 -33
- package/dist/{dependency-CzpXmeu7.d.ts → dependency-elYkHuk5.d.ts} +25 -25
- package/dist/{document-tLd6pYWe.d.ts → document-rqUlE_OE.d.ts} +1 -1
- package/dist/domain/card.d.ts +1 -1
- package/dist/domain/collection.d.ts +1 -1
- package/dist/domain/data-action.d.ts +2 -2
- package/dist/domain/data-action.js +43 -10
- package/dist/domain/database.d.ts +1 -1
- package/dist/domain/dataset.d.ts +1 -1
- package/dist/domain/dependency.d.ts +1 -1
- package/dist/domain/document.d.ts +1 -1
- package/dist/domain/eid-translation.d.ts +1 -1
- package/dist/domain/field.d.ts +1 -1
- package/dist/domain/git-sync.d.ts +1 -1
- package/dist/domain/metric.d.ts +1 -1
- package/dist/domain/replacement.d.ts +1 -1
- package/dist/domain/revision.d.ts +1 -1
- package/dist/domain/search.d.ts +1 -1
- package/dist/domain/table.d.ts +1 -1
- package/dist/domain/timeline.d.ts +1 -1
- package/dist/domain/transform-inspector.d.ts +1 -1
- package/dist/{eid-translation-CH6NPWd-.d.ts → eid-translation-CP79Tz71.d.ts} +5 -5
- package/dist/{erd-CbV7xvAc.d.ts → erd-D2fpjDTj.d.ts} +1 -1
- package/dist/errors.d.ts +1 -1
- package/dist/{field-p9Rme2zB.d.ts → field-D-kF3G7v.d.ts} +2 -2
- package/dist/{field-D1Pfk-0S.d.ts → field-awM3Y7IP.d.ts} +2 -2
- package/dist/{git-sync-BTf1aYHr.d.ts → git-sync-8Tk8TirZ.d.ts} +1 -1
- package/dist/{git-sync-C99SVdJ9.d.ts → git-sync-nvbSaNfS.d.ts} +1 -1
- package/dist/{glossary-DFvnz-E5.d.ts → glossary-CQMSJmIx.d.ts} +1 -1
- package/dist/http/errors.d.ts +1 -1
- package/dist/http/oauth.d.ts +1 -1
- package/dist/http/oauth.js +47 -36
- package/dist/http/transport.d.ts +1 -1
- package/dist/index.d.ts +26 -26
- package/dist/index.js +3 -3
- package/dist/{json-BksZpXDC.d.ts → json-DvOVLFVY.d.ts} +1 -1
- package/dist/json.d.ts +1 -1
- package/dist/{measure-lPz8qnwz.d.ts → measure-D4ArCbsa.d.ts} +1 -1
- package/dist/{metric-DcYloqOQ.d.ts → metric-BtEVH_Yp.d.ts} +1 -1
- package/dist/{notification-Cp5GJErS.d.ts → notification-BsuPAfMW.d.ts} +1 -1
- package/dist/{oauth-C4ordeoJ.d.ts → oauth-CVoZpuq8.d.ts} +4 -2
- package/dist/{oauth-login-D734Jvbq.js → oauth-login--tDagiZu.js} +29 -11
- package/dist/{oauth-login-CJsT_3EE.d.ts → oauth-login-SZ4Csai8.d.ts} +3 -2
- package/dist/{oauth-session-BlIlcd8Q.d.ts → oauth-session-COLH4puN.d.ts} +1 -1
- package/dist/{paginate-COuL0Gzl.d.ts → paginate-Du9kUbXZ.d.ts} +1 -1
- package/dist/paginate.d.ts +1 -1
- package/dist/{pulse-BzKmz3Yn.d.ts → pulse-drQKS_pg.d.ts} +1 -1
- package/dist/{replacement-BGyggp-G.d.ts → replacement-CyvtbxGg.d.ts} +5 -5
- package/dist/{replacement-CVebCuNp.d.ts → replacement-g3IKzPPj.d.ts} +5 -5
- package/dist/{requirement-check-glU7wqhQ.d.ts → requirement-check-Nv0trVbp.d.ts} +1 -1
- package/dist/resources/api-key.d.ts +1 -1
- package/dist/resources/card.d.ts +1 -1
- package/dist/resources/collection.d.ts +1 -1
- package/dist/resources/collection.js +6 -1
- package/dist/resources/content-translation.d.ts +1 -1
- package/dist/resources/dashboard.d.ts +1 -1
- package/dist/resources/data-action.d.ts +22 -4
- package/dist/resources/data-action.js +10 -5
- package/dist/resources/data-app.d.ts +1 -1
- package/dist/resources/database.d.ts +1 -1
- package/dist/resources/dataset.d.ts +1 -1
- package/dist/resources/dependency.d.ts +1 -1
- package/dist/resources/document.d.ts +2 -2
- package/dist/resources/eid-translation.d.ts +2 -2
- package/dist/resources/erd.d.ts +1 -1
- package/dist/resources/field.d.ts +1 -1
- package/dist/resources/git-sync.d.ts +1 -1
- package/dist/resources/glossary.d.ts +1 -1
- package/dist/resources/library.d.ts +1 -1
- package/dist/resources/measure.d.ts +1 -1
- package/dist/resources/metric.d.ts +1 -1
- package/dist/resources/moderation-review.d.ts +1 -1
- package/dist/resources/notification.d.ts +1 -1
- package/dist/resources/optional-parsed.d.ts +1 -1
- package/dist/resources/permission.d.ts +1 -1
- package/dist/resources/pivot-export.d.ts +1 -1
- package/dist/resources/pulse.d.ts +1 -1
- package/dist/resources/replacement.d.ts +1 -1
- package/dist/resources/revision.d.ts +3 -3
- package/dist/resources/search.d.ts +1 -1
- package/dist/resources/segment.d.ts +1 -1
- package/dist/resources/setting.d.ts +1 -1
- package/dist/resources/setup.d.ts +1 -1
- package/dist/resources/snippet.d.ts +1 -1
- package/dist/resources/table.d.ts +1 -1
- package/dist/resources/timeline-event.d.ts +2 -2
- package/dist/resources/timeline.d.ts +1 -1
- package/dist/resources/transform-dag-run.d.ts +1 -1
- package/dist/resources/transform-inspector.d.ts +2 -2
- package/dist/resources/transform-job.d.ts +1 -1
- package/dist/resources/transform-python.d.ts +1 -1
- package/dist/resources/transform-tag.d.ts +1 -1
- package/dist/resources/transform-test.d.ts +1 -1
- package/dist/resources/transform.d.ts +1 -1
- package/dist/resources/upload.d.ts +1 -1
- package/dist/resources/user.d.ts +1 -1
- package/dist/{revision-Dyl-8p7d.d.ts → revision-Cft5Lcev.d.ts} +4 -4
- package/dist/{search-Cm5IxKss.d.ts → search-BUr4r7d2.d.ts} +5 -5
- package/dist/{search-Cten2h0I.d.ts → search-DX1IVRRC.d.ts} +2 -2
- package/dist/{segment-DQLX6r1E.d.ts → segment-c2EDEJNd.d.ts} +1 -1
- package/dist/signal.d.ts +3 -2
- package/dist/signal.js +9 -4
- package/dist/{snippet-Djn0rL21.d.ts → snippet-CSt-f812.d.ts} +1 -1
- package/dist/{table-CDZbLNow.d.ts → table-BA-k8Zgt.d.ts} +6 -6
- package/dist/{table-Od6uvDVW.d.ts → table-R-q8w__K.d.ts} +10 -10
- package/dist/{timeline-BK45hy-h.d.ts → timeline-B35sx1FM.d.ts} +31 -31
- package/dist/{timeline-BTs6fuRp.d.ts → timeline-D3Clk0_n.d.ts} +2 -2
- package/dist/{transform-WASQAXeA.d.ts → transform-DzgPup_a.d.ts} +2 -2
- package/dist/{transform-inspector-CMCh8WKV.d.ts → transform-inspector-BUYBt6--.d.ts} +4 -4
- package/dist/{transform-job-DmTwKxhc.d.ts → transform-job-DtLWrsyH.d.ts} +1 -1
- package/dist/{transform-test-CR_i54IV.d.ts → transform-test-B_HR-yKA.d.ts} +1 -1
- package/dist/{transport-BsXqRujn.d.ts → transport-CyHAGDqx.d.ts} +1 -1
- package/dist/{upload-B5YjVkSW.d.ts → upload-BSixoElJ.d.ts} +1 -1
- package/dist/version/capability-error.d.ts +1 -1
- package/dist/version/probe.d.ts +1 -1
- package/dist/version/profile.d.ts +1 -1
- package/dist/version/requirement-check.d.ts +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,17 @@
|
|
|
2
2
|
|
|
3
3
|
Notable changes to `@metabase/client`.
|
|
4
4
|
|
|
5
|
+
## 0.1.3
|
|
6
|
+
|
|
7
|
+
- `dataAction.create` creates an implicit action on a table as well as a query action. `DataActionCreateInput` is a union on `type`: a `"query"` body takes `dataset_query`, an `"implicit"` one takes `kind` (`ImplicitActionKind`, on the barrel) and `table_id`. Neither takes `database_id`, which the server derives from the query.
|
|
8
|
+
- `DataActionUpdateInput` patches a query action's `dataset_query` or an implicit action's `kind` and `table_id`, never both, and takes no `database_id`. `dataAction.update` refuses a `table_id` before the request on a server without `dataActionsWithoutModel`, which would drop it unread; `DATA_ACTION_TABLE_GATE` records the gate.
|
|
9
|
+
- `DataAction` and `DataActionCompact` read an implicit action's `kind` and `table_id`.
|
|
10
|
+
- `DataActionExecuteResult` reads an implicit action's `rows-updated`, `rows-deleted` or `created-row`, and `rows-affected` is optional.
|
|
11
|
+
|
|
12
|
+
## 0.1.2
|
|
13
|
+
|
|
14
|
+
- `oauthLogin` takes an optional `signal`. Aborting it, before or during the flow, rejects with the signal's reason when that is a `MetabaseError`, else with an `AbortError` carrying its message, frees the loopback callback port at once, and cancels discovery, client registration or the token exchange in flight. `tryDiscoverMetadata`, `discoverLoginMetadata`, `registerClient` and `exchangeCode` on `@metabase/client/http/oauth` take a signal too, and `@metabase/client/signal` exports `whenAborted`.
|
|
15
|
+
|
|
5
16
|
## 0.1.1
|
|
6
17
|
|
|
7
18
|
- `DashboardCreateInput` holds only the fields `POST /api/dashboard` reads, so a layout passed to `dashboard.create` fails to compile; send it as a `DashboardLayoutInput` through `dashboard.update`. At run time `dashboard.create` drops any other key before the request, as the server does, and refuses a blank `name`, as the server does.
|
package/README.md
CHANGED
|
@@ -255,7 +255,7 @@ A 400 refusing a remote-sync move carries the content behind it: `nonRemoteSynce
|
|
|
255
255
|
The client registers no signal handler and reads no process state, so cancellation reaches it as an
|
|
256
256
|
`AbortSignal` the host owns. Three places take one and they compose: `ClientOptions.signal` cancels
|
|
257
257
|
every request a client makes, `RequestOptions.signal` cancels a single request, and
|
|
258
|
-
`PollOptions.signal` stops a wait loop. Each is folded together with the request timeout, so whichever
|
|
258
|
+
`PollOptions.signal` stops a wait loop. `OAuthLoginInput.signal` cancels a login, which runs before there is a client (see Auth). Each is folded together with the request timeout, so whichever
|
|
259
259
|
fires first ends the work. A method's first call may also wait on the client's one shared server probe; the method's `signal` ends that caller's wait, while the probe itself belongs to the client and is cancelled only by `ClientOptions.signal`, so a later call still finds it settled.
|
|
260
260
|
|
|
261
261
|
```ts
|
|
@@ -423,7 +423,9 @@ an `OAuthCredential`. `refreshOAuthCredential` exchanges the rotating refresh to
|
|
|
423
423
|
revocation endpoint. Types: `Credential` (the `ApiKeyCredential | OAuthCredential` union),
|
|
424
424
|
`OAuthLoginInput`, `OAuthLoginDeps`.
|
|
425
425
|
|
|
426
|
-
|
|
426
|
+
`OAuthLoginInput.signal` cancels a login at any point: before it starts, during discovery, client registration or the token exchange, or while it waits for the browser's redirect. The request in flight is cancelled, the loopback callback port is freed at once, and the login rejects with the signal's reason when that is a `MetabaseError`, else with an `AbortError` carrying its message.
|
|
427
|
+
|
|
428
|
+
Unless the caller passes `metadata` from `tryDiscoverMetadata`, which makes the same check, `oauthLogin` checks that the server grants the full-access scope the REST API needs: a discovery document that lists it in `scopes_supported` settles it (Metabase v62 from the patch that introduced the scope, and v63), and otherwise the server's version does (`oauthFullAccessScopeUnadvertised`), because v64 and newer grant the scope without advertising it; a server that cannot is refused with a `ConfigError`. `tryDiscoverMetadata` takes a signal as well.
|
|
427
429
|
|
|
428
430
|
### Versions and requirements
|
|
429
431
|
|
|
@@ -435,7 +437,7 @@ Unless the caller passes `metadata` from `tryDiscoverMetadata`, which makes the
|
|
|
435
437
|
|
|
436
438
|
`METHOD_REQUIREMENTS` names, per client method (`"transform.get"`, `"gitSync.branches"` — the `MethodKey` as the method is reached on the client), the features it needs, strictest first; `methodRequirements(key)` reads one entry, `METHOD_KEYS` lists the keys, and `isMethodKey` narrows a string to one. When a gated method's request fails the way a server rejects what it lacks (a 402 premium refusal, an unrouted 404, or a 400 on a value outside an older enum or a body an older route reads in another shape), the client probes the server and throws a `CapabilityError` when that profile lacks a feature the method needs — a version gate reads `This operation requires Metabase v59+ (this server is v0.58.0). Upgrade Metabase to use it.`, a token gate `This operation requires the 'remote_sync' premium feature (not enabled on this server).` — and the error's `developerDetail` is a `RequirementFailure` carrying `reason`, `detail`, `feature`, `since`, `tokenFeature` and `serverVersion` — a Zod schema as well as a type (with `RequirementReason` for its `reason` enum), so a consumer that reports the refusal in its own output can describe it. A server that turns out to have every feature failed for another reason, and its own error stands. A 400 is also an ordinary validation failure, so it stands as the server's own `HttpError` when its field errors (`fieldErrors`, `specificFieldErrors`) name a field the missing parameter feature does not gate: a `mb.table.update` carrying a tier-named `data_layer` to a server that speaks medallions, alongside another field that server rejects, throws that field's rejection rather than the tier floor. A 400 that names no field, or one from a server lacking a feature the method itself needs, is the refusal. A method that needs nothing never consults the server; a newer release or a development build is placed past the newest known major, so only a token can explain a refusal there. `checkFeatures(features, profile)` is the check itself, over any feature list (`methodRequirements(key)` gives a method's), answering the first feature the profile lacks, and `featureFailures(features, profile)` answers every one, `featureGap(profile, feature)` says which half of a rule the profile fails (`FeatureGap`: `{ kind: "version" }` or `{ kind: "token", tokenFeature }`), and `ruleGap` is the same question asked of a bare rule. `featureAvailability(feature)` says which servers hold a feature, from its rule: `v64+`, or `token dashboard_subscription_filters` when every supported server meets the version floor. A consumer that describes what a server can do — gating a test lane, or filtering prose by the server it targets — reads the same check.
|
|
437
439
|
|
|
438
|
-
Some input fields take a value only some servers accept. `@metabase/client/version/input-gates` records each such field on the input schema that holds it, in a registry of the client's own rather than Zod's global one. `inputGatesOf(schema)` answers the `InputGate` entries recorded on a property node, or `null` when every server takes all its values. A gate names a `feature`, an `effect` (`"needs"`: the server must hold the feature; `"supersededBy"`: a server holding it reads the value as something else; `"droppedBy"`: a server holding it drops the value unread), and the `when` that triggers it (`GateTrigger`: the field `present`, one of `values`, or a `nonEmpty` array). `gateTriggered(gate, value)` says whether a value passed for the field triggers the gate. A `droppedBy` gate is a note and nothing enforces it: `TABLE_FROM_DEFINITION_GATE` on `table_id` of `MeasureCreateInput` and `SegmentCreateInput`, which a server holding `tableFromDefinition` drops, and every server is sent because one without the feature requires it. The domain modules export every other gate as a const the resource enforces it by: `DATA_SENSITIVITY_GATE` on `FieldUpdateInput.data_sensitivity`, `DATA_LAYER_TIER_GATE` and `DATA_LAYER_MEDALLION_GATE` on `TableUpdateInput.data_layer`, `DATA_AUTHORITY_WITHDRAWAL_GATE` on `data_authority` of `TableUpdateInput` and `TableBulkEditInput`, `DATA_ACTION_COLLECTION_GATE` on `DataActionUpdateInput.collection_id`, `SUBSCRIPTION_FILTERS_GATE` on `parameters` of `PulseCreateInput` and `PulseUpdateInput`, and `REVISION_ENTITY_GATES` (`measure`, `transform`, `transform-test`) on `RevisionRevertInput.entity`. A server lacking the feature is refused or explained the way its method's own requirement is.
|
|
440
|
+
Some input fields take a value only some servers accept. `@metabase/client/version/input-gates` records each such field on the input schema that holds it, in a registry of the client's own rather than Zod's global one. `inputGatesOf(schema)` answers the `InputGate` entries recorded on a property node, or `null` when every server takes all its values. A gate names a `feature`, an `effect` (`"needs"`: the server must hold the feature; `"supersededBy"`: a server holding it reads the value as something else; `"droppedBy"`: a server holding it drops the value unread), and the `when` that triggers it (`GateTrigger`: the field `present`, one of `values`, or a `nonEmpty` array). `gateTriggered(gate, value)` says whether a value passed for the field triggers the gate. A `droppedBy` gate is a note and nothing enforces it: `TABLE_FROM_DEFINITION_GATE` on `table_id` of `MeasureCreateInput` and `SegmentCreateInput`, which a server holding `tableFromDefinition` drops, and every server is sent because one without the feature requires it. The domain modules export every other gate as a const the resource enforces it by: `DATA_SENSITIVITY_GATE` on `FieldUpdateInput.data_sensitivity`, `DATA_LAYER_TIER_GATE` and `DATA_LAYER_MEDALLION_GATE` on `TableUpdateInput.data_layer`, `DATA_AUTHORITY_WITHDRAWAL_GATE` on `data_authority` of `TableUpdateInput` and `TableBulkEditInput`, `DATA_ACTION_COLLECTION_GATE` on `DataActionUpdateInput.collection_id`, `DATA_ACTION_TABLE_GATE` on `DataActionUpdateInput.table_id`, `SUBSCRIPTION_FILTERS_GATE` on `parameters` of `PulseCreateInput` and `PulseUpdateInput`, and `REVISION_ENTITY_GATES` (`measure`, `transform`, `transform-test`) on `RevisionRevertInput.entity`. A server lacking the feature is refused or explained the way its method's own requirement is.
|
|
439
441
|
|
|
440
442
|
A resource whose wire shape differs between generations exports from its `@metabase/client/domain/<r>` module, beside the canonical schema, a reader that picks the exact schema for a `Features` and converts forward: `transformDetailSchema(features)` and `transformRowSchema(features)` read a `Transform` (the older generations' hydrated `table` on the detail endpoint, and no link on the rest, become `target_table_id`, and a Python source's `source-tables` keyed by alias becomes the list of `TransformSourceTableEntry`, whose `database_id`, `schema` and `table` are `null` for a table named by id alone; `transform.create`, `transform.update` and `transformPython.testRun` send the list back keyed by alias to such a server, `transformSourceBody(source, features)` and `pythonTestRunBody(params, features)` being the writers), `fieldDetailSchema(features)` reads a `FieldDetail`, which is a `FieldWithDataSensitivity` (its `data_sensitivity` `null` for an unlabelled field) on a generation with the label and a plain `Field` without the key elsewhere, told apart by `hasDataSensitivity`, `fieldRemappedValueSchema(features, sameField)` reads a `FieldRemappedValue` from the first cells of a row a generation pads with display columns, `transformJobSchema(features)` reads a `TransformJob` whose `active` is `null` on a generation that cannot switch jobs off, `transformJobRunResultSchema(features)` reads a `TransformJobRunResult` (`{ message, started, run_id }` — a stub id is `started: null, run_id: null`, the request accepted and the outcome unsaid; a numeric or null id is `started: id !== null, run_id: id`), and `libraryWireSchema(features)` with `toLibrary(wire, listing)` reads a `Library` whose `LibraryChild` entries carry `type` from the wire where the generation sends it and `is_remote_synced` from the collection listing on every generation (`LibraryCollectionInfo`, `LibraryListing`). Each `null` in a canonical field means "this server cannot say". `ResponseShapeError.developerDetail.serverSkew` carries the profile's `skew`, and a `newer-than-known` server is named as such in the message's lead line.
|
|
441
443
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as Credential, c as OAuthCredential, d as credentialSecrets, f as expiresAtFromNow, i as AuthHeader, l as assertCredentialHeaderSafe, m as oauthCredentialFromTokens, n as AUTHORIZATION_HEADER, o as CredentialRefresher, p as isOAuthExpired, r as ApiKeyCredential, s as DEFAULT_EXPIRES_IN_SECONDS, t as API_KEY_HEADER, u as credentialAuthHeader } from "../credential-
|
|
1
|
+
import { a as Credential, c as OAuthCredential, d as credentialSecrets, f as expiresAtFromNow, i as AuthHeader, l as assertCredentialHeaderSafe, m as oauthCredentialFromTokens, n as AUTHORIZATION_HEADER, o as CredentialRefresher, p as isOAuthExpired, r as ApiKeyCredential, s as DEFAULT_EXPIRES_IN_SECONDS, t as API_KEY_HEADER, u as credentialAuthHeader } from "../credential-B6fKSvqp.js";
|
|
2
2
|
export { API_KEY_HEADER, AUTHORIZATION_HEADER, ApiKeyCredential, AuthHeader, Credential, CredentialRefresher, DEFAULT_EXPIRES_IN_SECONDS, OAuthCredential, assertCredentialHeaderSafe, credentialAuthHeader, credentialSecrets, expiresAtFromNow, isOAuthExpired, oauthCredentialFromTokens };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as OAuthLoginInput, r as oauthLogin, t as OAuthLoginDeps } from "../oauth-login-
|
|
1
|
+
import { n as OAuthLoginInput, r as oauthLogin, t as OAuthLoginDeps } from "../oauth-login-SZ4Csai8.js";
|
|
2
2
|
export { OAuthLoginDeps, OAuthLoginInput, oauthLogin };
|
package/dist/auth/oauth-login.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as oauthLogin } from "../oauth-login
|
|
1
|
+
import { t as oauthLogin } from "../oauth-login--tDagiZu.js";
|
|
2
2
|
export { oauthLogin };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as revokeOAuthCredential, t as refreshOAuthCredential } from "../oauth-session-
|
|
1
|
+
import { n as revokeOAuthCredential, t as refreshOAuthCredential } from "../oauth-session-COLH4puN.js";
|
|
2
2
|
export { refreshOAuthCredential, revokeOAuthCredential };
|
|
@@ -7,9 +7,9 @@ declare const CardType: z.ZodEnum<{
|
|
|
7
7
|
}>;
|
|
8
8
|
type CardType = z.infer<typeof CardType>;
|
|
9
9
|
declare const CardListFilter: z.ZodEnum<{
|
|
10
|
-
archived: "archived";
|
|
11
10
|
database: "database";
|
|
12
11
|
table: "table";
|
|
12
|
+
archived: "archived";
|
|
13
13
|
all: "all";
|
|
14
14
|
mine: "mine";
|
|
15
15
|
bookmarked: "bookmarked";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { f as RequestOptions, h as Transport } from "./transport-
|
|
1
|
+
import { f as RequestOptions, h as Transport } from "./transport-CyHAGDqx.js";
|
|
2
2
|
import { t as ListResult } from "./list-BT_bBm9Z.js";
|
|
3
|
-
import { a as CardListFilter, i as CardDetail, l as CardUpdateInput, o as CardQueryResult, r as CardCreateInput, t as Card } from "./card-
|
|
4
|
-
import { r as QueryMetadata } from "./dataset-
|
|
3
|
+
import { a as CardListFilter, i as CardDetail, l as CardUpdateInput, o as CardQueryResult, r as CardCreateInput, t as Card } from "./card-BBLDmhtp.js";
|
|
4
|
+
import { r as QueryMetadata } from "./dataset-Du1GRHhd.js";
|
|
5
5
|
import { n as ExportFormat } from "./query-Xsin530u.js";
|
|
6
6
|
//#region src/resources/card.d.ts
|
|
7
7
|
interface CardListParams {
|
|
@@ -1,85 +1,85 @@
|
|
|
1
|
-
import "./credential-
|
|
2
|
-
import "./oauth-login-
|
|
3
|
-
import "./oauth-session-
|
|
1
|
+
import "./credential-B6fKSvqp.js";
|
|
2
|
+
import "./oauth-login-SZ4Csai8.js";
|
|
3
|
+
import "./oauth-session-COLH4puN.js";
|
|
4
4
|
import "./session-properties-COtlxAcK.js";
|
|
5
5
|
import "./features-SMSfJhB6.js";
|
|
6
6
|
import "./tag-qzjGGci8.js";
|
|
7
|
-
import { _ as WaitOptions, f as RequestOptions, g as TransportRequestOptions, h as Transport, n as ClientOptions, t as ClientCredentials, yt as ServerProfile } from "./transport-
|
|
7
|
+
import { _ as WaitOptions, f as RequestOptions, g as TransportRequestOptions, h as Transport, n as ClientOptions, t as ClientCredentials, yt as ServerProfile } from "./transport-CyHAGDqx.js";
|
|
8
8
|
import { t as ListResult } from "./list-BT_bBm9Z.js";
|
|
9
9
|
import "./requirements-Dx_ZVzl7.js";
|
|
10
|
-
import "./requirement-check-
|
|
11
|
-
import { n as Page } from "./paginate-
|
|
10
|
+
import "./requirement-check-Nv0trVbp.js";
|
|
11
|
+
import { n as Page } from "./paginate-Du9kUbXZ.js";
|
|
12
12
|
import { a as PollOptions } from "./poll-CIwnee7h.js";
|
|
13
|
-
import "./json-
|
|
13
|
+
import "./json-DvOVLFVY.js";
|
|
14
14
|
import { i as CreatedApiKey, r as ApiKeyCreateInput, t as ApiKey } from "./api-key-DJeN1-7G.js";
|
|
15
|
-
import { i as CardDetail, l as CardUpdateInput, o as CardQueryResult, r as CardCreateInput, t as Card } from "./card-
|
|
16
|
-
import { c as CollectionId, g as CollectionTreeNode, i as Collection, s as CollectionCreateInput, v as CollectionUpdateInput } from "./collection-
|
|
15
|
+
import { i as CardDetail, l as CardUpdateInput, o as CardQueryResult, r as CardCreateInput, t as Card } from "./card-BBLDmhtp.js";
|
|
16
|
+
import { c as CollectionId, g as CollectionTreeNode, i as Collection, s as CollectionCreateInput, v as CollectionUpdateInput } from "./collection-BtjnSckn.js";
|
|
17
17
|
import "./content-translation-zfUkE_OG.js";
|
|
18
18
|
import "./cron-DThzerR6.js";
|
|
19
19
|
import { _ as DashcardDetail, a as DashboardCopyInput, m as DashboardUpdateInput, o as DashboardCreateInput, r as DashboardCopy, s as DashboardDetail, t as Dashboard, u as DashboardParameterConstraints, v as DashcardPatchInput } from "./dashboard-DtLXVgtf.js";
|
|
20
|
-
import {
|
|
20
|
+
import { l as DataActionUpdateInput, o as DataActionExecuteInput, r as DataAction, s as DataActionExecuteResult } from "./data-action-DqwcRA7B.js";
|
|
21
21
|
import "./data-app-CqP5_fpB.js";
|
|
22
|
-
import { o as DatabaseSyncResult, s as DatabaseUpdateInput, t as Database, u as DatabaseWithSettings } from "./database-
|
|
23
|
-
import { r as QueryMetadata, t as CompiledQuery } from "./dataset-
|
|
24
|
-
import "./dependency-
|
|
25
|
-
import { a as DocumentUpdateInput, i as DocumentCreateInput, t as Document } from "./document-
|
|
26
|
-
import { a as EidTranslateResult, i as EidTranslateInput } from "./eid-translation-
|
|
22
|
+
import { o as DatabaseSyncResult, s as DatabaseUpdateInput, t as Database, u as DatabaseWithSettings } from "./database-DULVEXki.js";
|
|
23
|
+
import { r as QueryMetadata, t as CompiledQuery } from "./dataset-Du1GRHhd.js";
|
|
24
|
+
import "./dependency-B8aPt_IM.js";
|
|
25
|
+
import { a as DocumentUpdateInput, i as DocumentCreateInput, t as Document } from "./document-rqUlE_OE.js";
|
|
26
|
+
import { a as EidTranslateResult, i as EidTranslateInput } from "./eid-translation-CP79Tz71.js";
|
|
27
27
|
import "./embedding-oU3gqfgX.js";
|
|
28
28
|
import "./erd-BdeFEeSy.js";
|
|
29
|
-
import { c as FieldRemappedValue, d as FieldSummary, f as FieldUpdateInput, l as FieldSearchMatches, p as FieldValues, s as FieldDetail } from "./field-
|
|
30
|
-
import "./git-sync-
|
|
29
|
+
import { c as FieldRemappedValue, d as FieldSummary, f as FieldUpdateInput, l as FieldSearchMatches, p as FieldValues, s as FieldDetail } from "./field-D-kF3G7v.js";
|
|
30
|
+
import "./git-sync-nvbSaNfS.js";
|
|
31
31
|
import { i as GlossaryUpdateInput, r as GlossaryCreateInput, t as Glossary } from "./glossary-CHK3elPj.js";
|
|
32
32
|
import "./library-B9pEq7qP.js";
|
|
33
33
|
import "./measure-CgH14YQZ.js";
|
|
34
|
-
import { g as MetricFilterClause, x as MetricMathExpression } from "./metric-
|
|
34
|
+
import { g as MetricFilterClause, x as MetricMathExpression } from "./metric-BtEVH_Yp.js";
|
|
35
35
|
import "./moderation-review-B4RUTZ6_.js";
|
|
36
36
|
import { l as NotificationCreateInput, r as Notification, x as NotificationUpdateInput } from "./notification-D1MThyKE.js";
|
|
37
37
|
import { s as ParameterValues } from "./parameter-ak-J-IOj.js";
|
|
38
38
|
import { a as PermissionsGraph } from "./permission-BnCQw5Kp.js";
|
|
39
39
|
import { h as PulseUpdateInput, l as PulseCreateInput, t as Pulse } from "./pulse-0LG3K6qO.js";
|
|
40
40
|
import { n as ExportFormat, t as DatasetQuery } from "./query-Xsin530u.js";
|
|
41
|
-
import "./replacement-
|
|
42
|
-
import "./search-
|
|
41
|
+
import "./replacement-CyvtbxGg.js";
|
|
42
|
+
import "./search-BUr4r7d2.js";
|
|
43
43
|
import { i as SegmentUpdateInput, r as SegmentCreateInput, t as Segment } from "./segment-CbAgVO-5.js";
|
|
44
|
-
import "./revision-
|
|
44
|
+
import "./revision-Cft5Lcev.js";
|
|
45
45
|
import { t as Setting } from "./setting-DXuQGXGF.js";
|
|
46
46
|
import { n as SetupResult, t as SetupInput } from "./setup-JqcJ2unJ.js";
|
|
47
47
|
import { i as SnippetUpdateInput, r as SnippetCreateInput, t as Snippet } from "./snippet-C_Ilx7tR.js";
|
|
48
|
-
import { S as TableSchemaSyncResult, a as Table, g as TableForeignKey, h as TableFieldValuesResult, y as TableQueryMetadata } from "./table-
|
|
49
|
-
import { i as TimelineEvent, l as TimelineUpdateInput, o as TimelineEventCreateInput, r as TimelineCreateInput, s as TimelineEventUpdateInput, t as Timeline } from "./timeline-
|
|
48
|
+
import { S as TableSchemaSyncResult, a as Table, g as TableForeignKey, h as TableFieldValuesResult, y as TableQueryMetadata } from "./table-R-q8w__K.js";
|
|
49
|
+
import { i as TimelineEvent, l as TimelineUpdateInput, o as TimelineEventCreateInput, r as TimelineCreateInput, s as TimelineEventUpdateInput, t as Timeline } from "./timeline-B35sx1FM.js";
|
|
50
50
|
import "./transform-C5thnJwW.js";
|
|
51
51
|
import "./transform-dag-run-BgZwv1yx.js";
|
|
52
|
-
import "./transform-inspector-
|
|
52
|
+
import "./transform-inspector-BUYBt6--.js";
|
|
53
53
|
import "./transform-job-D8jTQtdX.js";
|
|
54
54
|
import "./transform-python-DtL3xxMj.js";
|
|
55
55
|
import "./transform-tag-C6j5EUkX.js";
|
|
56
56
|
import "./transform-test-CeMzDpUC.js";
|
|
57
57
|
import { r as UploadUpdateResult, t as UploadResult } from "./upload-UPfZFdbH.js";
|
|
58
58
|
import { t as CurrentUser } from "./user-Sqqv7rqh.js";
|
|
59
|
-
import { n as CardListParams, r as CardQueryParams, t as CardExportParams } from "./card-
|
|
60
|
-
import { i as CollectionTreeParams, n as CollectionItemPageOptions, r as CollectionListParams, t as CollectionItemListParams } from "./collection-
|
|
59
|
+
import { n as CardListParams, r as CardQueryParams, t as CardExportParams } from "./card-DkHtPMK4.js";
|
|
60
|
+
import { i as CollectionTreeParams, n as CollectionItemPageOptions, r as CollectionListParams, t as CollectionItemListParams } from "./collection-DWjkDrln.js";
|
|
61
61
|
import { t as CsvFile } from "./csv-upload--K35QedP.js";
|
|
62
|
-
import { r as DashcardCardIssue, t as DashboardListParams } from "./dashboard-
|
|
63
|
-
import { n as DatabaseListParams, r as DatabaseSyncSchemaParams, t as DatabaseGetParams } from "./database-
|
|
64
|
-
import { n as DatasetNativeParams, t as DatasetExportParams } from "./dataset-
|
|
65
|
-
import { i as DependencyItemPageOptions, n as DependencyDependentsParams, r as DependencyItemListParams, t as DependencyBrokenParams } from "./dependency-
|
|
66
|
-
import { t as ErdParams } from "./erd-
|
|
67
|
-
import { a as FieldSetDataSensitivityParams, i as FieldSearchParams, t as FieldRemappingParams } from "./field-
|
|
68
|
-
import { a as SyncRemoteChangesParams, i as SyncImportParams, n as SyncExportParams, r as SyncExportPreflightParams, s as SyncStashParams, t as SyncCreateBranchParams } from "./git-sync-
|
|
69
|
-
import { t as GlossaryListParams } from "./glossary-
|
|
70
|
-
import { t as MeasureArchiveParams } from "./measure-
|
|
71
|
-
import { t as NotificationListParams } from "./notification-
|
|
72
|
-
import { t as PulseListParams } from "./pulse-
|
|
73
|
-
import { t as ReplacementRunListParams } from "./replacement-
|
|
74
|
-
import { n as SearchParams, t as SearchPage } from "./search-
|
|
75
|
-
import { t as SegmentArchiveParams } from "./segment-
|
|
76
|
-
import { t as SnippetListParams } from "./snippet-
|
|
77
|
-
import { t as TableListParams } from "./table-
|
|
78
|
-
import { n as TimelineListParams, t as TimelineEventsParams } from "./timeline-
|
|
79
|
-
import { a as TransformRunSummaryPageParams, i as TransformRunParams, n as TransformRunPageOptions, r as TransformRunPageParams, t as TransformDagParams } from "./transform-
|
|
80
|
-
import { t as TransformJobRunParams } from "./transform-job-
|
|
81
|
-
import { t as TransformTestListParams } from "./transform-test-
|
|
82
|
-
import { t as UploadCsvParams } from "./upload-
|
|
62
|
+
import { r as DashcardCardIssue, t as DashboardListParams } from "./dashboard-B4qWeR10.js";
|
|
63
|
+
import { n as DatabaseListParams, r as DatabaseSyncSchemaParams, t as DatabaseGetParams } from "./database-Cw8ICtQi.js";
|
|
64
|
+
import { n as DatasetNativeParams, t as DatasetExportParams } from "./dataset-26H-dH4N.js";
|
|
65
|
+
import { i as DependencyItemPageOptions, n as DependencyDependentsParams, r as DependencyItemListParams, t as DependencyBrokenParams } from "./dependency-elYkHuk5.js";
|
|
66
|
+
import { t as ErdParams } from "./erd-D2fpjDTj.js";
|
|
67
|
+
import { a as FieldSetDataSensitivityParams, i as FieldSearchParams, t as FieldRemappingParams } from "./field-awM3Y7IP.js";
|
|
68
|
+
import { a as SyncRemoteChangesParams, i as SyncImportParams, n as SyncExportParams, r as SyncExportPreflightParams, s as SyncStashParams, t as SyncCreateBranchParams } from "./git-sync-8Tk8TirZ.js";
|
|
69
|
+
import { t as GlossaryListParams } from "./glossary-CQMSJmIx.js";
|
|
70
|
+
import { t as MeasureArchiveParams } from "./measure-D4ArCbsa.js";
|
|
71
|
+
import { t as NotificationListParams } from "./notification-BsuPAfMW.js";
|
|
72
|
+
import { t as PulseListParams } from "./pulse-drQKS_pg.js";
|
|
73
|
+
import { t as ReplacementRunListParams } from "./replacement-g3IKzPPj.js";
|
|
74
|
+
import { n as SearchParams, t as SearchPage } from "./search-DX1IVRRC.js";
|
|
75
|
+
import { t as SegmentArchiveParams } from "./segment-c2EDEJNd.js";
|
|
76
|
+
import { t as SnippetListParams } from "./snippet-CSt-f812.js";
|
|
77
|
+
import { t as TableListParams } from "./table-BA-k8Zgt.js";
|
|
78
|
+
import { n as TimelineListParams, t as TimelineEventsParams } from "./timeline-D3Clk0_n.js";
|
|
79
|
+
import { a as TransformRunSummaryPageParams, i as TransformRunParams, n as TransformRunPageOptions, r as TransformRunPageParams, t as TransformDagParams } from "./transform-DzgPup_a.js";
|
|
80
|
+
import { t as TransformJobRunParams } from "./transform-job-DtLWrsyH.js";
|
|
81
|
+
import { t as TransformTestListParams } from "./transform-test-B_HR-yKA.js";
|
|
82
|
+
import { t as UploadCsvParams } from "./upload-BSixoElJ.js";
|
|
83
83
|
//#region src/resources/metric.d.ts
|
|
84
84
|
interface MetricDimensionListParams {
|
|
85
85
|
query?: string | undefined;
|
|
@@ -272,7 +272,7 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
272
272
|
itemPages: (ref: string | number, params?: CollectionItemListParams | undefined, options?: CollectionItemPageOptions | undefined) => AsyncIterable<Page<{
|
|
273
273
|
[x: string]: unknown;
|
|
274
274
|
id: number;
|
|
275
|
-
model: "
|
|
275
|
+
model: "collection" | "card" | "dashboard" | "dataset" | "document" | "metric" | "measure" | "pulse" | "snippet" | "table" | "timeline" | "transform" | "exploration" | "no_models" | "indexed-entity" | "action";
|
|
276
276
|
name: string;
|
|
277
277
|
archived: boolean | null;
|
|
278
278
|
description?: string | null | undefined;
|
|
@@ -308,12 +308,28 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
308
308
|
list: (options?: RequestOptions) => Promise<ListResult<DataAction>>;
|
|
309
309
|
get: (id: number, options?: RequestOptions) => Promise<DataAction>;
|
|
310
310
|
create: (params: {
|
|
311
|
-
name: string;
|
|
312
311
|
type: "query";
|
|
313
|
-
database_id: number;
|
|
314
312
|
dataset_query: {
|
|
315
313
|
[x: string]: unknown;
|
|
316
314
|
};
|
|
315
|
+
name: string;
|
|
316
|
+
parameters?: {
|
|
317
|
+
[x: string]: unknown;
|
|
318
|
+
id: string;
|
|
319
|
+
type: string;
|
|
320
|
+
target: unknown;
|
|
321
|
+
name?: string | undefined;
|
|
322
|
+
slug?: string | undefined;
|
|
323
|
+
required?: boolean | undefined;
|
|
324
|
+
}[] | undefined;
|
|
325
|
+
collection_id?: number | null | undefined;
|
|
326
|
+
description?: string | null | undefined;
|
|
327
|
+
visualization_settings?: unknown;
|
|
328
|
+
} | {
|
|
329
|
+
type: "implicit";
|
|
330
|
+
kind: "row/create" | "row/update" | "row/delete";
|
|
331
|
+
table_id: number;
|
|
332
|
+
name: string;
|
|
317
333
|
parameters?: {
|
|
318
334
|
[x: string]: unknown;
|
|
319
335
|
id: string;
|
|
@@ -352,6 +368,8 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
352
368
|
collection_id: number | null;
|
|
353
369
|
database_id?: number | null | undefined;
|
|
354
370
|
dataset_query?: unknown;
|
|
371
|
+
kind?: string | undefined;
|
|
372
|
+
table_id?: number | null | undefined;
|
|
355
373
|
}>;
|
|
356
374
|
update: (id: number, params: DataActionUpdateInput, options?: RequestOptions) => Promise<DataAction>;
|
|
357
375
|
archive: (id: number, options?: RequestOptions) => Promise<DataAction>;
|
|
@@ -481,18 +499,18 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
481
499
|
exportQuery: (format: ExportFormat, params: DatasetExportParams, options?: RequestOptions) => Promise<ReadableStream<Uint8Array>>;
|
|
482
500
|
};
|
|
483
501
|
dependency: {
|
|
484
|
-
graph: (type: "
|
|
502
|
+
graph: (type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox", id: number, options?: RequestOptions | undefined) => Promise<{
|
|
485
503
|
[x: string]: unknown;
|
|
486
504
|
nodes: {
|
|
487
505
|
[x: string]: unknown;
|
|
488
506
|
id: number;
|
|
489
|
-
type: "
|
|
507
|
+
type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox";
|
|
490
508
|
data: {
|
|
491
509
|
[x: string]: unknown;
|
|
492
510
|
name?: string | null | undefined;
|
|
493
511
|
display_name?: string | null | undefined;
|
|
494
512
|
description?: string | null | undefined;
|
|
495
|
-
type?: "query" | "metric" | "model" | "
|
|
513
|
+
type?: "query" | "metric" | "model" | "implicit" | "question" | null | undefined;
|
|
496
514
|
display?: string | null | undefined;
|
|
497
515
|
database_id?: number | null | undefined;
|
|
498
516
|
db_id?: number | null | undefined;
|
|
@@ -531,26 +549,26 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
531
549
|
} | null | undefined;
|
|
532
550
|
view_count?: number | null | undefined;
|
|
533
551
|
};
|
|
534
|
-
dependents_count: Partial<Record<"
|
|
552
|
+
dependents_count: Partial<Record<"dashboard" | "document" | "metric" | "measure" | "segment" | "snippet" | "table" | "transform" | "model" | "action" | "sandbox" | "question", number>> | null;
|
|
535
553
|
}[];
|
|
536
554
|
edges: {
|
|
537
555
|
[x: string]: unknown;
|
|
538
|
-
from_entity_type: "
|
|
556
|
+
from_entity_type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox";
|
|
539
557
|
from_entity_id: number;
|
|
540
|
-
to_entity_type: "
|
|
558
|
+
to_entity_type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox";
|
|
541
559
|
to_entity_id: number;
|
|
542
560
|
}[];
|
|
543
561
|
}>;
|
|
544
|
-
dependents: (type: "
|
|
562
|
+
dependents: (type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox", id: number, params?: DependencyDependentsParams | undefined, options?: RequestOptions | undefined) => Promise<ListResult<{
|
|
545
563
|
[x: string]: unknown;
|
|
546
564
|
id: number;
|
|
547
|
-
type: "
|
|
565
|
+
type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox";
|
|
548
566
|
data: {
|
|
549
567
|
[x: string]: unknown;
|
|
550
568
|
name?: string | null | undefined;
|
|
551
569
|
display_name?: string | null | undefined;
|
|
552
570
|
description?: string | null | undefined;
|
|
553
|
-
type?: "query" | "metric" | "model" | "
|
|
571
|
+
type?: "query" | "metric" | "model" | "implicit" | "question" | null | undefined;
|
|
554
572
|
display?: string | null | undefined;
|
|
555
573
|
database_id?: number | null | undefined;
|
|
556
574
|
db_id?: number | null | undefined;
|
|
@@ -589,18 +607,18 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
589
607
|
} | null | undefined;
|
|
590
608
|
view_count?: number | null | undefined;
|
|
591
609
|
};
|
|
592
|
-
dependents_count: Partial<Record<"
|
|
610
|
+
dependents_count: Partial<Record<"dashboard" | "document" | "metric" | "measure" | "segment" | "snippet" | "table" | "transform" | "model" | "action" | "sandbox" | "question", number>> | null;
|
|
593
611
|
}>>;
|
|
594
|
-
broken: (type: "
|
|
612
|
+
broken: (type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox", id: number, params?: DependencyBrokenParams | undefined, options?: RequestOptions | undefined) => Promise<ListResult<{
|
|
595
613
|
[x: string]: unknown;
|
|
596
614
|
id: number;
|
|
597
|
-
type: "
|
|
615
|
+
type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox";
|
|
598
616
|
data: {
|
|
599
617
|
[x: string]: unknown;
|
|
600
618
|
name?: string | null | undefined;
|
|
601
619
|
display_name?: string | null | undefined;
|
|
602
620
|
description?: string | null | undefined;
|
|
603
|
-
type?: "query" | "metric" | "model" | "
|
|
621
|
+
type?: "query" | "metric" | "model" | "implicit" | "question" | null | undefined;
|
|
604
622
|
display?: string | null | undefined;
|
|
605
623
|
database_id?: number | null | undefined;
|
|
606
624
|
db_id?: number | null | undefined;
|
|
@@ -643,13 +661,13 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
643
661
|
unreferencedPages: (params?: DependencyItemListParams | undefined, options?: DependencyItemPageOptions | undefined) => AsyncIterable<Page<{
|
|
644
662
|
[x: string]: unknown;
|
|
645
663
|
id: number;
|
|
646
|
-
type: "
|
|
664
|
+
type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox";
|
|
647
665
|
data: {
|
|
648
666
|
[x: string]: unknown;
|
|
649
667
|
name?: string | null | undefined;
|
|
650
668
|
display_name?: string | null | undefined;
|
|
651
669
|
description?: string | null | undefined;
|
|
652
|
-
type?: "query" | "metric" | "model" | "
|
|
670
|
+
type?: "query" | "metric" | "model" | "implicit" | "question" | null | undefined;
|
|
653
671
|
display?: string | null | undefined;
|
|
654
672
|
database_id?: number | null | undefined;
|
|
655
673
|
db_id?: number | null | undefined;
|
|
@@ -688,18 +706,18 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
688
706
|
} | null | undefined;
|
|
689
707
|
view_count?: number | null | undefined;
|
|
690
708
|
};
|
|
691
|
-
dependents_count: Partial<Record<"
|
|
709
|
+
dependents_count: Partial<Record<"dashboard" | "document" | "metric" | "measure" | "segment" | "snippet" | "table" | "transform" | "model" | "action" | "sandbox" | "question", number>> | null;
|
|
692
710
|
}>>;
|
|
693
711
|
breakingPages: (params?: DependencyItemListParams | undefined, options?: DependencyItemPageOptions | undefined) => AsyncIterable<Page<{
|
|
694
712
|
[x: string]: unknown;
|
|
695
713
|
id: number;
|
|
696
|
-
type: "
|
|
714
|
+
type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox";
|
|
697
715
|
data: {
|
|
698
716
|
[x: string]: unknown;
|
|
699
717
|
name?: string | null | undefined;
|
|
700
718
|
display_name?: string | null | undefined;
|
|
701
719
|
description?: string | null | undefined;
|
|
702
|
-
type?: "query" | "metric" | "model" | "
|
|
720
|
+
type?: "query" | "metric" | "model" | "implicit" | "question" | null | undefined;
|
|
703
721
|
display?: string | null | undefined;
|
|
704
722
|
database_id?: number | null | undefined;
|
|
705
723
|
db_id?: number | null | undefined;
|
|
@@ -738,15 +756,15 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
738
756
|
} | null | undefined;
|
|
739
757
|
view_count?: number | null | undefined;
|
|
740
758
|
};
|
|
741
|
-
dependents_count: Partial<Record<"
|
|
759
|
+
dependents_count: Partial<Record<"dashboard" | "document" | "metric" | "measure" | "segment" | "snippet" | "table" | "transform" | "model" | "action" | "sandbox" | "question", number>> | null;
|
|
742
760
|
dependents_errors?: {
|
|
743
761
|
[x: string]: unknown;
|
|
744
762
|
id: number;
|
|
745
|
-
analyzed_entity_type: "
|
|
763
|
+
analyzed_entity_type: "card" | "dashboard" | "document" | "measure" | "segment" | "snippet" | "table" | "transform" | "action" | "sandbox";
|
|
746
764
|
analyzed_entity_id: number;
|
|
747
765
|
error_type: "missing-column" | "missing-table-alias" | "missing-table" | "missing-card" | "duplicate-column" | "syntax-error" | "validation-exception-error";
|
|
748
766
|
error_detail?: string | null | undefined;
|
|
749
|
-
source_entity_type?: "
|
|
767
|
+
source_entity_type?: "card" | "table" | "transform" | null | undefined;
|
|
750
768
|
source_entity_id?: number | null | undefined;
|
|
751
769
|
}[] | null | undefined;
|
|
752
770
|
}>>;
|
|
@@ -1517,9 +1535,9 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
1517
1535
|
id: number;
|
|
1518
1536
|
status: "timeout" | "failed" | "pending" | "started" | "succeeded" | "canceled";
|
|
1519
1537
|
is_active: true | null;
|
|
1520
|
-
source_entity_type: "
|
|
1538
|
+
source_entity_type: "card" | "table" | "transform";
|
|
1521
1539
|
source_entity_id: number;
|
|
1522
|
-
target_entity_type: "
|
|
1540
|
+
target_entity_type: "card" | "table" | "transform";
|
|
1523
1541
|
target_entity_id: number;
|
|
1524
1542
|
progress: number | null;
|
|
1525
1543
|
message: string | null;
|
|
@@ -1532,9 +1550,9 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
1532
1550
|
id: number;
|
|
1533
1551
|
status: "timeout" | "failed" | "pending" | "started" | "succeeded" | "canceled";
|
|
1534
1552
|
is_active: true | null;
|
|
1535
|
-
source_entity_type: "
|
|
1553
|
+
source_entity_type: "card" | "table" | "transform";
|
|
1536
1554
|
source_entity_id: number;
|
|
1537
|
-
target_entity_type: "
|
|
1555
|
+
target_entity_type: "card" | "table" | "transform";
|
|
1538
1556
|
target_entity_id: number;
|
|
1539
1557
|
progress: number | null;
|
|
1540
1558
|
message: string | null;
|
|
@@ -1545,7 +1563,7 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
1545
1563
|
cancelRun: (id: number, options?: RequestOptions | undefined) => Promise<void>;
|
|
1546
1564
|
};
|
|
1547
1565
|
revision: {
|
|
1548
|
-
list: (entity: "
|
|
1566
|
+
list: (entity: "card" | "dashboard" | "document" | "measure" | "segment" | "transform" | "transform-test", id: number, options?: RequestOptions | undefined) => Promise<ListResult<{
|
|
1549
1567
|
[x: string]: unknown;
|
|
1550
1568
|
id: number;
|
|
1551
1569
|
timestamp: string;
|
|
@@ -1566,7 +1584,7 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
1566
1584
|
};
|
|
1567
1585
|
}>>;
|
|
1568
1586
|
revert: (params: {
|
|
1569
|
-
entity: "
|
|
1587
|
+
entity: "card" | "dashboard" | "document" | "measure" | "segment" | "transform" | "transform-test";
|
|
1570
1588
|
id: number;
|
|
1571
1589
|
revision_id: number;
|
|
1572
1590
|
}, options?: RequestOptions | undefined) => Promise<{
|
|
@@ -1683,9 +1701,9 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
1683
1701
|
caveats?: string | null | undefined;
|
|
1684
1702
|
points_of_interest?: string | null | undefined;
|
|
1685
1703
|
show_in_getting_started?: boolean | undefined;
|
|
1686
|
-
field_order?: "
|
|
1704
|
+
field_order?: "database" | "custom" | "alphabetical" | "smart" | undefined;
|
|
1687
1705
|
data_authority?: "unconfigured" | "authoritative" | "computed" | "ingested" | null | undefined;
|
|
1688
|
-
data_source?: "unknown" | "
|
|
1706
|
+
data_source?: "unknown" | "upload" | "transform" | "ingested" | "metabase-transform" | "source-data" | null | undefined;
|
|
1689
1707
|
data_layer?: "internal" | "hidden" | "final" | "gold" | "silver" | "bronze" | "copper" | null | undefined;
|
|
1690
1708
|
owner_email?: string | null | undefined;
|
|
1691
1709
|
owner_user_id?: number | null | undefined;
|
|
@@ -1738,7 +1756,7 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
1738
1756
|
schema_ids?: string[] | undefined;
|
|
1739
1757
|
table_ids?: number[] | undefined;
|
|
1740
1758
|
data_authority?: "unconfigured" | "authoritative" | "computed" | "ingested" | null | undefined;
|
|
1741
|
-
data_source?: "unknown" | "
|
|
1759
|
+
data_source?: "unknown" | "upload" | "transform" | "ingested" | "metabase-transform" | "source-data" | null | undefined;
|
|
1742
1760
|
data_layer?: "internal" | "hidden" | "final" | null | undefined;
|
|
1743
1761
|
entity_type?: "entity/GenericTable" | "entity/UserTable" | "entity/CompanyTable" | "entity/TransactionTable" | "entity/ProductTable" | "entity/SubscriptionTable" | "entity/EventTable" | null | undefined;
|
|
1744
1762
|
owner_email?: string | null | undefined;
|
|
@@ -1749,7 +1767,7 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
1749
1767
|
schema_ids?: string[] | undefined;
|
|
1750
1768
|
table_ids?: number[] | undefined;
|
|
1751
1769
|
data_authority?: "unconfigured" | "authoritative" | "computed" | "ingested" | null | undefined;
|
|
1752
|
-
data_source?: "unknown" | "
|
|
1770
|
+
data_source?: "unknown" | "upload" | "transform" | "ingested" | "metabase-transform" | "source-data" | null | undefined;
|
|
1753
1771
|
data_layer?: "internal" | "hidden" | "final" | null | undefined;
|
|
1754
1772
|
entity_type?: "entity/GenericTable" | "entity/UserTable" | "entity/CompanyTable" | "entity/TransactionTable" | "entity/ProductTable" | "entity/SubscriptionTable" | "entity/EventTable" | null | undefined;
|
|
1755
1773
|
owner_email?: string | null | undefined;
|
|
@@ -2584,7 +2602,7 @@ declare function createClient(config: ClientCredentials, options: ClientOptions)
|
|
|
2584
2602
|
[x: string]: unknown;
|
|
2585
2603
|
name: string;
|
|
2586
2604
|
};
|
|
2587
|
-
severity: "
|
|
2605
|
+
severity: "error" | "info" | "warning";
|
|
2588
2606
|
message: string;
|
|
2589
2607
|
metadata?: {
|
|
2590
2608
|
[x: string]: unknown;
|
package/dist/client.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as createClient, t as MetabaseClient } from "./client-
|
|
1
|
+
import { n as createClient, t as MetabaseClient } from "./client-eOkt3tTd.js";
|
|
2
2
|
export { MetabaseClient, createClient };
|