@databricks/appkit-ui 0.88.0 → 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 (142) 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/react/table/table-wrapper.js +6 -1
  16. package/dist/react/table/table-wrapper.js.map +1 -1
  17. package/dist/react/table/types.d.ts +5 -1
  18. package/dist/react/table/types.d.ts.map +1 -1
  19. package/dist/react/ui/button.d.ts +1 -1
  20. package/dist/shared/src/genie.d.ts +9 -3
  21. package/dist/shared/src/genie.d.ts.map +1 -1
  22. package/dist/shared/src/workspace-client/factory.d.ts +0 -1
  23. package/dist/shared/src/workspace-client/index.d.ts +1 -2
  24. package/dist/shared/src/workspace-client/modular.d.ts +19 -0
  25. package/dist/shared/src/workspace-client/types.d.ts +1 -2
  26. package/dist/workspace-client/client.js +81 -23
  27. package/dist/workspace-client/client.js.map +1 -1
  28. package/dist/workspace-client/errors.d.ts +14 -2
  29. package/dist/workspace-client/errors.d.ts.map +1 -0
  30. package/dist/workspace-client/errors.js +45 -2
  31. package/dist/workspace-client/errors.js.map +1 -0
  32. package/dist/workspace-client/factory.d.ts +1 -1
  33. package/dist/workspace-client/factory.js.map +1 -1
  34. package/dist/workspace-client/index.d.ts +4 -3
  35. package/dist/workspace-client/index.js +2 -2
  36. package/dist/workspace-client/modular.d.ts +109 -0
  37. package/dist/workspace-client/modular.d.ts.map +1 -0
  38. package/dist/workspace-client/modular.js +447 -0
  39. package/dist/workspace-client/modular.js.map +1 -0
  40. package/dist/workspace-client/options.d.ts +29 -0
  41. package/dist/workspace-client/options.d.ts.map +1 -0
  42. package/dist/workspace-client/types.d.ts +35 -38
  43. package/dist/workspace-client/types.d.ts.map +1 -1
  44. package/docs/api/appkit/Class.ApiError.md +110 -0
  45. package/docs/api/appkit/Class.DatabricksAdapter.md +2 -2
  46. package/docs/api/appkit/Class.SupervisorApiAdapter.md +1 -1
  47. package/docs/api/appkit/Function.generateDatabaseCredential.md +2 -2
  48. package/docs/api/appkit/Function.getWorkspaceClient.md +2 -2
  49. package/docs/api/appkit/Interface.DirectoryEntry.md +62 -0
  50. package/docs/api/appkit/Interface.DownloadResponse.md +45 -0
  51. package/docs/api/appkit/Interface.JobAPI.md +20 -12
  52. package/docs/api/appkit/Interface.LakebasePoolConfig.md +1 -1
  53. package/docs/api/appkit/Interface.WorkspaceClient.md +168 -26
  54. package/docs/api/appkit/Interface.WorkspaceClientOptions.md +1 -14
  55. package/docs/api/appkit/TypeAlias.FilesDirectoryEntry.md +8 -0
  56. package/docs/api/appkit/TypeAlias.FilesDownloadResponse.md +8 -0
  57. package/docs/api/appkit/TypeAlias.JobsExport.md +1 -1
  58. package/docs/api/appkit/TypeAlias.WorkspaceClientLike.md +16 -0
  59. package/docs/api/appkit-ui/data/DataTable.md +16 -16
  60. package/docs/api/appkit.md +7 -2
  61. package/docs/plugins/files.md +20 -3
  62. package/docs/plugins/jobs.md +9 -9
  63. package/docs/plugins/testing.md +10 -8
  64. package/llms.txt +7 -2
  65. package/node_modules/@databricks/sdk-genie/LICENSE +203 -0
  66. package/node_modules/@databricks/sdk-genie/README.md +23 -0
  67. package/node_modules/@databricks/sdk-genie/dist/package.js +7 -0
  68. package/node_modules/@databricks/sdk-genie/dist/package.js.map +1 -0
  69. package/node_modules/@databricks/sdk-genie/dist/v1/client.d.ts +175 -0
  70. package/node_modules/@databricks/sdk-genie/dist/v1/client.d.ts.map +1 -0
  71. package/node_modules/@databricks/sdk-genie/dist/v1/client.js +829 -0
  72. package/node_modules/@databricks/sdk-genie/dist/v1/client.js.map +1 -0
  73. package/node_modules/@databricks/sdk-genie/dist/v1/index.d.ts +3 -0
  74. package/node_modules/@databricks/sdk-genie/dist/v1/index.js +4 -0
  75. package/node_modules/@databricks/sdk-genie/dist/v1/model.d.ts +1799 -0
  76. package/node_modules/@databricks/sdk-genie/dist/v1/model.d.ts.map +1 -0
  77. package/node_modules/@databricks/sdk-genie/dist/v1/model.js +1097 -0
  78. package/node_modules/@databricks/sdk-genie/dist/v1/model.js.map +1 -0
  79. package/node_modules/@databricks/sdk-genie/dist/v1/transport.d.ts +37 -0
  80. package/node_modules/@databricks/sdk-genie/dist/v1/transport.d.ts.map +1 -0
  81. package/node_modules/@databricks/sdk-genie/dist/v1/transport.js +73 -0
  82. package/node_modules/@databricks/sdk-genie/dist/v1/transport.js.map +1 -0
  83. package/node_modules/@databricks/sdk-genie/dist/v1/utils.d.ts +43 -0
  84. package/node_modules/@databricks/sdk-genie/dist/v1/utils.d.ts.map +1 -0
  85. package/node_modules/@databricks/sdk-genie/dist/v1/utils.js +130 -0
  86. package/node_modules/@databricks/sdk-genie/dist/v1/utils.js.map +1 -0
  87. package/node_modules/@databricks/sdk-genie/package.json +46 -0
  88. package/node_modules/@databricks/sdk-statementexecution/LICENSE +203 -0
  89. package/node_modules/@databricks/sdk-statementexecution/README.md +23 -0
  90. package/node_modules/@databricks/sdk-statementexecution/dist/package.js +7 -0
  91. package/node_modules/@databricks/sdk-statementexecution/dist/package.js.map +1 -0
  92. package/node_modules/@databricks/sdk-statementexecution/dist/v1/client.d.ts +91 -0
  93. package/node_modules/@databricks/sdk-statementexecution/dist/v1/client.d.ts.map +1 -0
  94. package/node_modules/@databricks/sdk-statementexecution/dist/v1/client.js +183 -0
  95. package/node_modules/@databricks/sdk-statementexecution/dist/v1/client.js.map +1 -0
  96. package/node_modules/@databricks/sdk-statementexecution/dist/v1/index.d.ts +3 -0
  97. package/node_modules/@databricks/sdk-statementexecution/dist/v1/index.js +4 -0
  98. package/node_modules/@databricks/sdk-statementexecution/dist/v1/model.d.ts +506 -0
  99. package/node_modules/@databricks/sdk-statementexecution/dist/v1/model.d.ts.map +1 -0
  100. package/node_modules/@databricks/sdk-statementexecution/dist/v1/model.js +302 -0
  101. package/node_modules/@databricks/sdk-statementexecution/dist/v1/model.js.map +1 -0
  102. package/node_modules/@databricks/sdk-statementexecution/dist/v1/transport.d.ts +37 -0
  103. package/node_modules/@databricks/sdk-statementexecution/dist/v1/transport.d.ts.map +1 -0
  104. package/node_modules/@databricks/sdk-statementexecution/dist/v1/transport.js +73 -0
  105. package/node_modules/@databricks/sdk-statementexecution/dist/v1/transport.js.map +1 -0
  106. package/node_modules/@databricks/sdk-statementexecution/dist/v1/utils.d.ts +25 -0
  107. package/node_modules/@databricks/sdk-statementexecution/dist/v1/utils.d.ts.map +1 -0
  108. package/node_modules/@databricks/sdk-statementexecution/dist/v1/utils.js +87 -0
  109. package/node_modules/@databricks/sdk-statementexecution/dist/v1/utils.js.map +1 -0
  110. package/node_modules/@databricks/sdk-statementexecution/package.json +46 -0
  111. package/node_modules/@databricks/sdk-vectorsearch/LICENSE +203 -0
  112. package/node_modules/@databricks/sdk-vectorsearch/README.md +23 -0
  113. package/node_modules/@databricks/sdk-vectorsearch/dist/package.js +7 -0
  114. package/node_modules/@databricks/sdk-vectorsearch/dist/package.js.map +1 -0
  115. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/client.d.ts +70 -0
  116. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/client.d.ts.map +1 -0
  117. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/client.js +474 -0
  118. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/client.js.map +1 -0
  119. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/index.d.ts +3 -0
  120. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/index.js +4 -0
  121. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/model.d.ts +704 -0
  122. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/model.d.ts.map +1 -0
  123. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/model.js +635 -0
  124. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/model.js.map +1 -0
  125. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/transport.d.ts +37 -0
  126. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/transport.d.ts.map +1 -0
  127. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/transport.js +73 -0
  128. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/transport.js.map +1 -0
  129. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/utils.d.ts +37 -0
  130. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/utils.d.ts.map +1 -0
  131. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/utils.js +104 -0
  132. package/node_modules/@databricks/sdk-vectorsearch/dist/v1/utils.js.map +1 -0
  133. package/node_modules/@databricks/sdk-vectorsearch/package.json +46 -0
  134. package/package.json +29 -4
  135. package/sbom.cdx.json +1 -1
  136. package/dist/shared/src/workspace-client/errors.d.ts +0 -1
  137. package/dist/shared/src/workspace-client/legacy.d.ts +0 -3
  138. package/dist/workspace-client/legacy.d.ts +0 -34
  139. package/dist/workspace-client/legacy.d.ts.map +0 -1
  140. package/dist/workspace-client/legacy.js +0 -23
  141. package/dist/workspace-client/legacy.js.map +0 -1
  142. package/docs/api/appkit/Interface.WorkspaceClientLike.md +0 -67
