@databricks/appkit-ui 0.88.1 → 0.89.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.
Files changed (136) hide show
  1. package/CLAUDE.md +7 -2
  2. package/dist/cli/commands/doctor/checks-existence.js +16 -16
  3. package/dist/cli/commands/doctor/checks-existence.js.map +1 -1
  4. package/dist/cli/commands/doctor/checks.js +15 -18
  5. package/dist/cli/commands/doctor/checks.js.map +1 -1
  6. package/dist/cli/commands/doctor/databricks-client.js +8 -6
  7. package/dist/cli/commands/doctor/databricks-client.js.map +1 -1
  8. package/dist/cli/commands/registry/workspace-picker.js +34 -24
  9. package/dist/cli/commands/registry/workspace-picker.js.map +1 -1
  10. package/dist/react/genie/genie-chart-inference.js.map +1 -1
  11. package/dist/react/genie/genie-query-transform.d.ts +5 -2
  12. package/dist/react/genie/genie-query-transform.d.ts.map +1 -1
  13. package/dist/react/genie/genie-query-transform.js +14 -8
  14. package/dist/react/genie/genie-query-transform.js.map +1 -1
  15. package/dist/shared/src/genie.d.ts +9 -3
  16. package/dist/shared/src/genie.d.ts.map +1 -1
  17. package/dist/shared/src/workspace-client/factory.d.ts +0 -1
  18. package/dist/shared/src/workspace-client/index.d.ts +1 -2
  19. package/dist/shared/src/workspace-client/modular.d.ts +19 -0
  20. package/dist/shared/src/workspace-client/types.d.ts +1 -2
  21. package/dist/workspace-client/client.js +81 -23
  22. package/dist/workspace-client/client.js.map +1 -1
  23. package/dist/workspace-client/errors.d.ts +14 -2
  24. package/dist/workspace-client/errors.d.ts.map +1 -0
  25. package/dist/workspace-client/errors.js +45 -2
  26. package/dist/workspace-client/errors.js.map +1 -0
  27. package/dist/workspace-client/factory.d.ts +1 -1
  28. package/dist/workspace-client/factory.js.map +1 -1
  29. package/dist/workspace-client/index.d.ts +4 -3
  30. package/dist/workspace-client/index.js +2 -2
  31. package/dist/workspace-client/modular.d.ts +109 -0
  32. package/dist/workspace-client/modular.d.ts.map +1 -0
  33. package/dist/workspace-client/modular.js +447 -0
  34. package/dist/workspace-client/modular.js.map +1 -0
  35. package/dist/workspace-client/options.d.ts +29 -0
  36. package/dist/workspace-client/options.d.ts.map +1 -0
  37. package/dist/workspace-client/types.d.ts +35 -38
  38. package/dist/workspace-client/types.d.ts.map +1 -1
  39. package/docs/api/appkit/Class.ApiError.md +110 -0
  40. package/docs/api/appkit/Class.DatabricksAdapter.md +2 -2
  41. package/docs/api/appkit/Class.SupervisorApiAdapter.md +1 -1
  42. package/docs/api/appkit/Function.generateDatabaseCredential.md +2 -2
  43. package/docs/api/appkit/Function.getWorkspaceClient.md +2 -2
  44. package/docs/api/appkit/Interface.DirectoryEntry.md +62 -0
  45. package/docs/api/appkit/Interface.DownloadResponse.md +45 -0
  46. package/docs/api/appkit/Interface.JobAPI.md +20 -12
  47. package/docs/api/appkit/Interface.LakebasePoolConfig.md +1 -1
  48. package/docs/api/appkit/Interface.WorkspaceClient.md +168 -26
  49. package/docs/api/appkit/Interface.WorkspaceClientOptions.md +1 -14
  50. package/docs/api/appkit/TypeAlias.FilesDirectoryEntry.md +8 -0
  51. package/docs/api/appkit/TypeAlias.FilesDownloadResponse.md +8 -0
  52. package/docs/api/appkit/TypeAlias.JobsExport.md +1 -1
  53. package/docs/api/appkit/TypeAlias.WorkspaceClientLike.md +16 -0
  54. package/docs/api/appkit.md +7 -2
  55. package/docs/plugins/files.md +20 -3
  56. package/docs/plugins/jobs.md +9 -9
  57. package/docs/plugins/testing.md +10 -8
  58. package/llms.txt +7 -2
  59. package/node_modules/@databricks/sdk-genie/LICENSE +203 -0
  60. package/node_modules/@databricks/sdk-genie/README.md +23 -0
  61. package/node_modules/@databricks/sdk-genie/dist/package.js +7 -0
  62. package/node_modules/@databricks/sdk-genie/dist/package.js.map +1 -0
  63. package/node_modules/@databricks/sdk-genie/dist/v1/client.d.ts +175 -0
  64. package/node_modules/@databricks/sdk-genie/dist/v1/client.d.ts.map +1 -0
  65. package/node_modules/@databricks/sdk-genie/dist/v1/client.js +829 -0
  66. package/node_modules/@databricks/sdk-genie/dist/v1/client.js.map +1 -0
  67. package/node_modules/@databricks/sdk-genie/dist/v1/index.d.ts +3 -0
  68. package/node_modules/@databricks/sdk-genie/dist/v1/index.js +4 -0
  69. package/node_modules/@databricks/sdk-genie/dist/v1/model.d.ts +1799 -0
  70. package/node_modules/@databricks/sdk-genie/dist/v1/model.d.ts.map +1 -0
  71. package/node_modules/@databricks/sdk-genie/dist/v1/model.js +1097 -0
  72. package/node_modules/@databricks/sdk-genie/dist/v1/model.js.map +1 -0
  73. package/node_modules/@databricks/sdk-genie/dist/v1/transport.d.ts +37 -0
  74. package/node_modules/@databricks/sdk-genie/dist/v1/transport.d.ts.map +1 -0
  75. package/node_modules/@databricks/sdk-genie/dist/v1/transport.js +73 -0
  76. package/node_modules/@databricks/sdk-genie/dist/v1/transport.js.map +1 -0
  77. package/node_modules/@databricks/sdk-genie/dist/v1/utils.d.ts +43 -0
  78. package/node_modules/@databricks/sdk-genie/dist/v1/utils.d.ts.map +1 -0
  79. package/node_modules/@databricks/sdk-genie/dist/v1/utils.js +130 -0
  80. package/node_modules/@databricks/sdk-genie/dist/v1/utils.js.map +1 -0
  81. package/node_modules/@databricks/sdk-genie/package.json +46 -0
  82. package/node_modules/@databricks/sdk-statementexecution/LICENSE +203 -0
  83. package/node_modules/@databricks/sdk-statementexecution/README.md +23 -0
  84. package/node_modules/@databricks/sdk-statementexecution/dist/package.js +7 -0
  85. package/node_modules/@databricks/sdk-statementexecution/dist/package.js.map +1 -0
  86. package/node_modules/@databricks/sdk-statementexecution/dist/v1/client.d.ts +91 -0
  87. package/node_modules/@databricks/sdk-statementexecution/dist/v1/client.d.ts.map +1 -0
  88. package/node_modules/@databricks/sdk-statementexecution/dist/v1/client.js +183 -0
  89. package/node_modules/@databricks/sdk-statementexecution/dist/v1/client.js.map +1 -0
  90. package/node_modules/@databricks/sdk-statementexecution/dist/v1/index.d.ts +3 -0
  91. package/node_modules/@databricks/sdk-statementexecution/dist/v1/index.js +4 -0
  92. package/node_modules/@databricks/sdk-statementexecution/dist/v1/model.d.ts +506 -0
  93. package/node_modules/@databricks/sdk-statementexecution/dist/v1/model.d.ts.map +1 -0
  94. package/node_modules/@databricks/sdk-statementexecution/dist/v1/model.js +302 -0
  95. package/node_modules/@databricks/sdk-statementexecution/dist/v1/model.js.map +1 -0
  96. package/node_modules/@databricks/sdk-statementexecution/dist/v1/transport.d.ts +37 -0
  97. package/node_modules/@databricks/sdk-statementexecution/dist/v1/transport.d.ts.map +1 -0
  98. package/node_modules/@databricks/sdk-statementexecution/dist/v1/transport.js +73 -0
  99. package/node_modules/@databricks/sdk-statementexecution/dist/v1/transport.js.map +1 -0
  100. package/node_modules/@databricks/sdk-statementexecution/dist/v1/utils.d.ts +25 -0
  101. package/node_modules/@databricks/sdk-statementexecution/dist/v1/utils.d.ts.map +1 -0
  102. package/node_modules/@databricks/sdk-statementexecution/dist/v1/utils.js +87 -0
  103. package/node_modules/@databricks/sdk-statementexecution/dist/v1/utils.js.map +1 -0
  104. package/node_modules/@databricks/sdk-statementexecution/package.json +46 -0
  105. package/node_modules/@databricks/sdk-vectorsearch/LICENSE +203 -0
  106. package/node_modules/@databricks/sdk-vectorsearch/README.md +23 -0
  107. package/node_modules/@databricks/sdk-vectorsearch/dist/package.js +7 -0
  108. package/node_modules/@databricks/sdk-vectorsearch/dist/package.js.map +1 -0
  109. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/client.d.ts +70 -0
  110. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/client.d.ts.map +1 -0
  111. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/client.js +474 -0
  112. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/client.js.map +1 -0
  113. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/index.d.ts +3 -0
  114. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/index.js +4 -0
  115. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/model.d.ts +704 -0
  116. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/model.d.ts.map +1 -0
  117. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/model.js +635 -0
  118. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/model.js.map +1 -0
  119. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/transport.d.ts +37 -0
  120. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/transport.d.ts.map +1 -0
  121. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/transport.js +73 -0
  122. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/transport.js.map +1 -0
  123. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/utils.d.ts +37 -0
  124. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/utils.d.ts.map +1 -0
  125. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/utils.js +104 -0
  126. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/utils.js.map +1 -0
  127. package/node_modules/@databricks/sdk-vectorsearch/package.json +46 -0
  128. package/package.json +29 -4
  129. package/sbom.cdx.json +1 -1
  130. package/dist/shared/src/workspace-client/errors.d.ts +0 -1
  131. package/dist/shared/src/workspace-client/legacy.d.ts +0 -3
  132. package/dist/workspace-client/legacy.d.ts +0 -34
  133. package/dist/workspace-client/legacy.d.ts.map +0 -1
  134. package/dist/workspace-client/legacy.js +0 -23
  135. package/dist/workspace-client/legacy.js.map +0 -1
  136. package/docs/api/appkit/Interface.WorkspaceClientLike.md +0 -67