@@ -1,3 +1,46 @@
1
- import { ApiError } from "@databricks/sdk-experimental";
1
+ import { ApiError } from "@databricks/sdk-core/apierror";
2
2
 
3
- export { ApiError };
3
+ //#region src/workspace-client/errors.ts
4
+ /**
5
+ * API error type surfaced by the AppKit workspace client.
6
+ *
7
+ * AppKit's own error class, with the field names AppKit and its consumers read
8
+ * (`statusCode`, `errorCode`). The modular `@databricks/sdk-core` `ApiError`
9
+ * keeps its status in `httpStatusCode` and its code in `code`, so it also
10
+ * exposes the AppKit names, and `instanceof ApiError` matches it too.
11
+ */
12
+ for (const [name, source] of [["statusCode", "httpStatusCode"], ["errorCode", "code"]]) if (!Object.hasOwn(ApiError.prototype, name)) Object.defineProperty(ApiError.prototype, name, {
13
+ configurable: true,
14
+ get() {
15
+ return this[source];
16
+ },
17
+ set(value) {
18
+ Object.defineProperty(this, name, {
19
+ value,
20
+ writable: true,
21
+ enumerable: true,
22
+ configurable: true
23
+ });
24
+ }
25
+ });
26
+ var ApiError$1 = class ApiError$1 extends Error {
27
+ constructor(message, errorCode, statusCode, response, details = []) {
28
+ super(message);
29
+ this.errorCode = errorCode;
30
+ this.statusCode = statusCode;
31
+ this.response = response;
32
+ this.details = details;
33
+ this.name = "ApiError";
34
+ }
35
+ /** Like the legacy SDK: only 429 is retryable by status alone. */
36
+ isRetryable() {
37
+ return this.statusCode === 429;
38
+ }
39
+ static [Symbol.hasInstance](value) {
40
+ return Function.prototype[Symbol.hasInstance].call(ApiError$1, value) || value instanceof ApiError;
41
+ }
42
+ };
43
+
44
+ //#endregion
45
+ export { ApiError$1 as ApiError };
46
+ //# sourceMappingURL=errors.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.js","names":["ModularApiError","ApiError"],"sources":["../../src/workspace-client/errors.ts"],"sourcesContent":["/**\n * API error type surfaced by the AppKit workspace client.\n *\n * AppKit's own error class, with the field names AppKit and its consumers read\n * (`statusCode`, `errorCode`). The modular `@databricks/sdk-core` `ApiError`\n * keeps its status in `httpStatusCode` and its code in `code`, so it also\n * exposes the AppKit names, and `instanceof ApiError` matches it too.\n */\nimport { ApiError as ModularApiError } from \"@databricks/sdk-core/apierror\";\n\n// AppKit-name aliases on modular errors. Setters store an own value, so call\n// sites that assign `statusCode` (e.g. via Object.assign) keep working.\nfor (const [name, source] of [\n [\"statusCode\", \"httpStatusCode\"],\n [\"errorCode\", \"code\"],\n] as const) {\n if (!Object.hasOwn(ModularApiError.prototype, name)) {\n Object.defineProperty(ModularApiError.prototype, name, {\n configurable: true,\n get(this: ModularApiError) {\n return this[source];\n },\n set(this: ModularApiError, value: unknown) {\n Object.defineProperty(this, name, {\n value,\n writable: true,\n enumerable: true,\n configurable: true,\n });\n },\n });\n }\n}\n\nexport class ApiError extends Error {\n constructor(\n message: string,\n readonly errorCode: string,\n readonly statusCode: number,\n readonly response?: unknown,\n readonly details: unknown[] = [],\n ) {\n super(message);\n this.name = \"ApiError\";\n }\n\n /** Like the legacy SDK: only 429 is retryable by status alone. */\n isRetryable(): boolean {\n return this.statusCode === 429;\n }\n\n static [Symbol.hasInstance](value: unknown): boolean {\n return (\n Function.prototype[Symbol.hasInstance].call(ApiError, value) ||\n value instanceof ModularApiError\n );\n }\n}\n"],"mappings":";;;;;;;;;;;AAYA,KAAK,MAAM,CAAC,MAAM,WAAW,CAC3B,CAAC,cAAc,iBAAiB,EAChC,CAAC,aAAa,OAAO,CACtB,CACC,KAAI,CAAC,OAAO,OAAOA,SAAgB,WAAW,KAAK,CACjD,QAAO,eAAeA,SAAgB,WAAW,MAAM;CACrD,cAAc;CACd,MAA2B;AACzB,SAAO,KAAK;;CAEd,IAA2B,OAAgB;AACzC,SAAO,eAAe,MAAM,MAAM;GAChC;GACA,UAAU;GACV,YAAY;GACZ,cAAc;GACf,CAAC;;CAEL,CAAC;AAIN,IAAaC,aAAb,MAAaA,mBAAiB,MAAM;CAClC,YACE,SACA,AAAS,WACT,AAAS,YACT,AAAS,UACT,AAAS,UAAqB,EAAE,EAChC;AACA,QAAM,QAAQ;EALL;EACA;EACA;EACA;AAGT,OAAK,OAAO;;;CAId,cAAuB;AACrB,SAAO,KAAK,eAAe;;CAG7B,QAAQ,OAAO,aAAa,OAAyB;AACnD,SACE,SAAS,UAAU,OAAO,aAAa,KAAKA,YAAU,MAAM,IAC5D,iBAAiBD"}
@@ -1,4 +1,4 @@
1
- import { WorkspaceClientOptions } from "./legacy.js";
1
+ import { WorkspaceClientOptions } from "./options.js";
2
2
  import { WorkspaceClient } from "./types.js";
3
3
 
4
4
  //#region src/workspace-client/factory.d.ts
@@ -1 +1 @@
1
- {"version":3,"file":"factory.js","names":[],"sources":["../../src/workspace-client/factory.ts"],"sourcesContent":["/**\n * Public factory for constructing a wrapper instance.\n */\nimport { AppKitWorkspaceClient } from \"./client\";\nimport type { WorkspaceClientOptions } from \"./legacy\";\nimport type { WorkspaceClient } from \"./types\";\n\n/**\n * Construct an AppKit workspace client.\n *\n * Auth resolution:\n * - If `opts.token` is set, uses PAT credentials.\n * - Otherwise walks the SDK default auth chain (env vars + ~/.databrickscfg).\n *\n * Host resolution:\n * - Explicit `opts.host` → use it.\n * - Otherwise resolved by the SDK from `DATABRICKS_HOST` / profile.\n */\nexport function createWorkspaceClient(\n opts: WorkspaceClientOptions = {},\n): WorkspaceClient {\n return new AppKitWorkspaceClient(opts);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAkBA,SAAgB,sBACd,OAA+B,EAAE,EAChB;AACjB,QAAO,IAAI,sBAAsB,KAAK"}
1
+ {"version":3,"file":"factory.js","names":[],"sources":["../../src/workspace-client/factory.ts"],"sourcesContent":["/**\n * Public factory for constructing a wrapper instance.\n */\nimport { AppKitWorkspaceClient } from \"./client\";\nimport type { WorkspaceClientOptions } from \"./options\";\nimport type { WorkspaceClient } from \"./types\";\n\n/**\n * Construct an AppKit workspace client.\n *\n * Auth resolution:\n * - If `opts.token` is set, uses PAT credentials.\n * - Otherwise walks the SDK default auth chain (env vars + ~/.databrickscfg).\n *\n * Host resolution:\n * - Explicit `opts.host` → use it.\n * - Otherwise resolved by the SDK from `DATABRICKS_HOST` / profile.\n */\nexport function createWorkspaceClient(\n opts: WorkspaceClientOptions = {},\n): WorkspaceClient {\n return new AppKitWorkspaceClient(opts);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAkBA,SAAgB,sBACd,OAA+B,EAAE,EAChB;AACjB,QAAO,IAAI,sBAAsB,KAAK"}
@@ -1,5 +1,6 @@
1
1
  import { ApiError } from "./errors.js";
2
- import { CancellationToken, ClientOptions, ConfigError, Context, GenieMessage, LegacyWorkspaceClient, Time, TimeUnits, Waiter, WorkspaceClientOptions, loadConfigFile } from "./legacy.js";
3
- import { WorkspaceClient, files, jobs, serving, sql } from "./types.js";
2
+ import { ClientOptions, WorkspaceClientOptions } from "./options.js";
3
+ import { App, AppsClient, AuthConfigError, BaseRun, CancelRunRequest, ColumnInfo, ConnectionInfo, ConnectionsClient, DatabaseClient, DatabaseCredential, DatabaseInstance, Disposition, EndpointHealth, EndpointInfo, EndpointState, ExecuteStatementRequest, Experiment, ExperimentsClient, ExternalLink, FilesClient, FilesDirectoryEntry, FilesDownloadResponse, Format, FunctionInfo, FunctionsClient, GenerateDatabaseCredentialRequest, GenieClient, GenieGetMessageQueryResultResponse, GenieMessage, GetConnectionRequest, GetFunctionRequest, GetInferenceEndpointRequest, GetJobRequest, GetJobResponse, GetRunOutputRequest, GetRunOutputResponse, GetRunRequest, GetRunResponse, GetVolumeRequest, GetWarehouseResponse, InferenceEndpoint, InferenceEndpointDetailed, JobsClient, ListAppsRequest, ListAppsResponse, ListConnectionsRequest, ListConnectionsResponse, ListDatabaseInstancesRequest, ListDatabaseInstancesResponse, ListExperimentsRequest, ListExperimentsResponse, ListInferenceEndpointsRequest, ListInferenceEndpointsResponse, ListRunsRequest, ModelServingClient, ModularApiError, PostgresClient, QueryVectorIndexRequest, QueryVectorIndexResponse, ResultData, ResultManifest, RunNowRequest, RunNowResponse, Schema, ScimClient, ServiceError, StatementExecutionClient, StatementParameter, StatementResponse, StatementStatus, StatementStatus_State, SubmitRunRequest, SubmitRunResponse, TablesClient, VectorSearchClient, VolumeInfo, VolumesClient, WarehousesClient, WorkspaceAuth, WorkspaceRequest, buildAppsClient, buildConnectionsClient, buildDatabaseClient, buildExperimentsClient, buildFilesClient, buildFunctionsClient, buildGenieClient, buildJobsClient, buildModelServingClient, buildPostgresClient, buildScimClient, buildStatementExecutionClient, buildTablesClient, buildVectorSearchClient, buildVolumesClient, buildWarehousesClient, buildWorkspaceAuth, isAuthConfigError, resolveProfile } from "./modular.js";
4
+ import { WorkspaceClient } from "./types.js";
4
5
  import { createWorkspaceClient } from "./factory.js";
5
- export { ApiError, type CancellationToken, type ClientOptions, ConfigError, Context, type GenieMessage, type LegacyWorkspaceClient, Time, TimeUnits, type Waiter, type WorkspaceClient, type WorkspaceClientOptions, createWorkspaceClient, type files, type jobs, loadConfigFile, type serving, type sql };
6
+ export { ApiError, App, AppsClient, AuthConfigError, BaseRun, CancelRunRequest, type ClientOptions, ColumnInfo, ConnectionInfo, ConnectionsClient, DatabaseClient, DatabaseCredential, DatabaseInstance, Disposition, EndpointHealth, EndpointInfo, EndpointState, ExecuteStatementRequest, Experiment, ExperimentsClient, ExternalLink, FilesClient, FilesDirectoryEntry, FilesDownloadResponse, Format, FunctionInfo, FunctionsClient, GenerateDatabaseCredentialRequest, GenieClient, GenieGetMessageQueryResultResponse, GenieMessage, GetConnectionRequest, GetFunctionRequest, GetInferenceEndpointRequest, GetJobRequest, GetJobResponse, GetRunOutputRequest, GetRunOutputResponse, GetRunRequest, GetRunResponse, GetVolumeRequest, GetWarehouseResponse, InferenceEndpoint, InferenceEndpointDetailed, JobsClient, ListAppsRequest, ListAppsResponse, ListConnectionsRequest, ListConnectionsResponse, ListDatabaseInstancesRequest, ListDatabaseInstancesResponse, ListExperimentsRequest, ListExperimentsResponse, ListInferenceEndpointsRequest, ListInferenceEndpointsResponse, ListRunsRequest, ModelServingClient, ModularApiError, PostgresClient, QueryVectorIndexRequest, QueryVectorIndexResponse, ResultData, ResultManifest, RunNowRequest, RunNowResponse, Schema, ScimClient, ServiceError, StatementExecutionClient, StatementParameter, StatementResponse, StatementStatus, StatementStatus_State, SubmitRunRequest, SubmitRunResponse, TablesClient, VectorSearchClient, VolumeInfo, VolumesClient, WarehousesClient, WorkspaceAuth, type WorkspaceClient, type WorkspaceClientOptions, WorkspaceRequest, buildAppsClient, buildConnectionsClient, buildDatabaseClient, buildExperimentsClient, buildFilesClient, buildFunctionsClient, buildGenieClient, buildJobsClient, buildModelServingClient, buildPostgresClient, buildScimClient, buildStatementExecutionClient, buildTablesClient, buildVectorSearchClient, buildVolumesClient, buildWarehousesClient, buildWorkspaceAuth, createWorkspaceClient, isAuthConfigError, resolveProfile };
@@ -1,5 +1,5 @@
1
1
  import { ApiError } from "./errors.js";
2
- import { ConfigError, Context, Time, TimeUnits, loadConfigFile } from "./legacy.js";
2
+ import { ModularApiError, isAuthConfigError, resolveProfile } from "./modular.js";
3
3
  import { createWorkspaceClient } from "./factory.js";
4
4
 
5
- export { ApiError, ConfigError, Context, Time, TimeUnits, createWorkspaceClient, loadConfigFile };
5
+ export { ApiError, ModularApiError, createWorkspaceClient, isAuthConfigError, resolveProfile };
@@ -0,0 +1,109 @@
1
+ import { WorkspaceClientOptions } from "./options.js";
2
+ import { ApiError as ModularApiError } from "@databricks/sdk-core/apierror";
3
+ import { HttpRequest } from "@databricks/sdk-core/http";
4
+ import { resolve as resolveProfile } from "@databricks/sdk-core/profiles";
5
+ import { ScimClient, ScimClient as ScimClient$1 } from "@databricks/sdk-scim/v1";
6
+ import { ColumnInfo, Disposition, ExecuteStatementRequest, ExternalLink, Format, ResultData, ResultManifest, Schema, ServiceError, StatementExecutionClient, StatementExecutionClient as StatementExecutionClient$1, StatementParameter, StatementResponse, StatementStatus, StatementStatus_State } from "@databricks/sdk-statementexecution/v1";
7
+ import { EndpointHealth, EndpointInfo, EndpointState, GetWarehouseResponse, WarehousesClient, WarehousesClient as WarehousesClient$1 } from "@databricks/sdk-warehouses/v1";
8
+ import { App, AppsClient, AppsClient as AppsClient$1, ListAppsRequest, ListAppsResponse } from "@databricks/sdk-apps/v1";
9
+ import { DatabaseClient, DatabaseClient as DatabaseClient$1, DatabaseCredential, DatabaseInstance, GenerateDatabaseCredentialRequest, ListDatabaseInstancesRequest, ListDatabaseInstancesResponse } from "@databricks/sdk-database/v1";
10
+ import { Experiment, ExperimentsClient, ExperimentsClient as ExperimentsClient$1, ListExperimentsRequest, ListExperimentsResponse } from "@databricks/sdk-experiments/v1";
11
+ import { DirectoryEntry as FilesDirectoryEntry, DownloadFileResponse as FilesDownloadResponse, FilesClient, FilesClient as FilesClient$1 } from "@databricks/sdk-files/v2";
12
+ import { GenieClient, GenieClient as GenieClient$1, GenieGetMessageQueryResultResponse, GenieMessage } from "@databricks/sdk-genie/v1";
13
+ import { BaseRun, CancelRunRequest, GetJobRequest, GetJobResponse, GetRunOutputRequest, GetRunOutputResponse, GetRunRequest, GetRunResponse, JobsClient, JobsClient as JobsClient$1, ListRunsRequest, RunNowRequest, RunNowResponse, SubmitRunRequest, SubmitRunResponse } from "@databricks/sdk-jobs/v2";
14
+ import { GetInferenceEndpointRequest, InferenceEndpoint, InferenceEndpointDetailed, ListInferenceEndpointsRequest, ListInferenceEndpointsResponse, ModelServingClient, ModelServingClient as ModelServingClient$1 } from "@databricks/sdk-modelserving/v1";
15
+ import { PostgresClient, PostgresClient as PostgresClient$1 } from "@databricks/sdk-postgres/v1";
16
+ import { ConnectionInfo, ConnectionsClient, ConnectionsClient as ConnectionsClient$1, GetConnectionRequest, ListConnectionsRequest, ListConnectionsResponse } from "@databricks/sdk-uc-connections/v1";
17
+ import { FunctionInfo, FunctionsClient, FunctionsClient as FunctionsClient$1, GetFunctionRequest } from "@databricks/sdk-uc-functions/v1";
18
+ import { TablesClient, TablesClient as TablesClient$1 } from "@databricks/sdk-uc-tables/v1";
19
+ import { GetVolumeRequest, VolumeInfo, VolumesClient, VolumesClient as VolumesClient$1 } from "@databricks/sdk-uc-volumes/v1";
20
+ import { QueryVectorIndexRequest, QueryVectorIndexResponse, VectorSearchClient, VectorSearchClient as VectorSearchClient$1 } from "@databricks/sdk-vectorsearch/v1";
21
+
22
+ //#region src/workspace-client/modular.d.ts
23
+ /** Auth could not be configured (missing or unsupported credentials). */
24
+ declare class AuthConfigError extends Error {
25
+ name: string;
26
+ }
27
+ /** Whether `e` means auth isn't set up, from AppKit or the modular SDK. */
28
+ declare function isAuthConfigError(e: unknown): e is Error;
29
+ /** A raw REST call against the workspace host. */
30
+ interface WorkspaceRequest {
31
+ method: string;
32
+ /** Path on the workspace host, e.g. `/api/2.0/preview/scim/v2/Me`. */
33
+ path: string;
34
+ query?: Record<string, string>;
35
+ headers?: Headers;
36
+ body?: HttpRequest["body"];
37
+ signal?: AbortSignal;
38
+ }
39
+ /** Host, auth headers, and raw requests resolved exactly like the modular clients. */
40
+ interface WorkspaceAuth {
41
+ /** Scheme-normalized workspace host, without a trailing slash. */
42
+ getHost(): Promise<string>;
43
+ /** Set the auth header(s) (e.g. `Authorization`) on `headers`. */
44
+ authenticate(headers: Headers): Promise<void>;
45
+ /**
46
+ * Send a request through the modular transport (AppKit User-Agent + auth).
47
+ * Returns the raw `Response` (body unread, so it can stream); throws
48
+ * {@link ApiError} on a non-2xx status.
49
+ */
50
+ request(req: WorkspaceRequest): Promise<Response>;
51
+ }
52
+ /**
53
+ * Build host/credential resolution from {@link mapToClientOptions}, mirroring
54
+ * the modular SDK's `resolveClientConfig` (sdk-warehouses `dist/v1/transport.js`):
55
+ * resolve the profile from config file + env, explicit options win, and fall
56
+ * back to `defaultCredentials` over the resolved profile. Resolved once, lazily;
57
+ * a failed resolution is retried on the next call.
58
+ */
59
+ declare function buildWorkspaceAuth(opts: WorkspaceClientOptions): WorkspaceAuth;
60
+ /** Build a modular Warehouses client from wrapper options. */
61
+ declare function buildWarehousesClient(opts: WorkspaceClientOptions): WarehousesClient;
62
+ /** Build a modular Statement Execution client from wrapper options. */
63
+ declare function buildStatementExecutionClient(opts: WorkspaceClientOptions): StatementExecutionClient;
64
+ /**
65
+ * Build a modular SCIM client from wrapper options. Backs the facade's
66
+ * `currentUser` accessor: legacy `currentUser.me()` is `ScimClient.me({})`.
67
+ */
68
+ declare function buildScimClient(opts: WorkspaceClientOptions): ScimClient;
69
+ /** Build a modular Apps client from wrapper options. */
70
+ declare function buildAppsClient(opts: WorkspaceClientOptions): AppsClient;
71
+ /** Build a modular Genie client from wrapper options. */
72
+ declare function buildGenieClient(opts: WorkspaceClientOptions): GenieClient;
73
+ /** Build a modular Jobs (API 2.2) client from wrapper options. */
74
+ declare function buildJobsClient(opts: WorkspaceClientOptions): JobsClient;
75
+ /**
76
+ * Build a modular Files client from wrapper options. `getFileMetadata` is not
77
+ * used: its generated HEAD call parses the (empty) body and drops the response
78
+ * headers that carry the metadata, so the connector issues that HEAD through
79
+ * {@link WorkspaceAuth.request} instead.
80
+ */
81
+ declare function buildFilesClient(opts: WorkspaceClientOptions): FilesClient;
82
+ /**
83
+ * Build a modular Vector Search client from wrapper options. Query calls rely
84
+ * on the sdk-vectorsearch pnpm patch (`debugLevel` / `debugInfo`, `bigint` rows).
85
+ */
86
+ declare function buildVectorSearchClient(opts: WorkspaceClientOptions): VectorSearchClient;
87
+ /** Build a modular Model Serving (serving endpoints) client from wrapper options. */
88
+ declare function buildModelServingClient(opts: WorkspaceClientOptions): ModelServingClient;
89
+ /** Build a modular MLflow Experiments client from wrapper options. */
90
+ declare function buildExperimentsClient(opts: WorkspaceClientOptions): ExperimentsClient;
91
+ /** Build a modular Unity Catalog Tables client from wrapper options. */
92
+ declare function buildTablesClient(opts: WorkspaceClientOptions): TablesClient;
93
+ /** Build a modular Unity Catalog Volumes client from wrapper options. */
94
+ declare function buildVolumesClient(opts: WorkspaceClientOptions): VolumesClient;
95
+ /** Build a modular Unity Catalog Functions client from wrapper options. */
96
+ declare function buildFunctionsClient(opts: WorkspaceClientOptions): FunctionsClient;
97
+ /** Build a modular Unity Catalog Connections client from wrapper options. */
98
+ declare function buildConnectionsClient(opts: WorkspaceClientOptions): ConnectionsClient;
99
+ /** Build a modular Lakebase (provisioned) Database client from wrapper options. */
100
+ declare function buildDatabaseClient(opts: WorkspaceClientOptions): DatabaseClient;
101
+ /**
102
+ * Build a modular Lakebase Postgres (autoscaling: projects, branches,
103
+ * endpoints) client from wrapper options. Distinct from the provisioned
104
+ * `/api/2.0/database` instance API.
105
+ */
106
+ declare function buildPostgresClient(opts: WorkspaceClientOptions): PostgresClient;
107
+ //#endregion
108
+ export { type App, type AppsClient$1 as AppsClient, AuthConfigError, type BaseRun, type CancelRunRequest, type ColumnInfo, type ConnectionInfo, type ConnectionsClient$1 as ConnectionsClient, type DatabaseClient$1 as DatabaseClient, type DatabaseCredential, type DatabaseInstance, type Disposition, type EndpointHealth, type EndpointInfo, type EndpointState, type ExecuteStatementRequest, type Experiment, type ExperimentsClient$1 as ExperimentsClient, type ExternalLink, type FilesClient$1 as FilesClient, type FilesDirectoryEntry, type FilesDownloadResponse, type Format, type FunctionInfo, type FunctionsClient$1 as FunctionsClient, type GenerateDatabaseCredentialRequest, type GenieClient$1 as GenieClient, type GenieGetMessageQueryResultResponse, type GenieMessage, type GetConnectionRequest, type GetFunctionRequest, type GetInferenceEndpointRequest, type GetJobRequest, type GetJobResponse, type GetRunOutputRequest, type GetRunOutputResponse, type GetRunRequest, type GetRunResponse, type GetVolumeRequest, type GetWarehouseResponse, type InferenceEndpoint, type InferenceEndpointDetailed, type JobsClient$1 as JobsClient, type ListAppsRequest, type ListAppsResponse, type ListConnectionsRequest, type ListConnectionsResponse, type ListDatabaseInstancesRequest, type ListDatabaseInstancesResponse, type ListExperimentsRequest, type ListExperimentsResponse, type ListInferenceEndpointsRequest, type ListInferenceEndpointsResponse, type ListRunsRequest, type ModelServingClient$1 as ModelServingClient, ModularApiError, type PostgresClient$1 as PostgresClient, type QueryVectorIndexRequest, type QueryVectorIndexResponse, type ResultData, type ResultManifest, type RunNowRequest, type RunNowResponse, type Schema, type ScimClient$1 as ScimClient, type ServiceError, type StatementExecutionClient$1 as StatementExecutionClient, type StatementParameter, type StatementResponse, type StatementStatus, type StatementStatus_State, type SubmitRunRequest, type SubmitRunResponse, type TablesClient$1 as TablesClient, type VectorSearchClient$1 as VectorSearchClient, type VolumeInfo, type VolumesClient$1 as VolumesClient, type WarehousesClient$1 as WarehousesClient, WorkspaceAuth, WorkspaceRequest, buildAppsClient, buildConnectionsClient, buildDatabaseClient, buildExperimentsClient, buildFilesClient, buildFunctionsClient, buildGenieClient, buildJobsClient, buildModelServingClient, buildPostgresClient, buildScimClient, buildStatementExecutionClient, buildTablesClient, buildVectorSearchClient, buildVolumesClient, buildWarehousesClient, buildWorkspaceAuth, isAuthConfigError, resolveProfile };
109
+ //# sourceMappingURL=modular.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"modular.d.ts","names":[],"sources":["../../src/workspace-client/modular.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;cA6La,eAAA,SAAwB,KAAA;EAC1B,IAAA;AAAA;AADX;AAAA,iBAKgB,iBAAA,CAAkB,CAAA,YAAa,CAAA,IAAK,KAAA;;UAuNnC,gBAAA;EACf,MAAA;EAxNc;EA0Nd,IAAA;EACA,KAAA,GAAQ,MAAA;EACR,OAAA,GAAU,OAAA;EACV,IAAA,GAAO,WAAA;EACP,MAAA,GAAS,WAAA;AAAA;;UAIM,aAAA;EAXA;EAaf,OAAA,IAAW,OAAA;;EAEX,YAAA,CAAa,OAAA,EAAS,OAAA,GAAU,OAAA;EAVtB;;;;;EAgBV,OAAA,CAAQ,GAAA,EAAK,gBAAA,GAAmB,OAAA,CAAQ,QAAA;AAAA;;;;;;;;iBAU1B,kBAAA,CACd,IAAA,EAAM,sBAAA,GACL,aAAA;;iBAsGa,qBAAA,CACd,IAAA,EAAM,sBAAA,GACL,gBAAA;AA9HH;AAAA,iBAmIgB,6BAAA,CACd,IAAA,EAAM,sBAAA,GACL,wBAAA;;;;;iBAYa,eAAA,CAAgB,IAAA,EAAM,sBAAA,GAAyB,UAAA;;iBAK/C,eAAA,CAAgB,IAAA,EAAM,sBAAA,GAAyB,UAAA;;iBAsC/C,gBAAA,CAAiB,IAAA,EAAM,sBAAA,GAAyB,WAAA;;iBAQhD,eAAA,CAAgB,IAAA,EAAM,sBAAA,GAAyB,UAAA;;;;;;;iBAa/C,gBAAA,CAAiB,IAAA,EAAM,sBAAA,GAAyB,WAAA;;;;AA7LhE;iBAwMgB,uBAAA,CACd,IAAA,EAAM,sBAAA,GACL,kBAAA;;iBAWa,uBAAA,CACd,IAAA,EAAM,sBAAA,GACL,kBAAA;;iBAWa,sBAAA,CACd,IAAA,EAAM,sBAAA,GACL,iBAAA;;iBASa,iBAAA,CAAkB,IAAA,EAAM,sBAAA,GAAyB,YAAA;;iBAQjD,kBAAA,CACd,IAAA,EAAM,sBAAA,GACL,aAAA;;iBAQa,oBAAA,CACd,IAAA,EAAM,sBAAA,GACL,eAAA;;iBASa,sBAAA,CACd,IAAA,EAAM,sBAAA,GACL,iBAAA;;iBAWa,mBAAA,CACd,IAAA,EAAM,sBAAA,GACL,cAAA;;;;;;iBAkBa,mBAAA,CACd,IAAA,EAAM,sBAAA,GACL,cAAA"}