@@ -1 +0,0 @@
1
- import "@databricks/sdk-experimental";
@@ -1,3 +0,0 @@
1
- import "@databricks/sdk-experimental";
2
- import "@databricks/sdk-experimental/dist/apis/dashboards";
3
- import "@databricks/sdk-experimental/dist/wait";
@@ -1,34 +0,0 @@
1
- import * as SDK from "@databricks/sdk-experimental";
2
- import { CancellationToken, ClientOptions, ClientOptions as ClientOptions$1, WorkspaceClient } from "@databricks/sdk-experimental";
3
- import { GenieMessage } from "@databricks/sdk-experimental/dist/apis/dashboards";
4
- import { Waiter } from "@databricks/sdk-experimental/dist/wait";
5
-
6
- //#region src/workspace-client/legacy.d.ts
7
- /** The concrete legacy SDK client type. */
8
- type LegacyWorkspaceClient = WorkspaceClient;
9
- /**
10
- * Options used to construct the wrapper. Mirrors the subset of the old SDK's
11
- * `Config` + `ClientOptions` that AppKit relies on today; we deliberately do
12
- * NOT re-expose every old-SDK config knob.
13
- */
14
- interface WorkspaceClientOptions {
15
- /** Databricks host, e.g. https://my-workspace.cloud.databricks.com. Defaults to DATABRICKS_HOST / profile resolution. */
16
- host?: string;
17
- /** `~/.databrickscfg` profile name. Used when no host/token is provided. */
18
- profile?: string;
19
- /** Bearer token. When set, `authType` defaults to "pat". */
20
- token?: string;
21
- /** Authentication strategy passed to the legacy client. */
22
- authType?: "pat";
23
- /**
24
- * SDK client options (product / productVersion / userAgentExtra) used to
25
- * stamp the outbound User-Agent. Produced by `getClientOptions()`; omitted
26
- * by build-time callers that don't stamp a User-Agent.
27
- */
28
- clientOptions?: ClientOptions;
29
- }
30
- declare const ConfigError: typeof SDK.ConfigError, Context: typeof SDK.Context, TimeUnits: typeof SDK.TimeUnits, loadConfigFile: typeof SDK.loadConfigFile;
31
- declare const Time: typeof SDK.Time;
32
- //#endregion
33
- export { type CancellationToken, type ClientOptions$1 as ClientOptions, ConfigError, Context, type GenieMessage, LegacyWorkspaceClient, Time, TimeUnits, type Waiter, WorkspaceClientOptions, loadConfigFile };
34
- //# sourceMappingURL=legacy.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"legacy.d.ts","names":[],"sources":["../../src/workspace-client/legacy.ts"],"mappings":";;;;;;;KAqBY,qBAAA,GAAwB,eAAA;;;;;;UAOnB,sBAAA;EAcc;EAZ7B,IAAA;EA2Da;EAzDb,OAAA;;EAEA,KAAA;EAuDiC;EArDjC,QAAA;EAqD4D;;;;;EA/C5D,aAAA,GAAgB,aAAA;AAAA;AAAA,cA+CH,WAAA,SAAW,GAAA,CAAA,WAAA,EAAA,OAAA,SAAS,GAAA,CAAA,OAAA,EAAA,SAAA,SAAW,GAAA,CAAA,SAAA,EAAA,cAAA,SAAgB,GAAA,CAAA,cAAA;AAAA,cACjD,IAAA,SAAI,GAAA,CAAA,IAAA"}
@@ -1,23 +0,0 @@
1
- import * as SDK from "@databricks/sdk-experimental";
2
-
3
- //#region src/workspace-client/legacy.ts
4
- const { WorkspaceClient: SdkWorkspaceClientCtor } = SDK;
5
- /**
6
- * Construct a legacy `WorkspaceClient` from wrapper options.
7
- *
8
- * Centralised so the wrapper facade, the `.toLegacyWorkspaceClient()` escape
9
- * hatch, and any per-request OBO client all build it the same way.
10
- */
11
- function buildLegacyWorkspaceClient(opts) {
12
- return new SdkWorkspaceClientCtor(opts.token !== void 0 ? {
13
- host: opts.host,
14
- token: opts.token,
15
- authType: opts.authType ?? "pat"
16
- } : opts.host ? { host: opts.host } : opts.profile ? { profile: opts.profile } : {}, opts.clientOptions);
17
- }
18
- const { ConfigError, Context, TimeUnits, loadConfigFile } = SDK;
19
- const Time = SDK.Time ?? SDK.default.Time;
20
-
21
- //#endregion
22
- export { ConfigError, Context, Time, TimeUnits, buildLegacyWorkspaceClient, loadConfigFile };
23
- //# sourceMappingURL=legacy.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"legacy.js","names":[],"sources":["../../src/workspace-client/legacy.ts"],"sourcesContent":["/**\n * The single module in AppKit allowed to import `@databricks/sdk-experimental`\n * directly (enforced by the oxlint `no-restricted-imports` boundary rule). Every\n * other AppKit module reaches the SDK through the wrapper's re-exports and the\n * {@link WorkspaceClient} facade.\n *\n * Isolating the SDK here is what makes the incremental migration to the modular\n * Databricks SDK a localized change: to migrate a service, swap its getter in\n * `client.ts` from the legacy delegate to the modular client — nothing else in\n * the codebase imports the SDK, so the blast radius is one connector + its test.\n */\n\nimport type {\n ClientOptions,\n WorkspaceClient as SdkWorkspaceClient,\n} from \"@databricks/sdk-experimental\";\nimport * as SDK from \"@databricks/sdk-experimental\";\n\nconst { WorkspaceClient: SdkWorkspaceClientCtor } = SDK;\n\n/** The concrete legacy SDK client type. */\nexport type LegacyWorkspaceClient = SdkWorkspaceClient;\n\n/**\n * Options used to construct the wrapper. Mirrors the subset of the old SDK's\n * `Config` + `ClientOptions` that AppKit relies on today; we deliberately do\n * NOT re-expose every old-SDK config knob.\n */\nexport interface WorkspaceClientOptions {\n /** Databricks host, e.g. https://my-workspace.cloud.databricks.com. Defaults to DATABRICKS_HOST / profile resolution. */\n host?: string;\n /** `~/.databrickscfg` profile name. Used when no host/token is provided. */\n profile?: string;\n /** Bearer token. When set, `authType` defaults to \"pat\". */\n token?: string;\n /** Authentication strategy passed to the legacy client. */\n authType?: \"pat\";\n /**\n * SDK client options (product / productVersion / userAgentExtra) used to\n * stamp the outbound User-Agent. Produced by `getClientOptions()`; omitted\n * by build-time callers that don't stamp a User-Agent.\n */\n clientOptions?: ClientOptions;\n}\n\n/**\n * Construct a legacy `WorkspaceClient` from wrapper options.\n *\n * Centralised so the wrapper facade, the `.toLegacyWorkspaceClient()` escape\n * hatch, and any per-request OBO client all build it the same way.\n */\nexport function buildLegacyWorkspaceClient(\n opts: WorkspaceClientOptions,\n): LegacyWorkspaceClient {\n // Check `token !== undefined`, NOT truthiness: an explicitly-passed token\n // must stick to the PAT path even when it's an empty string. Falling through\n // to the default-auth branch on an empty OBO token would silently\n // authenticate as the service principal instead of failing — a privilege\n // escalation in the OBO path. An invalid/empty token should blow up loudly.\n const cfg =\n opts.token !== undefined\n ? { host: opts.host, token: opts.token, authType: opts.authType ?? \"pat\" }\n : opts.host\n ? { host: opts.host }\n : opts.profile\n ? { profile: opts.profile }\n : {};\n return new SdkWorkspaceClientCtor(cfg, opts.clientOptions);\n}\n\n// ── SDK type re-exports ──────────────────────────────────────────────\nexport type {\n CancellationToken,\n ClientOptions,\n} from \"@databricks/sdk-experimental\";\n// ── SDK value re-exports ─────────────────────────────────────────────\n//\n// AppKit modules import these from the wrapper instead of the SDK so the\n// boundary rule holds. `Context` bridges AbortSignal → CancellationToken\n// (serving/jobs/sql-warehouse); `Time`/`TimeUnits` drive genie polling;\n// `ConfigError` is matched in service-context's auth-failure handling.\n//\n// These are sourced off the namespace import rather than `export { ... } from`\n// because the SDK is CommonJS: its `Time` export is emitted as a getter that\n// calls `__importDefault(...)`, which defeats Node's static named-export\n// detection — a direct `export { Time }` throws \"does not provide an export\n// named 'Time'\" at ESM link time. `Time` is only reachable via the module\n// object, so we fall back to `SDK.default.Time` (matching the original genie\n// connector's `SDK.Time ?? SDK.default.Time` guard).\nexport const { ConfigError, Context, TimeUnits, loadConfigFile } = SDK;\nexport const Time =\n SDK.Time ?? (SDK as unknown as { default: typeof SDK }).default.Time;\n\n// Deep-import types used by the genie connector's waiter idiom. Not exposed\n// on the SDK's top-level index, so re-exported here to keep the genie\n// connector off a direct `@databricks/sdk-experimental/dist/**` import.\nexport type { GenieMessage } from \"@databricks/sdk-experimental/dist/apis/dashboards\";\nexport type { Waiter } from \"@databricks/sdk-experimental/dist/wait\";\n"],"mappings":";;;AAkBA,MAAM,EAAE,iBAAiB,2BAA2B;;;;;;;AAiCpD,SAAgB,2BACd,MACuB;AAcvB,QAAO,IAAI,uBAPT,KAAK,UAAU,SACX;EAAE,MAAM,KAAK;EAAM,OAAO,KAAK;EAAO,UAAU,KAAK,YAAY;EAAO,GACxE,KAAK,OACH,EAAE,MAAM,KAAK,MAAM,GACnB,KAAK,UACH,EAAE,SAAS,KAAK,SAAS,GACzB,EAAE,EAC2B,KAAK,cAAc;;AAsB5D,MAAa,EAAE,aAAa,SAAS,WAAW,mBAAmB;AACnE,MAAa,OACX,IAAI,QAAS,IAA2C,QAAQ"}
@@ -1,67 +0,0 @@
1
- # Interface: WorkspaceClientLike
2
-
3
- Structural shape of a Databricks SDK client used by [fromSupervisorApi](./docs/api/appkit/Function.fromSupervisorApi.md). Only what we need: `apiClient.request` for streaming and `config.ensureResolved` to materialise the host/credentials.
4
-
5
- Exported because [SupervisorApiAdapterOptions.workspaceClient](./docs/api/appkit/Interface.SupervisorApiAdapterOptions.md#workspaceclient) (a public type) references it — callers passing their own client can name the shape they need to satisfy.
6
-
7
- ## Extends[​](#extends "Direct link to Extends")
8
-
9
- * `ApiClientLike`
10
-
11
- ## Properties[​](#properties "Direct link to Properties")
12
-
13
- ### apiClient[​](#apiclient "Direct link to apiClient")
14
-
15
- ```ts
16
- apiClient: {
17
- request: Promise<unknown>;
18
- };
19
-
20
- ```
21
-
22
- #### request()[​](#request "Direct link to request()")
23
-
24
- ```ts
25
- request(options: Record<string, unknown>, context?: unknown): Promise<unknown>;
26
-
27
- ```
28
-
29
- ##### Parameters[​](#parameters "Direct link to Parameters")
30
-
31
- | Parameter | Type |
32
- | ---------- | ----------------------------- |
33
- | `options` | `Record`<`string`, `unknown`> |
34
- | `context?` | `unknown` |
35
-
36
- ##### Returns[​](#returns "Direct link to Returns")
37
-
38
- `Promise`<`unknown`>
39
-
40
- #### Inherited from[​](#inherited-from "Direct link to Inherited from")
41
-
42
- ```ts
43
- ApiClientLike.apiClient
44
-
45
- ```
46
-
47
- ***
48
-
49
- ### config[​](#config "Direct link to config")
50
-
51
- ```ts
52
- config: {
53
- ensureResolved: Promise<void>;
54
- };
55
-
56
- ```
57
-
58
- #### ensureResolved()[​](#ensureresolved "Direct link to ensureResolved()")
59
-
60
- ```ts
61
- ensureResolved(): Promise<void>;
62
-
63
- ```
64
-
65
- ##### Returns[​](#returns-1 "Direct link to Returns")
66
-
67
- `Promise`<`void`>