From 155ec06b52140eab94333c79ba201637d25c64eb Mon Sep 17 00:00:00 2001 From: "databricks-ci-ghec-2[bot]" <184307802+databricks-ci-ghec-2[bot]@users.noreply.github.com> Date: Sat, 29 Aug 2026 04:12:31 +0000 Subject: [PATCH] Update SDK to 0f2c9a3d507d46e8726ac09e0348d52d3f9c9bc8 --- package-lock.json | 676 +++++++++--------- packages/accessmanagement/src/v1/model.ts | 66 +- packages/aigateway/src/v1/client.ts | 30 +- packages/aigateway/src/v1/model.ts | 131 ++-- packages/alerts/src/v1/model.ts | 7 +- packages/alerts/src/v2/model.ts | 102 +-- packages/apps/src/v1/model.ts | 298 ++++---- packages/authentication/src/v1/model.ts | 60 +- packages/budgetpolicy/src/v1/model.ts | 12 +- packages/budgets/src/v1/model.ts | 26 +- packages/cleanrooms/src/v1/model.ts | 150 ++-- packages/clusterlibraries/src/v2/model.ts | 36 +- packages/clusterpolicies/src/v2/client.ts | 125 ---- packages/clusterpolicies/src/v2/index.ts | 6 - packages/clusterpolicies/src/v2/model.ts | 183 +---- packages/clusters/src/v2/client.ts | 134 ---- packages/clusters/src/v2/index.ts | 6 - packages/clusters/src/v2/model.ts | 293 +++----- packages/commandexecution/src/v2/model.ts | 18 +- packages/customllms/src/v1/model.ts | 61 +- packages/database/src/v1/model.ts | 92 +-- packages/dataclassification/src/v1/model.ts | 28 +- packages/dataquality/src/v1/model.ts | 164 ++--- packages/disasterrecovery/src/v1/model.ts | 124 ++-- packages/environments/src/v1/model.ts | 26 +- packages/experiments/src/v1/model.ts | 208 +++--- packages/features/src/v1/model.ts | 530 +++++++------- packages/featurestore/src/v1/model.ts | 44 +- packages/files/src/v2/model.ts | 59 +- packages/forecasting/src/v1/model.ts | 22 +- packages/genie/src/v1/client.ts | 36 + packages/genie/src/v1/index.ts | 1 + packages/genie/src/v1/model.ts | 324 +++++---- packages/gitcredentials/src/v1/model.ts | 35 +- packages/globalinitscripts/src/v2/model.ts | 26 +- packages/instancepools/src/v2/model.ts | 19 +- packages/instanceprofiles/src/v2/model.ts | 16 +- packages/jobs/src/v2/index.ts | 2 + packages/jobs/src/v2/model.ts | 561 +++++++++------ packages/keyconfigurations/src/v1/model.ts | 34 +- packages/knowledgeassistants/src/v1/model.ts | 118 +-- packages/lakeview/src/v1/client.ts | 62 +- packages/lakeview/src/v1/model.ts | 95 ++- packages/logdelivery/src/v1/model.ts | 78 +- packages/marketplaces/src/v1/model.ts | 295 ++++---- packages/modelregistry/src/v1/model.ts | 190 ++--- packages/modelserving/src/v1/model.ts | 193 +++-- packages/modelservingquery/src/v1/model.ts | 4 +- packages/networking/src/v1/model.ts | 224 +++--- packages/pipelines/src/v2/model.ts | 180 +++-- packages/policyfamilies/src/v2/model.ts | 2 +- packages/postgres/src/v1/client.ts | 187 +++++ packages/postgres/src/v1/index.ts | 11 + packages/postgres/src/v1/model.ts | 534 +++++++++++--- packages/queries/src/v1/model.ts | 19 +- packages/queryhistory/src/v1/model.ts | 4 +- packages/repos/src/v1/model.ts | 16 +- packages/scim/src/v1/model.ts | 48 +- packages/secrets/src/v1/model.ts | 76 +- packages/settings/src/v2/model.ts | 58 +- packages/sharing/src/v1/model.ts | 90 +-- packages/statementexecution/src/v1/model.ts | 26 +- .../storageconfigurations/src/v1/model.ts | 22 +- packages/supervisoragents/src/v1/model.ts | 102 +-- packages/tagassignments/src/v1/model.ts | 40 +- packages/tagpolicies/src/v1/model.ts | 22 +- packages/tokenmanagement/src/v1/model.ts | 15 +- packages/tokens/src/v1/model.ts | 19 +- packages/uc/abacpolicies/src/v1/index.ts | 4 + packages/uc/abacpolicies/src/v1/model.ts | 259 ++++++- .../uc/artifactallowlists/src/v1/model.ts | 30 +- packages/uc/catalogs/src/v1/model.ts | 36 +- packages/uc/connections/src/v1/model.ts | 24 +- packages/uc/credentials/src/v1/model.ts | 120 ++-- .../uc/entitytagassignments/src/v1/model.ts | 40 +- packages/uc/externallineage/src/v1/model.ts | 60 +- packages/uc/externallocations/src/v1/model.ts | 44 +- packages/uc/externalmetadata/src/v1/model.ts | 20 +- packages/uc/functions/src/v1/model.ts | 52 +- packages/uc/grants/src/v1/model.ts | 16 +- packages/uc/metastores/src/v1/model.ts | 91 ++- packages/uc/registeredmodels/src/v1/model.ts | 58 +- packages/uc/resourcequotas/src/v1/model.ts | 10 +- packages/uc/rfa/src/v1/model.ts | 14 +- packages/uc/schemas/src/v1/model.ts | 52 +- packages/uc/secrets/src/v1/model.ts | 36 +- packages/uc/systemschemas/src/v1/model.ts | 14 +- packages/uc/tables/src/v1/model.ts | 136 ++-- packages/uc/volumes/src/v1/model.ts | 12 +- packages/uc/workspacebindings/src/v1/model.ts | 25 +- packages/vectorsearch/src/v1/model.ts | 96 +-- packages/warehouses/src/v1/model.ts | 34 +- packages/workspaces/src/v1/model.ts | 16 +- 93 files changed, 4554 insertions(+), 4246 deletions(-) diff --git a/package-lock.json b/package-lock.json index 1f2fb4657..cf7f6c6d8 100644 --- a/package-lock.json +++ b/package-lock.json @@ -6724,12 +6724,12 @@ }, "packages/accessmanagement": { "name": "@databricks/sdk-accessmanagement", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6740,12 +6740,12 @@ }, "packages/aigateway": { "name": "@databricks/sdk-aigateway", - "version": "0.8.0", + "version": "0.12.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6756,12 +6756,12 @@ }, "packages/alerts": { "name": "@databricks/sdk-alerts", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6772,12 +6772,12 @@ }, "packages/apps": { "name": "@databricks/sdk-apps", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6805,10 +6805,10 @@ }, "packages/auth": { "name": "@databricks/sdk-auth", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-core": ">=0.41.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", "zod": "^4.3.6" }, "engines": { @@ -6817,12 +6817,12 @@ }, "packages/authentication": { "name": "@databricks/sdk-authentication", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6850,12 +6850,12 @@ }, "packages/budgetpolicy": { "name": "@databricks/sdk-budgetpolicy", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6866,12 +6866,12 @@ }, "packages/budgets": { "name": "@databricks/sdk-budgets", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6933,12 +6933,12 @@ }, "packages/cleanrooms": { "name": "@databricks/sdk-cleanrooms", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6949,12 +6949,12 @@ }, "packages/clusterlibraries": { "name": "@databricks/sdk-clusterlibraries", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6965,12 +6965,12 @@ }, "packages/clusterpolicies": { "name": "@databricks/sdk-clusterpolicies", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6981,12 +6981,12 @@ }, "packages/clusters": { "name": "@databricks/sdk-clusters", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -6997,12 +6997,12 @@ }, "packages/commandexecution": { "name": "@databricks/sdk-commandexecution", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7030,7 +7030,7 @@ }, "packages/core": { "name": "@databricks/sdk-core", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { "json-bigint": "^1.0.0", @@ -7059,12 +7059,12 @@ }, "packages/customllms": { "name": "@databricks/sdk-customllms", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7075,12 +7075,12 @@ }, "packages/database": { "name": "@databricks/sdk-database", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7091,12 +7091,12 @@ }, "packages/dataclassification": { "name": "@databricks/sdk-dataclassification", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7107,12 +7107,12 @@ }, "packages/dataquality": { "name": "@databricks/sdk-dataquality", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7123,12 +7123,12 @@ }, "packages/disasterrecovery": { "name": "@databricks/sdk-disasterrecovery", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7156,12 +7156,12 @@ }, "packages/environments": { "name": "@databricks/sdk-environments", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7190,12 +7190,12 @@ }, "packages/experiments": { "name": "@databricks/sdk-experiments", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7257,12 +7257,12 @@ }, "packages/features": { "name": "@databricks/sdk-features", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7273,12 +7273,12 @@ }, "packages/featurestore": { "name": "@databricks/sdk-featurestore", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7289,12 +7289,12 @@ }, "packages/files": { "name": "@databricks/sdk-files", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7305,12 +7305,12 @@ }, "packages/forecasting": { "name": "@databricks/sdk-forecasting", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7338,12 +7338,12 @@ }, "packages/genie": { "name": "@databricks/sdk-genie", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7354,12 +7354,12 @@ }, "packages/gitcredentials": { "name": "@databricks/sdk-gitcredentials", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7370,12 +7370,12 @@ }, "packages/globalinitscripts": { "name": "@databricks/sdk-globalinitscripts", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7403,12 +7403,12 @@ }, "packages/instancepools": { "name": "@databricks/sdk-instancepools", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7419,12 +7419,12 @@ }, "packages/instanceprofiles": { "name": "@databricks/sdk-instanceprofiles", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7435,12 +7435,12 @@ }, "packages/jobs": { "name": "@databricks/sdk-jobs", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7451,12 +7451,12 @@ }, "packages/keyconfigurations": { "name": "@databricks/sdk-keyconfigurations", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7467,12 +7467,12 @@ }, "packages/knowledgeassistants": { "name": "@databricks/sdk-knowledgeassistants", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7483,12 +7483,12 @@ }, "packages/lakeview": { "name": "@databricks/sdk-lakeview", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7499,12 +7499,12 @@ }, "packages/logdelivery": { "name": "@databricks/sdk-logdelivery", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7515,12 +7515,12 @@ }, "packages/marketplaces": { "name": "@databricks/sdk-marketplaces", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7548,12 +7548,12 @@ }, "packages/modelregistry": { "name": "@databricks/sdk-modelregistry", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7564,12 +7564,12 @@ }, "packages/modelserving": { "name": "@databricks/sdk-modelserving", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7580,12 +7580,12 @@ }, "packages/modelservingquery": { "name": "@databricks/sdk-modelservingquery", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7596,12 +7596,12 @@ }, "packages/networking": { "name": "@databricks/sdk-networking", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7612,12 +7612,12 @@ }, "packages/notificationdestinations": { "name": "@databricks/sdk-notificationdestinations", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7628,12 +7628,12 @@ }, "packages/oauth": { "name": "@databricks/sdk-oauth", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7661,11 +7661,11 @@ }, "packages/options": { "name": "@databricks/sdk-options", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0" + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0" }, "engines": { "node": ">=22.0.0" @@ -7673,12 +7673,12 @@ }, "packages/pipelines": { "name": "@databricks/sdk-pipelines", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7689,12 +7689,12 @@ }, "packages/policyfamilies": { "name": "@databricks/sdk-policyfamilies", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7705,12 +7705,12 @@ }, "packages/postgres": { "name": "@databricks/sdk-postgres", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7721,12 +7721,12 @@ }, "packages/queries": { "name": "@databricks/sdk-queries", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7737,12 +7737,12 @@ }, "packages/queryhistory": { "name": "@databricks/sdk-queryhistory", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7770,12 +7770,12 @@ }, "packages/repos": { "name": "@databricks/sdk-repos", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7837,12 +7837,12 @@ }, "packages/scim": { "name": "@databricks/sdk-scim", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7870,12 +7870,12 @@ }, "packages/secrets": { "name": "@databricks/sdk-secrets", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7903,12 +7903,12 @@ }, "packages/settings": { "name": "@databricks/sdk-settings", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7919,12 +7919,12 @@ }, "packages/sharing": { "name": "@databricks/sdk-sharing", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7935,12 +7935,12 @@ }, "packages/statementexecution": { "name": "@databricks/sdk-statementexecution", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7951,12 +7951,12 @@ }, "packages/storageconfigurations": { "name": "@databricks/sdk-storageconfigurations", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -7967,12 +7967,12 @@ }, "packages/supervisoragents": { "name": "@databricks/sdk-supervisoragents", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8017,12 +8017,12 @@ }, "packages/tagassignments": { "name": "@databricks/sdk-tagassignments", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8033,12 +8033,12 @@ }, "packages/tagpolicies": { "name": "@databricks/sdk-tagpolicies", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8049,12 +8049,12 @@ }, "packages/tokenmanagement": { "name": "@databricks/sdk-tokenmanagement", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8065,12 +8065,12 @@ }, "packages/tokens": { "name": "@databricks/sdk-tokens", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8081,12 +8081,12 @@ }, "packages/uc/abacpolicies": { "name": "@databricks/sdk-uc-abacpolicies", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8097,12 +8097,12 @@ }, "packages/uc/artifactallowlists": { "name": "@databricks/sdk-uc-artifactallowlists", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8113,12 +8113,12 @@ }, "packages/uc/catalogs": { "name": "@databricks/sdk-uc-catalogs", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8129,12 +8129,12 @@ }, "packages/uc/connections": { "name": "@databricks/sdk-uc-connections", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8145,12 +8145,12 @@ }, "packages/uc/credentials": { "name": "@databricks/sdk-uc-credentials", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8161,12 +8161,12 @@ }, "packages/uc/entitytagassignments": { "name": "@databricks/sdk-uc-entitytagassignments", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8177,12 +8177,12 @@ }, "packages/uc/externallineage": { "name": "@databricks/sdk-uc-externallineage", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8193,12 +8193,12 @@ }, "packages/uc/externallocations": { "name": "@databricks/sdk-uc-externallocations", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8209,12 +8209,12 @@ }, "packages/uc/externalmetadata": { "name": "@databricks/sdk-uc-externalmetadata", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8225,12 +8225,12 @@ }, "packages/uc/functions": { "name": "@databricks/sdk-uc-functions", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8241,12 +8241,12 @@ }, "packages/uc/grants": { "name": "@databricks/sdk-uc-grants", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8257,12 +8257,12 @@ }, "packages/uc/metastores": { "name": "@databricks/sdk-uc-metastores", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8273,12 +8273,12 @@ }, "packages/uc/onlinetables": { "name": "@databricks/sdk-uc-onlinetables", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8306,12 +8306,12 @@ }, "packages/uc/registeredmodels": { "name": "@databricks/sdk-uc-registeredmodels", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8322,12 +8322,12 @@ }, "packages/uc/resourcequotas": { "name": "@databricks/sdk-uc-resourcequotas", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8338,12 +8338,12 @@ }, "packages/uc/rfa": { "name": "@databricks/sdk-uc-rfa", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8354,12 +8354,12 @@ }, "packages/uc/schemas": { "name": "@databricks/sdk-uc-schemas", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8370,12 +8370,12 @@ }, "packages/uc/secrets": { "name": "@databricks/sdk-uc-secrets", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8386,12 +8386,12 @@ }, "packages/uc/systemschemas": { "name": "@databricks/sdk-uc-systemschemas", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8402,12 +8402,12 @@ }, "packages/uc/tables": { "name": "@databricks/sdk-uc-tables", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8418,12 +8418,12 @@ }, "packages/uc/volumes": { "name": "@databricks/sdk-uc-volumes", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8434,12 +8434,12 @@ }, "packages/uc/workspacebindings": { "name": "@databricks/sdk-uc-workspacebindings", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8450,12 +8450,12 @@ }, "packages/usagedashboards": { "name": "@databricks/sdk-usagedashboards", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8483,12 +8483,12 @@ }, "packages/vectorsearch": { "name": "@databricks/sdk-vectorsearch", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8516,12 +8516,12 @@ }, "packages/warehouses": { "name": "@databricks/sdk-warehouses", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" @@ -8566,12 +8566,12 @@ }, "packages/workspaces": { "name": "@databricks/sdk-workspaces", - "version": "0.41.0", + "version": "0.45.0", "license": "Apache-2.0", "dependencies": { - "@databricks/sdk-auth": ">=0.41.0 <1.0.0", - "@databricks/sdk-core": ">=0.41.0 <1.0.0", - "@databricks/sdk-options": ">=0.41.0 <1.0.0", + "@databricks/sdk-auth": ">=0.45.0 <1.0.0", + "@databricks/sdk-core": ">=0.45.0 <1.0.0", + "@databricks/sdk-options": ">=0.45.0 <1.0.0", "@js-temporal/polyfill": "^0.5.0", "json-bigint": "^1.0.0", "zod": "^4.3.6" diff --git a/packages/accessmanagement/src/v1/model.ts b/packages/accessmanagement/src/v1/model.ts index 5c39bea51..230b8100e 100644 --- a/packages/accessmanagement/src/v1/model.ts +++ b/packages/accessmanagement/src/v1/model.ts @@ -110,25 +110,25 @@ export interface Actor { } export interface CheckPolicyRequest { - actor?: Actor | undefined; - permission?: string | undefined; + actor: Actor; + permission: string; /** * Ex: (servicePrincipal/use, accounts//servicePrincipals/) * Ex: (servicePrincipal.ruleSet/update, accounts//servicePrincipals//ruleSets/default) */ - resource?: string | undefined; - consistencyToken?: ConsistencyToken | undefined; - authzIdentity?: RequestAuthzIdentity | undefined; + resource: string; + consistencyToken: ConsistencyToken; + authzIdentity: RequestAuthzIdentity; resourceInfo?: ResourceInfo | undefined; } export interface CheckPolicyResponse { isPermitted?: boolean | undefined; - consistencyToken?: ConsistencyToken | undefined; + consistencyToken: ConsistencyToken; } export interface ConsistencyToken { - value?: string | undefined; + value: string; } /** Removes all permission assignments for a workspace given a principal. */ @@ -164,7 +164,7 @@ export interface GetRuleSetRequest { * `name=accounts//servicePrincipals//ruleSets/default` | A name for a rule set on the service principal. * `name=accounts//tagPolicies//ruleSets/default` | A name for a rule set on the tag policy. */ - name?: string | undefined; + name: string; /** * Etag used for versioning. The response is at least as fresh as the eTag provided. Etag is used for optimistic * concurrency control as a way to help prevent simultaneous updates of a rule set from overwriting each other. It is @@ -177,7 +177,7 @@ export interface GetRuleSetRequest { * `etag=` | An empty etag can only be used in GET to indicate no freshness requirements. * `etag=RENUAAABhSweA4NvVmmUYdiU717H3Tgy0UJdor3gE4a+mq/oj9NjAf8ZsQ==` | An etag encoded a specific version of the rule set to get or to be updated. */ - etag?: string | undefined; + etag: string; } export interface GrantRule { @@ -191,7 +191,7 @@ export interface GrantRule { */ principals?: string[] | undefined; /** Role that is assigned to the list of principals. */ - role?: string | undefined; + role: string; } export interface ListAssignableRolesForResourceRequest { @@ -207,7 +207,7 @@ export interface ListAssignableRolesForResourceRequest { * `resource=accounts//servicePrincipals/` | A resource name for the service principal. * `resource=accounts//tagPolicies/` | A resource name for the tag policy. */ - resource?: string | undefined; + resource: string; } export interface ListAssignableRolesForResourceResponse { @@ -301,7 +301,7 @@ export interface PrincipalOutput { export interface ResourceInfo { /** Id of the current resource. */ - id?: string | undefined; + id: string; /** Parent resource info for the current resource. The parent may have another parent. */ parentResourceInfo?: ResourceInfo | undefined; /** The legacy acl path of the current resource. */ @@ -310,12 +310,12 @@ export interface ResourceInfo { export interface Role { /** Role to assign to a principal or a list of principals on a resource. */ - name?: string | undefined; + name: string; } export interface RuleSet { /** Name of the rule set. */ - name?: string | undefined; + name: string; /** * Identifies the version of the rule set returned. * Etag used for versioning. The response is at least as fresh as the eTag provided. @@ -325,13 +325,13 @@ export interface RuleSet { * order to avoid race conditions that is get an etag from a GET rule set request, and pass it * with the PUT update request to identify the rule set version you are updating. */ - etag?: string | undefined; + etag: string; grantRules?: GrantRule[] | undefined; } export interface RuleSetUpdateRequest { /** Name of the rule set. */ - name?: string | undefined; + name: string; /** * Identifies the version of the rule set returned. * Etag used for versioning. The response is at least as fresh as the eTag provided. @@ -341,7 +341,7 @@ export interface RuleSetUpdateRequest { * order to avoid race conditions that is get an etag from a GET rule set request, and pass it * with the PUT update request to identify the rule set version you are updating. */ - etag?: string | undefined; + etag: string; grantRules?: GrantRule[] | undefined; } @@ -365,8 +365,8 @@ export interface UpdateRuleSetRequest { /** account ID. */ accountId?: string | undefined; /** Name of the rule set. */ - name?: string | undefined; - ruleSet?: RuleSetUpdateRequest | undefined; + name: string; + ruleSet: RuleSetUpdateRequest; } export interface UpdateWorkspacePermissionAssignmentRequest { @@ -430,9 +430,7 @@ export const unmarshalCheckPolicyResponseSchema: z.ZodType z .object({ is_permitted: z.boolean().optional(), - consistency_token: z - .lazy(() => unmarshalConsistencyTokenSchema) - .optional(), + consistency_token: z.lazy(() => unmarshalConsistencyTokenSchema), }) .transform(d => ({ isPermitted: d.is_permitted, @@ -441,7 +439,7 @@ export const unmarshalCheckPolicyResponseSchema: z.ZodType export const unmarshalConsistencyTokenSchema: z.ZodType = z .object({ - value: z.string().optional(), + value: z.string(), }) .transform(d => ({ value: d.value, @@ -453,7 +451,7 @@ export const unmarshalDeleteWorkspacePermissionAssignmentResponseSchema: z.ZodTy export const unmarshalGrantRuleSchema: z.ZodType = z .object({ principals: z.array(z.string()).optional(), - role: z.string().optional(), + role: z.string(), }) .transform(d => ({ principals: d.principals, @@ -579,7 +577,7 @@ export const unmarshalPrincipalOutputSchema: z.ZodType = z export const unmarshalRoleSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -587,8 +585,8 @@ export const unmarshalRoleSchema: z.ZodType = z export const unmarshalRuleSetSchema: z.ZodType = z .object({ - name: z.string().optional(), - etag: z.string().optional(), + name: z.string(), + etag: z.string(), grant_rules: z.array(z.lazy(() => unmarshalGrantRuleSchema)).optional(), }) .transform(d => ({ @@ -651,7 +649,7 @@ export const marshalActorSchema: z.ZodType = z export const marshalConsistencyTokenSchema: z.ZodType = z .object({ - value: z.string().optional(), + value: z.string(), }) .transform(d => ({ value: d.value, @@ -660,7 +658,7 @@ export const marshalConsistencyTokenSchema: z.ZodType = z export const marshalGrantRuleSchema: z.ZodType = z .object({ principals: z.array(z.string()).optional(), - role: z.string().optional(), + role: z.string(), }) .transform(d => ({ principals: d.principals, @@ -669,7 +667,7 @@ export const marshalGrantRuleSchema: z.ZodType = z export const marshalResourceInfoSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), parentResourceInfo: z.lazy(() => marshalResourceInfoSchema).optional(), legacyAclPath: z.string().optional(), }) @@ -681,8 +679,8 @@ export const marshalResourceInfoSchema: z.ZodType = z export const marshalRuleSetUpdateRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - etag: z.string().optional(), + name: z.string(), + etag: z.string(), grantRules: z.array(z.lazy(() => marshalGrantRuleSchema)).optional(), }) .transform(d => ({ @@ -722,8 +720,8 @@ export const marshalUpdateObjectPermissionsRequestSchema: z.ZodType = z export const marshalUpdateRuleSetRequestSchema: z.ZodType = z .object({ accountId: z.string().optional(), - name: z.string().optional(), - ruleSet: z.lazy(() => marshalRuleSetUpdateRequestSchema).optional(), + name: z.string(), + ruleSet: z.lazy(() => marshalRuleSetUpdateRequestSchema), }) .transform(d => ({ account_id: d.accountId, diff --git a/packages/aigateway/src/v1/client.ts b/packages/aigateway/src/v1/client.ts index bef04e361..25bfec0be 100644 --- a/packages/aigateway/src/v1/client.ts +++ b/packages/aigateway/src/v1/client.ts @@ -267,7 +267,10 @@ export class AiGatewayClient { const url = `${host}/api/2.1/unity-catalog/${req.name ?? ''}`; const params = new URLSearchParams(); if (req.etag !== undefined) { - params.append('etag', String(req.etag)); + params.append( + 'etag', + btoa(Array.from(req.etag, b => String.fromCharCode(b)).join('')) + ); } const query = params.toString(); const fullUrl = query !== '' ? `${url}?${query}` : url; @@ -304,7 +307,10 @@ export class AiGatewayClient { const url = `${host}/api/2.1/unity-catalog/${req.name ?? ''}`; const params = new URLSearchParams(); if (req.etag !== undefined) { - params.append('etag', String(req.etag)); + params.append( + 'etag', + btoa(Array.from(req.etag, b => String.fromCharCode(b)).join('')) + ); } const query = params.toString(); const fullUrl = query !== '' ? `${url}?${query}` : url; @@ -340,7 +346,10 @@ export class AiGatewayClient { const url = `${host}/api/2.1/unity-catalog/${req.name ?? ''}`; const params = new URLSearchParams(); if (req.etag !== undefined) { - params.append('etag', String(req.etag)); + params.append( + 'etag', + btoa(Array.from(req.etag, b => String.fromCharCode(b)).join('')) + ); } const query = params.toString(); const fullUrl = query !== '' ? `${url}?${query}` : url; @@ -695,7 +704,10 @@ export class AiGatewayClient { params.append('update_mask', req.updateMask.toString()); } if (req.etag !== undefined) { - params.append('etag', String(req.etag)); + params.append( + 'etag', + btoa(Array.from(req.etag, b => String.fromCharCode(b)).join('')) + ); } const query = params.toString(); const fullUrl = query !== '' ? `${url}?${query}` : url; @@ -749,7 +761,10 @@ export class AiGatewayClient { params.append('update_mask', req.updateMask.toString()); } if (req.etag !== undefined) { - params.append('etag', String(req.etag)); + params.append( + 'etag', + btoa(Array.from(req.etag, b => String.fromCharCode(b)).join('')) + ); } const query = params.toString(); const fullUrl = query !== '' ? `${url}?${query}` : url; @@ -805,7 +820,10 @@ export class AiGatewayClient { params.append('update_mask', req.updateMask.toString()); } if (req.etag !== undefined) { - params.append('etag', String(req.etag)); + params.append( + 'etag', + btoa(Array.from(req.etag, b => String.fromCharCode(b)).join('')) + ); } const query = params.toString(); const fullUrl = query !== '' ? `${url}?${query}` : url; diff --git a/packages/aigateway/src/v1/model.ts b/packages/aigateway/src/v1/model.ts index a690a52b2..288c8639f 100644 --- a/packages/aigateway/src/v1/model.ts +++ b/packages/aigateway/src/v1/model.ts @@ -211,14 +211,14 @@ export interface CreateMcpServiceRequest { * Format: `schemas/{catalog}.{schema}`. * Each `{...}` component is capped at 255 characters individually. */ - parent?: string | undefined; + parent: string; /** Name for the MCP service, e.g. "my_mcp_service". */ - mcpServiceId?: string | undefined; + mcpServiceId: string; /** * The MCP service to create. The server populates `name` from `parent` + * `mcp_service_id`; clients should leave it unset. */ - mcpService?: McpService | undefined; + mcpService: McpService; } /** Request to create a new model provider service. */ @@ -228,14 +228,14 @@ export interface CreateModelProviderServiceRequest { * Format: `schemas/{catalog}.{schema}`. * Each `{...}` component is capped at 255 characters individually. */ - parent?: string | undefined; + parent: string; /** Name for the model provider service, e.g. "openai_prod". */ - modelProviderServiceId?: string | undefined; + modelProviderServiceId: string; /** * The model provider service to create. The server populates `name` from * `parent` + `model_provider_service_id`; clients should leave it unset. */ - modelProviderService?: ModelProviderService | undefined; + modelProviderService: ModelProviderService; } /** Request to create a new model service. */ @@ -245,14 +245,14 @@ export interface CreateModelServiceRequest { * Format: `schemas/{catalog}.{schema}`. * Each `{...}` component is capped at 255 characters individually. */ - parent?: string | undefined; + parent: string; /** Name for the model service, e.g. "my_model_service". */ - modelServiceId?: string | undefined; + modelServiceId: string; /** * The model service to create. The server populates `name` from `parent` + * `model_service_id`; clients should leave it unset. */ - modelService?: ModelService | undefined; + modelService: ModelService; } /** Request to delete an MCP service. */ @@ -262,7 +262,7 @@ export interface DeleteMcpServiceRequest { * Format: `mcp-services/{catalog}.{schema}.{mcp_service}`. * Each `{...}` component is capped at 255 characters individually. */ - name?: string | undefined; + name: string; /** * If-match precondition: when set, the delete proceeds only if the current * server-side etag matches. Empty means unconditional delete. @@ -277,7 +277,7 @@ export interface DeleteModelProviderServiceRequest { * Format: `model-provider-services/{catalog}.{schema}.{model_provider_service}`. * Each `{...}` component is capped at 255 characters individually. */ - name?: string | undefined; + name: string; /** * If-match precondition: when set, the delete proceeds only if the current * server-side etag matches. Empty means unconditional delete. @@ -292,7 +292,7 @@ export interface DeleteModelServiceRequest { * Format: `model-services/{catalog}.{schema}.{model_service}`. * Each `{...}` component is capped at 255 characters individually. */ - name?: string | undefined; + name: string; /** * If-match precondition: when set, the delete proceeds only if the current * server-side etag matches. Empty means unconditional delete. @@ -307,7 +307,7 @@ export interface GetMcpServiceRequest { * Format: `mcp-services/{catalog}.{schema}.{mcp_service}`. * Each `{...}` component is capped at 255 characters individually. */ - name?: string | undefined; + name: string; } /** Request to get a model provider service. */ @@ -317,7 +317,7 @@ export interface GetModelProviderServiceRequest { * Format: `model-provider-services/{catalog}.{schema}.{model_provider_service}`. * Each `{...}` component is capped at 255 characters individually. */ - name?: string | undefined; + name: string; } /** Request to get a model service. */ @@ -327,7 +327,7 @@ export interface GetModelServiceRequest { * Format: `model-services/{catalog}.{schema}.{model_service}`. * Each `{...}` component is capped at 255 characters individually. */ - name?: string | undefined; + name: string; } /** @@ -345,7 +345,7 @@ export interface InferenceTableConfig { * Format: `schemas/{catalog}.{schema}`. Set at create time and immutable * thereafter; changing it on an existing service is rejected. */ - parent?: string | undefined; + parent: string; /** * Prefix for the inference-table's UC-registered name. The actual leaf name UC * stores is `_payload`; the `_payload` suffix is appended @@ -592,7 +592,7 @@ export interface McpServiceConfig_SourceConnection { * Name of the UC connection that hosts the MCP server, as * `connections/{catalog}.{schema}.{connection}`. */ - name?: string | undefined; + name: string; isDeleted?: boolean | undefined; } @@ -1238,7 +1238,7 @@ export interface ModelProviderServiceConfig_ModelTargetConfig { * hook for external destinations is the ModelProviderService referenced by * `ExternalModelConfig.model_provider_service`, not the model itself. */ - model?: string | undefined; + model: string; /** * Provider-native API types the model supports (e.g. * "openai/v1/chat/completions"). Used by the platform for request/response @@ -1308,10 +1308,9 @@ export interface ModelProviderServiceConfig_OpenAiProviderDirectConfig { export interface ModelProviderServiceConfig_ProviderSecret { /** * How the credential value is supplied. Exactly one variant may be set. - * (-- Wrapped in a oneof so a future non-plaintext source (e.g. a Databricks - * secret reference `{{secrets//}}`, mirroring AIGW v2's - * ProviderSecret) can be added as an additional variant without a breaking - * change. --) + * (-- Wrapped in a oneof so a non-plaintext source can be added as an + * additional variant without a breaking change; `secret_reference` is + * that variant, and further sources can follow the same way. --) */ value?: | { @@ -1339,7 +1338,7 @@ export interface ModelProviderServiceConfig_ServiceCredential { * create the caller supplies the name here. On read it reflects the * credential's current name at read time. */ - name?: string | undefined; + name: string; } /** @@ -1418,11 +1417,9 @@ export interface ModelServiceConfig { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface ModelServiceConfig_DestinationConfig { /** User-facing label for this destination, used in routing references. */ - name?: string | undefined; + name: string; /** Backing-model category. Determines which oneof variant is populated. */ - destinationType?: - | ModelServiceConfig_DestinationConfig_DestinationType - | undefined; + destinationType: ModelServiceConfig_DestinationConfig_DestinationType; /** * Share of traffic sent to this destination, 0-100. Optional on fallback * destinations; see FallbackConfig. @@ -1470,13 +1467,13 @@ export interface ModelServiceConfig_ExternalModelConfig { * Format: `model-provider-services/{catalog}.{schema}.{model_provider_service}`. * Each `{...}` component is capped at 255 characters individually. */ - modelProviderService?: string | undefined; + modelProviderService: string; /** * Routing target for the destination: the provider-side model selected from * the referenced ModelProviderService's `targets` catalog, plus the unified * API types the platform should translate to/from at request time. */ - target?: ModelProviderServiceConfig_ModelTargetConfig | undefined; + target: ModelProviderServiceConfig_ModelTargetConfig; } /** @@ -1504,7 +1501,7 @@ export interface ModelServiceConfig_PayPerTokenConfig { * Resource name of the UC model. * Format: `models/{catalog}.{schema}.{model}`. */ - model?: string | undefined; + model: string; } /** @@ -1523,7 +1520,7 @@ export interface ModelServiceConfig_ProvisionedThroughputConfig { * caller picks which one this destination routes to. The endpoint must * exist at create time. */ - modelServingEndpoint?: string | undefined; + modelServingEndpoint: string; /** * UC model FQN of the model served by the backing endpoint (e.g., * `system.ai.databricks-claude-opus-4-6`). Resolved from Model Serving at @@ -1582,9 +1579,9 @@ export interface ModelServiceConfig_RoutingConfig_TrafficSplitting {} */ export interface RateLimit { /** Scope key. Determines whether `principal` is required. */ - key?: RateLimit_RateLimitKey | undefined; + key: RateLimit_RateLimitKey; /** Renewal period. */ - renewalPeriod?: RateLimit_RateLimitRenewalPeriod | undefined; + renewalPeriod: RateLimit_RateLimitRenewalPeriod; /** * Principal this limit applies to: user email, group name, or service * principal application ID. Required unless `key` is @@ -1617,13 +1614,13 @@ export interface UpdateMcpServiceRequest { * resource (`mcp-services/{catalog}.{schema}.{mcp_service}`); only fields * listed in `update_mask` are applied. */ - mcpService?: McpService | undefined; + mcpService: McpService; /** * The list of fields to update. The framework validates each path against * the `mcp_service` field above. Wildcard paths (`paths: ["*"]`) are not * supported; list each field path explicitly. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; /** * If-match precondition: when set, the update proceeds only if the * current server-side etag matches. Empty means an unconditional update. @@ -1642,13 +1639,13 @@ export interface UpdateModelProviderServiceRequest { * (`model-provider-services/{catalog}.{schema}.{model_provider_service}`); * only fields listed in `update_mask` are applied. */ - modelProviderService?: ModelProviderService | undefined; + modelProviderService: ModelProviderService; /** * The list of fields to update. The framework validates each path against * the `model_provider_service` field above. Wildcard paths (`paths: ["*"]`) * are not supported; list each field path explicitly. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; /** * If-match precondition: when set, the update proceeds only if the * current server-side etag matches. Empty means an unconditional update. @@ -1666,13 +1663,13 @@ export interface UpdateModelServiceRequest { * resource (`model-services/{catalog}.{schema}.{model_service}`); only * fields listed in `update_mask` are applied. */ - modelService?: ModelService | undefined; + modelService: ModelService; /** * The list of fields to update. The framework validates each path against * the `model_service` field above. Wildcard paths (`paths: ["*"]`) are not * supported; list each field path explicitly. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; /** * If-match precondition: when set, the update proceeds only if the * current server-side etag matches. Empty means an unconditional update. @@ -1683,7 +1680,7 @@ export interface UpdateModelServiceRequest { export const unmarshalInferenceTableConfigSchema: z.ZodType = z .object({ - parent: z.string().optional(), + parent: z.string(), table_name_prefix: z.string().optional(), disabled: z.boolean().optional(), table: z.string().optional(), @@ -1795,7 +1792,7 @@ export const unmarshalMcpServiceConfigSchema: z.ZodType = z export const unmarshalMcpServiceConfig_SourceConnectionSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), is_deleted: z.boolean().optional(), }) .transform(d => ({ @@ -2248,7 +2245,7 @@ export const unmarshalModelProviderServiceConfig_MicrosoftFoundryProviderDirectC export const unmarshalModelProviderServiceConfig_ModelTargetConfigSchema: z.ZodType = z .object({ - model: z.string().optional(), + model: z.string(), native_api_types: z.array(z.string()).optional(), }) .transform(d => ({ @@ -2310,7 +2307,7 @@ export const unmarshalModelProviderServiceConfig_ProviderSecretSchema: z.ZodType export const unmarshalModelProviderServiceConfig_ServiceCredentialSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -2376,8 +2373,8 @@ export const unmarshalModelServiceConfigSchema: z.ZodType = export const unmarshalModelServiceConfig_DestinationConfigSchema: z.ZodType = z .object({ - name: z.string().optional(), - destination_type: z.string().optional(), + name: z.string(), + destination_type: z.string(), traffic_percentage: z.number().optional(), pay_per_token_config: z .lazy(() => unmarshalModelServiceConfig_PayPerTokenConfigSchema) @@ -2420,10 +2417,10 @@ export const unmarshalModelServiceConfig_DestinationConfigSchema: z.ZodType = z .object({ - model_provider_service: z.string().optional(), - target: z - .lazy(() => unmarshalModelProviderServiceConfig_ModelTargetConfigSchema) - .optional(), + model_provider_service: z.string(), + target: z.lazy( + () => unmarshalModelProviderServiceConfig_ModelTargetConfigSchema + ), }) .transform(d => ({ modelProviderService: d.model_provider_service, @@ -2448,7 +2445,7 @@ export const unmarshalModelServiceConfig_FallbackConfigSchema: z.ZodType = z .object({ - model: z.string().optional(), + model: z.string(), }) .transform(d => ({ model: d.model, @@ -2458,7 +2455,7 @@ export const unmarshalModelServiceConfig_PayPerTokenConfigSchema: z.ZodType = z .object({ - model_serving_endpoint: z.string().optional(), + model_serving_endpoint: z.string(), model: z.string().optional(), }) .transform(d => ({ @@ -2507,8 +2504,8 @@ export const unmarshalModelServiceConfig_RoutingConfig_TrafficSplittingSchema: z export const unmarshalRateLimitSchema: z.ZodType = z .object({ - key: z.string().optional(), - renewal_period: z.string().optional(), + key: z.string(), + renewal_period: z.string(), principal: z.string().optional(), requests: z .union([z.number(), z.bigint(), z.string()]) @@ -2533,7 +2530,7 @@ export const unmarshalRateLimitSchema: z.ZodType = z export const marshalInferenceTableConfigSchema: z.ZodType = z .object({ - parent: z.string().optional(), + parent: z.string(), tableNamePrefix: z.string().optional(), disabled: z.boolean().optional(), table: z.string().optional(), @@ -2612,7 +2609,7 @@ export const marshalMcpServiceConfigSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalMcpServiceConfig_SourceConnectionSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), isDeleted: z.boolean().optional(), }) .transform(d => ({ @@ -3120,7 +3117,7 @@ export const marshalModelProviderServiceConfig_MicrosoftFoundryProviderDirectCon export const marshalModelProviderServiceConfig_ModelTargetConfigSchema: z.ZodType = z .object({ - model: z.string().optional(), + model: z.string(), nativeApiTypes: z.array(z.string()).optional(), }) .transform(d => ({ @@ -3191,7 +3188,7 @@ export const marshalModelProviderServiceConfig_ProviderSecretSchema: z.ZodType = export const marshalModelProviderServiceConfig_ServiceCredentialSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -3255,8 +3252,8 @@ export const marshalModelServiceConfigSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalModelServiceConfig_DestinationConfigSchema: z.ZodType = z .object({ - name: z.string().optional(), - destinationType: z.string().optional(), + name: z.string(), + destinationType: z.string(), trafficPercentage: z.number().optional(), typeConfig: z .discriminatedUnion('$case', [ @@ -3301,10 +3298,10 @@ export const marshalModelServiceConfig_DestinationConfigSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalModelServiceConfig_ExternalModelConfigSchema: z.ZodType = z .object({ - modelProviderService: z.string().optional(), - target: z - .lazy(() => marshalModelProviderServiceConfig_ModelTargetConfigSchema) - .optional(), + modelProviderService: z.string(), + target: z.lazy( + () => marshalModelProviderServiceConfig_ModelTargetConfigSchema + ), }) .transform(d => ({ model_provider_service: d.modelProviderService, @@ -3325,7 +3322,7 @@ export const marshalModelServiceConfig_FallbackConfigSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalModelServiceConfig_PayPerTokenConfigSchema: z.ZodType = z .object({ - model: z.string().optional(), + model: z.string(), }) .transform(d => ({ model: d.model, @@ -3335,7 +3332,7 @@ export const marshalModelServiceConfig_PayPerTokenConfigSchema: z.ZodType = z export const marshalModelServiceConfig_ProvisionedThroughputConfigSchema: z.ZodType = z .object({ - modelServingEndpoint: z.string().optional(), + modelServingEndpoint: z.string(), model: z.string().optional(), }) .transform(d => ({ @@ -3382,8 +3379,8 @@ export const marshalModelServiceConfig_RoutingConfig_TrafficSplittingSchema: z.Z export const marshalRateLimitSchema: z.ZodType = z .object({ - key: z.string().optional(), - renewalPeriod: z.string().optional(), + key: z.string(), + renewalPeriod: z.string(), principal: z.string().optional(), requests: z.bigint().optional(), tokens: z.bigint().optional(), diff --git a/packages/alerts/src/v1/model.ts b/packages/alerts/src/v1/model.ts index 2389f92dc..48a1eff59 100644 --- a/packages/alerts/src/v1/model.ts +++ b/packages/alerts/src/v1/model.ts @@ -202,7 +202,7 @@ export interface TrashAlertRequest { export interface UpdateAlertRequest { alert?: UpdateAlertRequestAlert | undefined; - updateMask?: FieldMask | undefined; + updateMask: FieldMask; id?: string | undefined; /** If true, automatically resolve alert display name conflicts. Otherwise, fail the request if the alert's display name conflicts with an existing alert's display name. */ autoResolveDisplayName?: boolean | undefined; @@ -523,10 +523,7 @@ export const marshalCreateAlertRequestAlertSchema: z.ZodType = z export const marshalUpdateAlertRequestSchema: z.ZodType = z .object({ alert: z.lazy(() => marshalUpdateAlertRequestAlertSchema).optional(), - updateMask: z - .any() - .transform((m: FieldMask) => m.toString()) - .optional(), + updateMask: z.any().transform((m: FieldMask) => m.toString()), id: z.string().optional(), autoResolveDisplayName: z.boolean().optional(), }) diff --git a/packages/alerts/src/v2/model.ts b/packages/alerts/src/v2/model.ts index d4adc959e..e2527e178 100644 --- a/packages/alerts/src/v2/model.ts +++ b/packages/alerts/src/v2/model.ts @@ -73,10 +73,10 @@ export type SchedulePauseStatus = | (string & {}); export interface Alert { - /** UUID identifying the alert. */ + /** The canonical identifier of the alert to retrieve information about. */ id?: string | undefined; /** The display name of the alert. */ - displayName?: string | undefined; + displayName: string; /** The owner's username. This field is set to "Unavailable" if the user has been deleted. */ ownerUserName?: string | undefined; /** The timestamp indicating when the alert was created. */ @@ -86,17 +86,17 @@ export interface Alert { /** The workspace path of the folder containing the alert. Can only be set on create, and cannot be updated. */ parentPath?: string | undefined; /** Text of the query to be run. */ - queryText?: string | undefined; + queryText: string; /** ID of the SQL warehouse attached to the alert. */ - warehouseId?: string | undefined; + warehouseId: string; /** * The run as username or application ID of service principal. * On Create and Update, this field can be set to application ID of an active service principal. Setting this field requires the servicePrincipal/user role. * Deprecated: Use `run_as` field instead. This field will be removed in a future release. */ runAsUserName?: string | undefined; - evaluation?: AlertEvaluation | undefined; - schedule?: CronSchedule | undefined; + evaluation: AlertEvaluation; + schedule: CronSchedule; /** Indicates whether the query is trashed. */ lifecycleState?: AlertLifecycleState | undefined; /** Custom summary for the alert. support mustache template. */ @@ -118,17 +118,26 @@ export interface Alert { */ effectiveRunAs?: AlertRunAs | undefined; /** - * Query parameters bound when executing the alert query, referenced in the - * query text with `:name` syntax. Static values only. + * A list of parameters to pass into the alert SQL query statement containing parameter markers. Static values only. + * + * Reference a parameter in the query text as `:name`. Each parameter must have a unique, non-empty name. + * Each parameter consists of a name, a value, and optionally a type. To represent a NULL + * value, the `value` field may be omitted or set to `null` explicitly. If the `type` field + * is omitted, the value is interpreted as a string. + * + * If the type is given, parameters will be checked for type correctness according + * to the given type. A value is correct if the provided string can be converted to + * the requested type using the `cast` function. The exact semantics are described in + * the section [`cast` function](https://docs.databricks.com/sql/language-manual/functions/cast.html) of the SQL language reference. */ parameters?: AlertStatementParameter[] | undefined; } export interface AlertEvaluation { /** Source column from result to use to evaluate alert */ - source?: AlertOperandColumn | undefined; + source: AlertOperandColumn; /** Operator used for comparison in alert evaluation. */ - comparisonOperator?: ComparisonOperator | undefined; + comparisonOperator: ComparisonOperator; /** Threshold to user for alert evaluation, can be a column or a value. */ threshold?: AlertOperand | undefined; /** User or Notification Destination to notify when alert is triggered. */ @@ -162,7 +171,7 @@ export interface AlertOperand { } export interface AlertOperandColumn { - name?: string | undefined; + name: string; display?: string | undefined; /** If not set, the behavior is equivalent to using `First row` in the UI. */ aggregation?: Aggregation | undefined; @@ -193,21 +202,20 @@ export interface AlertRunAs { } /** - * Redash-owned copy of the internal StatementParameter for the external AlertV2 API. - * The internal `ordinal` and `args` fields are intentionally omitted: the public API - * supports only flat, named scalar parameters; complex types (ARRAY, MAP, STRUCT) are - * not supported. This mirrors SEA's public StatementParameter schema, see: - * cmdexec/sql-exec-api/proto/sql_exec_api_service.proto:763-779 + * A named parameter bound to the alert query. Only flat, named scalar parameters are + * supported; complex types such as ARRAY, MAP, and STRUCT are not. */ export interface AlertStatementParameter { - /** The name of the parameter, referenced in the query as `:name`. */ - name?: string | undefined; - /** The bound value for the parameter, given as a string. If omitted, the value is interpreted as NULL. */ + /** + * The name of the parameter. Reference it in the query text as `:name`. Required, must be + * non-empty, and must be unique across the alert's parameters. + */ + name: string; + /** The value bound to the parameter, represented as a string. If omitted, the value is interpreted as NULL. */ value?: string | undefined; /** - * The SQL data type of the parameter, e.g. STRING, INT, or DATE. Defaults to STRING. This is a - * string rather than an enum because scalar subtypes such as DECIMAL(10, 4) cannot be enumerated. - * Complex types such as ARRAY, MAP, and STRUCT are not supported. + * The SQL data type of the parameter, for example `STRING`, `INT`, or `DECIMAL(10, 2)`. If no type is given + * the type is assumed to be `STRING`. Complex types such as `ARRAY`, `MAP`, and `STRUCT` are not supported. */ type?: string | undefined; } @@ -228,13 +236,13 @@ export interface CronSchedule { * A cron expression using quartz syntax that specifies the schedule for this pipeline. * Should use the quartz format described here: http://www.quartz-scheduler.org/documentation/quartz-2.1.7/tutorials/tutorial-lesson-06.html */ - quartzCronSchedule?: string | undefined; + quartzCronSchedule: string; /** * A Java timezone id. The schedule will be resolved using this timezone. * This will be combined with the quartz_cron_schedule to determine the schedule. * See https://docs.databricks.com/sql/language-manual/sql-ref-syntax-aux-conf-mgmt-set-timezone.html for details. */ - timezoneId?: string | undefined; + timezoneId: string; /** Indicate whether this schedule is paused or not. */ pauseStatus?: SchedulePauseStatus | undefined; } @@ -268,13 +276,13 @@ export interface TrashAlertRequest { export interface UpdateAlertRequest { alert?: Alert | undefined; - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export const unmarshalAlertSchema: z.ZodType = z .object({ id: z.string().optional(), - display_name: z.string().optional(), + display_name: z.string(), owner_user_name: z.string().optional(), create_time: z .string() @@ -285,11 +293,11 @@ export const unmarshalAlertSchema: z.ZodType = z .transform(s => Temporal.Instant.from(s)) .optional(), parent_path: z.string().optional(), - query_text: z.string().optional(), - warehouse_id: z.string().optional(), + query_text: z.string(), + warehouse_id: z.string(), run_as_user_name: z.string().optional(), - evaluation: z.lazy(() => unmarshalAlertEvaluationSchema).optional(), - schedule: z.lazy(() => unmarshalCronScheduleSchema).optional(), + evaluation: z.lazy(() => unmarshalAlertEvaluationSchema), + schedule: z.lazy(() => unmarshalCronScheduleSchema), lifecycle_state: z.string().optional(), custom_summary: z.string().optional(), custom_description: z.string().optional(), @@ -321,8 +329,8 @@ export const unmarshalAlertSchema: z.ZodType = z export const unmarshalAlertEvaluationSchema: z.ZodType = z .object({ - source: z.lazy(() => unmarshalAlertOperandColumnSchema).optional(), - comparison_operator: z.string().optional(), + source: z.lazy(() => unmarshalAlertOperandColumnSchema), + comparison_operator: z.string(), threshold: z.lazy(() => unmarshalAlertOperandSchema).optional(), notification: z.lazy(() => unmarshalAlertNotificationSchema).optional(), state: z.string().optional(), @@ -373,7 +381,7 @@ export const unmarshalAlertOperandSchema: z.ZodType = z export const unmarshalAlertOperandColumnSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), display: z.string().optional(), aggregation: z.string().optional(), }) @@ -420,7 +428,7 @@ export const unmarshalAlertRunAsSchema: z.ZodType = z export const unmarshalAlertStatementParameterSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), value: z.string().optional(), type: z.string().optional(), }) @@ -446,8 +454,8 @@ export const unmarshalAlertSubscriptionSchema: z.ZodType = z export const unmarshalCronScheduleSchema: z.ZodType = z .object({ - quartz_cron_schedule: z.string().optional(), - timezone_id: z.string().optional(), + quartz_cron_schedule: z.string(), + timezone_id: z.string(), pause_status: z.string().optional(), }) .transform(d => ({ @@ -472,7 +480,7 @@ export const unmarshalListAlertsResponseSchema: z.ZodType = export const marshalAlertSchema: z.ZodType = z .object({ id: z.string().optional(), - displayName: z.string().optional(), + displayName: z.string(), ownerUserName: z.string().optional(), createTime: z .any() @@ -483,11 +491,11 @@ export const marshalAlertSchema: z.ZodType = z .transform((d: Temporal.Instant) => d.toString()) .optional(), parentPath: z.string().optional(), - queryText: z.string().optional(), - warehouseId: z.string().optional(), + queryText: z.string(), + warehouseId: z.string(), runAsUserName: z.string().optional(), - evaluation: z.lazy(() => marshalAlertEvaluationSchema).optional(), - schedule: z.lazy(() => marshalCronScheduleSchema).optional(), + evaluation: z.lazy(() => marshalAlertEvaluationSchema), + schedule: z.lazy(() => marshalCronScheduleSchema), lifecycleState: z.string().optional(), customSummary: z.string().optional(), customDescription: z.string().optional(), @@ -519,8 +527,8 @@ export const marshalAlertSchema: z.ZodType = z export const marshalAlertEvaluationSchema: z.ZodType = z .object({ - source: z.lazy(() => marshalAlertOperandColumnSchema).optional(), - comparisonOperator: z.string().optional(), + source: z.lazy(() => marshalAlertOperandColumnSchema), + comparisonOperator: z.string(), threshold: z.lazy(() => marshalAlertOperandSchema).optional(), notification: z.lazy(() => marshalAlertNotificationSchema).optional(), state: z.string().optional(), @@ -576,7 +584,7 @@ export const marshalAlertOperandSchema: z.ZodType = z export const marshalAlertOperandColumnSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), display: z.string().optional(), aggregation: z.string().optional(), }) @@ -627,7 +635,7 @@ export const marshalAlertRunAsSchema: z.ZodType = z export const marshalAlertStatementParameterSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), value: z.string().optional(), type: z.string().optional(), }) @@ -660,8 +668,8 @@ export const marshalAlertSubscriptionSchema: z.ZodType = z export const marshalCronScheduleSchema: z.ZodType = z .object({ - quartzCronSchedule: z.string().optional(), - timezoneId: z.string().optional(), + quartzCronSchedule: z.string(), + timezoneId: z.string(), pauseStatus: z.string().optional(), }) .transform(d => ({ diff --git a/packages/apps/src/v1/model.ts b/packages/apps/src/v1/model.ts index 22645b0b8..ddb03f67e 100644 --- a/packages/apps/src/v1/model.ts +++ b/packages/apps/src/v1/model.ts @@ -834,7 +834,7 @@ export interface App { * The name of the app. The name must contain only lowercase alphanumeric characters and hyphens. * It must be unique within the workspace. */ - name?: string | undefined; + name: string; /** The description of the app. */ description?: string | undefined; computeStatus?: ComputeStatus | undefined; @@ -962,9 +962,9 @@ export interface AppDeploymentStatus { /** App manifest definition */ export interface AppManifest { /** The manifest schema version, for now only 1 is allowed */ - version?: number | undefined; + version: number; /** Name of the app defined by manifest author / publisher */ - name?: string | undefined; + name: string; /** Description of the app defined by manifest author / publisher */ description?: string | undefined; resourceSpecs?: AppManifest_AppResourceSpec[] | undefined; @@ -972,36 +972,32 @@ export interface AppManifest { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface AppManifest_AppResourceExperimentSpec { - permission?: - | AppManifest_AppResourceExperimentSpec_ExperimentPermission - | undefined; + permission: AppManifest_AppResourceExperimentSpec_ExperimentPermission; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface AppManifest_AppResourceJobSpec { /** Permissions to grant on the Job. Supported permissions are: "CAN_MANAGE", "IS_OWNER", "CAN_MANAGE_RUN", "CAN_VIEW". */ - permission?: AppManifest_AppResourceJobSpec_JobPermission | undefined; + permission: AppManifest_AppResourceJobSpec_JobPermission; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface AppManifest_AppResourceSecretSpec { /** Permission to grant on the secret scope. For secrets, only one permission is allowed. Permission must be one of: "READ", "WRITE", "MANAGE". */ - permission?: AppManifest_AppResourceSecretSpec_SecretPermission | undefined; + permission: AppManifest_AppResourceSecretSpec_SecretPermission; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface AppManifest_AppResourceServingEndpointSpec { /** Permission to grant on the serving endpoint. Supported permissions are: "CAN_MANAGE", "CAN_QUERY", "CAN_VIEW". */ - permission?: - | AppManifest_AppResourceServingEndpointSpec_ServingEndpointPermission - | undefined; + permission: AppManifest_AppResourceServingEndpointSpec_ServingEndpointPermission; } /** AppResource related fields are copied from app.proto but excludes resource identifiers (e.g. name, id, key, scope, etc.) */ // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface AppManifest_AppResourceSpec { /** Name of the App Resource. */ - name?: string | undefined; + name: string; /** Description of the App Resource. */ description?: string | undefined; resource?: @@ -1029,24 +1025,18 @@ export interface AppManifest_AppResourceSpec { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface AppManifest_AppResourceSqlWarehouseSpec { /** Permission to grant on the SQL warehouse. Supported permissions are: "CAN_MANAGE", "CAN_USE", "IS_OWNER". */ - permission?: - | AppManifest_AppResourceSqlWarehouseSpec_SqlWarehousePermission - | undefined; + permission: AppManifest_AppResourceSqlWarehouseSpec_SqlWarehousePermission; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface AppManifest_AppResourceUcSecurableSpec { - securableType?: - | AppManifest_AppResourceUcSecurableSpec_UcSecurableType - | undefined; - permission?: - | AppManifest_AppResourceUcSecurableSpec_UcSecurablePermission - | undefined; + securableType: AppManifest_AppResourceUcSecurableSpec_UcSecurableType; + permission: AppManifest_AppResourceUcSecurableSpec_UcSecurablePermission; } export interface AppResource { /** Name of the App Resource. */ - name?: string | undefined; + name: string; /** Description of the App Resource. */ description?: string | undefined; resource?: @@ -1069,27 +1059,27 @@ export interface AppResourceApp { } export interface AppResourceDatabase { - instanceName?: string | undefined; - databaseName?: string | undefined; - permission?: AppResourceDatabase_DatabasePermission | undefined; + instanceName: string; + databaseName: string; + permission: AppResourceDatabase_DatabasePermission; } export interface AppResourceExperiment { - experimentId?: string | undefined; - permission?: AppResourceExperiment_ExperimentPermission | undefined; + experimentId: string; + permission: AppResourceExperiment_ExperimentPermission; } export interface AppResourceGenieSpace { - name?: string | undefined; - spaceId?: string | undefined; - permission?: AppResourceGenieSpace_GenieSpacePermission | undefined; + name: string; + spaceId: string; + permission: AppResourceGenieSpace_GenieSpacePermission; } export interface AppResourceJob { /** Id of the job to grant permission on. */ - id?: string | undefined; + id: string; /** Permissions to grant on the Job. Supported permissions are: "CAN_MANAGE", "IS_OWNER", "CAN_MANAGE_RUN", "CAN_VIEW". */ - permission?: AppResourceJob_JobPermission | undefined; + permission: AppResourceJob_JobPermission; } export interface AppResourcePostgres { @@ -1100,31 +1090,31 @@ export interface AppResourcePostgres { export interface AppResourceSecret { /** Scope of the secret to grant permission on. */ - scope?: string | undefined; + scope: string; /** Key of the secret to grant permission on. */ - key?: string | undefined; + key: string; /** Permission to grant on the secret scope. For secrets, only one permission is allowed. Permission must be one of: "READ", "WRITE", "MANAGE". */ - permission?: AppResourceSecret_SecretPermission | undefined; + permission: AppResourceSecret_SecretPermission; } export interface AppResourceServingEndpoint { /** Name of the serving endpoint to grant permission on. */ - name?: string | undefined; + name: string; /** Permission to grant on the serving endpoint. Supported permissions are: "CAN_MANAGE", "CAN_QUERY", "CAN_VIEW". */ - permission?: AppResourceServingEndpoint_ServingEndpointPermission | undefined; + permission: AppResourceServingEndpoint_ServingEndpointPermission; } export interface AppResourceSqlWarehouse { /** Id of the SQL warehouse to grant permission on. */ - id?: string | undefined; + id: string; /** Permission to grant on the SQL warehouse. Supported permissions are: "CAN_MANAGE", "CAN_USE", "IS_OWNER". */ - permission?: AppResourceSqlWarehouse_SqlWarehousePermission | undefined; + permission: AppResourceSqlWarehouse_SqlWarehousePermission; } export interface AppResourceUcSecurable { - securableFullName?: string | undefined; - securableType?: AppResourceUcSecurable_UcSecurableType | undefined; - permission?: AppResourceUcSecurable_UcSecurablePermission | undefined; + securableFullName: string; + securableType: AppResourceUcSecurable_UcSecurableType; + permission: AppResourceUcSecurable_UcSecurablePermission; /** * The securable kind from Unity Catalog. * See https://docs.databricks.com/api/workspace/tables/get#securable_kind_manifest-securable_kind. @@ -1172,7 +1162,7 @@ export interface ApplicationStatus { export interface AsyncUpdateAppRequest { app?: App | undefined; - updateMask?: FieldMask | undefined; + updateMask: FieldMask; appName?: string | undefined; } @@ -1207,7 +1197,7 @@ export interface CreateCustomTemplateRequest { } export interface CreateSpaceRequest { - space?: Space | undefined; + space: Space; } export interface CustomTemplate { @@ -1215,17 +1205,17 @@ export interface CustomTemplate { * The name of the template. It must contain only alphanumeric characters, hyphens, underscores, and whitespaces. * It must be unique within the workspace. */ - name?: string | undefined; + name: string; /** The description of the template. */ description?: string | undefined; /** The Git repository URL that the template resides in. */ - gitRepo?: string | undefined; + gitRepo: string; /** The path to the template within the Git repository. */ - path?: string | undefined; + path: string; /** The manifest of the template. It defines fields and default values when installing the template. */ - manifest?: AppManifest | undefined; + manifest: AppManifest; /** The Git provider of the template. */ - gitProvider?: string | undefined; + gitProvider: string; creator?: string | undefined; } @@ -1241,12 +1231,12 @@ export interface DeleteAppThumbnailRequest { export interface DeleteCustomTemplateRequest { /** The name of the custom template. */ - name?: string | undefined; + name: string; } export interface DeleteSpaceRequest { /** The name of the app space. */ - name?: string | undefined; + name: string; } export interface EnvVar { @@ -1285,7 +1275,7 @@ export interface GetAppUpdateRequest { export interface GetCustomTemplateRequest { /** The name of the custom template. */ - name?: string | undefined; + name: string; } /** The request message for `GetOperation` method. */ @@ -1302,12 +1292,12 @@ export interface GetSpaceRequest { /** Git repository configuration specifying the location of the repository. */ export interface GitRepository { /** URL of the Git repository. */ - url?: string | undefined; + url: string; /** * Git provider. Case insensitive. Supported values: gitHub, gitHubEnterprise, bitbucketCloud, * bitbucketServer, azureDevOpsServices, gitLab, gitLabEnterpriseEdition, awsCodeCommit. */ - provider?: string | undefined; + provider: string; /** * When true, automatically deploys the app on push events to the branch configured in * the app's deployment_source.git_source. @@ -1462,7 +1452,7 @@ export interface Space { * The name of the app space. The name must contain only lowercase alphanumeric characters and hyphens. * It must be unique within the workspace. */ - name?: string | undefined; + name: string; /** The description of the app space. */ description?: string | undefined; /** The status of the app space. */ @@ -1493,6 +1483,12 @@ export interface Space { usagePolicyId?: string | undefined; /** The effective usage policy ID used by apps in the space. */ effectiveUsagePolicyId?: string | undefined; + /** + * The group whose permissions users assume via Role Authorization for apps in this space. When + * set, user tokens assume the role of this group instead of doing regular obo token downscoping. + * Set only at space creation. + */ + assumeGroupId?: string | undefined; } export interface SpaceStatus { @@ -1536,11 +1532,11 @@ export interface TelemetryExportDestination { /** Unity Catalog Destinations for OTEL telemetry export. */ export interface UnityCatalog { /** Unity Catalog table for OTEL logs. */ - logsTable?: string | undefined; + logsTable: string; /** Unity Catalog table for OTEL metrics. */ - metricsTable?: string | undefined; + metricsTable: string; /** Unity Catalog table for OTEL traces (spans). */ - tracesTable?: string | undefined; + tracesTable: string; } export interface UpdateAppRequest { @@ -1559,8 +1555,8 @@ export interface UpdateCustomTemplateRequest { } export interface UpdateSpaceRequest { - space?: Space | undefined; - updateMask?: FieldMask | undefined; + space: Space; + updateMask: FieldMask; } export const unmarshalApiErrorSchema: z.ZodType = z @@ -1579,7 +1575,7 @@ export const unmarshalApiErrorSchema: z.ZodType = z export const unmarshalAppSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), compute_status: z.lazy(() => unmarshalComputeStatusSchema).optional(), app_status: z.lazy(() => unmarshalApplicationStatusSchema).optional(), @@ -1728,8 +1724,8 @@ export const unmarshalAppDeploymentStatusSchema: z.ZodType export const unmarshalAppManifestSchema: z.ZodType = z .object({ - version: z.number().optional(), - name: z.string().optional(), + version: z.number(), + name: z.string(), description: z.string().optional(), resource_specs: z .array(z.lazy(() => unmarshalAppManifest_AppResourceSpecSchema)) @@ -1746,7 +1742,7 @@ export const unmarshalAppManifestSchema: z.ZodType = z export const unmarshalAppManifest_AppResourceExperimentSpecSchema: z.ZodType = z .object({ - permission: z.string().optional(), + permission: z.string(), }) .transform(d => ({ permission: d.permission, @@ -1756,7 +1752,7 @@ export const unmarshalAppManifest_AppResourceExperimentSpecSchema: z.ZodType = z .object({ - permission: z.string().optional(), + permission: z.string(), }) .transform(d => ({ permission: d.permission, @@ -1766,7 +1762,7 @@ export const unmarshalAppManifest_AppResourceJobSpecSchema: z.ZodType = z .object({ - permission: z.string().optional(), + permission: z.string(), }) .transform(d => ({ permission: d.permission, @@ -1776,7 +1772,7 @@ export const unmarshalAppManifest_AppResourceSecretSpecSchema: z.ZodType = z .object({ - permission: z.string().optional(), + permission: z.string(), }) .transform(d => ({ permission: d.permission, @@ -1786,7 +1782,7 @@ export const unmarshalAppManifest_AppResourceServingEndpointSpecSchema: z.ZodTyp export const unmarshalAppManifest_AppResourceSpecSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), secret_spec: z .lazy(() => unmarshalAppManifest_AppResourceSecretSpecSchema) @@ -1842,7 +1838,7 @@ export const unmarshalAppManifest_AppResourceSpecSchema: z.ZodType = z .object({ - permission: z.string().optional(), + permission: z.string(), }) .transform(d => ({ permission: d.permission, @@ -1852,8 +1848,8 @@ export const unmarshalAppManifest_AppResourceSqlWarehouseSpecSchema: z.ZodType = z .object({ - securable_type: z.string().optional(), - permission: z.string().optional(), + securable_type: z.string(), + permission: z.string(), }) .transform(d => ({ securableType: d.securable_type, @@ -1862,7 +1858,7 @@ export const unmarshalAppManifest_AppResourceUcSecurableSpecSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), secret: z.lazy(() => unmarshalAppResourceSecretSchema).optional(), sql_warehouse: z @@ -1924,9 +1920,9 @@ export const unmarshalAppResourceAppSchema: z.ZodType = z export const unmarshalAppResourceDatabaseSchema: z.ZodType = z .object({ - instance_name: z.string().optional(), - database_name: z.string().optional(), - permission: z.string().optional(), + instance_name: z.string(), + database_name: z.string(), + permission: z.string(), }) .transform(d => ({ instanceName: d.instance_name, @@ -1937,8 +1933,8 @@ export const unmarshalAppResourceDatabaseSchema: z.ZodType export const unmarshalAppResourceExperimentSchema: z.ZodType = z .object({ - experiment_id: z.string().optional(), - permission: z.string().optional(), + experiment_id: z.string(), + permission: z.string(), }) .transform(d => ({ experimentId: d.experiment_id, @@ -1948,9 +1944,9 @@ export const unmarshalAppResourceExperimentSchema: z.ZodType = z .object({ - name: z.string().optional(), - space_id: z.string().optional(), - permission: z.string().optional(), + name: z.string(), + space_id: z.string(), + permission: z.string(), }) .transform(d => ({ name: d.name, @@ -1960,8 +1956,8 @@ export const unmarshalAppResourceGenieSpaceSchema: z.ZodType = z .object({ - id: z.string().optional(), - permission: z.string().optional(), + id: z.string(), + permission: z.string(), }) .transform(d => ({ id: d.id, @@ -1983,9 +1979,9 @@ export const unmarshalAppResourcePostgresSchema: z.ZodType export const unmarshalAppResourceSecretSchema: z.ZodType = z .object({ - scope: z.string().optional(), - key: z.string().optional(), - permission: z.string().optional(), + scope: z.string(), + key: z.string(), + permission: z.string(), }) .transform(d => ({ scope: d.scope, @@ -1996,8 +1992,8 @@ export const unmarshalAppResourceSecretSchema: z.ZodType = z export const unmarshalAppResourceServingEndpointSchema: z.ZodType = z .object({ - name: z.string().optional(), - permission: z.string().optional(), + name: z.string(), + permission: z.string(), }) .transform(d => ({ name: d.name, @@ -2007,8 +2003,8 @@ export const unmarshalAppResourceServingEndpointSchema: z.ZodType = z .object({ - id: z.string().optional(), - permission: z.string().optional(), + id: z.string(), + permission: z.string(), }) .transform(d => ({ id: d.id, @@ -2018,9 +2014,9 @@ export const unmarshalAppResourceSqlWarehouseSchema: z.ZodType = z .object({ - securable_full_name: z.string().optional(), - securable_type: z.string().optional(), - permission: z.string().optional(), + securable_full_name: z.string(), + securable_type: z.string(), + permission: z.string(), securable_kind: z.string().optional(), }) .transform(d => ({ @@ -2107,12 +2103,12 @@ export const unmarshalComputeStatusSchema: z.ZodType = z export const unmarshalCustomTemplateSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), - git_repo: z.string().optional(), - path: z.string().optional(), - manifest: z.lazy(() => unmarshalAppManifestSchema).optional(), - git_provider: z.string().optional(), + git_repo: z.string(), + path: z.string(), + manifest: z.lazy(() => unmarshalAppManifestSchema), + git_provider: z.string(), creator: z.string().optional(), }) .transform(d => ({ @@ -2143,8 +2139,8 @@ export const unmarshalEnvVarSchema: z.ZodType = z export const unmarshalGitRepositorySchema: z.ZodType = z .object({ - url: z.string().optional(), - provider: z.string().optional(), + url: z.string(), + provider: z.string(), auto_deploy: z.boolean().optional(), caller_credential_id: z .union([z.number(), z.bigint(), z.string()]) @@ -2250,7 +2246,7 @@ export const unmarshalOperationSchema: z.ZodType = z export const unmarshalSpaceSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), status: z.lazy(() => unmarshalSpaceStatusSchema).optional(), id: z.string().optional(), @@ -2275,6 +2271,7 @@ export const unmarshalSpaceSchema: z.ZodType = z service_principal_client_id: z.string().optional(), usage_policy_id: z.string().optional(), effective_usage_policy_id: z.string().optional(), + assume_group_id: z.string().optional(), }) .transform(d => ({ name: d.name, @@ -2293,6 +2290,7 @@ export const unmarshalSpaceSchema: z.ZodType = z servicePrincipalClientId: d.service_principal_client_id, usagePolicyId: d.usage_policy_id, effectiveUsagePolicyId: d.effective_usage_policy_id, + assumeGroupId: d.assume_group_id, })); export const unmarshalSpaceStatusSchema: z.ZodType = z @@ -2345,9 +2343,9 @@ export const unmarshalTelemetryExportDestinationSchema: z.ZodType = z .object({ - logs_table: z.string().optional(), - metrics_table: z.string().optional(), - traces_table: z.string().optional(), + logs_table: z.string(), + metrics_table: z.string(), + traces_table: z.string(), }) .transform(d => ({ logsTable: d.logs_table, @@ -2357,7 +2355,7 @@ export const unmarshalUnityCatalogSchema: z.ZodType = z export const marshalAppSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), computeStatus: z.lazy(() => marshalComputeStatusSchema).optional(), appStatus: z.lazy(() => marshalApplicationStatusSchema).optional(), @@ -2511,8 +2509,8 @@ export const marshalAppDeploymentStatusSchema: z.ZodType = z export const marshalAppManifestSchema: z.ZodType = z .object({ - version: z.number().optional(), - name: z.string().optional(), + version: z.number(), + name: z.string(), description: z.string().optional(), resourceSpecs: z .array(z.lazy(() => marshalAppManifest_AppResourceSpecSchema)) @@ -2528,7 +2526,7 @@ export const marshalAppManifestSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalAppManifest_AppResourceExperimentSpecSchema: z.ZodType = z .object({ - permission: z.string().optional(), + permission: z.string(), }) .transform(d => ({ permission: d.permission, @@ -2537,7 +2535,7 @@ export const marshalAppManifest_AppResourceExperimentSpecSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalAppManifest_AppResourceJobSpecSchema: z.ZodType = z .object({ - permission: z.string().optional(), + permission: z.string(), }) .transform(d => ({ permission: d.permission, @@ -2546,7 +2544,7 @@ export const marshalAppManifest_AppResourceJobSpecSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalAppManifest_AppResourceSecretSpecSchema: z.ZodType = z .object({ - permission: z.string().optional(), + permission: z.string(), }) .transform(d => ({ permission: d.permission, @@ -2556,7 +2554,7 @@ export const marshalAppManifest_AppResourceSecretSpecSchema: z.ZodType = z export const marshalAppManifest_AppResourceServingEndpointSpecSchema: z.ZodType = z .object({ - permission: z.string().optional(), + permission: z.string(), }) .transform(d => ({ permission: d.permission, @@ -2565,7 +2563,7 @@ export const marshalAppManifest_AppResourceServingEndpointSpecSchema: z.ZodType // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalAppManifest_AppResourceSpecSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), resource: z .discriminatedUnion('$case', [ @@ -2630,7 +2628,7 @@ export const marshalAppManifest_AppResourceSpecSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalAppManifest_AppResourceSqlWarehouseSpecSchema: z.ZodType = z .object({ - permission: z.string().optional(), + permission: z.string(), }) .transform(d => ({ permission: d.permission, @@ -2639,8 +2637,8 @@ export const marshalAppManifest_AppResourceSqlWarehouseSpecSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalAppManifest_AppResourceUcSecurableSpecSchema: z.ZodType = z .object({ - securableType: z.string().optional(), - permission: z.string().optional(), + securableType: z.string(), + permission: z.string(), }) .transform(d => ({ securable_type: d.securableType, @@ -2649,7 +2647,7 @@ export const marshalAppManifest_AppResourceUcSecurableSpecSchema: z.ZodType = z export const marshalAppResourceSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), resource: z .discriminatedUnion('$case', [ @@ -2735,9 +2733,9 @@ export const marshalAppResourceAppSchema: z.ZodType = z export const marshalAppResourceDatabaseSchema: z.ZodType = z .object({ - instanceName: z.string().optional(), - databaseName: z.string().optional(), - permission: z.string().optional(), + instanceName: z.string(), + databaseName: z.string(), + permission: z.string(), }) .transform(d => ({ instance_name: d.instanceName, @@ -2747,8 +2745,8 @@ export const marshalAppResourceDatabaseSchema: z.ZodType = z export const marshalAppResourceExperimentSchema: z.ZodType = z .object({ - experimentId: z.string().optional(), - permission: z.string().optional(), + experimentId: z.string(), + permission: z.string(), }) .transform(d => ({ experiment_id: d.experimentId, @@ -2757,9 +2755,9 @@ export const marshalAppResourceExperimentSchema: z.ZodType = z export const marshalAppResourceGenieSpaceSchema: z.ZodType = z .object({ - name: z.string().optional(), - spaceId: z.string().optional(), - permission: z.string().optional(), + name: z.string(), + spaceId: z.string(), + permission: z.string(), }) .transform(d => ({ name: d.name, @@ -2769,8 +2767,8 @@ export const marshalAppResourceGenieSpaceSchema: z.ZodType = z export const marshalAppResourceJobSchema: z.ZodType = z .object({ - id: z.string().optional(), - permission: z.string().optional(), + id: z.string(), + permission: z.string(), }) .transform(d => ({ id: d.id, @@ -2791,9 +2789,9 @@ export const marshalAppResourcePostgresSchema: z.ZodType = z export const marshalAppResourceSecretSchema: z.ZodType = z .object({ - scope: z.string().optional(), - key: z.string().optional(), - permission: z.string().optional(), + scope: z.string(), + key: z.string(), + permission: z.string(), }) .transform(d => ({ scope: d.scope, @@ -2803,8 +2801,8 @@ export const marshalAppResourceSecretSchema: z.ZodType = z export const marshalAppResourceServingEndpointSchema: z.ZodType = z .object({ - name: z.string().optional(), - permission: z.string().optional(), + name: z.string(), + permission: z.string(), }) .transform(d => ({ name: d.name, @@ -2813,8 +2811,8 @@ export const marshalAppResourceServingEndpointSchema: z.ZodType = z export const marshalAppResourceSqlWarehouseSchema: z.ZodType = z .object({ - id: z.string().optional(), - permission: z.string().optional(), + id: z.string(), + permission: z.string(), }) .transform(d => ({ id: d.id, @@ -2823,9 +2821,9 @@ export const marshalAppResourceSqlWarehouseSchema: z.ZodType = z export const marshalAppResourceUcSecurableSchema: z.ZodType = z .object({ - securableFullName: z.string().optional(), - securableType: z.string().optional(), - permission: z.string().optional(), + securableFullName: z.string(), + securableType: z.string(), + permission: z.string(), securableKind: z.string().optional(), }) .transform(d => ({ @@ -2863,10 +2861,7 @@ export const marshalApplicationStatusSchema: z.ZodType = z export const marshalAsyncUpdateAppRequestSchema: z.ZodType = z .object({ app: z.lazy(() => marshalAppSchema).optional(), - updateMask: z - .any() - .transform((m: FieldMask) => m.toString()) - .optional(), + updateMask: z.any().transform((m: FieldMask) => m.toString()), appName: z.string().optional(), }) .transform(d => ({ @@ -2889,12 +2884,12 @@ export const marshalComputeStatusSchema: z.ZodType = z export const marshalCustomTemplateSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), - gitRepo: z.string().optional(), - path: z.string().optional(), - manifest: z.lazy(() => marshalAppManifestSchema).optional(), - gitProvider: z.string().optional(), + gitRepo: z.string(), + path: z.string(), + manifest: z.lazy(() => marshalAppManifestSchema), + gitProvider: z.string(), creator: z.string().optional(), }) .transform(d => ({ @@ -2925,8 +2920,8 @@ export const marshalEnvVarSchema: z.ZodType = z export const marshalGitRepositorySchema: z.ZodType = z .object({ - url: z.string().optional(), - provider: z.string().optional(), + url: z.string(), + provider: z.string(), autoDeploy: z.boolean().optional(), callerCredentialId: z.bigint().optional(), }) @@ -2961,7 +2956,7 @@ export const marshalGitSourceSchema: z.ZodType = z export const marshalSpaceSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), status: z.lazy(() => marshalSpaceStatusSchema).optional(), id: z.string().optional(), @@ -2983,6 +2978,7 @@ export const marshalSpaceSchema: z.ZodType = z servicePrincipalClientId: z.string().optional(), usagePolicyId: z.string().optional(), effectiveUsagePolicyId: z.string().optional(), + assumeGroupId: z.string().optional(), }) .transform(d => ({ name: d.name, @@ -3001,6 +2997,7 @@ export const marshalSpaceSchema: z.ZodType = z service_principal_client_id: d.servicePrincipalClientId, usage_policy_id: d.usagePolicyId, effective_usage_policy_id: d.effectiveUsagePolicyId, + assume_group_id: d.assumeGroupId, })); export const marshalSpaceStatusSchema: z.ZodType = z @@ -3048,9 +3045,9 @@ export const marshalTelemetryExportDestinationSchema: z.ZodType = z export const marshalUnityCatalogSchema: z.ZodType = z .object({ - logsTable: z.string().optional(), - metricsTable: z.string().optional(), - tracesTable: z.string().optional(), + logsTable: z.string(), + metricsTable: z.string(), + tracesTable: z.string(), }) .transform(d => ({ logs_table: d.logsTable, @@ -3187,6 +3184,7 @@ const gitSourceFieldMaskSchema: FieldMaskSchema = { }; const spaceFieldMaskSchema: FieldMaskSchema = { + assumeGroupId: {wire: 'assume_group_id'}, createTime: {wire: 'create_time'}, creator: {wire: 'creator'}, description: {wire: 'description'}, diff --git a/packages/authentication/src/v1/model.ts b/packages/authentication/src/v1/model.ts index e41dd1c5c..3fef52f46 100644 --- a/packages/authentication/src/v1/model.ts +++ b/packages/authentication/src/v1/model.ts @@ -7,30 +7,30 @@ import {z} from 'zod'; export interface CreateAccountFederationPolicyRequest { /** The account id for the federation policy. */ - accountId?: string | undefined; + accountId: string; /** The service principal id for the federation policy. */ - servicePrincipalId?: bigint | undefined; + servicePrincipalId: bigint; /** * The identifier for the federation policy. The identifier must contain only lowercase * alphanumeric characters, numbers, hyphens, and slashes. If unspecified, the id will be * assigned by . */ policyId?: string | undefined; - policy?: FederationPolicy | undefined; + policy: FederationPolicy; } export interface CreateServicePrincipalFederationPolicyRequest { /** The account id for the federation policy. */ - accountId?: string | undefined; + accountId: string; /** The service principal id for the federation policy. */ - servicePrincipalId?: bigint | undefined; + servicePrincipalId: bigint; /** * The identifier for the federation policy. The identifier must contain only lowercase * alphanumeric characters, numbers, hyphens, and slashes. If unspecified, the id will be * assigned by . */ policyId?: string | undefined; - policy?: FederationPolicy | undefined; + policy: FederationPolicy; } export interface CreateServicePrincipalSecretRequest { @@ -61,20 +61,20 @@ export interface CreateServicePrincipalSecretResponse { export interface DeleteAccountFederationPolicyRequest { /** The account id for the federation policy. */ - accountId?: string | undefined; + accountId: string; /** The service principal id for the federation policy. */ - servicePrincipalId?: bigint | undefined; + servicePrincipalId: bigint; /** The identifier for the federation policy. */ - policyId?: string | undefined; + policyId: string; } export interface DeleteServicePrincipalFederationPolicyRequest { /** The account id for the federation policy. */ - accountId?: string | undefined; + accountId: string; /** The service principal id for the federation policy. */ - servicePrincipalId?: bigint | undefined; + servicePrincipalId: bigint; /** The identifier for the federation policy. */ - policyId?: string | undefined; + policyId: string; } export interface DeleteServicePrincipalSecretRequest { @@ -116,27 +116,27 @@ export interface FederationPolicy { export interface GetAccountFederationPolicyRequest { /** The account id for the federation policy. */ - accountId?: string | undefined; + accountId: string; /** The service principal id for the federation policy. */ - servicePrincipalId?: bigint | undefined; + servicePrincipalId: bigint; /** The identifier for the federation policy. */ - policyId?: string | undefined; + policyId: string; } export interface GetServicePrincipalFederationPolicyRequest { /** The account id for the federation policy. */ - accountId?: string | undefined; + accountId: string; /** The service principal id for the federation policy. */ - servicePrincipalId?: bigint | undefined; + servicePrincipalId: bigint; /** The identifier for the federation policy. */ - policyId?: string | undefined; + policyId: string; } export interface ListAccountFederationPoliciesRequest { /** The account id for the federation policy. */ - accountId?: string | undefined; + accountId: string; /** The service principal id for the federation policy. */ - servicePrincipalId?: bigint | undefined; + servicePrincipalId: bigint; pageSize?: number | undefined; pageToken?: string | undefined; } @@ -148,9 +148,9 @@ export interface ListFederationPoliciesResponse { export interface ListServicePrincipalFederationPoliciesRequest { /** The account id for the federation policy. */ - accountId?: string | undefined; + accountId: string; /** The service principal id for the federation policy. */ - servicePrincipalId?: bigint | undefined; + servicePrincipalId: bigint; pageSize?: number | undefined; pageToken?: string | undefined; } @@ -237,12 +237,12 @@ export interface ServicePrincipalSecret { export interface UpdateAccountFederationPolicyRequest { /** The account id for the federation policy. */ - accountId?: string | undefined; + accountId: string; /** The service principal id for the federation policy. */ - servicePrincipalId?: bigint | undefined; + servicePrincipalId: bigint; /** The identifier for the federation policy. */ - policyId?: string | undefined; - policy?: FederationPolicy | undefined; + policyId: string; + policy: FederationPolicy; /** * The field mask specifies which fields of the policy to update. To specify multiple fields * in the field mask, use comma as the separator (no space). The special value '*' indicates @@ -255,12 +255,12 @@ export interface UpdateAccountFederationPolicyRequest { export interface UpdateServicePrincipalFederationPolicyRequest { /** The account id for the federation policy. */ - accountId?: string | undefined; + accountId: string; /** The service principal id for the federation policy. */ - servicePrincipalId?: bigint | undefined; + servicePrincipalId: bigint; /** The identifier for the federation policy. */ - policyId?: string | undefined; - policy?: FederationPolicy | undefined; + policyId: string; + policy: FederationPolicy; /** * The field mask specifies which fields of the policy to update. To specify multiple fields * in the field mask, use comma as the separator (no space). The special value '*' indicates diff --git a/packages/budgetpolicy/src/v1/model.ts b/packages/budgetpolicy/src/v1/model.ts index 9da02282d..5fc25afa9 100644 --- a/packages/budgetpolicy/src/v1/model.ts +++ b/packages/budgetpolicy/src/v1/model.ts @@ -59,7 +59,7 @@ export interface CustomPolicyTag { * - Cannot be “budget-policy-name”, “budget-policy-id” or "budget-policy-resolution-result" - * these tags are preserved. */ - key?: string | undefined; + key: string; /** The value of the tag. */ value?: string | undefined; } @@ -67,7 +67,7 @@ export interface CustomPolicyTag { /** Deletes a policy */ export interface DeleteBudgetPolicyRequest { /** The Id of the policy. */ - policyId?: string | undefined; + policyId: string; /** The account Id of the customer */ accountId?: string | undefined; } @@ -98,7 +98,7 @@ export interface Filter { export interface GetBudgetPolicyRequest { /** The Id of the policy. */ - policyId?: string | undefined; + policyId: string; /** The account Id of the customer */ accountId?: string | undefined; } @@ -164,7 +164,7 @@ export interface UpdateBudgetPolicyRequest { * must be specified even if not changed. The `policy_id` is used to identify the policy to * update. */ - policy?: BudgetPolicy | undefined; + policy: BudgetPolicy; /** The account Id of the customer */ accountId?: string | undefined; /** DEPRECATED. This is redundant field as LimitConfig is part of the BudgetPolicy */ @@ -193,7 +193,7 @@ export const unmarshalBudgetPolicySchema: z.ZodType = z export const unmarshalCustomPolicyTagSchema: z.ZodType = z .object({ - key: z.string().optional(), + key: z.string(), value: z.string().optional(), }) .transform(d => ({ @@ -242,7 +242,7 @@ export const marshalCreateBudgetPolicyRequestSchema: z.ZodType = z export const marshalCustomPolicyTagSchema: z.ZodType = z .object({ - key: z.string().optional(), + key: z.string(), value: z.string().optional(), }) .transform(d => ({ diff --git a/packages/budgets/src/v1/model.ts b/packages/budgets/src/v1/model.ts index 704d067da..088a878ba 100644 --- a/packages/budgets/src/v1/model.ts +++ b/packages/budgets/src/v1/model.ts @@ -181,7 +181,7 @@ export interface CreateBudgetConfigurationBudget { export interface CreateBudgetConfigurationRequest { /** Properties of the new budget configuration. */ - budget?: CreateBudgetConfigurationBudget | undefined; + budget: CreateBudgetConfigurationBudget; } export interface CreateBudgetConfigurationResponse { @@ -195,9 +195,9 @@ export interface CreateBudgetConfigurationResponse { */ export interface DeleteBudgetConfigurationRequest { /** The budget configuration ID. */ - budgetId?: string | undefined; + budgetId: string; /** account ID. */ - accountId?: string | undefined; + accountId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -205,9 +205,9 @@ export interface DeleteBudgetConfigurationResponse {} export interface GetBudgetConfigurationRequest { /** The budget configuration ID */ - budgetId?: string | undefined; + budgetId: string; /** account ID. */ - accountId?: string | undefined; + accountId: string; includeSpendStatus?: boolean | undefined; } @@ -217,7 +217,7 @@ export interface GetBudgetConfigurationResponse { export interface ListBudgetConfigurationsRequest { /** account ID. */ - accountId?: string | undefined; + accountId: string; /** * A page token received from a previous get all budget configurations call. This token can be used to retrieve the subsequent page. * Requests first page if absent. @@ -265,9 +265,9 @@ export interface UpdateBudgetConfigurationBudget { export interface UpdateBudgetConfigurationRequest { /** The budget configuration ID. */ - budgetId?: string | undefined; + budgetId: string; /** The updated budget. This will overwrite the budget specified by the budget ID. */ - budget?: UpdateBudgetConfigurationBudget | undefined; + budget: UpdateBudgetConfigurationBudget; } export interface UpdateBudgetConfigurationResponse { @@ -575,9 +575,7 @@ export const marshalCreateBudgetConfigurationBudgetSchema: z.ZodType = z export const marshalCreateBudgetConfigurationRequestSchema: z.ZodType = z .object({ - budget: z - .lazy(() => marshalCreateBudgetConfigurationBudgetSchema) - .optional(), + budget: z.lazy(() => marshalCreateBudgetConfigurationBudgetSchema), }) .transform(d => ({ budget: d.budget, @@ -619,10 +617,8 @@ export const marshalUpdateBudgetConfigurationBudgetSchema: z.ZodType = z export const marshalUpdateBudgetConfigurationRequestSchema: z.ZodType = z .object({ - budgetId: z.string().optional(), - budget: z - .lazy(() => marshalUpdateBudgetConfigurationBudgetSchema) - .optional(), + budgetId: z.string(), + budget: z.lazy(() => marshalUpdateBudgetConfigurationBudgetSchema), }) .transform(d => ({ budget_id: d.budgetId, diff --git a/packages/cleanrooms/src/v1/model.ts b/packages/cleanrooms/src/v1/model.ts index 8016a54e2..fda8a841c 100644 --- a/packages/cleanrooms/src/v1/model.ts +++ b/packages/cleanrooms/src/v1/model.ts @@ -427,9 +427,9 @@ export interface CleanRoomAsset { * For notebooks, the name is the notebook file name. * For jar analyses, the name is the jar analysis name. */ - name?: string | undefined; + name: string; /** The type of the asset. */ - assetType?: CleanRoomAsset_AssetType | undefined; + assetType: CleanRoomAsset_AssetType; /** When the asset is added to the clean room, in epoch milliseconds. */ addedAt?: bigint | undefined; /** Status of the asset */ @@ -528,7 +528,7 @@ export interface CleanRoomAsset_ForeignTableLocalDetails { * The fully qualified name of the foreign table in its owner's local metastore, * in the format of *catalog*.*schema*.*foreign_table_name* */ - localName?: string | undefined; + localName: string; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. @@ -566,7 +566,7 @@ export interface CleanRoomAsset_Notebook { * Base 64 representation of the notebook contents. * This is the same format as returned by [workspace/export](https://docs.databricks.com/api/workspace/workspace/export) with the format of **HTML**. */ - notebookContent?: string | undefined; + notebookContent: string; /** Server generated etag that represents the notebook version. */ etag?: string | undefined; /** Aliases of collaborators that can run the notebook. */ @@ -599,7 +599,7 @@ export interface CleanRoomAsset_TableLocalDetails { * The fully qualified name of the table in its owner's local metastore, * in the format of *catalog*.*schema*.*table_name* */ - localName?: string | undefined; + localName: string; /** Partition filtering specification for a shared table. */ partitions?: PartitionSpecification_Partition[] | undefined; } @@ -616,7 +616,7 @@ export interface CleanRoomAsset_ViewLocalDetails { * The fully qualified name of the view in its owner's local metastore, * in the format of *catalog*.*schema*.*view_name* */ - localName?: string | undefined; + localName: string; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. @@ -625,7 +625,7 @@ export interface CleanRoomAsset_VolumeLocalDetails { * The fully qualified name of the volume in its owner's local metastore, * in the format of *catalog*.*schema*.*volume_name* */ - localName?: string | undefined; + localName: string; } export interface CleanRoomAutoApprovalRule { @@ -692,7 +692,7 @@ export interface CleanRoomCollaborator { * multiple values internally such as catalog alias and clean room name for single metastore clean rooms. * It should follow [UC securable naming requirements](https://docs.databricks.com/en/data-governance/unity-catalog/index.html#securable-object-naming-requirements). */ - collaboratorAlias?: string | undefined; + collaboratorAlias: string; /** * Generated display name for the collaborator. In the case of a single metastore clean room, it is the clean * room name. For x-metastore clean rooms, it is the organization name of the metastore. It is not restricted to @@ -912,9 +912,9 @@ export interface ColumnMask { */ usingColumnNames?: string[] | undefined; /** - * The list of additional table columns or literals to be passed as additional arguments to - * a column mask function. This is the replacement of the deprecated using_column_names field and - * carries information about the types (alias or constant) of the arguments to the mask function. + * The list of table columns or literals to be passed as additional arguments to a column mask + * function, carrying the type (column reference vs constant literal) of each argument. + * Deprecated: use using_column_names instead. */ usingArguments?: PolicyFunctionArgument[] | undefined; } @@ -928,16 +928,16 @@ export interface ComplianceSecurityProfile { } export interface CreateCleanRoomAssetRequest { - asset?: CleanRoomAsset | undefined; + asset: CleanRoomAsset; } export interface CreateCleanRoomAssetReviewRequest { /** Name of the clean room */ - cleanRoomName?: string | undefined; + cleanRoomName: string; /** Name of the asset */ - name?: string | undefined; + name: string; /** Asset type. Can either be NOTEBOOK_FILE or JAR_ANALYSIS. */ - assetType?: CleanRoomAsset_AssetType | undefined; + assetType: CleanRoomAsset_AssetType; review?: | {$case: 'notebookReview'; notebookReview: NotebookVersionReview} | {$case: 'jarAnalysisReview'; jarAnalysisReview: JarAnalysisVersionReview} @@ -964,17 +964,17 @@ export interface CreateCleanRoomAssetReviewResponse { } export interface CreateCleanRoomAutoApprovalRuleRequest { - autoApprovalRule?: CleanRoomAutoApprovalRule | undefined; + autoApprovalRule: CleanRoomAutoApprovalRule; } export interface CreateCleanRoomOutputCatalogRequest { /** Name of the clean room. */ - cleanRoomName?: string | undefined; - outputCatalog?: CleanRoomOutputCatalog | undefined; + cleanRoomName: string; + outputCatalog: CleanRoomOutputCatalog; } export interface CreateCleanRoomOutputCatalogResponse { - outputCatalog?: CleanRoomOutputCatalog | undefined; + outputCatalog: CleanRoomOutputCatalog; } export interface CreateCleanRoomRequest { @@ -983,11 +983,11 @@ export interface CreateCleanRoomRequest { export interface DeleteCleanRoomAssetRequest { /** Name of the clean room. */ - cleanRoomName?: string | undefined; + cleanRoomName: string; /** The type of the asset. */ - assetType?: CleanRoomAsset_AssetType | undefined; + assetType: CleanRoomAsset_AssetType; /** The fully qualified name of the asset, it is same as the name field in CleanRoomAsset. */ - name?: string | undefined; + name: string; } /** @@ -998,13 +998,13 @@ export interface DeleteCleanRoomAssetRequest { export interface DeleteCleanRoomAssetResponse {} export interface DeleteCleanRoomAutoApprovalRuleRequest { - cleanRoomName?: string | undefined; - ruleId?: string | undefined; + cleanRoomName: string; + ruleId: string; } export interface DeleteCleanRoomRequest { /** Name of the clean room. */ - name?: string | undefined; + name: string; } /** @@ -1078,49 +1078,49 @@ export interface EgressNetworkPolicy_InternetAccessPolicy_StorageDestination { export interface GetCleanRoomAssetRequest { /** Name of the clean room. */ - cleanRoomName?: string | undefined; + cleanRoomName: string; /** The type of the asset. */ - assetType?: CleanRoomAsset_AssetType | undefined; + assetType: CleanRoomAsset_AssetType; /** The fully qualified name of the asset, it is same as the name field in CleanRoomAsset. */ - name?: string | undefined; + name: string; } export interface GetCleanRoomAssetRevisionRequest { /** Name of the clean room. */ - cleanRoomName?: string | undefined; + cleanRoomName: string; /** Name of the asset. */ - name?: string | undefined; + name: string; /** Asset type. Only NOTEBOOK_FILE is supported. */ - assetType?: CleanRoomAsset_AssetType | undefined; + assetType: CleanRoomAsset_AssetType; /** Revision etag to fetch. If not provided, the latest revision will be returned. */ etag?: string | undefined; } export interface GetCleanRoomAutoApprovalRuleRequest { - cleanRoomName?: string | undefined; - ruleId?: string | undefined; + cleanRoomName: string; + ruleId: string; } export interface GetCleanRoomRequest { - name?: string | undefined; + name: string; } export interface JarAnalysisVersionReview { /** Etag identifying the jar analysis version, with its value being a hash of an internally-generated UUID */ - etag?: string | undefined; + etag: string; /** Review outcome */ - reviewState?: CleanRoomJarAnalysisReview_JarAnalysisReviewState | undefined; + reviewState: CleanRoomJarAnalysisReview_JarAnalysisReviewState; /** Review comment */ comment?: string | undefined; } export interface ListCleanRoomAssetRevisionsRequest { /** Name of the clean room. */ - cleanRoomName?: string | undefined; + cleanRoomName: string; /** Name of the asset. */ - name?: string | undefined; + name: string; /** Asset type. Only NOTEBOOK_FILE is supported. */ - assetType?: CleanRoomAsset_AssetType | undefined; + assetType: CleanRoomAsset_AssetType; /** Maximum number of asset revisions to return. Defaults to 10. */ pageSize?: number | undefined; /** Opaque pagination token to go to next page based on the previous query. */ @@ -1134,7 +1134,7 @@ export interface ListCleanRoomAssetRevisionsResponse { export interface ListCleanRoomAssetsRequest { /** Name of the clean room. */ - cleanRoomName?: string | undefined; + cleanRoomName: string; /** Opaque pagination token to go to next page based on previous query. */ pageToken?: string | undefined; } @@ -1150,7 +1150,7 @@ export interface ListCleanRoomAssetsResponse { } export interface ListCleanRoomAutoApprovalRulesRequest { - cleanRoomName?: string | undefined; + cleanRoomName: string; /** Maximum number of auto-approval rules to return. Defaults to 100. */ pageSize?: number | undefined; /** Opaque pagination token to go to next page based on previous query. */ @@ -1168,7 +1168,7 @@ export interface ListCleanRoomAutoApprovalRulesResponse { export interface ListCleanRoomNotebookTaskRunsRequest { /** Name of the clean room. */ - cleanRoomName?: string | undefined; + cleanRoomName: string; /** Notebook name */ notebookName?: string | undefined; /** The maximum number of task runs to return. Currently ignored - all runs will be returned. */ @@ -1189,7 +1189,7 @@ export interface ListCleanRoomNotebookTaskRunsResponse { export interface ListCleanRoomTaskRunsRequest { /** Name of the clean room. */ - cleanRoomName?: string | undefined; + cleanRoomName: string; /** Executable name. */ name?: string | undefined; /** Filter by the type of Clean Room task. */ @@ -1228,9 +1228,9 @@ export interface ListCleanRoomsResponse { export interface NotebookVersionReview { /** Etag identifying the notebook version */ - etag?: string | undefined; + etag: string; /** Review outcome */ - reviewState?: CleanRoomNotebookReview_NotebookReviewState | undefined; + reviewState: CleanRoomNotebookReview_NotebookReviewState; /** Review comment */ comment?: string | undefined; } @@ -1297,7 +1297,7 @@ export interface UpdateCleanRoomAssetRequest { * The asset to update. * The asset's `name` and `asset_type` fields are used to identify the asset to update. */ - asset?: CleanRoomAsset | undefined; + asset: CleanRoomAsset; } export interface UpdateCleanRoomAutoApprovalRuleRequest { @@ -1307,7 +1307,7 @@ export interface UpdateCleanRoomAutoApprovalRuleRequest { export interface UpdateCleanRoomRequest { /** Name of the clean room. */ - name?: string | undefined; + name: string; cleanRoom?: CleanRoom | undefined; } @@ -1352,8 +1352,8 @@ export const unmarshalCleanRoomSchema: z.ZodType = z export const unmarshalCleanRoomAssetSchema: z.ZodType = z .object({ clean_room_name: z.string().optional(), - name: z.string().optional(), - asset_type: z.string().optional(), + name: z.string(), + asset_type: z.string(), added_at: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) @@ -1439,7 +1439,7 @@ export const unmarshalCleanRoomAsset_ForeignTableSchema: z.ZodType = z .object({ - local_name: z.string().optional(), + local_name: z.string(), }) .transform(d => ({ localName: d.local_name, @@ -1475,7 +1475,7 @@ export const unmarshalCleanRoomAsset_JarAnalysisSchema: z.ZodType = z .object({ - notebook_content: z.string().optional(), + notebook_content: z.string(), etag: z.string().optional(), runner_collaborator_aliases: z.array(z.string()).optional(), reviews: z @@ -1509,7 +1509,7 @@ export const unmarshalCleanRoomAsset_TableSchema: z.ZodType = z .object({ - local_name: z.string().optional(), + local_name: z.string(), partitions: z .array(z.lazy(() => unmarshalPartitionSpecification_PartitionSchema)) .optional(), @@ -1533,7 +1533,7 @@ export const unmarshalCleanRoomAsset_ViewSchema: z.ZodType export const unmarshalCleanRoomAsset_ViewLocalDetailsSchema: z.ZodType = z .object({ - local_name: z.string().optional(), + local_name: z.string(), }) .transform(d => ({ localName: d.local_name, @@ -1543,7 +1543,7 @@ export const unmarshalCleanRoomAsset_ViewLocalDetailsSchema: z.ZodType = z .object({ - local_name: z.string().optional(), + local_name: z.string(), }) .transform(d => ({ localName: d.local_name, @@ -1596,7 +1596,7 @@ export const unmarshalCleanRoomCollaboratorSchema: z.ZodType BigInt(v)) .optional(), invite_recipient_email: z.string().optional(), - collaborator_alias: z.string().optional(), + collaborator_alias: z.string(), display_name: z.string().optional(), }) .transform(d => ({ @@ -1935,9 +1935,7 @@ export const unmarshalCreateCleanRoomAssetReviewResponseSchema: z.ZodType = z .object({ - output_catalog: z - .lazy(() => unmarshalCleanRoomOutputCatalogSchema) - .optional(), + output_catalog: z.lazy(() => unmarshalCleanRoomOutputCatalogSchema), }) .transform(d => ({ outputCatalog: d.output_catalog, @@ -2194,8 +2192,8 @@ export const marshalCleanRoomSchema: z.ZodType = z export const marshalCleanRoomAssetSchema: z.ZodType = z .object({ cleanRoomName: z.string().optional(), - name: z.string().optional(), - assetType: z.string().optional(), + name: z.string(), + assetType: z.string(), addedAt: z.bigint().optional(), status: z.string().optional(), ownerCollaboratorAlias: z.string().optional(), @@ -2294,7 +2292,7 @@ export const marshalCleanRoomAsset_ForeignTableSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalCleanRoomAsset_ForeignTableLocalDetailsSchema: z.ZodType = z .object({ - localName: z.string().optional(), + localName: z.string(), }) .transform(d => ({ local_name: d.localName, @@ -2328,7 +2326,7 @@ export const marshalCleanRoomAsset_JarAnalysisSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalCleanRoomAsset_NotebookSchema: z.ZodType = z .object({ - notebookContent: z.string().optional(), + notebookContent: z.string(), etag: z.string().optional(), runnerCollaboratorAliases: z.array(z.string()).optional(), reviews: z @@ -2360,7 +2358,7 @@ export const marshalCleanRoomAsset_TableSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalCleanRoomAsset_TableLocalDetailsSchema: z.ZodType = z .object({ - localName: z.string().optional(), + localName: z.string(), partitions: z .array(z.lazy(() => marshalPartitionSpecification_PartitionSchema)) .optional(), @@ -2382,7 +2380,7 @@ export const marshalCleanRoomAsset_ViewSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalCleanRoomAsset_ViewLocalDetailsSchema: z.ZodType = z .object({ - localName: z.string().optional(), + localName: z.string(), }) .transform(d => ({ local_name: d.localName, @@ -2391,7 +2389,7 @@ export const marshalCleanRoomAsset_ViewLocalDetailsSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalCleanRoomAsset_VolumeLocalDetailsSchema: z.ZodType = z .object({ - localName: z.string().optional(), + localName: z.string(), }) .transform(d => ({ local_name: d.localName, @@ -2443,7 +2441,7 @@ export const marshalCleanRoomCollaboratorSchema: z.ZodType = z organizationName: z.string().optional(), inviteRecipientWorkspaceId: z.bigint().optional(), inviteRecipientEmail: z.string().optional(), - collaboratorAlias: z.string().optional(), + collaboratorAlias: z.string(), displayName: z.string().optional(), }) .transform(d => ({ @@ -2583,9 +2581,9 @@ export const marshalComplianceSecurityProfileSchema: z.ZodType = z export const marshalCreateCleanRoomAssetReviewRequestSchema: z.ZodType = z .object({ - cleanRoomName: z.string().optional(), - name: z.string().optional(), - assetType: z.string().optional(), + cleanRoomName: z.string(), + name: z.string(), + assetType: z.string(), review: z .discriminatedUnion('$case', [ z.object({ @@ -2615,9 +2613,7 @@ export const marshalCreateCleanRoomAssetReviewRequestSchema: z.ZodType = z export const marshalCreateCleanRoomAutoApprovalRuleRequestSchema: z.ZodType = z .object({ - autoApprovalRule: z - .lazy(() => marshalCleanRoomAutoApprovalRuleSchema) - .optional(), + autoApprovalRule: z.lazy(() => marshalCleanRoomAutoApprovalRuleSchema), }) .transform(d => ({ auto_approval_rule: d.autoApprovalRule, @@ -2720,8 +2716,8 @@ export const marshalEgressNetworkPolicy_InternetAccessPolicy_StorageDestinationS export const marshalJarAnalysisVersionReviewSchema: z.ZodType = z .object({ - etag: z.string().optional(), - reviewState: z.string().optional(), + etag: z.string(), + reviewState: z.string(), comment: z.string().optional(), }) .transform(d => ({ @@ -2732,8 +2728,8 @@ export const marshalJarAnalysisVersionReviewSchema: z.ZodType = z export const marshalNotebookVersionReviewSchema: z.ZodType = z .object({ - etag: z.string().optional(), - reviewState: z.string().optional(), + etag: z.string(), + reviewState: z.string(), comment: z.string().optional(), }) .transform(d => ({ @@ -2789,7 +2785,7 @@ export const marshalPolicyFunctionArgumentSchema: z.ZodType = z export const marshalUpdateCleanRoomRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), cleanRoom: z.lazy(() => marshalCleanRoomSchema).optional(), }) .transform(d => ({ diff --git a/packages/clusterlibraries/src/v2/model.ts b/packages/clusterlibraries/src/v2/model.ts index be0e5a8c7..375ec094c 100644 --- a/packages/clusterlibraries/src/v2/model.ts +++ b/packages/clusterlibraries/src/v2/model.ts @@ -48,14 +48,14 @@ export interface ClusterLibraryStatuses { export interface ClusterStatusRequest { /** Unique identifier of the cluster whose status should be retrieved. */ - clusterId?: string | undefined; + clusterId: string; } export interface InstallLibrariesRequest { /** Unique identifier for the cluster on which to install these libraries. */ - clusterId?: string | undefined; + clusterId: string; /** The libraries to install. */ - libraries?: Library[] | undefined; + libraries: Library[]; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -144,7 +144,7 @@ export interface ListAllClusterLibraryStatusesResponse { export interface MavenLibrary { /** Gradle-style maven coordinates. For example: "org.jsoup:jsoup:1.7.2". */ - coordinates?: string | undefined; + coordinates: string; /** * Maven repo to install the Maven package from. If omitted, both Maven Central Repository * and Spark Packages are searched. @@ -164,7 +164,7 @@ export interface PythonPyPiLibrary { * The name of the pypi package to install. An optional exact version specification is also * supported. Examples: "simplejson" and "simplejson==3.8.0". */ - package?: string | undefined; + package: string; /** * The repository where the package can be found. If not specified, the default pip index is * used. @@ -174,16 +174,16 @@ export interface PythonPyPiLibrary { export interface RCranLibrary { /** The name of the CRAN package to install. */ - package?: string | undefined; + package: string; /** The repository where the package can be found. If not specified, the default CRAN repo is used. */ repo?: string | undefined; } export interface UninstallLibrariesRequest { /** Unique identifier for the cluster on which to uninstall these libraries. */ - clusterId?: string | undefined; + clusterId: string; /** The libraries to uninstall. */ - libraries?: Library[] | undefined; + libraries: Library[]; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -264,7 +264,7 @@ export const unmarshalListAllClusterLibraryStatusesResponseSchema: z.ZodType = z .object({ - coordinates: z.string().optional(), + coordinates: z.string(), repo: z.string().optional(), exclusions: z.array(z.string()).optional(), }) @@ -276,7 +276,7 @@ export const unmarshalMavenLibrarySchema: z.ZodType = z export const unmarshalPythonPyPiLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -286,7 +286,7 @@ export const unmarshalPythonPyPiLibrarySchema: z.ZodType = z export const unmarshalRCranLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -299,8 +299,8 @@ export const unmarshalUninstallLibrariesResponseSchema: z.ZodType marshalLibrarySchema)).optional(), + clusterId: z.string(), + libraries: z.array(z.lazy(() => marshalLibrarySchema)), }) .transform(d => ({ cluster_id: d.clusterId, @@ -342,7 +342,7 @@ export const marshalLibrarySchema: z.ZodType = z export const marshalMavenLibrarySchema: z.ZodType = z .object({ - coordinates: z.string().optional(), + coordinates: z.string(), repo: z.string().optional(), exclusions: z.array(z.string()).optional(), }) @@ -354,7 +354,7 @@ export const marshalMavenLibrarySchema: z.ZodType = z export const marshalPythonPyPiLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -364,7 +364,7 @@ export const marshalPythonPyPiLibrarySchema: z.ZodType = z export const marshalRCranLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -374,8 +374,8 @@ export const marshalRCranLibrarySchema: z.ZodType = z export const marshalUninstallLibrariesRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), - libraries: z.array(z.lazy(() => marshalLibrarySchema)).optional(), + clusterId: z.string(), + libraries: z.array(z.lazy(() => marshalLibrarySchema)), }) .transform(d => ({ cluster_id: d.clusterId, diff --git a/packages/clusterpolicies/src/v2/client.ts b/packages/clusterpolicies/src/v2/client.ts index 60c31f408..cbc69f3df 100644 --- a/packages/clusterpolicies/src/v2/client.ts +++ b/packages/clusterpolicies/src/v2/client.ts @@ -17,32 +17,24 @@ import { } from './utils'; import pkgJson from '../../package.json' with {type: 'json'}; import type { - ClusterPolicyRevision, CreatePolicyRequest, CreatePolicyResponse, DeletePolicyRequest, DeletePolicyResponse, EditPolicyRequest, EditPolicyResponse, - GetClusterPolicyRevisionRequest, GetPolicyRequest, - ListClusterPolicyRevisionsRequest, - ListClusterPolicyRevisionsResponse, ListPoliciesRequest, ListPoliciesResponse, Policy, - RollbackClusterPolicyRequest, } from './model'; import { marshalCreatePolicyRequestSchema, marshalDeletePolicyRequestSchema, marshalEditPolicyRequestSchema, - marshalRollbackClusterPolicyRequestSchema, - unmarshalClusterPolicyRevisionSchema, unmarshalCreatePolicyResponseSchema, unmarshalDeletePolicyResponseSchema, unmarshalEditPolicyResponseSchema, - unmarshalListClusterPolicyRevisionsResponseSchema, unmarshalListPoliciesResponseSchema, unmarshalPolicySchema, } from './model'; @@ -80,123 +72,6 @@ export class ClusterPoliciesClient { return this.config; } - /** Get details of a cluster policy revision. */ - async getClusterPolicyRevision( - req: GetClusterPolicyRevisionRequest, - options?: CallOptions - ): Promise { - const {host, workspaceId, httpClient} = await this.resolveConfig(); - const url = `${host}/api/2.0/${req.name ?? ''}`; - let resp: ClusterPolicyRevision | undefined; - const call = async (callSignal?: AbortSignal): Promise => { - const headers = new Headers(); - if (workspaceId !== undefined) { - headers.set('X-Databricks-Workspace-Id', workspaceId); - } - headers.set('User-Agent', this.userAgent); - const httpReq = buildHttpRequest('GET', url, headers, callSignal); - const respBody = await executeHttpCall({ - request: httpReq, - httpClient, - logger: this.logger, - }); - resp = parseResponse(respBody, unmarshalClusterPolicyRevisionSchema); - }; - await executeCall(call, options); - if (resp === undefined) { - throw new Error('operation completed without a result.'); - } - return resp; - } - - /** Lists a cluster policy's revisions, ordered from most to least recent. */ - async listClusterPolicyRevisions( - req: ListClusterPolicyRevisionsRequest, - options?: CallOptions - ): Promise { - const {host, workspaceId, httpClient} = await this.resolveConfig(); - const url = `${host}/api/2.0/${req.parent ?? ''}/revisions`; - const params = new URLSearchParams(); - if (req.pageSize !== undefined) { - params.append('page_size', String(req.pageSize)); - } - if (req.pageToken !== undefined) { - params.append('page_token', req.pageToken); - } - const query = params.toString(); - const fullUrl = query !== '' ? `${url}?${query}` : url; - let resp: ListClusterPolicyRevisionsResponse | undefined; - const call = async (callSignal?: AbortSignal): Promise => { - const headers = new Headers(); - if (workspaceId !== undefined) { - headers.set('X-Databricks-Workspace-Id', workspaceId); - } - headers.set('User-Agent', this.userAgent); - const httpReq = buildHttpRequest('GET', fullUrl, headers, callSignal); - const respBody = await executeHttpCall({ - request: httpReq, - httpClient, - logger: this.logger, - }); - resp = parseResponse( - respBody, - unmarshalListClusterPolicyRevisionsResponseSchema - ); - }; - await executeCall(call, options); - if (resp === undefined) { - throw new Error('operation completed without a result.'); - } - return resp; - } - - async *listClusterPolicyRevisionsIter( - req: ListClusterPolicyRevisionsRequest, - options?: CallOptions - ): AsyncGenerator { - const pageReq: ListClusterPolicyRevisionsRequest = {...req}; - for (;;) { - const resp = await this.listClusterPolicyRevisions(pageReq, options); - for (const item of resp.clusterPolicyRevisions ?? []) { - yield item; - } - if (resp.nextPageToken === undefined || resp.nextPageToken === '') { - return; - } - pageReq.pageToken = resp.nextPageToken; - } - } - - /** Rolls back a cluster policy to a previous revision. */ - async rollbackClusterPolicy( - req: RollbackClusterPolicyRequest, - options?: CallOptions - ): Promise { - const {host, workspaceId, httpClient} = await this.resolveConfig(); - const url = `${host}/api/2.0/${req.name ?? ''}/rollback`; - const body = marshalRequest(req, marshalRollbackClusterPolicyRequestSchema); - let resp: ClusterPolicyRevision | undefined; - const call = async (callSignal?: AbortSignal): Promise => { - const headers = new Headers({'Content-Type': 'application/json'}); - if (workspaceId !== undefined) { - headers.set('X-Databricks-Workspace-Id', workspaceId); - } - headers.set('User-Agent', this.userAgent); - const httpReq = buildHttpRequest('POST', url, headers, callSignal, body); - const respBody = await executeHttpCall({ - request: httpReq, - httpClient, - logger: this.logger, - }); - resp = parseResponse(respBody, unmarshalClusterPolicyRevisionSchema); - }; - await executeCall(call, options); - if (resp === undefined) { - throw new Error('operation completed without a result.'); - } - return resp; - } - /** Creates a new policy with prescribed settings. */ async createPolicy( req: CreatePolicyRequest, diff --git a/packages/clusterpolicies/src/v2/index.ts b/packages/clusterpolicies/src/v2/index.ts index e36e74ac7..79176d710 100644 --- a/packages/clusterpolicies/src/v2/index.ts +++ b/packages/clusterpolicies/src/v2/index.ts @@ -9,24 +9,18 @@ export {ClusterPoliciesClient} from './client'; export {ListOrder, PolicySortColumn} from './model'; export type { - ClusterPolicyRevision, CreatePolicyRequest, CreatePolicyResponse, DeletePolicyRequest, DeletePolicyResponse, EditPolicyRequest, EditPolicyResponse, - GetClusterPolicyRevisionRequest, GetPolicyRequest, Library, - ListClusterPolicyRevisionsRequest, - ListClusterPolicyRevisionsResponse, ListPoliciesRequest, ListPoliciesResponse, MavenLibrary, Policy, - PolicyOwnAttributes, PythonPyPiLibrary, RCranLibrary, - RollbackClusterPolicyRequest, } from './model'; diff --git a/packages/clusterpolicies/src/v2/model.ts b/packages/clusterpolicies/src/v2/model.ts index 7cdad98c8..3e7d24f10 100644 --- a/packages/clusterpolicies/src/v2/model.ts +++ b/packages/clusterpolicies/src/v2/model.ts @@ -1,6 +1,5 @@ // Code generated from API definition by Databricks SDK Generator. DO NOT EDIT. -import {Temporal} from '@js-temporal/polyfill'; import {z} from 'zod'; // eslint-disable-next-line @typescript-eslint/naming-convention -- Enum-style const object. @@ -23,24 +22,6 @@ export type PolicySortColumn = | (typeof PolicySortColumn)[keyof typeof PolicySortColumn] | (string & {}); -/** - * Represents a cluster policy revision. - * - * Only the 100 most recent revisions are stored for each cluster policy. - */ -export interface ClusterPolicyRevision { - /** ID of the cluster policy revision. */ - revisionId?: string | undefined; - /** Time when the cluster policy revision was created. */ - createTime?: Temporal.Instant | undefined; - /** Settings used to create/edit the policy. */ - settings?: PolicyOwnAttributes | undefined; - /** Name of the user who edited this policy. */ - editUser?: string | undefined; - /** Whether this is the current revision. */ - isCurrent?: boolean | undefined; -} - export interface CreatePolicyRequest { /** * Cluster Policy name requested by the user. This has to be unique. Length must be between 1 and 100 @@ -80,7 +61,7 @@ export interface CreatePolicyResponse { export interface DeletePolicyRequest { /** The ID of the policy to delete. */ - policyId?: string | undefined; + policyId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -88,7 +69,7 @@ export interface DeletePolicyResponse {} export interface EditPolicyRequest { /** The ID of the policy to update. */ - policyId?: string | undefined; + policyId: string; /** * Cluster Policy name requested by the user. This has to be unique. Length must be between 1 and 100 * characters. @@ -123,18 +104,9 @@ export interface EditPolicyRequest { // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface EditPolicyResponse {} -/** Request to get a cluster policy revision by ID. */ -export interface GetClusterPolicyRevisionRequest { - /** - * The fully qualified resource name of the cluster policy revision. - * Format: cluster-policies/{policy_id}/revisions/{revision_id}. - */ - name?: string | undefined; -} - export interface GetPolicyRequest { /** Canonical unique identifier for the Cluster Policy. */ - policyId?: string | undefined; + policyId: string; } export interface Library { @@ -198,27 +170,6 @@ export interface Library { | undefined; } -/** Request to list cluster policy revisions. */ -export interface ListClusterPolicyRevisionsRequest { - /** - * The fully qualified resource name of the parent cluster. - * Format: cluster-policies/{policy_id}. - */ - parent?: string | undefined; - /** Maximum number of cluster policy revisions to return per page. */ - pageSize?: number | undefined; - /** Pagination token from a previous list cluster policy revisions request. */ - pageToken?: string | undefined; -} - -/** Response when listing cluster policy revisions. */ -export interface ListClusterPolicyRevisionsResponse { - /** Cluster policy revisions in the current page. */ - clusterPolicyRevisions?: ClusterPolicyRevision[] | undefined; - /** Token for fetching the next page. Empty when there are no more results. */ - nextPageToken?: string | undefined; -} - export interface ListPoliciesRequest { /** * The order in which the policies get listed. @@ -241,7 +192,7 @@ export interface ListPoliciesResponse { export interface MavenLibrary { /** Gradle-style maven coordinates. For example: "org.jsoup:jsoup:1.7.2". */ - coordinates?: string | undefined; + coordinates: string; /** * Maven repo to install the Maven package from. If omitted, both Maven Central Repository * and Spark Packages are searched. @@ -303,44 +254,12 @@ export interface Policy { libraries?: Library[] | undefined; } -export interface PolicyOwnAttributes { - /** - * Cluster Policy name requested by the user. This has to be unique. Length must be between 1 and 100 - * characters. - */ - name?: string | undefined; - /** Policy definition document expressed in [Databricks Cluster Policy Definition Language](https://docs.databricks.com/administration-guide/clusters/policy-definition.html). */ - definition?: string | undefined; - /** Additional human-readable description of the cluster policy. */ - description?: string | undefined; - /** - * ID of the policy family. The cluster policy's policy definition inherits the policy - * family's policy definition. - * - * Cannot be used with `definition`. Use `policy_family_definition_overrides` instead to - * customize the policy definition. - */ - policyFamilyId?: string | undefined; - /** - * Policy definition JSON document expressed in [Databricks Policy Definition Language](https://docs.databricks.com/administration-guide/clusters/policy-definition.html). - * The JSON document must be passed as a string and cannot be embedded in the requests. - * - * You can use this to customize the policy definition inherited from the policy family. - * Policy rules specified here are merged into the inherited policy definition. - */ - policyFamilyDefinitionOverrides?: string | undefined; - /** Max number of clusters per user that can be active using this policy. If not present, there is no max limit. */ - maxClustersPerUser?: bigint | undefined; - /** A list of libraries to be installed on the next cluster restart that uses this policy. The maximum number of libraries is 500. */ - libraries?: Library[] | undefined; -} - export interface PythonPyPiLibrary { /** * The name of the pypi package to install. An optional exact version specification is also * supported. Examples: "simplejson" and "simplejson==3.8.0". */ - package?: string | undefined; + package: string; /** * The repository where the package can be found. If not specified, the default pip index is * used. @@ -350,40 +269,11 @@ export interface PythonPyPiLibrary { export interface RCranLibrary { /** The name of the CRAN package to install. */ - package?: string | undefined; + package: string; /** The repository where the package can be found. If not specified, the default CRAN repo is used. */ repo?: string | undefined; } -/** Request to roll back cluster policy. */ -export interface RollbackClusterPolicyRequest { - /** - * The fully qualified resource name of the cluster policy revision. - * Format: cluster-policies/{policy_id}/revisions/{revision_id}. - */ - name?: string | undefined; -} - -export const unmarshalClusterPolicyRevisionSchema: z.ZodType = - z - .object({ - revision_id: z.string().optional(), - create_time: z - .string() - .transform(s => Temporal.Instant.from(s)) - .optional(), - settings: z.lazy(() => unmarshalPolicyOwnAttributesSchema).optional(), - edit_user: z.string().optional(), - is_current: z.boolean().optional(), - }) - .transform(d => ({ - revisionId: d.revision_id, - createTime: d.create_time, - settings: d.settings, - editUser: d.edit_user, - isCurrent: d.is_current, - })); - export const unmarshalCreatePolicyResponseSchema: z.ZodType = z .object({ @@ -431,19 +321,6 @@ export const unmarshalLibrarySchema: z.ZodType = z : undefined, })); -export const unmarshalListClusterPolicyRevisionsResponseSchema: z.ZodType = - z - .object({ - cluster_policy_revisions: z - .array(z.lazy(() => unmarshalClusterPolicyRevisionSchema)) - .optional(), - next_page_token: z.string().optional(), - }) - .transform(d => ({ - clusterPolicyRevisions: d.cluster_policy_revisions, - nextPageToken: d.next_page_token, - })); - export const unmarshalListPoliciesResponseSchema: z.ZodType = z .object({ @@ -455,7 +332,7 @@ export const unmarshalListPoliciesResponseSchema: z.ZodType = z .object({ - coordinates: z.string().optional(), + coordinates: z.string(), repo: z.string().optional(), exclusions: z.array(z.string()).optional(), }) @@ -499,33 +376,9 @@ export const unmarshalPolicySchema: z.ZodType = z libraries: d.libraries, })); -export const unmarshalPolicyOwnAttributesSchema: z.ZodType = - z - .object({ - name: z.string().optional(), - definition: z.string().optional(), - description: z.string().optional(), - policy_family_id: z.string().optional(), - policy_family_definition_overrides: z.string().optional(), - max_clusters_per_user: z - .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), - libraries: z.array(z.lazy(() => unmarshalLibrarySchema)).optional(), - }) - .transform(d => ({ - name: d.name, - definition: d.definition, - description: d.description, - policyFamilyId: d.policy_family_id, - policyFamilyDefinitionOverrides: d.policy_family_definition_overrides, - maxClustersPerUser: d.max_clusters_per_user, - libraries: d.libraries, - })); - export const unmarshalPythonPyPiLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -535,7 +388,7 @@ export const unmarshalPythonPyPiLibrarySchema: z.ZodType = z export const unmarshalRCranLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -565,7 +418,7 @@ export const marshalCreatePolicyRequestSchema: z.ZodType = z export const marshalDeletePolicyRequestSchema: z.ZodType = z .object({ - policyId: z.string().optional(), + policyId: z.string(), }) .transform(d => ({ policy_id: d.policyId, @@ -573,7 +426,7 @@ export const marshalDeletePolicyRequestSchema: z.ZodType = z export const marshalEditPolicyRequestSchema: z.ZodType = z .object({ - policyId: z.string().optional(), + policyId: z.string(), name: z.string().optional(), definition: z.string().optional(), description: z.string().optional(), @@ -628,7 +481,7 @@ export const marshalLibrarySchema: z.ZodType = z export const marshalMavenLibrarySchema: z.ZodType = z .object({ - coordinates: z.string().optional(), + coordinates: z.string(), repo: z.string().optional(), exclusions: z.array(z.string()).optional(), }) @@ -640,7 +493,7 @@ export const marshalMavenLibrarySchema: z.ZodType = z export const marshalPythonPyPiLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -650,18 +503,10 @@ export const marshalPythonPyPiLibrarySchema: z.ZodType = z export const marshalRCranLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ package: d.package, repo: d.repo, })); - -export const marshalRollbackClusterPolicyRequestSchema: z.ZodType = z - .object({ - name: z.string().optional(), - }) - .transform(d => ({ - name: d.name, - })); diff --git a/packages/clusters/src/v2/client.ts b/packages/clusters/src/v2/client.ts index 8d8175b4f..abfc852d7 100644 --- a/packages/clusters/src/v2/client.ts +++ b/packages/clusters/src/v2/client.ts @@ -27,7 +27,6 @@ import type { ClusterCompliance, ClusterEvent, ClusterInfo, - ClusterRevision, CreateClusterRequest, CreateClusterResponse, DeleteClusterRequest, @@ -37,7 +36,6 @@ import type { EnforcePolicyComplianceForClusterRequest, EnforcePolicyComplianceForClusterResponse, GetClusterRequest, - GetClusterRevisionRequest, GetEventsResponse, GetPolicyComplianceForClusterRequest, GetPolicyComplianceForClusterResponse, @@ -47,8 +45,6 @@ import type { ListAvailableZonesResponse, ListClusterComplianceForPolicyRequest, ListClusterComplianceForPolicyResponse, - ListClusterRevisionsRequest, - ListClusterRevisionsResponse, ListClustersRequest, ListClustersResponse, ListEventsRequest, @@ -62,7 +58,6 @@ import type { ResizeClusterResponse, RestartClusterRequest, RestartClusterResponse, - RollbackClusterRequest, StartClusterRequest, StartClusterResponse, UnpinClusterRequest, @@ -83,14 +78,12 @@ import { marshalPinClusterRequestSchema, marshalResizeClusterRequestSchema, marshalRestartClusterRequestSchema, - marshalRollbackClusterRequestSchema, marshalStartClusterRequestSchema, marshalUnpinClusterRequestSchema, marshalUpdateClusterRequestSchema, unmarshalCancelPendingClusterEnforcementResponseSchema, unmarshalChangeClusterOwnerResponseSchema, unmarshalClusterInfoSchema, - unmarshalClusterRevisionSchema, unmarshalCreateClusterResponseSchema, unmarshalDeleteClusterResponseSchema, unmarshalEditClusterResponseSchema, @@ -100,7 +93,6 @@ import { unmarshalGetSparkVersionsResponseSchema, unmarshalListAvailableZonesResponseSchema, unmarshalListClusterComplianceForPolicyResponseSchema, - unmarshalListClusterRevisionsResponseSchema, unmarshalListClustersResponseSchema, unmarshalListNodeTypesResponseSchema, unmarshalPermanentDeleteClusterResponseSchema, @@ -196,132 +188,6 @@ export class ClustersClient { } } - /** Get details of a cluster revision. */ - async getClusterRevision( - req: GetClusterRevisionRequest, - options?: CallOptions - ): Promise { - const {host, workspaceId, httpClient} = await this.resolveConfig(); - const url = `${host}/api/2.1/${req.name ?? ''}`; - let resp: ClusterRevision | undefined; - const call = async (callSignal?: AbortSignal): Promise => { - const headers = new Headers(); - if (workspaceId !== undefined) { - headers.set('X-Databricks-Workspace-Id', workspaceId); - } - headers.set('User-Agent', this.userAgent); - const httpReq = buildHttpRequest('GET', url, headers, callSignal); - const respBody = await executeHttpCall({ - request: httpReq, - httpClient, - logger: this.logger, - }); - resp = parseResponse(respBody, unmarshalClusterRevisionSchema); - }; - await executeCall(call, options); - if (resp === undefined) { - throw new Error('operation completed without a result.'); - } - return resp; - } - - /** Lists a cluster's revisions, ordered from most to least recent. */ - async listClusterRevisions( - req: ListClusterRevisionsRequest, - options?: CallOptions - ): Promise { - const {host, workspaceId, httpClient} = await this.resolveConfig(); - const url = `${host}/api/2.1/${req.parent ?? ''}/revisions`; - const params = new URLSearchParams(); - if (req.pageSize !== undefined) { - params.append('page_size', String(req.pageSize)); - } - if (req.pageToken !== undefined) { - params.append('page_token', req.pageToken); - } - const query = params.toString(); - const fullUrl = query !== '' ? `${url}?${query}` : url; - let resp: ListClusterRevisionsResponse | undefined; - const call = async (callSignal?: AbortSignal): Promise => { - const headers = new Headers(); - if (workspaceId !== undefined) { - headers.set('X-Databricks-Workspace-Id', workspaceId); - } - headers.set('User-Agent', this.userAgent); - const httpReq = buildHttpRequest('GET', fullUrl, headers, callSignal); - const respBody = await executeHttpCall({ - request: httpReq, - httpClient, - logger: this.logger, - }); - resp = parseResponse( - respBody, - unmarshalListClusterRevisionsResponseSchema - ); - }; - await executeCall(call, options); - if (resp === undefined) { - throw new Error('operation completed without a result.'); - } - return resp; - } - - async *listClusterRevisionsIter( - req: ListClusterRevisionsRequest, - options?: CallOptions - ): AsyncGenerator { - const pageReq: ListClusterRevisionsRequest = {...req}; - for (;;) { - const resp = await this.listClusterRevisions(pageReq, options); - for (const item of resp.clusterRevisions ?? []) { - yield item; - } - if (resp.nextPageToken === undefined || resp.nextPageToken === '') { - return; - } - pageReq.pageToken = resp.nextPageToken; - } - } - - /** - * Rolls back a cluster to a previous revision. - * A cluster can be rolled back if it is in a `RUNNING` or `TERMINATED` state. - * - * If a cluster is rolled back while in a `RUNNING` state, it will be restarted so that the new attributes can take effect. - * - * If a cluster is rolled back while in a `TERMINATED` state, it will remain `TERMINATED`. - * The next time it is started using the `clusters/start` API, the new attributes will take effect. - * Any attempt to roll back a cluster in any other state will be rejected with an `INVALID_PARAMETER_VALUE` error code. - */ - async rollbackCluster( - req: RollbackClusterRequest, - options?: CallOptions - ): Promise { - const {host, workspaceId, httpClient} = await this.resolveConfig(); - const url = `${host}/api/2.1/${req.name ?? ''}/rollback`; - const body = marshalRequest(req, marshalRollbackClusterRequestSchema); - let resp: ClusterRevision | undefined; - const call = async (callSignal?: AbortSignal): Promise => { - const headers = new Headers({'Content-Type': 'application/json'}); - if (workspaceId !== undefined) { - headers.set('X-Databricks-Workspace-Id', workspaceId); - } - headers.set('User-Agent', this.userAgent); - const httpReq = buildHttpRequest('POST', url, headers, callSignal, body); - const respBody = await executeHttpCall({ - request: httpReq, - httpClient, - logger: this.logger, - }); - resp = parseResponse(respBody, unmarshalClusterRevisionSchema); - }; - await executeCall(call, options); - if (resp === undefined) { - throw new Error('operation completed without a result.'); - } - return resp; - } - /** Change the owner of the cluster. You must be an admin and the cluster must be terminated to perform this operation. The service principal application ID can be supplied as an argument to `owner_username`. */ async changeClusterOwner( req: ChangeClusterOwnerRequest, diff --git a/packages/clusters/src/v2/index.ts b/packages/clusters/src/v2/index.ts index 302a45066..aa1c88d28 100644 --- a/packages/clusters/src/v2/index.ts +++ b/packages/clusters/src/v2/index.ts @@ -19,7 +19,6 @@ export { AwsAvailability, AzureAvailability, CloudProviderNodeStatus, - ClusterEditReason, ComputeKind, ConfidentialComputeType, DataPlaneClusterEventType, @@ -58,7 +57,6 @@ export type { ClusterInfo, ClusterInfo_ComputeSpec, ClusterLogConf, - ClusterRevision, ClusterSize, ClusterState, CreateClusterRequest, @@ -79,7 +77,6 @@ export type { GcpAttributes, GcsStorageInfo, GetClusterRequest, - GetClusterRevisionRequest, GetEventsResponse, GetPolicyComplianceForClusterRequest, GetPolicyComplianceForClusterResponse, @@ -93,8 +90,6 @@ export type { ListAvailableZonesResponse, ListClusterComplianceForPolicyRequest, ListClusterComplianceForPolicyResponse, - ListClusterRevisionsRequest, - ListClusterRevisionsResponse, ListClustersRequest, ListClustersResponse, ListEventsRequest, @@ -116,7 +111,6 @@ export type { ResizeClusterResponse, RestartClusterRequest, RestartClusterResponse, - RollbackClusterRequest, S3StorageInfo, SparkInfo, SparkInfo_SparkNode, diff --git a/packages/clusters/src/v2/model.ts b/packages/clusters/src/v2/model.ts index f1438c6b4..6b7f56b9c 100644 --- a/packages/clusters/src/v2/model.ts +++ b/packages/clusters/src/v2/model.ts @@ -55,27 +55,6 @@ export type CloudProviderNodeStatus = | (typeof CloudProviderNodeStatus)[keyof typeof CloudProviderNodeStatus] | (string & {}); -/** Possible reasons a cluster might be edited. */ -// eslint-disable-next-line @typescript-eslint/naming-convention -- Enum-style const object. -export const ClusterEditReason = { - /** Default value. Not used. */ - CLUSTER_EDIT_REASON_UNSPECIFIED: 'CLUSTER_EDIT_REASON_UNSPECIFIED', - /** Cluster was initially created. */ - CREATION: 'CREATION', - /** Cluster was manually edited by the user. */ - MANUAL_EDIT: 'MANUAL_EDIT', - /** Cluster was edited as part of a policy enforcement. */ - POLICY_ENFORCEMENT: 'POLICY_ENFORCEMENT', - /** - * Cluster was edited as part of a policy enforcement that - * was scheduled on the next cluster termination / restart. - */ - DEFERRED_POLICY_ENFORCEMENT: 'DEFERRED_POLICY_ENFORCEMENT', -} as const; -export type ClusterEditReason = - | (typeof ClusterEditReason)[keyof typeof ClusterEditReason] - | (string & {}); - /** * The kind of compute described by this compute specification. * @@ -1124,7 +1103,7 @@ export type ResizeCause_ResizeCause = /** A storage location in Adls Gen2 */ export interface Adlsgen2Info { /** abfss destination, e.g. `abfss://@.dfs.core.windows.net/`. */ - destination?: string | undefined; + destination: string; } export interface AutoScale { @@ -1266,7 +1245,7 @@ export interface AzureAttributes { /** Request to cancel the pending enforcement for a cluster. */ export interface CancelPendingClusterEnforcementRequest { /** The ID of the cluster to cancel the pending enforcement for. */ - clusterId?: string | undefined; + clusterId: string; /** * If true and no pending enforcement exists, the request will succeed but no action * will be taken. @@ -1283,9 +1262,9 @@ export interface CancelPendingClusterEnforcementRequest { export interface CancelPendingClusterEnforcementResponse {} export interface ChangeClusterOwnerRequest { - clusterId?: string | undefined; + clusterId: string; /** New owner of the cluster_id after this RPC. */ - ownerUsername?: string | undefined; + ownerUsername: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -1293,7 +1272,7 @@ export interface ChangeClusterOwnerResponse {} export interface CloneCluster { /** The cluster that is being cloned. */ - sourceClusterId?: string | undefined; + sourceClusterId: string; } export interface CloudProviderNodeInfo { @@ -1465,7 +1444,7 @@ export interface ClusterAttributes { export interface ClusterCompliance { /** Canonical unique identifier for a cluster. */ - clusterId?: string | undefined; + clusterId: string; /** Whether this cluster is in compliance with the latest version of its policy. */ isCompliant?: boolean | undefined; /** @@ -1482,7 +1461,7 @@ export interface ClusterCompliance { } export interface ClusterEvent { - clusterId?: string | undefined; + clusterId: string; /** * The timestamp when the event occurred, stored as the number of milliseconds since * the Unix epoch. If not provided, this will be assigned by the Timeline service. @@ -1977,26 +1956,6 @@ export interface ClusterLogConf { | undefined; } -/** - * Represents a cluster revision. - * - * Only the 100 most recent revisions are stored for each cluster. - */ -export interface ClusterRevision { - /** ID of the cluster revision. */ - revisionId?: string | undefined; - /** Time when the cluster revision was created. */ - createTime?: Temporal.Instant | undefined; - /** Settings used to create/edit the cluster. */ - settings?: ClusterInfo_ComputeSpec | undefined; - /** Reason the cluster was edited. */ - editReason?: ClusterEditReason | undefined; - /** Name of the user who edited this cluster. */ - editUser?: string | undefined; - /** Whether this is the current revision. */ - isCurrent?: boolean | undefined; -} - export interface ClusterSize { size?: | { @@ -2230,12 +2189,12 @@ export interface DataPlaneEventDetails { /** A storage location in DBFS */ export interface DbfsStorageInfo { /** dbfs destination, e.g. `dbfs:/my/path` */ - destination?: string | undefined; + destination: string; } export interface DeleteClusterRequest { /** The cluster to be terminated. */ - clusterId?: string | undefined; + clusterId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -2262,7 +2221,7 @@ export interface DockerImage { export interface EditClusterRequest { /** ID of the cluster */ - clusterId?: string | undefined; + clusterId: string; /** When set to true, fixed and default values from the policy will be used for fields that are omitted. When set to false, only fixed values from the policy will be applied. */ applyPolicyDefaultValues?: boolean | undefined; size?: @@ -2451,7 +2410,7 @@ export interface EditClusterResponse {} export interface EnforcePolicyComplianceForClusterRequest { /** The ID of the cluster you want to enforce policy compliance on. */ - clusterId?: string | undefined; + clusterId: string; /** * If set, previews the changes that would be made to a cluster * to enforce compliance but does not update the cluster. @@ -2811,21 +2770,12 @@ export interface GcpAttributes { /** A storage location in Google Cloud Platform's GCS */ export interface GcsStorageInfo { /** GCS destination/URI, e.g. `gs://my-bucket/some-prefix` */ - destination?: string | undefined; + destination: string; } export interface GetClusterRequest { /** The cluster about which to retrieve information. */ - clusterId?: string | undefined; -} - -/** Request to get a cluster revision by ID. */ -export interface GetClusterRevisionRequest { - /** - * The fully qualified resource name of the cluster revision. - * Format: clusters/{cluster_id}/revisions/{revision_id}. - */ - name?: string | undefined; + clusterId: string; } export interface GetEventsResponse { @@ -2857,7 +2807,7 @@ export interface GetEventsResponse { export interface GetPolicyComplianceForClusterRequest { /** The ID of the cluster to get the compliance status */ - clusterId?: string | undefined; + clusterId: string; } export interface GetPolicyComplianceForClusterResponse { @@ -3066,7 +3016,7 @@ export interface ListAvailableZonesResponse { export interface ListClusterComplianceForPolicyRequest { /** Canonical unique identifier for the cluster policy. */ - policyId?: string | undefined; + policyId: string; /** * A page token that can be used to navigate to the next page or previous page as * returned by `next_page_token` or `prev_page_token`. @@ -3095,27 +3045,6 @@ export interface ListClusterComplianceForPolicyResponse { prevPageToken?: string | undefined; } -/** Request to list cluster revisions. */ -export interface ListClusterRevisionsRequest { - /** - * The fully qualified resource name of the parent cluster. - * Format: clusters/{cluster_id}. - */ - parent?: string | undefined; - /** Maximum number of cluster revisions to return per page. */ - pageSize?: number | undefined; - /** Pagination token from a previous list cluster revisions request. */ - pageToken?: string | undefined; -} - -/** Response when listing cluster revisions. */ -export interface ListClusterRevisionsResponse { - /** Cluster revisions in the current page. */ - clusterRevisions?: ClusterRevision[] | undefined; - /** Token for fetching the next page. Empty when there are no more results. */ - nextPageToken?: string | undefined; -} - export interface ListClustersRequest { /** Use next_page_token or prev_page_token returned from the previous request to list the next or previous page of clusters respectively. */ pageToken?: string | undefined; @@ -3139,7 +3068,7 @@ export interface ListClustersResponse { export interface ListEventsRequest { /** The ID of the cluster to retrieve events about. */ - clusterId?: string | undefined; + clusterId: string; /** * The start time in epoch milliseconds. * If empty, returns events starting from the beginning of time. @@ -3195,7 +3124,7 @@ export interface ListNodeTypesResponse { export interface LocalFileInfo { /** local file destination, e.g. `file:/my/local/file.sh` */ - destination?: string | undefined; + destination: string; } export interface LogAnalyticsInfo { @@ -3224,7 +3153,7 @@ export interface LogSyncStatus { */ export interface NodeInstanceType { /** Unique identifier across instance types */ - instanceTypeId?: string | undefined; + instanceTypeId: string; /** Number of local disks that are present on this instance. */ localDisks?: number | undefined; /** Size of the individual local disks attached to this instance (i.e. per local disk). */ @@ -3241,26 +3170,26 @@ export interface NodeInstanceType { */ export interface NodeType { /** Unique identifier for this node type. */ - nodeTypeId?: string | undefined; + nodeTypeId: string; /** Memory (in MB) available for this node type. */ - memoryMb?: number | undefined; + memoryMb: number; /** * Number of CPU cores available for this node type. * Note that this can be fractional, e.g., 2.5 cores, if the number of cores on a * machine instance is not divisible by the number of Spark nodes on that machine. */ - numCores?: number | undefined; + numCores: number; /** A string description associated with this node type, e.g., "r3.xlarge". */ - description?: string | undefined; + description: string; /** An identifier for the type of hardware that this node runs on, e.g., "r3.2xlarge" in AWS. */ - instanceTypeId?: string | undefined; + instanceTypeId: string; /** Whether the node type is deprecated. Non-deprecated node types offer greater performance. */ isDeprecated?: boolean | undefined; /** * A descriptive category for this node type. Examples include "Memory Optimized" and * "Compute Optimized". */ - category?: string | undefined; + category: string; /** * Whether this node type support EBS volumes. EBS volumes is disabled for node types that * we could place multiple corresponding containers on the same hosting instance. @@ -3300,6 +3229,11 @@ export interface NodeType { export interface NodeTypeFlexibility { /** A list of node type IDs to use as fallbacks when the primary node type is unavailable. */ alternateNodeTypeIds?: string[] | undefined; + /** + * The AWS Context ID for EC2 Fleet. + * When set (non-empty), the value is passed to AWS CreateFleet API to create the EC2 Fleet. + */ + awsContextId?: string | undefined; } /** @@ -3332,14 +3266,14 @@ export interface PendingEnforcement { export interface PermanentDeleteClusterRequest { /** The cluster to be deleted. */ - clusterId?: string | undefined; + clusterId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface PermanentDeleteClusterResponse {} export interface PinClusterRequest { - clusterId?: string | undefined; + clusterId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -3350,7 +3284,7 @@ export interface ResizeCause {} export interface ResizeClusterRequest { /** The cluster to be resized. */ - clusterId?: string | undefined; + clusterId: string; size?: | { $case: 'numWorkers'; @@ -3382,22 +3316,13 @@ export interface ResizeClusterResponse {} export interface RestartClusterRequest { /** The cluster to be started. */ - clusterId?: string | undefined; + clusterId: string; restartUser?: string | undefined; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface RestartClusterResponse {} -/** Request to roll back cluster. */ -export interface RollbackClusterRequest { - /** - * The fully qualified resource name of the cluster revision. - * Format: clusters/{cluster_id}/revisions/{revision_id}. - */ - name?: string | undefined; -} - /** A storage location in Amazon S3 */ export interface S3StorageInfo { /** @@ -3405,7 +3330,7 @@ export interface S3StorageInfo { * cluster iam role, please make sure you set cluster iam role and the role has write access to the * destination. Please also note that you cannot use AWS keys to deliver logs. */ - destination?: string | undefined; + destination: string; /** * S3 region, e.g. `us-west-2`. Either region or endpoint needs to be set. If both are set, * endpoint will be used. @@ -3492,7 +3417,7 @@ export interface SparkVersion { export interface StartClusterRequest { /** The cluster to be started. */ - clusterId?: string | undefined; + clusterId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -3508,7 +3433,7 @@ export interface TerminationReason { } export interface UnpinClusterRequest { - clusterId?: string | undefined; + clusterId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -3516,13 +3441,11 @@ export interface UnpinClusterResponse {} export interface UpdateClusterRequest { /** ID of the cluster. */ - clusterId?: string | undefined; + clusterId: string; /** The cluster to be updated. */ cluster?: UpdateClusterRequest_UpdateClusterResource | undefined; /** Used to specify which cluster attributes and size fields to update. See https://google.aip.dev/161 for more details. */ - updateMask?: - | FieldMask - | undefined; + updateMask: FieldMask; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. @@ -3717,13 +3640,13 @@ export interface VolumesStorageInfo { * UC Volumes destination, e.g. `/Volumes/catalog/schema/vol1/init-scripts/setup-datadog.sh` * or `dbfs:/Volumes/catalog/schema/vol1/init-scripts/setup-datadog.sh` */ - destination?: string | undefined; + destination: string; } /** Cluster Attributes showing for clusters workload types. */ export interface WorkloadType { /** defined what type of clients can use the cluster. E.g. Notebooks, Jobs */ - clients?: WorkloadType_ClientsTypes | undefined; + clients: WorkloadType_ClientsTypes; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. @@ -3737,12 +3660,12 @@ export interface WorkloadType_ClientsTypes { /** A storage location in Workspace Filesystem (WSFS) */ export interface WorkspaceStorageInfo { /** wsfs destination, e.g. `workspace:/cluster-init-scripts/setup-datadog.sh` */ - destination?: string | undefined; + destination: string; } export const unmarshalAdlsgen2InfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -3895,7 +3818,7 @@ export const unmarshalClusterAttributesSchema: z.ZodType = z export const unmarshalClusterComplianceSchema: z.ZodType = z .object({ - cluster_id: z.string().optional(), + cluster_id: z.string(), is_compliant: z.boolean().optional(), violations: z.record(z.string(), z.string()).optional(), pending_enforcement: z @@ -3911,7 +3834,7 @@ export const unmarshalClusterComplianceSchema: z.ZodType = z export const unmarshalClusterEventSchema: z.ZodType = z .object({ - cluster_id: z.string().optional(), + cluster_id: z.string(), timestamp: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) @@ -4177,27 +4100,6 @@ export const unmarshalClusterLogConfSchema: z.ZodType = z : undefined, })); -export const unmarshalClusterRevisionSchema: z.ZodType = z - .object({ - revision_id: z.string().optional(), - create_time: z - .string() - .transform(s => Temporal.Instant.from(s)) - .optional(), - settings: z.lazy(() => unmarshalClusterInfo_ComputeSpecSchema).optional(), - edit_reason: z.string().optional(), - edit_user: z.string().optional(), - is_current: z.boolean().optional(), - }) - .transform(d => ({ - revisionId: d.revision_id, - createTime: d.create_time, - settings: d.settings, - editReason: d.edit_reason, - editUser: d.edit_user, - isCurrent: d.is_current, - })); - export const unmarshalClusterSizeSchema: z.ZodType = z .object({ num_workers: z.number().optional(), @@ -4241,7 +4143,7 @@ export const unmarshalDataPlaneEventDetailsSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -4480,7 +4382,7 @@ export const unmarshalGcpAttributesSchema: z.ZodType = z export const unmarshalGcsStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -4650,19 +4552,6 @@ export const unmarshalListClusterComplianceForPolicyResponseSchema: z.ZodType
  • = - z - .object({ - cluster_revisions: z - .array(z.lazy(() => unmarshalClusterRevisionSchema)) - .optional(), - next_page_token: z.string().optional(), - }) - .transform(d => ({ - clusterRevisions: d.cluster_revisions, - nextPageToken: d.next_page_token, - })); - export const unmarshalListClustersResponseSchema: z.ZodType = z .object({ @@ -4678,7 +4567,7 @@ export const unmarshalListClustersResponseSchema: z.ZodType = z .object({ - cluster_id: z.string().optional(), + cluster_id: z.string(), start_time: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) @@ -4723,7 +4612,7 @@ export const unmarshalListNodeTypesResponseSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -4754,7 +4643,7 @@ export const unmarshalLogSyncStatusSchema: z.ZodType = z export const unmarshalNodeInstanceTypeSchema: z.ZodType = z .object({ - instance_type_id: z.string().optional(), + instance_type_id: z.string(), local_disks: z.number().optional(), local_disk_size_gb: z.number().optional(), local_nvme_disk_size_gb: z.number().optional(), @@ -4770,13 +4659,13 @@ export const unmarshalNodeInstanceTypeSchema: z.ZodType = z export const unmarshalNodeTypeSchema: z.ZodType = z .object({ - node_type_id: z.string().optional(), - memory_mb: z.number().optional(), - num_cores: z.number().optional(), - description: z.string().optional(), - instance_type_id: z.string().optional(), + node_type_id: z.string(), + memory_mb: z.number(), + num_cores: z.number(), + description: z.string(), + instance_type_id: z.string(), is_deprecated: z.boolean().optional(), - category: z.string().optional(), + category: z.string(), support_ebs_volumes: z.boolean().optional(), support_cluster_tags: z.boolean().optional(), num_gpus: z.number().optional(), @@ -4820,9 +4709,11 @@ export const unmarshalNodeTypeFlexibilitySchema: z.ZodType z .object({ alternate_node_type_ids: z.array(z.string()).optional(), + aws_context_id: z.string().optional(), }) .transform(d => ({ alternateNodeTypeIds: d.alternate_node_type_ids, + awsContextId: d.aws_context_id, })); export const unmarshalPendingEnforcementSchema: z.ZodType = @@ -4871,7 +4762,7 @@ export const unmarshalRestartClusterResponseSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), region: z.string().optional(), endpoint: z.string().optional(), enable_encryption: z.boolean().optional(), @@ -4960,7 +4851,7 @@ export const unmarshalUpdateClusterResponseSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -4968,7 +4859,7 @@ export const unmarshalVolumesStorageInfoSchema: z.ZodType = export const unmarshalWorkloadTypeSchema: z.ZodType = z .object({ - clients: z.lazy(() => unmarshalWorkloadType_ClientsTypesSchema).optional(), + clients: z.lazy(() => unmarshalWorkloadType_ClientsTypesSchema), }) .transform(d => ({ clients: d.clients, @@ -4989,7 +4880,7 @@ export const unmarshalWorkloadType_ClientsTypesSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -4997,7 +4888,7 @@ export const unmarshalWorkspaceStorageInfoSchema: z.ZodType ({ destination: d.destination, @@ -5057,7 +4948,7 @@ export const marshalAzureAttributesSchema: z.ZodType = z export const marshalCancelPendingClusterEnforcementRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), allowMissing: z.boolean().optional(), }) .transform(d => ({ @@ -5067,8 +4958,8 @@ export const marshalCancelPendingClusterEnforcementRequestSchema: z.ZodType = z export const marshalChangeClusterOwnerRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), - ownerUsername: z.string().optional(), + clusterId: z.string(), + ownerUsername: z.string(), }) .transform(d => ({ cluster_id: d.clusterId, @@ -5077,7 +4968,7 @@ export const marshalChangeClusterOwnerRequestSchema: z.ZodType = z export const marshalCloneClusterSchema: z.ZodType = z .object({ - sourceClusterId: z.string().optional(), + sourceClusterId: z.string(), }) .transform(d => ({ source_cluster_id: d.sourceClusterId, @@ -5199,7 +5090,7 @@ export const marshalCreateClusterRequestSchema: z.ZodType = z export const marshalDbfsStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -5207,7 +5098,7 @@ export const marshalDbfsStorageInfoSchema: z.ZodType = z export const marshalDeleteClusterRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), }) .transform(d => ({ cluster_id: d.clusterId, @@ -5244,7 +5135,7 @@ export const marshalDockerImageSchema: z.ZodType = z export const marshalEditClusterRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), applyPolicyDefaultValues: z.boolean().optional(), size: z .discriminatedUnion('$case', [ @@ -5334,7 +5225,7 @@ export const marshalEditClusterRequestSchema: z.ZodType = z export const marshalEnforcePolicyComplianceForClusterRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), validateOnly: z.boolean().optional(), enforceMode: z.string().optional(), }) @@ -5368,7 +5259,7 @@ export const marshalGcpAttributesSchema: z.ZodType = z export const marshalGcsStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -5423,7 +5314,7 @@ export const marshalInitScriptInfoSchema: z.ZodType = z export const marshalListEventsRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), startTime: z.bigint().optional(), endTime: z.bigint().optional(), order: z.string().optional(), @@ -5447,7 +5338,7 @@ export const marshalListEventsRequestSchema: z.ZodType = z export const marshalLocalFileInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -5466,14 +5357,16 @@ export const marshalLogAnalyticsInfoSchema: z.ZodType = z export const marshalNodeTypeFlexibilitySchema: z.ZodType = z .object({ alternateNodeTypeIds: z.array(z.string()).optional(), + awsContextId: z.string().optional(), }) .transform(d => ({ alternate_node_type_ids: d.alternateNodeTypeIds, + aws_context_id: d.awsContextId, })); export const marshalPermanentDeleteClusterRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), }) .transform(d => ({ cluster_id: d.clusterId, @@ -5481,7 +5374,7 @@ export const marshalPermanentDeleteClusterRequestSchema: z.ZodType = z export const marshalPinClusterRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), }) .transform(d => ({ cluster_id: d.clusterId, @@ -5489,7 +5382,7 @@ export const marshalPinClusterRequestSchema: z.ZodType = z export const marshalResizeClusterRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), size: z .discriminatedUnion('$case', [ z.object({$case: z.literal('numWorkers'), numWorkers: z.number()}), @@ -5508,7 +5401,7 @@ export const marshalResizeClusterRequestSchema: z.ZodType = z export const marshalRestartClusterRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), restartUser: z.string().optional(), }) .transform(d => ({ @@ -5516,17 +5409,9 @@ export const marshalRestartClusterRequestSchema: z.ZodType = z restart_user: d.restartUser, })); -export const marshalRollbackClusterRequestSchema: z.ZodType = z - .object({ - name: z.string().optional(), - }) - .transform(d => ({ - name: d.name, - })); - export const marshalS3StorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), region: z.string().optional(), endpoint: z.string().optional(), enableEncryption: z.boolean().optional(), @@ -5546,7 +5431,7 @@ export const marshalS3StorageInfoSchema: z.ZodType = z export const marshalStartClusterRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), }) .transform(d => ({ cluster_id: d.clusterId, @@ -5554,7 +5439,7 @@ export const marshalStartClusterRequestSchema: z.ZodType = z export const marshalUnpinClusterRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), }) .transform(d => ({ cluster_id: d.clusterId, @@ -5562,14 +5447,11 @@ export const marshalUnpinClusterRequestSchema: z.ZodType = z export const marshalUpdateClusterRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), + clusterId: z.string(), cluster: z .lazy(() => marshalUpdateClusterRequest_UpdateClusterResourceSchema) .optional(), - updateMask: z - .any() - .transform((m: FieldMask) => m.toString()) - .optional(), + updateMask: z.any().transform((m: FieldMask) => m.toString()), }) .transform(d => ({ cluster_id: d.clusterId, @@ -5668,7 +5550,7 @@ export const marshalUpdateClusterRequest_UpdateClusterResourceSchema: z.ZodType export const marshalVolumesStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -5676,7 +5558,7 @@ export const marshalVolumesStorageInfoSchema: z.ZodType = z export const marshalWorkloadTypeSchema: z.ZodType = z .object({ - clients: z.lazy(() => marshalWorkloadType_ClientsTypesSchema).optional(), + clients: z.lazy(() => marshalWorkloadType_ClientsTypesSchema), }) .transform(d => ({ clients: d.clients, @@ -5695,7 +5577,7 @@ export const marshalWorkloadType_ClientsTypesSchema: z.ZodType = z export const marshalWorkspaceStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -5771,6 +5653,7 @@ const logAnalyticsInfoFieldMaskSchema: FieldMaskSchema = { const nodeTypeFlexibilityFieldMaskSchema: FieldMaskSchema = { alternateNodeTypeIds: {wire: 'alternate_node_type_ids'}, + awsContextId: {wire: 'aws_context_id'}, }; const s3StorageInfoFieldMaskSchema: FieldMaskSchema = { diff --git a/packages/commandexecution/src/v2/model.ts b/packages/commandexecution/src/v2/model.ts index 6b8ae91d2..76864c3d6 100644 --- a/packages/commandexecution/src/v2/model.ts +++ b/packages/commandexecution/src/v2/model.ts @@ -86,8 +86,8 @@ export interface CreateResponse { } export interface DestroyContextRequest { - clusterId?: string | undefined; - contextId?: string | undefined; + clusterId: string; + contextId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -105,9 +105,9 @@ export interface ExecuteCommandRequest { /** Request to get the status of a previously submitted command. */ export interface GetCommandStatusRequest { - clusterId?: string | undefined; - contextId?: string | undefined; - commandId?: string | undefined; + clusterId: string; + contextId: string; + commandId: string; } export interface GetCommandStatusResponse { @@ -118,8 +118,8 @@ export interface GetCommandStatusResponse { /** Request to retrieve the status of an execution context. */ export interface GetContextStatusRequest { - clusterId?: string | undefined; - contextId?: string | undefined; + clusterId: string; + contextId: string; } export interface GetContextStatusResponse { @@ -244,8 +244,8 @@ export const marshalCreateContextRequestSchema: z.ZodType = z export const marshalDestroyContextRequestSchema: z.ZodType = z .object({ - clusterId: z.string().optional(), - contextId: z.string().optional(), + clusterId: z.string(), + contextId: z.string(), }) .transform(d => ({ clusterId: d.clusterId, diff --git a/packages/customllms/src/v1/model.ts b/packages/customllms/src/v1/model.ts index ffac99e13..59c9f7d66 100644 --- a/packages/customllms/src/v1/model.ts +++ b/packages/customllms/src/v1/model.ts @@ -19,14 +19,14 @@ export const State = { export type State = (typeof State)[keyof typeof State] | (string & {}); export interface CancelCustomLlmOptimizationRunRequest { - id?: string | undefined; + id: string; } export interface CreateCustomLlmRequest { /** Name of the custom LLM. Only alphanumeric characters and dashes allowed. */ - name?: string | undefined; + name: string; /** Instructions for the custom LLM to follow */ - instructions?: string | undefined; + instructions: string; /** * Datasets used for training and evaluating the model, not for inference. * Currently, only 1 dataset is accepted. @@ -45,11 +45,11 @@ export interface CreateCustomLlmRequest { export interface CustomLlm { id?: string | undefined; /** Name of the custom LLM */ - name?: string | undefined; + name: string; /** Name of the endpoint that will be used to serve the custom LLM */ endpointName?: string | undefined; /** Instructions for the custom LLM to follow */ - instructions?: string | undefined; + instructions: string; /** Datasets used for training and evaluating the model, not for inference */ datasets?: Dataset[] | undefined; /** Guidelines for the custom LLM to adhere to */ @@ -64,29 +64,29 @@ export interface CustomLlm { } export interface Dataset { - table?: Table | undefined; + table: Table; } export interface DeleteCustomLlmRequest { /** The id of the custom llm */ - id?: string | undefined; + id: string; } export interface GetCustomLlmRequest { /** The id of the custom llm */ - id?: string | undefined; + id: string; } export interface StartCustomLlmOptimizationRunRequest { /** The Id of the tile. */ - id?: string | undefined; + id: string; } export interface Table { /** Full UC table path in catalog.schema.table_name format */ - tablePath?: string | undefined; + tablePath: string; /** Name of the request column */ - requestCol?: string | undefined; + requestCol: string; /** Optional: Name of the response column if the data is labeled */ responseCol?: string | undefined; } @@ -95,17 +95,17 @@ export interface UpdateCustomLlmRequest { /** The id of the custom llm */ id?: string | undefined; /** The CustomLlm containing the fields which should be updated. */ - customLlm?: CustomLlm | undefined; + customLlm: CustomLlm; /** The list of the CustomLlm fields to update. These should correspond to the values (or lack thereof) present in `custom_llm`. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export const unmarshalCustomLlmSchema: z.ZodType = z .object({ id: z.string().optional(), - name: z.string().optional(), + name: z.string(), endpoint_name: z.string().optional(), - instructions: z.string().optional(), + instructions: z.string(), datasets: z.array(z.lazy(() => unmarshalDatasetSchema)).optional(), guidelines: z.array(z.string()).optional(), optimization_state: z.string().optional(), @@ -131,7 +131,7 @@ export const unmarshalCustomLlmSchema: z.ZodType = z export const unmarshalDatasetSchema: z.ZodType = z .object({ - table: z.lazy(() => unmarshalTableSchema).optional(), + table: z.lazy(() => unmarshalTableSchema), }) .transform(d => ({ table: d.table, @@ -139,8 +139,8 @@ export const unmarshalDatasetSchema: z.ZodType = z export const unmarshalTableSchema: z.ZodType = z .object({ - table_path: z.string().optional(), - request_col: z.string().optional(), + table_path: z.string(), + request_col: z.string(), response_col: z.string().optional(), }) .transform(d => ({ @@ -151,7 +151,7 @@ export const unmarshalTableSchema: z.ZodType
    = z export const marshalCancelCustomLlmOptimizationRunRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), }) .transform(d => ({ id: d.id, @@ -159,8 +159,8 @@ export const marshalCancelCustomLlmOptimizationRunRequestSchema: z.ZodType = z export const marshalCreateCustomLlmRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - instructions: z.string().optional(), + name: z.string(), + instructions: z.string(), datasets: z.array(z.lazy(() => marshalDatasetSchema)).optional(), guidelines: z.array(z.string()).optional(), agentArtifactPath: z.string().optional(), @@ -176,9 +176,9 @@ export const marshalCreateCustomLlmRequestSchema: z.ZodType = z export const marshalCustomLlmSchema: z.ZodType = z .object({ id: z.string().optional(), - name: z.string().optional(), + name: z.string(), endpointName: z.string().optional(), - instructions: z.string().optional(), + instructions: z.string(), datasets: z.array(z.lazy(() => marshalDatasetSchema)).optional(), guidelines: z.array(z.string()).optional(), optimizationState: z.string().optional(), @@ -204,7 +204,7 @@ export const marshalCustomLlmSchema: z.ZodType = z export const marshalDatasetSchema: z.ZodType = z .object({ - table: z.lazy(() => marshalTableSchema).optional(), + table: z.lazy(() => marshalTableSchema), }) .transform(d => ({ table: d.table, @@ -212,7 +212,7 @@ export const marshalDatasetSchema: z.ZodType = z export const marshalStartCustomLlmOptimizationRunRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), }) .transform(d => ({ id: d.id, @@ -220,8 +220,8 @@ export const marshalStartCustomLlmOptimizationRunRequestSchema: z.ZodType = z export const marshalTableSchema: z.ZodType = z .object({ - tablePath: z.string().optional(), - requestCol: z.string().optional(), + tablePath: z.string(), + requestCol: z.string(), responseCol: z.string().optional(), }) .transform(d => ({ @@ -233,11 +233,8 @@ export const marshalTableSchema: z.ZodType = z export const marshalUpdateCustomLlmRequestSchema: z.ZodType = z .object({ id: z.string().optional(), - customLlm: z.lazy(() => marshalCustomLlmSchema).optional(), - updateMask: z - .any() - .transform((m: FieldMask) => m.toString()) - .optional(), + customLlm: z.lazy(() => marshalCustomLlmSchema), + updateMask: z.any().transform((m: FieldMask) => m.toString()), }) .transform(d => ({ id: d.id, diff --git a/packages/database/src/v1/model.ts b/packages/database/src/v1/model.ts index df5a99938..c700322ad 100644 --- a/packages/database/src/v1/model.ts +++ b/packages/database/src/v1/model.ts @@ -201,26 +201,26 @@ export type SyncedTableSpec_PgSpecificType = | (string & {}); export interface CreateDatabaseCatalogRequest { - catalog?: DatabaseCatalog | undefined; + catalog: DatabaseCatalog; } export interface CreateDatabaseInstanceRequest { /** Instance to create. */ - databaseInstance?: DatabaseInstance | undefined; + databaseInstance: DatabaseInstance; } export interface CreateDatabaseInstanceRoleRequest { instanceName?: string | undefined; - databaseInstanceRole?: DatabaseInstanceRole | undefined; + databaseInstanceRole: DatabaseInstanceRole; databaseInstanceName?: string | undefined; } export interface CreateDatabaseTableRequest { - table?: DatabaseTable | undefined; + table: DatabaseTable; } export interface CreateSyncedDatabaseTableRequest { - syncedTable?: SyncedDatabaseTable | undefined; + syncedTable: SyncedDatabaseTable; } export interface CustomTag { @@ -232,11 +232,11 @@ export interface CustomTag { export interface DatabaseCatalog { /** The name of the catalog in UC. */ - name?: string | undefined; + name: string; /** The name of the DatabaseInstance housing the database. */ - databaseInstanceName?: string | undefined; + databaseInstanceName: string; /** The name of the database (in an instance) associated with the catalog. */ - databaseName?: string | undefined; + databaseName: string; uid?: string | undefined; createDatabaseIfNotExists?: boolean | undefined; } @@ -251,7 +251,7 @@ export interface DatabaseInstance { /** An immutable UUID identifier for the instance. */ uid?: string | undefined; /** The name of the instance. This is the unique identifier for the instance. */ - name?: string | undefined; + name: string; /** The email of the creator of the instance. */ creator?: string | undefined; /** The DNS endpoint to connect to the instance for read+write access. */ @@ -400,7 +400,7 @@ export interface DatabaseInstanceRef { /** A DatabaseInstanceRole represents a Postgres role in a database instance. */ export interface DatabaseInstanceRole { /** The name of the role. This is the unique identifier for the role in an instance. */ - name?: string | undefined; + name: string; /** The type of the role. */ identityType?: DatabaseInstanceRole_IdentityType | undefined; /** An enum value for a standard role that this role is a member of. */ @@ -432,7 +432,7 @@ export interface DatabaseInstanceRole_Attributes { export interface DatabaseTable { /** Full three-part (catalog, schema, table) name of the table. */ - name?: string | undefined; + name: string; /** * Name of the target database instance. This is required when creating database tables in standard catalogs. * This is optional when creating database tables in registered catalogs. If this field is specified @@ -452,7 +452,7 @@ export interface DatabaseTable { } export interface DeleteDatabaseCatalogRequest { - name?: string | undefined; + name: string; } export interface DeleteDatabaseInstanceRequest { @@ -471,19 +471,19 @@ export interface DeleteDatabaseInstanceRequest { } export interface DeleteDatabaseInstanceRoleRequest { - instanceName?: string | undefined; - name?: string | undefined; + instanceName: string; + name: string; reassignOwnedTo?: string | undefined; /** This is the AIP standard name for the equivalent of Postgres' `IF EXISTS` option */ allowMissing?: boolean | undefined; } export interface DeleteDatabaseTableRequest { - name?: string | undefined; + name: string; } export interface DeleteSyncedDatabaseTableRequest { - name?: string | undefined; + name: string; /** Optional. When set to true, the actual PostgreSQL table will be dropped from the database. */ purgeData?: boolean | undefined; } @@ -519,7 +519,7 @@ export interface GenerateDatabaseCredentialRequest { } export interface GetDatabaseCatalogRequest { - name?: string | undefined; + name: string; } export interface GetDatabaseInstanceRequest { @@ -533,11 +533,11 @@ export interface GetDatabaseInstanceRoleRequest { } export interface GetDatabaseTableRequest { - name?: string | undefined; + name: string; } export interface GetSyncedDatabaseTableRequest { - name?: string | undefined; + name: string; } export interface ListDatabaseCatalogsRequest { @@ -644,7 +644,7 @@ export interface RequestedResource { export interface SyncedDatabaseTable { /** Full three-part (catalog, schema, table) name of the table. */ - name?: string | undefined; + name: string; /** * Name of the target database instance. This is required when creating synced database tables in standard catalogs. * This is optional when creating synced database tables in registered catalogs. If this field is specified @@ -823,9 +823,9 @@ export interface SyncedTableSpec { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface SyncedTableSpec_TypeOverride { /** Name of the source column whose target PostgreSQL type should be overridden. */ - columnName?: string | undefined; + columnName: string; /** PostgreSQL-specific target type to use for the column. */ - pgType?: SyncedTableSpec_PgSpecificType | undefined; + pgType: SyncedTableSpec_PgSpecificType; /** * Size parameter for the target type, for types that take one (e.g. vector * dimension, varchar length). Required when the chosen pg_type needs a size. @@ -893,25 +893,25 @@ export interface SyncedTableTriggeredUpdateStatus { export interface UpdateDatabaseCatalogRequest { /** Note that updating a database catalog is not yet supported. */ - databaseCatalog?: DatabaseCatalog | undefined; + databaseCatalog: DatabaseCatalog; /** The list of fields to update. Setting this field is not yet supported. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateDatabaseInstanceRequest { - databaseInstance?: DatabaseInstance | undefined; + databaseInstance: DatabaseInstance; /** * The list of fields to update. If unspecified, all fields will be updated when possible. To wipe out custom_tags, * specify custom_tags in the update_mask with an empty custom_tags map. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateSyncedDatabaseTableRequest { /** Note that updating a synced database table is not yet supported. */ - syncedTable?: SyncedDatabaseTable | undefined; + syncedTable: SyncedDatabaseTable; /** The list of fields to update. Setting this field is not yet supported. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export const unmarshalCustomTagSchema: z.ZodType = z @@ -926,9 +926,9 @@ export const unmarshalCustomTagSchema: z.ZodType = z export const unmarshalDatabaseCatalogSchema: z.ZodType = z .object({ - name: z.string().optional(), - database_instance_name: z.string().optional(), - database_name: z.string().optional(), + name: z.string(), + database_instance_name: z.string(), + database_name: z.string(), uid: z.string().optional(), create_database_if_not_exists: z.boolean().optional(), }) @@ -957,7 +957,7 @@ export const unmarshalDatabaseCredentialSchema: z.ZodType = export const unmarshalDatabaseInstanceSchema: z.ZodType = z .object({ uid: z.string().optional(), - name: z.string().optional(), + name: z.string(), creator: z.string().optional(), read_write_dns: z.string().optional(), creation_time: z @@ -1044,7 +1044,7 @@ export const unmarshalDatabaseInstanceRefSchema: z.ZodType export const unmarshalDatabaseInstanceRoleSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), identity_type: z.string().optional(), membership_role: z.string().optional(), attributes: z @@ -1080,7 +1080,7 @@ export const unmarshalDatabaseInstanceRole_AttributesSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), database_instance_name: z.string().optional(), logical_database_name: z.string().optional(), }) @@ -1174,7 +1174,7 @@ export const unmarshalNewPipelineSpecSchema: z.ZodType = z export const unmarshalSyncedDatabaseTableSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), database_instance_name: z.string().optional(), effective_database_instance_name: z.string().optional(), logical_database_name: z.string().optional(), @@ -1330,8 +1330,8 @@ export const unmarshalSyncedTableSpecSchema: z.ZodType = z export const unmarshalSyncedTableSpec_TypeOverrideSchema: z.ZodType = z .object({ - column_name: z.string().optional(), - pg_type: z.string().optional(), + column_name: z.string(), + pg_type: z.string(), size: z.number().optional(), }) .transform(d => ({ @@ -1418,9 +1418,9 @@ export const marshalCustomTagSchema: z.ZodType = z export const marshalDatabaseCatalogSchema: z.ZodType = z .object({ - name: z.string().optional(), - databaseInstanceName: z.string().optional(), - databaseName: z.string().optional(), + name: z.string(), + databaseInstanceName: z.string(), + databaseName: z.string(), uid: z.string().optional(), createDatabaseIfNotExists: z.boolean().optional(), }) @@ -1435,7 +1435,7 @@ export const marshalDatabaseCatalogSchema: z.ZodType = z export const marshalDatabaseInstanceSchema: z.ZodType = z .object({ uid: z.string().optional(), - name: z.string().optional(), + name: z.string(), creator: z.string().optional(), readWriteDns: z.string().optional(), creationTime: z @@ -1520,7 +1520,7 @@ export const marshalDatabaseInstanceRefSchema: z.ZodType = z export const marshalDatabaseInstanceRoleSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), identityType: z.string().optional(), membershipRole: z.string().optional(), attributes: z @@ -1555,7 +1555,7 @@ export const marshalDatabaseInstanceRole_AttributesSchema: z.ZodType = z export const marshalDatabaseTableSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), databaseInstanceName: z.string().optional(), logicalDatabaseName: z.string().optional(), }) @@ -1635,7 +1635,7 @@ export const marshalRequestedResourceSchema: z.ZodType = z export const marshalSyncedDatabaseTableSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), databaseInstanceName: z.string().optional(), effectiveDatabaseInstanceName: z.string().optional(), logicalDatabaseName: z.string().optional(), @@ -1771,8 +1771,8 @@ export const marshalSyncedTableSpecSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalSyncedTableSpec_TypeOverrideSchema: z.ZodType = z .object({ - columnName: z.string().optional(), - pgType: z.string().optional(), + columnName: z.string(), + pgType: z.string(), size: z.number().optional(), }) .transform(d => ({ diff --git a/packages/dataclassification/src/v1/model.ts b/packages/dataclassification/src/v1/model.ts index 9d51f0c9b..2bad6caf5 100644 --- a/packages/dataclassification/src/v1/model.ts +++ b/packages/dataclassification/src/v1/model.ts @@ -26,9 +26,9 @@ export interface AutoTaggingConfig { * The Classification Tag. For built-in classes this is a system tag (e.g., "class.name", * "class.location"); for custom classes it is a user-defined governance tag key. */ - classificationTag?: string | undefined; + classificationTag: string; /** Whether auto-tagging is enabled or disabled for this classification tag. */ - autoTaggingMode?: AutoTaggingConfig_AutoTaggingMode | undefined; + autoTaggingMode: AutoTaggingConfig_AutoTaggingMode; } /** @@ -72,7 +72,7 @@ export interface CatalogConfig { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface CatalogConfig_SchemaNames { /** Schema names, each relative to the parent catalog. Must not be empty. */ - names?: string[] | undefined; + names: string[]; } /** @@ -81,7 +81,7 @@ export interface CatalogConfig_SchemaNames { */ export interface CreateCatalogConfigRequest { /** Parent resource in the format: catalogs/{catalog_name} */ - parent?: string | undefined; + parent: string; /** The configuration to create. */ catalogConfig?: CatalogConfig | undefined; } @@ -92,13 +92,13 @@ export interface CreateCatalogConfigRequest { */ export interface DeleteCatalogConfigRequest { /** Resource name in the format: catalogs/{catalog_name}/config */ - name?: string | undefined; + name: string; } /** Get Data Classification configuration for a catalog. */ export interface GetCatalogConfigRequest { /** Resource name in the format: catalogs/{catalog_name}/config */ - name?: string | undefined; + name: string; } /** @@ -112,15 +112,15 @@ export interface UpdateCatalogConfigRequest { * The configuration to apply to the catalog. * The name field in catalog_config identifies which resource to update. */ - catalogConfig?: CatalogConfig | undefined; + catalogConfig: CatalogConfig; /** Field mask specifying which fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export const unmarshalAutoTaggingConfigSchema: z.ZodType = z .object({ - classification_tag: z.string().optional(), - auto_tagging_mode: z.string().optional(), + classification_tag: z.string(), + auto_tagging_mode: z.string(), }) .transform(d => ({ classificationTag: d.classification_tag, @@ -161,7 +161,7 @@ export const unmarshalCatalogConfigSchema: z.ZodType = z export const unmarshalCatalogConfig_SchemaNamesSchema: z.ZodType = z .object({ - names: z.array(z.string()).optional(), + names: z.array(z.string()), }) .transform(d => ({ names: d.names, @@ -169,8 +169,8 @@ export const unmarshalCatalogConfig_SchemaNamesSchema: z.ZodType ({ classification_tag: d.classificationTag, @@ -210,7 +210,7 @@ export const marshalCatalogConfigSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalCatalogConfig_SchemaNamesSchema: z.ZodType = z .object({ - names: z.array(z.string()).optional(), + names: z.array(z.string()), }) .transform(d => ({ names: d.names, diff --git a/packages/dataquality/src/v1/model.ts b/packages/dataquality/src/v1/model.ts index 4ad9342bd..e814577ec 100644 --- a/packages/dataquality/src/v1/model.ts +++ b/packages/dataquality/src/v1/model.ts @@ -137,7 +137,7 @@ export interface AnomalyDetectionConfig { /** Request to cancel a refresh. */ export interface CancelRefreshRequest { /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ - objectType?: string | undefined; + objectType: string; /** * The UUID of the request object. It is `schema_id` for `schema`, and `table_id` for `table`. * @@ -149,9 +149,9 @@ export interface CancelRefreshRequest { * 1. The [table_id](https://docs.databricks.com/api/workspace/tables/get#table_id) of the `Tables` resource. * 2. In [Catalog Explorer](https://docs.databricks.com/aws/en/catalog-explorer/) > select the `table` > go to the `Details` tab > the `Table ID` field. */ - objectId?: string | undefined; + objectId: string; /** Unique id of the refresh operation. */ - refreshId?: bigint | undefined; + refreshId: bigint; } /** Response to cancelling a refresh. */ @@ -175,13 +175,13 @@ export interface CreateRefreshRequest { /** The data quality monitoring workflow cron schedule. */ export interface CronSchedule { /** The expression that determines when to run the monitor. See [examples](https://www.quartz-scheduler.org/documentation/quartz-2.3.0/tutorials/crontrigger.html). */ - quartzCronExpression?: string | undefined; + quartzCronExpression: string; /** * A Java timezone id. The schedule for a job will be resolved with respect to this timezone. * See `Java TimeZone `_ for details. * The timezone id (e.g., ``America/Los_Angeles``) in which to evaluate the quartz expression. */ - timezoneId?: string | undefined; + timezoneId: string; /** Read only field that indicates whether the schedule is paused or not. */ pauseStatus?: CronSchedulePauseStatus | undefined; } @@ -189,7 +189,7 @@ export interface CronSchedule { /** Data Profiling Configurations. */ export interface DataProfilingConfig { /** ID of the schema where output tables are created. */ - outputSchemaId?: string | undefined; + outputSchemaId: string; /** * Field for specifying the absolute path to a custom directory to store data-monitoring * assets. Normally prepopulated to a default user location via UI and Python APIs. @@ -269,24 +269,24 @@ export interface DataProfilingConfig { /** Custom metric definition. */ export interface DataProfilingCustomMetric { /** Name of the metric in the output tables. */ - name?: string | undefined; + name: string; /** Jinja template for a SQL expression that specifies how to compute the metric. See [create metric definition](https://docs.databricks.com/en/lakehouse-monitoring/custom-metrics.html#create-definition). */ - definition?: string | undefined; + definition: string; /** * A list of column names in the input table the metric should be computed for. * Can use ``":table"`` to indicate that the metric needs information from multiple columns. */ - inputColumns?: string[] | undefined; + inputColumns: string[]; /** The output type of the custom metric. */ - outputDataType?: string | undefined; + outputDataType: string; /** The type of the custom metric. */ - type?: DataProfilingCustomMetricType | undefined; + type: DataProfilingCustomMetricType; } /** Request to delete a Monitor. */ export interface DeleteMonitorRequest { /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ - objectType?: string | undefined; + objectType: string; /** * The UUID of the request object. It is `schema_id` for `schema`, and `table_id` for `table`. * @@ -298,13 +298,13 @@ export interface DeleteMonitorRequest { * 1. The [table_id](https://docs.databricks.com/api/workspace/tables/get#table_id) of the `Tables` resource. * 2. In [Catalog Explorer](https://docs.databricks.com/aws/en/catalog-explorer/) > select the `table` > go to the `Details` tab > the `Table ID` field. */ - objectId?: string | undefined; + objectId: string; } /** Request to delete a ronitor. */ export interface DeleteRefreshRequest { /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ - objectType?: string | undefined; + objectType: string; /** * The UUID of the request object. It is `schema_id` for `schema`, and `table_id` for `table`. * @@ -316,15 +316,15 @@ export interface DeleteRefreshRequest { * 1. The [table_id](https://docs.databricks.com/api/workspace/tables/get#table_id) of the `Tables` resource. * 2. In [Catalog Explorer](https://docs.databricks.com/aws/en/catalog-explorer/) > select the `table` > go to the `Details` tab > the `Table ID` field. */ - objectId?: string | undefined; + objectId: string; /** Unique id of the refresh operation. */ - refreshId?: bigint | undefined; + refreshId: bigint; } /** Request to get a Monitor. */ export interface GetMonitorRequest { /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ - objectType?: string | undefined; + objectType: string; /** * The UUID of the request object. It is `schema_id` for `schema`, and `table_id` for `table`. * @@ -336,13 +336,13 @@ export interface GetMonitorRequest { * 1. The [table_id](https://docs.databricks.com/api/workspace/tables/get#table_id) of the `Tables` resource. * 2. In [Catalog Explorer](https://docs.databricks.com/aws/en/catalog-explorer/) > select the `table` > go to the `Details` tab > the `Table ID` field. */ - objectId?: string | undefined; + objectId: string; } /** Request to get a refresh. */ export interface GetRefreshRequest { /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ - objectType?: string | undefined; + objectType: string; /** * The UUID of the request object. It is `schema_id` for `schema`, and `table_id` for `table`. * @@ -354,25 +354,25 @@ export interface GetRefreshRequest { * 1. The [table_id](https://docs.databricks.com/api/workspace/tables/get#table_id) of the `Tables` resource. * 2. In [Catalog Explorer](https://docs.databricks.com/aws/en/catalog-explorer/) > select the `table` > go to the `Details` tab > the `Table ID` field. */ - objectId?: string | undefined; + objectId: string; /** Unique id of the refresh operation. */ - refreshId?: bigint | undefined; + refreshId: bigint; } /** Inference log configuration. */ export interface InferenceLogConfig { /** Problem type the model aims to solve. */ - problemType?: InferenceProblemType | undefined; + problemType: InferenceProblemType; /** Column for the timestamp. */ - timestampColumn?: string | undefined; + timestampColumn: string; /** List of granularities to use when aggregating data into time windows based on their timestamp. */ - granularities?: AggregationGranularity[] | undefined; + granularities: AggregationGranularity[]; /** Column for the prediction. */ - predictionColumn?: string | undefined; + predictionColumn: string; /** Column for the label. */ labelColumn?: string | undefined; /** Column for the model identifier. */ - modelIdColumn?: string | undefined; + modelIdColumn: string; } /** Request to list Monitors. */ @@ -390,7 +390,7 @@ export interface ListMonitorResponse { /** Request to list refreshes. */ export interface ListRefreshRequest { /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ - objectType?: string | undefined; + objectType: string; /** * The UUID of the request object. It is `schema_id` for `schema`, and `table_id` for `table`. * @@ -402,7 +402,7 @@ export interface ListRefreshRequest { * 1. The [table_id](https://docs.databricks.com/api/workspace/tables/get#table_id) of the `Tables` resource. * 2. In [Catalog Explorer](https://docs.databricks.com/aws/en/catalog-explorer/) > select the `table` > go to the `Details` tab > the `Table ID` field. */ - objectId?: string | undefined; + objectId: string; pageToken?: string | undefined; pageSize?: number | undefined; } @@ -416,7 +416,7 @@ export interface ListRefreshResponse { /** Monitor for the data quality of unity catalog entities such as schema or table. */ export interface Monitor { /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ - objectType?: string | undefined; + objectType: string; /** * The UUID of the request object. It is `schema_id` for `schema`, and `table_id` for `table`. * @@ -428,7 +428,7 @@ export interface Monitor { * 1. The [table_id](https://docs.databricks.com/api/workspace/tables/get#table_id) of the `Tables` resource. * 2. In [Catalog Explorer](https://docs.databricks.com/aws/en/catalog-explorer/) > select the `table` > go to the `Details` tab > the `Table ID` field. */ - objectId?: string | undefined; + objectId: string; /** Anomaly Detection Configuration, applicable to `schema` object types. */ anomalyDetectionConfig?: AnomalyDetectionConfig | undefined; /** @@ -453,7 +453,7 @@ export interface NotificationSettings { /** The Refresh object gives information on a refresh of the data quality monitoring pipeline. */ export interface Refresh { /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ - objectType?: string | undefined; + objectType: string; /** * The UUID of the request object. It is `schema_id` for `schema`, and `table_id` for `table`. * @@ -465,7 +465,7 @@ export interface Refresh { * 1. The [table_id](https://docs.databricks.com/api/workspace/tables/get#table_id) of the `Tables` resource. * 2. In [Catalog Explorer](https://docs.databricks.com/aws/en/catalog-explorer/) > select the `table` > go to the `Details` tab > the `Table ID` field. */ - objectId?: string | undefined; + objectId: string; /** Unique id of the refresh operation. */ refreshId?: bigint | undefined; /** The current state of the refresh. */ @@ -487,15 +487,15 @@ export interface SnapshotConfig {} /** Time series analysis configuration. */ export interface TimeSeriesConfig { /** Column for the timestamp. */ - timestampColumn?: string | undefined; + timestampColumn: string; /** List of granularities to use when aggregating data into time windows based on their timestamp. */ - granularities?: AggregationGranularity[] | undefined; + granularities: AggregationGranularity[]; } /** Request to update a Monitor. */ export interface UpdateMonitorRequest { /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ - objectType?: string | undefined; + objectType: string; /** * The UUID of the request object. It is `schema_id` for `schema`, and `table_id` for `table`. * @@ -507,20 +507,20 @@ export interface UpdateMonitorRequest { * 1. The [table_id](https://docs.databricks.com/api/workspace/tables/get#table_id) of the `Tables` resource. * 2. In [Catalog Explorer](https://docs.databricks.com/aws/en/catalog-explorer/) > select the `table` > go to the `Details` tab > the `Table ID` field. */ - objectId?: string | undefined; + objectId: string; /** The monitor to update. */ monitor?: Monitor | undefined; /** * The field mask to specify which fields to update as a comma-separated list. * Example value: `data_profiling_config.custom_metrics,data_profiling_config.schedule.quartz_cron_expression` */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } /** Request to update a refresh. */ export interface UpdateRefreshRequest { /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ - objectType?: string | undefined; + objectType: string; /** * The UUID of the request object. It is `schema_id` for `schema`, and `table_id` for `table`. * @@ -532,13 +532,13 @@ export interface UpdateRefreshRequest { * 1. The [table_id](https://docs.databricks.com/api/workspace/tables/get#table_id) of the `Tables` resource. * 2. In [Catalog Explorer](https://docs.databricks.com/aws/en/catalog-explorer/) > select the `table` > go to the `Details` tab > the `Table ID` field. */ - objectId?: string | undefined; + objectId: string; /** Unique id of the refresh operation. */ - refreshId?: bigint | undefined; + refreshId: bigint; /** The refresh to update. */ refresh?: Refresh | undefined; /** The field mask to specify which fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export const unmarshalAnomalyDetectionConfigSchema: z.ZodType = @@ -561,8 +561,8 @@ export const unmarshalCancelRefreshResponseSchema: z.ZodType = z .object({ - quartz_cron_expression: z.string().optional(), - timezone_id: z.string().optional(), + quartz_cron_expression: z.string(), + timezone_id: z.string(), pause_status: z.string().optional(), }) .transform(d => ({ @@ -574,7 +574,7 @@ export const unmarshalCronScheduleSchema: z.ZodType = z export const unmarshalDataProfilingConfigSchema: z.ZodType = z .object({ - output_schema_id: z.string().optional(), + output_schema_id: z.string(), assets_dir: z.string().optional(), inference_log: z.lazy(() => unmarshalInferenceLogConfigSchema).optional(), time_series: z.lazy(() => unmarshalTimeSeriesConfigSchema).optional(), @@ -633,11 +633,11 @@ export const unmarshalDataProfilingConfigSchema: z.ZodType export const unmarshalDataProfilingCustomMetricSchema: z.ZodType = z .object({ - name: z.string().optional(), - definition: z.string().optional(), - input_columns: z.array(z.string()).optional(), - output_data_type: z.string().optional(), - type: z.string().optional(), + name: z.string(), + definition: z.string(), + input_columns: z.array(z.string()), + output_data_type: z.string(), + type: z.string(), }) .transform(d => ({ name: d.name, @@ -650,12 +650,12 @@ export const unmarshalDataProfilingCustomMetricSchema: z.ZodType = z .object({ - problem_type: z.string().optional(), - timestamp_column: z.string().optional(), - granularities: z.array(z.string()).optional(), - prediction_column: z.string().optional(), + problem_type: z.string(), + timestamp_column: z.string(), + granularities: z.array(z.string()), + prediction_column: z.string(), label_column: z.string().optional(), - model_id_column: z.string().optional(), + model_id_column: z.string(), }) .transform(d => ({ problemType: d.problem_type, @@ -690,8 +690,8 @@ export const unmarshalListRefreshResponseSchema: z.ZodType export const unmarshalMonitorSchema: z.ZodType = z .object({ - object_type: z.string().optional(), - object_id: z.string().optional(), + object_type: z.string(), + object_id: z.string(), anomaly_detection_config: z .lazy(() => unmarshalAnomalyDetectionConfigSchema) .optional(), @@ -728,8 +728,8 @@ export const unmarshalNotificationSettingsSchema: z.ZodType = z .object({ - object_type: z.string().optional(), - object_id: z.string().optional(), + object_type: z.string(), + object_id: z.string(), refresh_id: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) @@ -762,8 +762,8 @@ export const unmarshalSnapshotConfigSchema: z.ZodType = export const unmarshalTimeSeriesConfigSchema: z.ZodType = z .object({ - timestamp_column: z.string().optional(), - granularities: z.array(z.string()).optional(), + timestamp_column: z.string(), + granularities: z.array(z.string()), }) .transform(d => ({ timestampColumn: d.timestamp_column, @@ -780,9 +780,9 @@ export const marshalAnomalyDetectionConfigSchema: z.ZodType = z export const marshalCancelRefreshRequestSchema: z.ZodType = z .object({ - objectType: z.string().optional(), - objectId: z.string().optional(), - refreshId: z.bigint().optional(), + objectType: z.string(), + objectId: z.string(), + refreshId: z.bigint(), }) .transform(d => ({ object_type: d.objectType, @@ -792,8 +792,8 @@ export const marshalCancelRefreshRequestSchema: z.ZodType = z export const marshalCronScheduleSchema: z.ZodType = z .object({ - quartzCronExpression: z.string().optional(), - timezoneId: z.string().optional(), + quartzCronExpression: z.string(), + timezoneId: z.string(), pauseStatus: z.string().optional(), }) .transform(d => ({ @@ -804,7 +804,7 @@ export const marshalCronScheduleSchema: z.ZodType = z export const marshalDataProfilingConfigSchema: z.ZodType = z .object({ - outputSchemaId: z.string().optional(), + outputSchemaId: z.string(), assetsDir: z.string().optional(), analysisConfig: z .discriminatedUnion('$case', [ @@ -873,11 +873,11 @@ export const marshalDataProfilingConfigSchema: z.ZodType = z export const marshalDataProfilingCustomMetricSchema: z.ZodType = z .object({ - name: z.string().optional(), - definition: z.string().optional(), - inputColumns: z.array(z.string()).optional(), - outputDataType: z.string().optional(), - type: z.string().optional(), + name: z.string(), + definition: z.string(), + inputColumns: z.array(z.string()), + outputDataType: z.string(), + type: z.string(), }) .transform(d => ({ name: d.name, @@ -889,12 +889,12 @@ export const marshalDataProfilingCustomMetricSchema: z.ZodType = z export const marshalInferenceLogConfigSchema: z.ZodType = z .object({ - problemType: z.string().optional(), - timestampColumn: z.string().optional(), - granularities: z.array(z.string()).optional(), - predictionColumn: z.string().optional(), + problemType: z.string(), + timestampColumn: z.string(), + granularities: z.array(z.string()), + predictionColumn: z.string(), labelColumn: z.string().optional(), - modelIdColumn: z.string().optional(), + modelIdColumn: z.string(), }) .transform(d => ({ problem_type: d.problemType, @@ -907,8 +907,8 @@ export const marshalInferenceLogConfigSchema: z.ZodType = z export const marshalMonitorSchema: z.ZodType = z .object({ - objectType: z.string().optional(), - objectId: z.string().optional(), + objectType: z.string(), + objectId: z.string(), anomalyDetectionConfig: z .lazy(() => marshalAnomalyDetectionConfigSchema) .optional(), @@ -941,8 +941,8 @@ export const marshalNotificationSettingsSchema: z.ZodType = z export const marshalRefreshSchema: z.ZodType = z .object({ - objectType: z.string().optional(), - objectId: z.string().optional(), + objectType: z.string(), + objectId: z.string(), refreshId: z.bigint().optional(), state: z.string().optional(), message: z.string().optional(), @@ -965,8 +965,8 @@ export const marshalSnapshotConfigSchema: z.ZodType = z.object({}); export const marshalTimeSeriesConfigSchema: z.ZodType = z .object({ - timestampColumn: z.string().optional(), - granularities: z.array(z.string()).optional(), + timestampColumn: z.string(), + granularities: z.array(z.string()), }) .transform(d => ({ timestamp_column: d.timestampColumn, diff --git a/packages/disasterrecovery/src/v1/model.ts b/packages/disasterrecovery/src/v1/model.ts index a08c94cec..dc7782b69 100644 --- a/packages/disasterrecovery/src/v1/model.ts +++ b/packages/disasterrecovery/src/v1/model.ts @@ -45,31 +45,31 @@ export type FailoverGroup_State = /** Request to create a new failover group. */ export interface CreateFailoverGroupRequest { /** The parent resource. Format: accounts/{account_id}. */ - parent?: string | undefined; + parent: string; /** The failover group to create. */ - failoverGroup?: FailoverGroup | undefined; + failoverGroup: FailoverGroup; /** When true, validates the request without creating the failover group. */ validateOnly?: boolean | undefined; /** * Client-provided identifier for the failover group. Used to construct the * resource name as {parent}/failover-groups/{failover_group_id}. */ - failoverGroupId?: string | undefined; + failoverGroupId: string; } /** Request to create a new stable URL for failover-aware workspace access. */ export interface CreateStableUrlRequest { /** The parent resource. Format: accounts/{account_id}. */ - parent?: string | undefined; + parent: string; /** The stable URL to create. */ - stableUrl?: StableUrl | undefined; + stableUrl: StableUrl; /** When true, validates the request without creating the stable URL. */ validateOnly?: boolean | undefined; /** * Client-provided identifier for the stable URL. Used to construct the * resource name as {parent}/stable-urls/{stable_url_id}. */ - stableUrlId?: string | undefined; + stableUrlId: string; } /** Request to delete a failover group. */ @@ -78,7 +78,7 @@ export interface DeleteFailoverGroupRequest { * The fully qualified resource name of the failover group to delete. * Format: accounts/{account_id}/failover-groups/{failover_group_id}. */ - name?: string | undefined; + name: string; /** * Opaque version string for optimistic locking. If provided, must match the * current etag. If omitted, the delete proceeds without an etag check. @@ -92,7 +92,7 @@ export interface DeleteStableUrlRequest { * The fully qualified resource name. * Format: accounts/{account_id}/stable-urls/{stable_url_id}. */ - name?: string | undefined; + name: string; } /** Request to failover a failover group to a new primary region. */ @@ -101,19 +101,19 @@ export interface FailoverFailoverGroupRequest { * The fully qualified resource name of the failover group to failover. * Format: accounts/{account_id}/failover-groups/{failover_group_id}. */ - name?: string | undefined; + name: string; /** * The target primary region. Must be one of the participating regions and different * from the current effective_primary_region. Serves as an idempotency check. */ - targetPrimaryRegion?: string | undefined; + targetPrimaryRegion: string; /** * Opaque version string for optimistic locking. If provided, must match the * current etag. If omitted, the failover proceeds regardless of current state. */ etag?: string | undefined; /** The type of failover to perform. */ - failoverType?: FailoverFailoverGroupRequest_FailoverType | undefined; + failoverType: FailoverFailoverGroupRequest_FailoverType; } /** @@ -132,9 +132,9 @@ export interface FailoverGroup { */ effectivePrimaryRegion?: string | undefined; /** List of all regions participating in this failover group. */ - regions?: string[] | undefined; + regions: string[]; /** Workspace sets, each containing workspaces that replicate to each other. */ - workspaceSets?: WorkspaceSet[] | undefined; + workspaceSets: WorkspaceSet[]; /** Unity Catalog replication configuration. */ unityCatalogAssets?: UcReplicationConfig | undefined; /** Aggregate state of the failover group. */ @@ -151,7 +151,7 @@ export interface FailoverGroup { * Initial primary region. Used only in Create requests to set the starting * primary region. Not returned in responses. */ - initialPrimaryRegion?: string | undefined; + initialPrimaryRegion: string; } /** Request to get a failover group. */ @@ -160,7 +160,7 @@ export interface GetFailoverGroupRequest { * The fully qualified resource name of the failover group. * Format: accounts/{account_id}/failover-groups/{failover_group_id}. */ - name?: string | undefined; + name: string; } /** Request to get a stable URL. */ @@ -169,13 +169,13 @@ export interface GetStableUrlRequest { * The fully qualified resource name. * Format: accounts/{account_id}/stable-urls/{stable_url_id}. */ - name?: string | undefined; + name: string; } /** Request to list failover groups for an account. */ export interface ListFailoverGroupsRequest { /** The parent resource. Format: accounts/{account_id}. */ - parent?: string | undefined; + parent: string; /** * Maximum number of failover groups to return per page: * - when set to a value greater than 0, the page length is the minimum of this value @@ -206,7 +206,7 @@ export interface ListFailoverGroupsResponse { /** Request to list stable URLs for an account. */ export interface ListStableUrlsRequest { /** The parent resource. Format: accounts/{account_id}. */ - parent?: string | undefined; + parent: string; /** * Maximum number of stable URLs to return per page: * - when set to a value greater than 0, the page length is the minimum of this value @@ -240,9 +240,9 @@ export interface ListStableUrlsResponse { */ export interface LocationMapping { /** Resource name for this location. */ - name?: string | undefined; + name: string; /** URI for each region. Each entry maps a region name to a storage URI. */ - uriByRegion?: LocationMappingEntry[] | undefined; + uriByRegion: LocationMappingEntry[]; } /** @@ -251,9 +251,9 @@ export interface LocationMapping { */ export interface LocationMappingEntry { /** The region name. */ - region?: string | undefined; + region: string; /** The storage URI for this region. */ - uri?: string | undefined; + uri: string; } /** @@ -278,7 +278,7 @@ export interface StableUrl { * requests to associate the stable URL with a workspace. Not returned in * responses. */ - initialWorkspaceId?: string | undefined; + initialWorkspaceId: string; /** * Fully qualified resource name of the FailoverGroup this stable URL is * currently linked to, in the format @@ -307,7 +307,7 @@ export interface StableUrl { /** A Unity Catalog catalog to replicate. */ export interface UcCatalog { /** The name of the UC catalog to replicate. */ - name?: string | undefined; + name: string; } /** Unity Catalog replication configuration (top-level, not per-set). */ @@ -315,12 +315,12 @@ export interface UcReplicationConfig { /** Location mappings - storage URI per region for each location. */ locationMappings?: LocationMapping[] | undefined; /** UC catalogs to replicate. */ - catalogs?: UcCatalog[] | undefined; + catalogs: UcCatalog[]; /** * The workspace set whose workspaces will be used for data replication * of all UC catalogs' underlying storage. */ - dataReplicationWorkspaceSet?: string | undefined; + dataReplicationWorkspaceSet: string; } /** Request to update a failover group. */ @@ -329,9 +329,9 @@ export interface UpdateFailoverGroupRequest { * The failover group with updated fields. The name field identifies the resource * and is populated from the URL path. */ - failoverGroup?: FailoverGroup | undefined; + failoverGroup: FailoverGroup; /** Comma-separated list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; /** * Optional opaque version string for optimistic locking, obtained from a prior read of * the failover group. If provided, the update is rejected unless it matches the failover @@ -343,12 +343,12 @@ export interface UpdateFailoverGroupRequest { /** A set of workspaces that replicate to each other across regions. */ export interface WorkspaceSet { /** Resource name for this workspace set. */ - name?: string | undefined; + name: string; /** * Workspace IDs in this set. The system derives and validates regions. * All workspaces must be in the Mission Critical tier. */ - workspaceIds?: string[] | undefined; + workspaceIds: string[]; /** * Whether to enable control plane DR (notebooks, jobs, clusters, etc.) for this set. * Defaults to false. @@ -366,10 +366,8 @@ export const unmarshalFailoverGroupSchema: z.ZodType = z .object({ name: z.string().optional(), effective_primary_region: z.string().optional(), - regions: z.array(z.string()).optional(), - workspace_sets: z - .array(z.lazy(() => unmarshalWorkspaceSetSchema)) - .optional(), + regions: z.array(z.string()), + workspace_sets: z.array(z.lazy(() => unmarshalWorkspaceSetSchema)), unity_catalog_assets: z .lazy(() => unmarshalUcReplicationConfigSchema) .optional(), @@ -387,7 +385,7 @@ export const unmarshalFailoverGroupSchema: z.ZodType = z .string() .transform(s => Temporal.Instant.from(s)) .optional(), - initial_primary_region: z.string().optional(), + initial_primary_region: z.string(), }) .transform(d => ({ name: d.name, @@ -429,10 +427,8 @@ export const unmarshalListStableUrlsResponseSchema: z.ZodType = z .object({ - name: z.string().optional(), - uri_by_region: z - .array(z.lazy(() => unmarshalLocationMappingEntrySchema)) - .optional(), + name: z.string(), + uri_by_region: z.array(z.lazy(() => unmarshalLocationMappingEntrySchema)), }) .transform(d => ({ name: d.name, @@ -442,8 +438,8 @@ export const unmarshalLocationMappingSchema: z.ZodType = z export const unmarshalLocationMappingEntrySchema: z.ZodType = z .object({ - region: z.string().optional(), - uri: z.string().optional(), + region: z.string(), + uri: z.string(), }) .transform(d => ({ region: d.region, @@ -454,7 +450,7 @@ export const unmarshalStableUrlSchema: z.ZodType = z .object({ name: z.string().optional(), url: z.string().optional(), - initial_workspace_id: z.string().optional(), + initial_workspace_id: z.string(), failover_group_name: z.string().optional(), effective_workspace_id: z.string().optional(), stable_workspace_id: z.string().optional(), @@ -470,7 +466,7 @@ export const unmarshalStableUrlSchema: z.ZodType = z export const unmarshalUcCatalogSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -482,8 +478,8 @@ export const unmarshalUcReplicationConfigSchema: z.ZodType location_mappings: z .array(z.lazy(() => unmarshalLocationMappingSchema)) .optional(), - catalogs: z.array(z.lazy(() => unmarshalUcCatalogSchema)).optional(), - data_replication_workspace_set: z.string().optional(), + catalogs: z.array(z.lazy(() => unmarshalUcCatalogSchema)), + data_replication_workspace_set: z.string(), }) .transform(d => ({ locationMappings: d.location_mappings, @@ -493,8 +489,8 @@ export const unmarshalUcReplicationConfigSchema: z.ZodType export const unmarshalWorkspaceSetSchema: z.ZodType = z .object({ - name: z.string().optional(), - workspace_ids: z.array(z.string()).optional(), + name: z.string(), + workspace_ids: z.array(z.string()), replicate_workspace_assets: z.boolean().optional(), stable_url_names: z.array(z.string()).optional(), }) @@ -507,10 +503,10 @@ export const unmarshalWorkspaceSetSchema: z.ZodType = z export const marshalFailoverFailoverGroupRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - targetPrimaryRegion: z.string().optional(), + name: z.string(), + targetPrimaryRegion: z.string(), etag: z.string().optional(), - failoverType: z.string().optional(), + failoverType: z.string(), }) .transform(d => ({ name: d.name, @@ -523,8 +519,8 @@ export const marshalFailoverGroupSchema: z.ZodType = z .object({ name: z.string().optional(), effectivePrimaryRegion: z.string().optional(), - regions: z.array(z.string()).optional(), - workspaceSets: z.array(z.lazy(() => marshalWorkspaceSetSchema)).optional(), + regions: z.array(z.string()), + workspaceSets: z.array(z.lazy(() => marshalWorkspaceSetSchema)), unityCatalogAssets: z .lazy(() => marshalUcReplicationConfigSchema) .optional(), @@ -542,7 +538,7 @@ export const marshalFailoverGroupSchema: z.ZodType = z .any() .transform((d: Temporal.Instant) => d.toString()) .optional(), - initialPrimaryRegion: z.string().optional(), + initialPrimaryRegion: z.string(), }) .transform(d => ({ name: d.name, @@ -560,10 +556,8 @@ export const marshalFailoverGroupSchema: z.ZodType = z export const marshalLocationMappingSchema: z.ZodType = z .object({ - name: z.string().optional(), - uriByRegion: z - .array(z.lazy(() => marshalLocationMappingEntrySchema)) - .optional(), + name: z.string(), + uriByRegion: z.array(z.lazy(() => marshalLocationMappingEntrySchema)), }) .transform(d => ({ name: d.name, @@ -572,8 +566,8 @@ export const marshalLocationMappingSchema: z.ZodType = z export const marshalLocationMappingEntrySchema: z.ZodType = z .object({ - region: z.string().optional(), - uri: z.string().optional(), + region: z.string(), + uri: z.string(), }) .transform(d => ({ region: d.region, @@ -584,7 +578,7 @@ export const marshalStableUrlSchema: z.ZodType = z .object({ name: z.string().optional(), url: z.string().optional(), - initialWorkspaceId: z.string().optional(), + initialWorkspaceId: z.string(), failoverGroupName: z.string().optional(), effectiveWorkspaceId: z.string().optional(), stableWorkspaceId: z.string().optional(), @@ -600,7 +594,7 @@ export const marshalStableUrlSchema: z.ZodType = z export const marshalUcCatalogSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -611,8 +605,8 @@ export const marshalUcReplicationConfigSchema: z.ZodType = z locationMappings: z .array(z.lazy(() => marshalLocationMappingSchema)) .optional(), - catalogs: z.array(z.lazy(() => marshalUcCatalogSchema)).optional(), - dataReplicationWorkspaceSet: z.string().optional(), + catalogs: z.array(z.lazy(() => marshalUcCatalogSchema)), + dataReplicationWorkspaceSet: z.string(), }) .transform(d => ({ location_mappings: d.locationMappings, @@ -622,8 +616,8 @@ export const marshalUcReplicationConfigSchema: z.ZodType = z export const marshalWorkspaceSetSchema: z.ZodType = z .object({ - name: z.string().optional(), - workspaceIds: z.array(z.string()).optional(), + name: z.string(), + workspaceIds: z.array(z.string()), replicateWorkspaceAssets: z.boolean().optional(), stableUrlNames: z.array(z.string()).optional(), }) diff --git a/packages/environments/src/v1/model.ts b/packages/environments/src/v1/model.ts index 0a9b14c62..3a80fce25 100644 --- a/packages/environments/src/v1/model.ts +++ b/packages/environments/src/v1/model.ts @@ -555,7 +555,7 @@ export interface ApiError { /** Request message for CreateWorkspaceBaseEnvironment. */ export interface CreateWorkspaceBaseEnvironmentRequest { /** Required. The workspace base environment to create. */ - workspaceBaseEnvironment?: WorkspaceBaseEnvironment | undefined; + workspaceBaseEnvironment: WorkspaceBaseEnvironment; /** * The ID to use for the workspace base environment, which will become the final component of * the resource name. @@ -598,7 +598,7 @@ export interface DeleteWorkspaceBaseEnvironmentRequest { * Required. The resource name of the workspace base environment to delete. * Format: workspace-base-environments/{workspace_base_environment} */ - name?: string | undefined; + name: string; } /** @@ -626,7 +626,7 @@ export interface GetDefaultWorkspaceBaseEnvironmentRequest { * A static resource name of the default workspace base environment. * Format: default-workspace-base-environment */ - name?: string | undefined; + name: string; } /** The request message for `GetOperation` method. */ @@ -641,7 +641,7 @@ export interface GetWorkspaceBaseEnvironmentRequest { * Required. The resource name of the workspace base environment to retrieve. * Format: workspace-base-environments/{workspace_base_environment} */ - name?: string | undefined; + name: string; } /** Request message for ListWorkspaceBaseEnvironments. */ @@ -715,13 +715,13 @@ export interface RefreshWorkspaceBaseEnvironmentRequest { * Required. The resource name of the workspace base environment to delete. * Format: workspace-base-environments/{workspace_base_environment} */ - name?: string | undefined; + name: string; } /** Request message for UpdateDefaultWorkspaceBaseEnvironment. */ export interface UpdateDefaultWorkspaceBaseEnvironmentRequest { /** Required. The default workspace base environment configuration to update. */ - defaultWorkspaceBaseEnvironment?: DefaultWorkspaceBaseEnvironment | undefined; + defaultWorkspaceBaseEnvironment: DefaultWorkspaceBaseEnvironment; /** * Field mask specifying which fields to update. Use comma as the separator for multiple fields (no space). * The special value '*' indicates that all fields should be updated (full replacement). @@ -730,17 +730,17 @@ export interface UpdateDefaultWorkspaceBaseEnvironmentRequest { * To unset one or both defaults, include the field path(s) in the mask and omit them from the request body. * To unset both, you must list both paths explicitly — the wildcard '*' cannot be used to unset fields. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } /** Request message for UpdateWorkspaceBaseEnvironment. */ export interface UpdateWorkspaceBaseEnvironmentRequest { - name?: string | undefined; + name: string; /** * Required. The workspace base environment with updated fields. * The name field is used to identify the environment to update. */ - workspaceBaseEnvironment?: WorkspaceBaseEnvironment | undefined; + workspaceBaseEnvironment: WorkspaceBaseEnvironment; } /** @@ -754,7 +754,7 @@ export interface WorkspaceBaseEnvironment { */ name?: string | undefined; /** Human-readable display name for the workspace base environment. */ - displayName?: string | undefined; + displayName: string; /** The WSFS or UC Volumes path to the environment YAML file. */ filepath?: string | undefined; /** User ID of the creator. */ @@ -862,7 +862,7 @@ export const unmarshalWorkspaceBaseEnvironmentSchema: z.ZodType ({ name: d.name, @@ -931,7 +931,7 @@ export const marshalRefreshWorkspaceBaseEnvironmentRequestSchema: z.ZodType = z export const marshalWorkspaceBaseEnvironmentSchema: z.ZodType = z .object({ name: z.string().optional(), - displayName: z.string().optional(), + displayName: z.string(), filepath: z.string().optional(), creatorUserId: z.string().optional(), createTime: z diff --git a/packages/experiments/src/v1/model.ts b/packages/experiments/src/v1/model.ts index a95faab2b..20cbbe978 100644 --- a/packages/experiments/src/v1/model.ts +++ b/packages/experiments/src/v1/model.ts @@ -58,7 +58,7 @@ export type ViewType = (typeof ViewType)[keyof typeof ViewType] | (string & {}); export interface CreateExperimentRequest { /** Experiment name. */ - name?: string | undefined; + name: string; /** * Location where all artifacts for the experiment are stored. * If not provided, the remote server will select an appropriate default. @@ -87,7 +87,7 @@ export interface CreateExperimentResponse { export interface CreateLoggedModelRequest { /** The ID of the experiment that owns the model. */ - experimentId?: string | undefined; + experimentId: string; /** The name of the model (optional). If not specified one will be generated. */ name?: string | undefined; /** The type of the model, such as ``"Agent"``, ``"Classifier"``, ``"LLM"``. */ @@ -133,16 +133,16 @@ export interface CreateRunResponse { */ export interface Dataset { /** The name of the dataset. E.g. “my.uc.table@2” “nyc-taxi-dataset”, “fantastic-elk-3” */ - name?: string | undefined; + name: string; /** Dataset digest, e.g. an md5 hash of the dataset that uniquely identifies it within datasets of the same name. */ - digest?: string | undefined; + digest: string; /** The type of the dataset source, e.g. ‘databricks-uc-table’, ‘DBFS’, ‘S3’, ... */ - sourceType?: string | undefined; + sourceType: string; /** * Source information for the dataset. Note that the source may not exactly reproduce the * dataset if it was transformed / modified before use with MLflow. */ - source?: string | undefined; + source: string; /** * The schema of the dataset. E.g., MLflow ColSpec JSON for a dataframe, MLflow TensorSpec JSON * for an ndarray, or another schema format. @@ -161,12 +161,12 @@ export interface DatasetInput { /** A list of tags for the dataset input, e.g. a “context” tag with value “training” */ tags?: InputTag[] | undefined; /** The dataset being used as a Run input. */ - dataset?: Dataset | undefined; + dataset: Dataset; } export interface DeleteExperimentRequest { /** ID of the associated experiment. */ - experimentId?: string | undefined; + experimentId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -174,7 +174,7 @@ export interface DeleteExperimentResponse {} export interface DeleteLoggedModelRequest { /** The ID of the logged model to delete. */ - modelId?: string | undefined; + modelId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -182,9 +182,9 @@ export interface DeleteLoggedModelResponse {} export interface DeleteLoggedModelTagRequest { /** The ID of the logged model to delete the tag from. */ - modelId?: string | undefined; + modelId: string; /** The tag key. */ - tagKey?: string | undefined; + tagKey: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -192,7 +192,7 @@ export interface DeleteLoggedModelTagResponse {} export interface DeleteRunRequest { /** ID of the run to delete. */ - runId?: string | undefined; + runId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -200,12 +200,12 @@ export interface DeleteRunResponse {} export interface DeleteRunsRequest { /** The ID of the experiment containing the runs to delete. */ - experimentId?: string | undefined; + experimentId: string; /** * The maximum creation timestamp in milliseconds since the UNIX epoch for deleting runs. Only runs created prior to * or at this timestamp are deleted. */ - maxTimestampMillis?: bigint | undefined; + maxTimestampMillis: bigint; /** * An optional positive integer indicating the maximum number of runs to delete. The maximum allowed value for * max_runs is 10000. @@ -220,9 +220,9 @@ export interface DeleteRunsResponse { export interface DeleteTagRequest { /** ID of the run that the tag was logged under. Must be provided. */ - runId?: string | undefined; + runId: string; /** Name of the tag. Maximum size is 255 bytes. Must be provided. */ - key?: string | undefined; + key: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -289,12 +289,12 @@ export interface FileInfo { export interface FinalizeLoggedModelRequest { /** The ID of the logged model to finalize. */ - modelId?: string | undefined; + modelId: string; /** * Whether or not the model is ready for use. ``"LOGGED_MODEL_UPLOAD_FAILED"`` indicates that something went wrong * when logging the model weights / agent code. */ - status?: LoggedModelStatus | undefined; + status: LoggedModelStatus; } export interface FinalizeLoggedModelResponse { @@ -304,7 +304,7 @@ export interface FinalizeLoggedModelResponse { export interface GetExperimentByNameRequest { /** Name of the associated experiment. */ - experimentName?: string | undefined; + experimentName: string; } export interface GetExperimentByNameResponse { @@ -314,7 +314,7 @@ export interface GetExperimentByNameResponse { export interface GetExperimentRequest { /** ID of the associated experiment. */ - experimentId?: string | undefined; + experimentId: string; } export interface GetExperimentResponse { @@ -332,7 +332,7 @@ export interface GetExperimentResponse { export interface GetLoggedModelRequest { /** The ID of the logged model to retrieve. */ - modelId?: string | undefined; + modelId: string; } export interface GetLoggedModelResponse { @@ -355,7 +355,7 @@ export interface GetMetricHistoryResponse { export interface GetRunRequest { /** ID of the run to fetch. Must be provided. */ - runId?: string | undefined; + runId: string; /** * [Deprecated, use `run_id` instead] ID of the run to fetch. This field will * be removed in a future MLflow version. @@ -371,9 +371,9 @@ export interface GetRunResponse { /** Tag for a dataset input. */ export interface InputTag { /** The tag key. */ - key?: string | undefined; + key: string; /** The tag value. */ - value?: string | undefined; + value: string; } export interface ListArtifactsRequest { @@ -441,7 +441,7 @@ export interface ListMetricHistoryRequest { */ runUuid?: string | undefined; /** Name of the metric. */ - metricKey?: string | undefined; + metricKey: string; /** Token indicating the page of metric histories to fetch. */ pageToken?: string | undefined; /** @@ -476,7 +476,7 @@ export interface LogBatchResponse {} export interface LogInputsRequest { /** ID of the run to log under */ - runId?: string | undefined; + runId: string; /** Dataset inputs */ datasets?: DatasetInput[] | undefined; /** Model inputs */ @@ -488,7 +488,7 @@ export interface LogInputsResponse {} export interface LogLoggedModelParamsRequest { /** The ID of the logged model to log params for. */ - modelId?: string | undefined; + modelId: string; /** Parameters to attach to the model. */ params?: LoggedModelParameter[] | undefined; } @@ -505,11 +505,11 @@ export interface LogMetricRequest { */ runUuid?: string | undefined; /** Name of the metric. */ - key?: string | undefined; + key: string; /** Double value of the metric being logged. */ - value?: number | undefined; + value: number; /** Unix timestamp in milliseconds at the time metric was logged. */ - timestamp?: bigint | undefined; + timestamp: bigint; /** Step at which to log the metric */ step?: bigint | undefined; /** ID of the logged model associated with the metric, if applicable */ @@ -542,7 +542,7 @@ export interface LogModelResponse {} export interface LogOutputsRequest { /** The ID of the Run from which to log outputs. */ - runId?: string | undefined; + runId: string; /** The model outputs from the Run. */ models?: ModelOutput[] | undefined; } @@ -559,9 +559,9 @@ export interface LogParamRequest { */ runUuid?: string | undefined; /** Name of the param. Maximum size is 255 bytes. */ - key?: string | undefined; + key: string; /** String value of the param being logged. Maximum size is 500 bytes. */ - value?: string | undefined; + value: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -666,15 +666,15 @@ export interface Metric { /** Represents a LoggedModel or Registered Model Version input to a Run. */ export interface ModelInput { /** The unique identifier of the model. */ - modelId?: string | undefined; + modelId: string; } /** Represents a LoggedModel output of a Run. */ export interface ModelOutput { /** The unique identifier of the model. */ - modelId?: string | undefined; + modelId: string; /** The step at which the model was produced. */ - step?: bigint | undefined; + step: bigint; } /** Param associated with a run. */ @@ -687,7 +687,7 @@ export interface Param { export interface RestoreExperimentRequest { /** ID of the associated experiment. */ - experimentId?: string | undefined; + experimentId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -695,7 +695,7 @@ export interface RestoreExperimentResponse {} export interface RestoreRunRequest { /** ID of the run to restore. */ - runId?: string | undefined; + runId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -703,12 +703,12 @@ export interface RestoreRunResponse {} export interface RestoreRunsRequest { /** The ID of the experiment containing the runs to restore. */ - experimentId?: string | undefined; + experimentId: string; /** * The minimum deletion timestamp in milliseconds since the UNIX epoch for restoring runs. Only runs deleted no * earlier than this timestamp are restored. */ - minTimestampMillis?: bigint | undefined; + minTimestampMillis: bigint; /** * An optional positive integer indicating the maximum number of runs to restore. The maximum allowed value for * max_runs is 10000. @@ -852,7 +852,7 @@ export interface SearchLoggedModelsRequest { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface SearchLoggedModelsRequest_Dataset { /** The name of the dataset. */ - datasetName?: string | undefined; + datasetName: string; /** The digest of the dataset. */ datasetDigest?: string | undefined; } @@ -860,7 +860,7 @@ export interface SearchLoggedModelsRequest_Dataset { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface SearchLoggedModelsRequest_OrderBy { /** The name of the field to order by, e.g. "metrics.accuracy". */ - fieldName?: string | undefined; + fieldName: string; /** Whether the search results order is ascending or not. */ ascending?: boolean | undefined; /** @@ -929,11 +929,11 @@ export interface SearchRunsResponse { export interface SetExperimentTagRequest { /** ID of the experiment under which to log the tag. Must be provided. */ - experimentId?: string | undefined; + experimentId: string; /** Name of the tag. Keys up to 250 bytes in size are supported. */ - key?: string | undefined; + key: string; /** String value of the tag being logged. Values up to 64KB in size are supported. */ - value?: string | undefined; + value: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -941,7 +941,7 @@ export interface SetExperimentTagResponse {} export interface SetLoggedModelTagsRequest { /** The ID of the logged model to set the tags on. */ - modelId?: string | undefined; + modelId: string; /** The tags to set on the logged model. */ tags?: LoggedModelTag[] | undefined; } @@ -958,9 +958,9 @@ export interface SetTagRequest { */ runUuid?: string | undefined; /** Name of the tag. Keys up to 250 bytes in size are supported. */ - key?: string | undefined; + key: string; /** String value of the tag being logged. Values up to 64KB in size are supported. */ - value?: string | undefined; + value: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -972,9 +972,9 @@ export interface SetTagResponse {} */ export interface UcTraceLocation { /** The name of the Unity Catalog catalog. */ - catalog?: string | undefined; + catalog: string; /** The name of the Unity Catalog schema within `catalog`. */ - schema?: string | undefined; + schema: string; /** * The prefix for the trace tables, which are named * `{catalog}.{schema}.{table_prefix}_otel_*`. May only contain letters, @@ -993,7 +993,7 @@ export interface UcTraceLocation { export interface UpdateExperimentRequest { /** ID of the associated experiment. */ - experimentId?: string | undefined; + experimentId: string; /** If provided, the experiment's name is changed to the new name. The new name must be unique. */ newName?: string | undefined; } @@ -1050,10 +1050,10 @@ export const unmarshalCreateRunResponseSchema: z.ZodType = z export const unmarshalDatasetSchema: z.ZodType = z .object({ - name: z.string().optional(), - digest: z.string().optional(), - source_type: z.string().optional(), - source: z.string().optional(), + name: z.string(), + digest: z.string(), + source_type: z.string(), + source: z.string(), schema: z.string().optional(), profile: z.string().optional(), }) @@ -1069,7 +1069,7 @@ export const unmarshalDatasetSchema: z.ZodType = z export const unmarshalDatasetInputSchema: z.ZodType = z .object({ tags: z.array(z.lazy(() => unmarshalInputTagSchema)).optional(), - dataset: z.lazy(() => unmarshalDatasetSchema).optional(), + dataset: z.lazy(() => unmarshalDatasetSchema), }) .transform(d => ({ tags: d.tags, @@ -1231,8 +1231,8 @@ export const unmarshalGetRunResponseSchema: z.ZodType = z export const unmarshalInputTagSchema: z.ZodType = z .object({ - key: z.string().optional(), - value: z.string().optional(), + key: z.string(), + value: z.string(), }) .transform(d => ({ key: d.key, @@ -1396,7 +1396,7 @@ export const unmarshalMetricSchema: z.ZodType = z export const unmarshalModelInputSchema: z.ZodType = z .object({ - model_id: z.string().optional(), + model_id: z.string(), }) .transform(d => ({ modelId: d.model_id, @@ -1549,8 +1549,8 @@ export const unmarshalSetTagResponseSchema: z.ZodType = export const unmarshalUcTraceLocationSchema: z.ZodType = z .object({ - catalog: z.string().optional(), - schema: z.string().optional(), + catalog: z.string(), + schema: z.string(), table_prefix: z.string().optional(), effective_table_prefix: z.string().optional(), }) @@ -1574,7 +1574,7 @@ export const unmarshalUpdateRunResponseSchema: z.ZodType = z export const marshalCreateExperimentRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), artifactLocation: z.string().optional(), tags: z.array(z.lazy(() => marshalExperimentTagSchema)).optional(), traceLocation: z @@ -1590,7 +1590,7 @@ export const marshalCreateExperimentRequestSchema: z.ZodType = z export const marshalCreateLoggedModelRequestSchema: z.ZodType = z .object({ - experimentId: z.string().optional(), + experimentId: z.string(), name: z.string().optional(), modelType: z.string().optional(), sourceRunId: z.string().optional(), @@ -1624,10 +1624,10 @@ export const marshalCreateRunRequestSchema: z.ZodType = z export const marshalDatasetSchema: z.ZodType = z .object({ - name: z.string().optional(), - digest: z.string().optional(), - sourceType: z.string().optional(), - source: z.string().optional(), + name: z.string(), + digest: z.string(), + sourceType: z.string(), + source: z.string(), schema: z.string().optional(), profile: z.string().optional(), }) @@ -1643,7 +1643,7 @@ export const marshalDatasetSchema: z.ZodType = z export const marshalDatasetInputSchema: z.ZodType = z .object({ tags: z.array(z.lazy(() => marshalInputTagSchema)).optional(), - dataset: z.lazy(() => marshalDatasetSchema).optional(), + dataset: z.lazy(() => marshalDatasetSchema), }) .transform(d => ({ tags: d.tags, @@ -1652,7 +1652,7 @@ export const marshalDatasetInputSchema: z.ZodType = z export const marshalDeleteExperimentRequestSchema: z.ZodType = z .object({ - experimentId: z.string().optional(), + experimentId: z.string(), }) .transform(d => ({ experiment_id: d.experimentId, @@ -1660,7 +1660,7 @@ export const marshalDeleteExperimentRequestSchema: z.ZodType = z export const marshalDeleteRunRequestSchema: z.ZodType = z .object({ - runId: z.string().optional(), + runId: z.string(), }) .transform(d => ({ run_id: d.runId, @@ -1668,8 +1668,8 @@ export const marshalDeleteRunRequestSchema: z.ZodType = z export const marshalDeleteRunsRequestSchema: z.ZodType = z .object({ - experimentId: z.string().optional(), - maxTimestampMillis: z.bigint().optional(), + experimentId: z.string(), + maxTimestampMillis: z.bigint(), maxRuns: z.number().optional(), }) .transform(d => ({ @@ -1680,8 +1680,8 @@ export const marshalDeleteRunsRequestSchema: z.ZodType = z export const marshalDeleteTagRequestSchema: z.ZodType = z .object({ - runId: z.string().optional(), - key: z.string().optional(), + runId: z.string(), + key: z.string(), }) .transform(d => ({ run_id: d.runId, @@ -1717,8 +1717,8 @@ export const marshalExperimentTraceLocationSchema: z.ZodType = z export const marshalFinalizeLoggedModelRequestSchema: z.ZodType = z .object({ - modelId: z.string().optional(), - status: z.string().optional(), + modelId: z.string(), + status: z.string(), }) .transform(d => ({ model_id: d.modelId, @@ -1727,8 +1727,8 @@ export const marshalFinalizeLoggedModelRequestSchema: z.ZodType = z export const marshalInputTagSchema: z.ZodType = z .object({ - key: z.string().optional(), - value: z.string().optional(), + key: z.string(), + value: z.string(), }) .transform(d => ({ key: d.key, @@ -1751,7 +1751,7 @@ export const marshalLogBatchRequestSchema: z.ZodType = z export const marshalLogInputsRequestSchema: z.ZodType = z .object({ - runId: z.string().optional(), + runId: z.string(), datasets: z.array(z.lazy(() => marshalDatasetInputSchema)).optional(), models: z.array(z.lazy(() => marshalModelInputSchema)).optional(), }) @@ -1763,7 +1763,7 @@ export const marshalLogInputsRequestSchema: z.ZodType = z export const marshalLogLoggedModelParamsRequestSchema: z.ZodType = z .object({ - modelId: z.string().optional(), + modelId: z.string(), params: z.array(z.lazy(() => marshalLoggedModelParameterSchema)).optional(), }) .transform(d => ({ @@ -1775,9 +1775,9 @@ export const marshalLogMetricRequestSchema: z.ZodType = z .object({ runId: z.string().optional(), runUuid: z.string().optional(), - key: z.string().optional(), - value: z.number().optional(), - timestamp: z.bigint().optional(), + key: z.string(), + value: z.number(), + timestamp: z.bigint(), step: z.bigint().optional(), modelId: z.string().optional(), datasetName: z.string().optional(), @@ -1807,7 +1807,7 @@ export const marshalLogModelRequestSchema: z.ZodType = z export const marshalLogOutputsRequestSchema: z.ZodType = z .object({ - runId: z.string().optional(), + runId: z.string(), models: z.array(z.lazy(() => marshalModelOutputSchema)).optional(), }) .transform(d => ({ @@ -1819,8 +1819,8 @@ export const marshalLogParamRequestSchema: z.ZodType = z .object({ runId: z.string().optional(), runUuid: z.string().optional(), - key: z.string().optional(), - value: z.string().optional(), + key: z.string(), + value: z.string(), }) .transform(d => ({ run_id: d.runId, @@ -1873,7 +1873,7 @@ export const marshalMetricSchema: z.ZodType = z export const marshalModelInputSchema: z.ZodType = z .object({ - modelId: z.string().optional(), + modelId: z.string(), }) .transform(d => ({ model_id: d.modelId, @@ -1881,8 +1881,8 @@ export const marshalModelInputSchema: z.ZodType = z export const marshalModelOutputSchema: z.ZodType = z .object({ - modelId: z.string().optional(), - step: z.bigint().optional(), + modelId: z.string(), + step: z.bigint(), }) .transform(d => ({ model_id: d.modelId, @@ -1901,7 +1901,7 @@ export const marshalParamSchema: z.ZodType = z export const marshalRestoreExperimentRequestSchema: z.ZodType = z .object({ - experimentId: z.string().optional(), + experimentId: z.string(), }) .transform(d => ({ experiment_id: d.experimentId, @@ -1909,7 +1909,7 @@ export const marshalRestoreExperimentRequestSchema: z.ZodType = z export const marshalRestoreRunRequestSchema: z.ZodType = z .object({ - runId: z.string().optional(), + runId: z.string(), }) .transform(d => ({ run_id: d.runId, @@ -1917,8 +1917,8 @@ export const marshalRestoreRunRequestSchema: z.ZodType = z export const marshalRestoreRunsRequestSchema: z.ZodType = z .object({ - experimentId: z.string().optional(), - minTimestampMillis: z.bigint().optional(), + experimentId: z.string(), + minTimestampMillis: z.bigint(), maxRuns: z.number().optional(), }) .transform(d => ({ @@ -1978,7 +1978,7 @@ export const marshalSearchLoggedModelsRequestSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalSearchLoggedModelsRequest_DatasetSchema: z.ZodType = z .object({ - datasetName: z.string().optional(), + datasetName: z.string(), datasetDigest: z.string().optional(), }) .transform(d => ({ @@ -1989,7 +1989,7 @@ export const marshalSearchLoggedModelsRequest_DatasetSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalSearchLoggedModelsRequest_OrderBySchema: z.ZodType = z .object({ - fieldName: z.string().optional(), + fieldName: z.string(), ascending: z.boolean().optional(), datasetName: z.string().optional(), datasetDigest: z.string().optional(), @@ -2021,9 +2021,9 @@ export const marshalSearchRunsRequestSchema: z.ZodType = z export const marshalSetExperimentTagRequestSchema: z.ZodType = z .object({ - experimentId: z.string().optional(), - key: z.string().optional(), - value: z.string().optional(), + experimentId: z.string(), + key: z.string(), + value: z.string(), }) .transform(d => ({ experiment_id: d.experimentId, @@ -2033,7 +2033,7 @@ export const marshalSetExperimentTagRequestSchema: z.ZodType = z export const marshalSetLoggedModelTagsRequestSchema: z.ZodType = z .object({ - modelId: z.string().optional(), + modelId: z.string(), tags: z.array(z.lazy(() => marshalLoggedModelTagSchema)).optional(), }) .transform(d => ({ @@ -2045,8 +2045,8 @@ export const marshalSetTagRequestSchema: z.ZodType = z .object({ runId: z.string().optional(), runUuid: z.string().optional(), - key: z.string().optional(), - value: z.string().optional(), + key: z.string(), + value: z.string(), }) .transform(d => ({ run_id: d.runId, @@ -2057,8 +2057,8 @@ export const marshalSetTagRequestSchema: z.ZodType = z export const marshalUcTraceLocationSchema: z.ZodType = z .object({ - catalog: z.string().optional(), - schema: z.string().optional(), + catalog: z.string(), + schema: z.string(), tablePrefix: z.string().optional(), effectiveTablePrefix: z.string().optional(), }) @@ -2071,7 +2071,7 @@ export const marshalUcTraceLocationSchema: z.ZodType = z export const marshalUpdateExperimentRequestSchema: z.ZodType = z .object({ - experimentId: z.string().optional(), + experimentId: z.string(), newName: z.string().optional(), }) .transform(d => ({ diff --git a/packages/features/src/v1/model.ts b/packages/features/src/v1/model.ts index 9d057acd4..0d3a63355 100644 --- a/packages/features/src/v1/model.ts +++ b/packages/features/src/v1/model.ts @@ -114,7 +114,7 @@ export interface AggregationFunction { /** Computes the approximate count of distinct values. */ export interface ApproxCountDistinctFunction { /** The input column from which the approximate count of distinct values is computed. */ - input?: string | undefined; + input: string; /** The maximum relative standard deviation allowed (default defined by Spark). */ relativeSd?: number | undefined; } @@ -122,9 +122,9 @@ export interface ApproxCountDistinctFunction { /** Computes the approximate percentile of values. */ export interface ApproxPercentileFunction { /** The input column from which the approximate percentile is computed. */ - input?: string | undefined; + input: string; /** The percentile value to compute (between 0 and 1). */ - percentile?: number | undefined; + percentile: number; /** The accuracy parameter (higher is more accurate but slower). */ accuracy?: bigint | undefined; } @@ -152,7 +152,7 @@ export interface AvgFunction { * Colon-prefixed notation (e.g., "value:amount") is supported for backwards * compatibility but is deprecated; migrate to dot notation. */ - input?: string | undefined; + input: string; } export interface BackfillSource { @@ -176,7 +176,7 @@ export interface BackfillSource { export interface BatchCreateMaterializedFeaturesRequest { /** The requests to create materialized features. */ - requests?: CreateMaterializedFeatureRequest[] | undefined; + requests: CreateMaterializedFeatureRequest[]; } export interface BatchCreateMaterializedFeaturesResponse { @@ -187,7 +187,7 @@ export interface BatchCreateMaterializedFeaturesResponse { /** A ColumnSelection function, equivalent to the LAST() record of an entity over a lifetime window */ export interface ColumnSelection { /** Column name from source to select as the feature value. */ - column?: string | undefined; + column: string; } /** Computes the count of values. */ @@ -198,27 +198,27 @@ export interface CountFunction { * Colon-prefixed notation (e.g., "value:amount") is supported for backwards * compatibility but is deprecated; migrate to dot notation. */ - input?: string | undefined; + input: string; } export interface CreateFeatureRequest { /** Feature to create. */ - feature?: Feature | undefined; + feature: Feature; } export interface CreateKafkaConfigRequest { - kafkaConfig?: KafkaConfig | undefined; + kafkaConfig: KafkaConfig; } export interface CreateMaterializedFeatureRequest { /** The materialized feature to create. */ - materializedFeature?: MaterializedFeature | undefined; + materializedFeature: MaterializedFeature; } /** Create a Stream, a governed UC entity representing an external streaming data source. */ export interface CreateStreamRequest { /** The Stream to create. */ - stream?: Stream | undefined; + stream: Stream; } /** A cron-based schedule trigger for the materialization pipeline. */ @@ -233,7 +233,7 @@ export interface CronSchedule { */ export interface CustomUdf { /** Fully qualified 3-part Unity Catalog path of the function to apply. */ - functionPath?: string | undefined; + functionPath: string; /** * Binds each UC function parameter to a source column. * May be empty for zero-argument functions (e.g. a timestamp generator). @@ -274,28 +274,28 @@ export interface DataSource { export interface DeleteFeatureRequest { /** Name of the feature to delete. */ - fullName?: string | undefined; + fullName: string; } export interface DeleteKafkaConfigRequest { /** Name of the Kafka config to delete. */ - name?: string | undefined; + name: string; } export interface DeleteMaterializedFeatureRequest { /** The ID of the materialized feature to delete. */ - materializedFeatureId?: string | undefined; + materializedFeatureId: string; } /** Delete a Stream by its full three-part name (catalog.schema.stream). */ export interface DeleteStreamRequest { /** Full three-part name (catalog.schema.stream) of the Stream to delete. */ - name?: string | undefined; + name: string; } export interface DeltaTableSource { /** The full three-part (catalog, schema, table) name of the Delta table. */ - fullName?: string | undefined; + fullName: string; /** Single WHERE clause to filter delta table before applying transformations. Will be row-wise evaluated, so should only include conditionals and projections. */ filterCondition?: string | undefined; /** @@ -318,9 +318,9 @@ export interface DeltaTableSource { */ export interface DirectMtlsConfig { /** A comma-separated list of host:port pairs for the Kafka bootstrap servers. */ - bootstrapServers?: string | undefined; + bootstrapServers: string; /** Mutual-TLS authentication configuration. */ - mtlsConfig?: MtlsConfig | undefined; + mtlsConfig: MtlsConfig; } /** @@ -349,7 +349,7 @@ export interface EntityColumn { * Colon-prefixed notation (e.g., "value:user_id") is supported for backwards * compatibility but is deprecated; migrate to dot notation. */ - name?: string | undefined; + name: string; } export interface Feature { @@ -358,11 +358,11 @@ export interface Feature { * feature's resource identifier; the catalog_name, schema_name, and name fields * below are OUTPUT_ONLY decomposed views of this value. */ - fullName?: string | undefined; + fullName: string; /** The data source of the feature. */ - source?: DataSource | undefined; + source: DataSource; /** The function by which the feature is computed. */ - function?: Function | undefined; + function: Function; /** The description of the feature. */ description?: string | undefined; /** @@ -395,31 +395,31 @@ export interface Feature { */ export interface FieldDefinition { /** The name of the field. */ - name?: string | undefined; + name: string; /** The scalar data type of the field. */ - dataType?: ScalarDataType | undefined; + dataType: ScalarDataType; } /** Returns the first N distinct values, ordered by the feature's timeseries column. */ export interface FirstDistinctFunction { /** The input column from which the first N distinct values are returned. */ - input?: string | undefined; + input: string; /** The number of distinct values to return. */ - n?: bigint | undefined; + n: bigint; } /** Returns the first value. */ export interface FirstFunction { /** The input column from which the first value is returned. */ - input?: string | undefined; + input: string; } /** Returns the first N values, ordered by the feature's timeseries column. */ export interface FirstNFunction { /** The input column from which the first N values are returned. */ - input?: string | undefined; + input: string; /** The number of values to return. */ - n?: bigint | undefined; + n: bigint; } /** @@ -428,7 +428,7 @@ export interface FirstNFunction { */ export interface FlatSchema { /** The list of fields in this schema. */ - fields?: FieldDefinition[] | undefined; + fields: FieldDefinition[]; } export interface Function { @@ -453,23 +453,23 @@ export interface Function { export interface GetFeatureRequest { /** Name of the feature to get. */ - fullName?: string | undefined; + fullName: string; } export interface GetKafkaConfigRequest { /** Name of the Kafka config to get. */ - name?: string | undefined; + name: string; } export interface GetMaterializedFeatureRequest { /** The ID of the materialized feature. */ - materializedFeatureId?: string | undefined; + materializedFeatureId: string; } /** Get a Stream by its full three-part name (catalog.schema.stream). */ export interface GetStreamRequest { /** Full three-part name (catalog.schema.stream) of the Stream to get. */ - name?: string | undefined; + name: string; } /** @@ -482,7 +482,7 @@ export interface IngestionConfig { * This table contains both 1) forward-filled data from the Stream and 2) backfilled data from the BackfillSource (if provided). * This table is created and managed by and is deleted when the Stream is deleted. */ - ingestionDestination?: IngestionDestination | undefined; + ingestionDestination: IngestionDestination; /** * A user-provided source for backfilling data. Historical data is used when creating a training set from streaming features linked to this Stream. * The backfill data stored in this location will be copied into the ingestion table for offline querying and training. @@ -520,9 +520,9 @@ export interface IngestionDestination { /** Binds a single UC function parameter to a source column. */ export interface InputBinding { /** Name of the UC function parameter. */ - parameter?: string | undefined; + parameter: string; /** Source column whose value is passed for this parameter at execution time. */ - column?: string | undefined; + column: string; } export interface JobContext { @@ -537,13 +537,13 @@ export interface KafkaConfig { * Name that uniquely identifies this Kafka config within the metastore. This will be the identifier used from the Feature object to reference these configs for a feature. * Can be distinct from topic name. */ - name?: string | undefined; + name: string; /** A comma-separated list of host/port pairs pointing to Kafka cluster. */ - bootstrapServers?: string | undefined; + bootstrapServers: string; /** Options to configure which Kafka topics to pull data from. */ - subscriptionMode?: SubscriptionMode | undefined; + subscriptionMode: SubscriptionMode; /** Authentication configuration for connection to topics. */ - authConfig?: AuthConfig | undefined; + authConfig: AuthConfig; /** Schema configuration for extracting message keys from topics. At least one of key_schema and value_schema must be provided. */ keySchema?: SchemaConfig | undefined; /** Schema configuration for extracting message values from topics. At least one of key_schema and value_schema must be provided. */ @@ -565,7 +565,7 @@ export interface KafkaConfig { export interface KafkaSource { /** Name of the Kafka source, used to identify it. This is used to look up the corresponding KafkaConfig object. Can be distinct from topic name. */ - name?: string | undefined; + name: string; /** The filter condition applied to the source data before aggregation. */ filterCondition?: string | undefined; } @@ -573,7 +573,7 @@ export interface KafkaSource { /** Kafka-specific configuration for a Stream. */ export interface KafkaStreamConfig { /** Options to configure which Kafka topics to pull data from. */ - subscriptionMode?: KafkaSubscriptionMode | undefined; + subscriptionMode: KafkaSubscriptionMode; /** * Optional Kafka source or consumer options, validated against a server-side * allowlist at request time. Allowed keys: @@ -649,23 +649,23 @@ export interface KinesisStreamConfig { /** Returns the last N distinct values, ordered by the feature's timeseries column. */ export interface LastDistinctFunction { /** The input column from which the last N distinct values are returned. */ - input?: string | undefined; + input: string; /** The number of distinct values to return. */ - n?: bigint | undefined; + n: bigint; } /** Returns the last value. */ export interface LastFunction { /** The input column from which the last value is returned. */ - input?: string | undefined; + input: string; } /** Returns the last N values, ordered by the feature's timeseries column. */ export interface LastNFunction { /** The input column from which the last N values are returned. */ - input?: string | undefined; + input: string; /** The number of values to return. */ - n?: bigint | undefined; + n: bigint; } /** Lineage context information for tracking where an API was invoked. This will allow us to track lineage, which currently uses caller entity information for use across the Lineage Client and Observability in Lumberjack. */ @@ -686,9 +686,9 @@ export interface ListFeaturesRequest { /** The maximum number of results to return. */ pageSize?: number | undefined; /** Name of parent catalog for features of interest. */ - catalogName?: string | undefined; + catalogName: string; /** Name of parent schema relative to its parent catalog. */ - schemaName?: string | undefined; + schemaName: string; } export interface ListFeaturesResponse { @@ -707,7 +707,7 @@ export interface ListKafkaConfigsRequest { export interface ListKafkaConfigsResponse { /** List of Kafka configs. Schemas are not included in the response. */ - kafkaConfigs?: KafkaConfig[] | undefined; + kafkaConfigs: KafkaConfig[]; /** Pagination token to request the next page of results for this query. */ nextPageToken?: string | undefined; } @@ -771,7 +771,7 @@ export interface MaterializedFeature { /** Server-assigned unique identifier for the materialized feature. */ materializedFeatureId?: string | undefined; /** The full name of the feature in Unity Catalog. */ - featureName?: string | undefined; + featureName: string; destination?: | { $case: 'offlineStoreConfig'; @@ -825,13 +825,13 @@ export interface MaterializedFeature { /** Computes the maximum value. */ export interface MaxFunction { /** The input column from which the maximum is computed. */ - input?: string | undefined; + input: string; } /** Computes the minimum value. */ export interface MinFunction { /** The input column from which the minimum is computed. */ - input?: string | undefined; + input: string; } /** @@ -853,23 +853,23 @@ export interface MtlsConfig { * and private key. e.g. "/Volumes////client.jks". The * materialization compute must have read permission on this volume. */ - keystoreLocation?: string | undefined; + keystoreLocation: string; /** Secret-scope reference for the JKS keystore password. */ - keystorePasswordRef?: SecretScopeReference | undefined; + keystorePasswordRef: SecretScopeReference; /** * Secret-scope reference for the private key password. Often the same value as the * keystore password (keytool's default), but provided as a separate field because * Apache Kafka requires it as a distinct option (kafka.ssl.key.password). */ - keyPasswordRef?: SecretScopeReference | undefined; + keyPasswordRef: SecretScopeReference; /** * Unity Catalog volume path to the JKS truststore file containing the CA certificate(s) * trusted to verify the Kafka broker's server certificate. * e.g. "/Volumes////truststore.jks". */ - truststoreLocation?: string | undefined; + truststoreLocation: string; /** Secret-scope reference for the JKS truststore password. */ - truststorePasswordRef?: SecretScopeReference | undefined; + truststorePasswordRef: SecretScopeReference; /** * Set to true only when the broker certificate's SAN intentionally does not match * the connection endpoint — for example when reaching the cluster through a @@ -886,14 +886,14 @@ export interface MtlsConfig { /** Configuration for offline store destination. */ export interface OfflineStoreConfig { /** The Unity Catalog catalog name. */ - catalogName?: string | undefined; + catalogName: string; /** The Unity Catalog schema name. */ - schemaName?: string | undefined; + schemaName: string; /** * Prefix for Unity Catalog table name. * The materialized feature will be stored in a table with this prefix and a generated postfix. */ - tableNamePrefix?: string | undefined; + tableNamePrefix: string; } /** Configuration for online store destination. */ @@ -902,19 +902,19 @@ export interface OnlineStoreConfig { * The Unity Catalog catalog name. This name is also used as the Lakebase logical database name. * Quoting is handled by the backend where needed, do not pre-quote it. */ - catalogName?: string | undefined; + catalogName: string; /** * The Unity Catalog schema name. This name is also used as the Lakebase schema name under the database. * Quoting is handled by the backend where needed, do not pre-quote it. */ - schemaName?: string | undefined; + schemaName: string; /** * Prefix for Unity Catalog table name. * The materialized feature will be stored in a Lakebase table with this prefix and a generated postfix. */ - tableNamePrefix?: string | undefined; + tableNamePrefix: string; /** The name of the target online store. */ - onlineStoreName?: string | undefined; + onlineStoreName: string; } /** @@ -926,14 +926,14 @@ export interface ProtoSchemaSpec { * The raw .proto file text (proto2 and proto3 syntax supported, see * https://protobuf.dev/programming-guides/proto3/ and https://protobuf.dev/programming-guides/proto2/). */ - schemaText?: string | undefined; + schemaText: string; /** * The fully-qualified name of the message within schema_text that describes the Kafka payload * (e.g. "Event" or "com.example.Event" if schema_text declares a package). Identifies which * message is used to decode each Kafka record — a .proto file may declare multiple messages * but only one represents the payload. Must not be empty. */ - messageName?: string | undefined; + messageName: string; } /** A request-time data source whose value is provided at inference time: offline batch scoring or online serving endpoint */ @@ -1016,7 +1016,7 @@ export interface SchemaLocator { } | undefined; /** Serialization format for this schema. */ - format?: SchemaLocator_Format | undefined; + format: SchemaLocator_Format; } /** @@ -1033,7 +1033,7 @@ export interface SchemaLocator { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface SchemaLocator_ConfluentSchema { /** The Confluent schema registry subject name. */ - subject?: string | undefined; + subject: string; } /** Configuration for resolving a Stream's schema from an external schema registry (e.g. Confluent). */ @@ -1041,7 +1041,7 @@ export interface SchemaRegistryConfig { /** A Schema Registry UC Connection object. */ ucConnection?: string | undefined; /** Reference to the schema registry API secret in a secret scope. */ - apiSecretRef?: SecretScopeReference | undefined; + apiSecretRef: SecretScopeReference; /** * Schema locator for the message payload. For Kafka this is the value. * At least one of payload_schema_locator or key_schema_locator must be set. @@ -1060,9 +1060,9 @@ export interface SchemaRegistryConfig { */ export interface SecretScopeReference { /** The secret scope name. */ - scope?: string | undefined; + scope: string; /** The key within the scope. */ - key?: string | undefined; + key: string; } export interface SlidingWindow { @@ -1072,7 +1072,7 @@ export interface SlidingWindow { */ windowDuration?: Temporal.Duration | undefined; /** The slide duration (interval by which windows advance, must be positive and less than duration). */ - slideDuration?: Temporal.Duration | undefined; + slideDuration: Temporal.Duration; /** * Non-negative analytic lag that evaluates the window this far in the past. Use this for timing * variations unrelated to source lateness, such as a 30-day count as of one week ago. If unset, @@ -1107,13 +1107,13 @@ export interface StddevPopFunction { * Colon-prefixed notation (e.g., "value:amount") is supported for backwards * compatibility but is deprecated; migrate to dot notation. */ - input?: string | undefined; + input: string; } /** Computes the sample standard deviation. */ export interface StddevSampFunction { /** The input column from which the sample standard deviation is computed. */ - input?: string | undefined; + input: string; } /** @@ -1122,20 +1122,20 @@ export interface StddevSampFunction { */ export interface Stream { /** Full three-part (catalog.schema.stream) name of the stream. */ - name?: string | undefined; + name: string; /** User-provided description. */ description?: string | undefined; /** Source-specific configuration. Determines the streaming platform source. */ - sourceConfig?: StreamSourceConfig | undefined; + sourceConfig: StreamSourceConfig; /** Specifies how to connect and authenticate to the stream platform. */ - connectionConfig?: StreamConnectionConfig | undefined; + connectionConfig: StreamConnectionConfig; /** * Schema definitions for the stream, provided either directly on the Stream or * resolved from an external schema registry through a UC Connection. */ - schemaConfig?: StreamSchemaConfig | undefined; + schemaConfig: StreamSchemaConfig; /** Configuration for streaming data ingestion: the managed table storing an offline copy of forward fill data and optional historical backfill. */ - ingestionConfig?: IngestionConfig | undefined; + ingestionConfig: IngestionConfig; /** Time at which this Stream was created. */ createTime?: Temporal.Instant | undefined; /** Username of the Stream creator. */ @@ -1211,7 +1211,7 @@ export interface StreamSchemaConfig { /** A Stream entity used as a data source for a feature. */ export interface StreamSource { /** Three-part full name of the Stream (catalog.schema.stream). */ - fullName?: string | undefined; + fullName: string; /** The filter condition applied to the source data before aggregation. */ filterCondition?: string | undefined; /** @@ -1287,7 +1287,7 @@ export interface SumFunction { * Colon-prefixed notation (e.g., "value:amount") is supported for backwards * compatibility but is deprecated; migrate to dot notation. */ - input?: string | undefined; + input: string; } /** A trigger that fires when the upstream source table changes. */ @@ -1326,12 +1326,12 @@ export interface TimeseriesColumn { * Colon-prefixed notation (e.g., "value:event_timestamp") is supported for * backwards compatibility but is deprecated; migrate to dot notation. */ - name?: string | undefined; + name: string; } export interface TumblingWindow { /** The duration of each tumbling window (non-overlapping, fixed-duration windows). */ - windowDuration?: Temporal.Duration | undefined; + windowDuration: Temporal.Duration; /** * Non-negative analytic lag that evaluates the window this far in the past. Use this for timing * variations unrelated to source lateness, such as a 30-day count as of one week ago. If unset, @@ -1348,46 +1348,46 @@ export interface TumblingWindow { export interface UpdateFeatureRequest { /** Feature to update. */ - feature?: Feature | undefined; + feature: Feature; /** The list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateKafkaConfigRequest { /** The Kafka config to update. */ - kafkaConfig?: KafkaConfig | undefined; + kafkaConfig: KafkaConfig; /** The list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateMaterializedFeatureRequest { /** The materialized feature to update. */ - materializedFeature?: MaterializedFeature | undefined; + materializedFeature: MaterializedFeature; /** * Provide the materialization feature fields which should be updated. * Currently, only the pipeline_state field can be updated. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } /** Update a Stream. Only fields listed in `update_mask` are mutated. */ export interface UpdateStreamRequest { /** The Stream to update. */ - stream?: Stream | undefined; + stream: Stream; /** The list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } /** Computes the population variance. */ export interface VarPopFunction { /** The input column from which the population variance is computed. */ - input?: string | undefined; + input: string; } /** Computes the sample variance. */ export interface VarSampFunction { /** The input column from which the sample variance is computed. */ - input?: string | undefined; + input: string; } export const unmarshalAggregationFunctionSchema: z.ZodType = @@ -1490,7 +1490,7 @@ export const unmarshalAggregationFunctionSchema: z.ZodType export const unmarshalApproxCountDistinctFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), relative_sd: z.number().optional(), }) .transform(d => ({ @@ -1501,8 +1501,8 @@ export const unmarshalApproxCountDistinctFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), - percentile: z.number().optional(), + input: z.string(), + percentile: z.number(), accuracy: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) @@ -1533,7 +1533,7 @@ export const unmarshalAuthConfigSchema: z.ZodType = z export const unmarshalAvgFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -1574,7 +1574,7 @@ export const unmarshalBatchCreateMaterializedFeaturesResponseSchema: z.ZodType = z .object({ - column: z.string().optional(), + column: z.string(), }) .transform(d => ({ column: d.column, @@ -1582,7 +1582,7 @@ export const unmarshalColumnSelectionSchema: z.ZodType = z export const unmarshalCountFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -1598,7 +1598,7 @@ export const unmarshalCronScheduleSchema: z.ZodType = z export const unmarshalCustomUdfSchema: z.ZodType = z .object({ - function_path: z.string().optional(), + function_path: z.string(), input_bindings: z .array(z.lazy(() => unmarshalInputBindingSchema)) .optional(), @@ -1637,7 +1637,7 @@ export const unmarshalDataSourceSchema: z.ZodType = z export const unmarshalDeltaTableSourceSchema: z.ZodType = z .object({ - full_name: z.string().optional(), + full_name: z.string(), filter_condition: z.string().optional(), transformation_sql: z.string().optional(), dataframe_schema: z.string().optional(), @@ -1651,8 +1651,8 @@ export const unmarshalDeltaTableSourceSchema: z.ZodType = z export const unmarshalDirectMtlsConfigSchema: z.ZodType = z .object({ - bootstrap_servers: z.string().optional(), - mtls_config: z.lazy(() => unmarshalMtlsConfigSchema).optional(), + bootstrap_servers: z.string(), + mtls_config: z.lazy(() => unmarshalMtlsConfigSchema), }) .transform(d => ({ bootstrapServers: d.bootstrap_servers, @@ -1671,7 +1671,7 @@ export const unmarshalDirectSchemasSchema: z.ZodType = z export const unmarshalEntityColumnSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -1679,9 +1679,9 @@ export const unmarshalEntityColumnSchema: z.ZodType = z export const unmarshalFeatureSchema: z.ZodType = z .object({ - full_name: z.string().optional(), - source: z.lazy(() => unmarshalDataSourceSchema).optional(), - function: z.lazy(() => unmarshalFunctionSchema).optional(), + full_name: z.string(), + source: z.lazy(() => unmarshalDataSourceSchema), + function: z.lazy(() => unmarshalFunctionSchema), description: z.string().optional(), lineage_context: z.lazy(() => unmarshalLineageContextSchema).optional(), entities: z.array(z.lazy(() => unmarshalEntityColumnSchema)).optional(), @@ -1712,8 +1712,8 @@ export const unmarshalFeatureSchema: z.ZodType = z export const unmarshalFieldDefinitionSchema: z.ZodType = z .object({ - name: z.string().optional(), - data_type: z.string().optional(), + name: z.string(), + data_type: z.string(), }) .transform(d => ({ name: d.name, @@ -1723,11 +1723,10 @@ export const unmarshalFieldDefinitionSchema: z.ZodType = z export const unmarshalFirstDistinctFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), n: z .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), + .transform(v => BigInt(v)), }) .transform(d => ({ input: d.input, @@ -1736,7 +1735,7 @@ export const unmarshalFirstDistinctFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -1744,11 +1743,8 @@ export const unmarshalFirstFunctionSchema: z.ZodType = z export const unmarshalFirstNFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), - n: z - .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), + input: z.string(), + n: z.union([z.number(), z.bigint(), z.string()]).transform(v => BigInt(v)), }) .transform(d => ({ input: d.input, @@ -1757,7 +1753,7 @@ export const unmarshalFirstNFunctionSchema: z.ZodType = z export const unmarshalFlatSchemaSchema: z.ZodType = z .object({ - fields: z.array(z.lazy(() => unmarshalFieldDefinitionSchema)).optional(), + fields: z.array(z.lazy(() => unmarshalFieldDefinitionSchema)), }) .transform(d => ({ fields: d.fields, @@ -1790,9 +1786,7 @@ export const unmarshalFunctionSchema: z.ZodType = z export const unmarshalIngestionConfigSchema: z.ZodType = z .object({ - ingestion_destination: z - .lazy(() => unmarshalIngestionDestinationSchema) - .optional(), + ingestion_destination: z.lazy(() => unmarshalIngestionDestinationSchema), backfill_source: z.lazy(() => unmarshalBackfillSourceSchema).optional(), deduplication_columns: z.array(z.string()).optional(), ingestion_pipeline_id: z.string().optional(), @@ -1831,8 +1825,8 @@ export const unmarshalIngestionDestinationSchema: z.ZodType = z .object({ - parameter: z.string().optional(), - column: z.string().optional(), + parameter: z.string(), + column: z.string(), }) .transform(d => ({ parameter: d.parameter, @@ -1857,10 +1851,10 @@ export const unmarshalJobContextSchema: z.ZodType = z export const unmarshalKafkaConfigSchema: z.ZodType = z .object({ - name: z.string().optional(), - bootstrap_servers: z.string().optional(), - subscription_mode: z.lazy(() => unmarshalSubscriptionModeSchema).optional(), - auth_config: z.lazy(() => unmarshalAuthConfigSchema).optional(), + name: z.string(), + bootstrap_servers: z.string(), + subscription_mode: z.lazy(() => unmarshalSubscriptionModeSchema), + auth_config: z.lazy(() => unmarshalAuthConfigSchema), key_schema: z.lazy(() => unmarshalSchemaConfigSchema).optional(), value_schema: z.lazy(() => unmarshalSchemaConfigSchema).optional(), extra_options: z.record(z.string(), z.string()).optional(), @@ -1881,7 +1875,7 @@ export const unmarshalKafkaConfigSchema: z.ZodType = z export const unmarshalKafkaSourceSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), filter_condition: z.string().optional(), }) .transform(d => ({ @@ -1891,9 +1885,7 @@ export const unmarshalKafkaSourceSchema: z.ZodType = z export const unmarshalKafkaStreamConfigSchema: z.ZodType = z .object({ - subscription_mode: z - .lazy(() => unmarshalKafkaSubscriptionModeSchema) - .optional(), + subscription_mode: z.lazy(() => unmarshalKafkaSubscriptionModeSchema), extra_options: z.record(z.string(), z.string()).optional(), }) .transform(d => ({ @@ -1942,11 +1934,10 @@ export const unmarshalKinesisStreamConfigSchema: z.ZodType export const unmarshalLastDistinctFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), n: z .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), + .transform(v => BigInt(v)), }) .transform(d => ({ input: d.input, @@ -1955,7 +1946,7 @@ export const unmarshalLastDistinctFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -1963,11 +1954,8 @@ export const unmarshalLastFunctionSchema: z.ZodType = z export const unmarshalLastNFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), - n: z - .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), + input: z.string(), + n: z.union([z.number(), z.bigint(), z.string()]).transform(v => BigInt(v)), }) .transform(d => ({ input: d.input, @@ -2001,9 +1989,7 @@ export const unmarshalListFeaturesResponseSchema: z.ZodType = z .object({ - kafka_configs: z - .array(z.lazy(() => unmarshalKafkaConfigSchema)) - .optional(), + kafka_configs: z.array(z.lazy(() => unmarshalKafkaConfigSchema)), next_page_token: z.string().optional(), }) .transform(d => ({ @@ -2039,7 +2025,7 @@ export const unmarshalMaterializedFeatureSchema: z.ZodType z .object({ materialized_feature_id: z.string().optional(), - feature_name: z.string().optional(), + feature_name: z.string(), offline_store_config: z .lazy(() => unmarshalOfflineStoreConfigSchema) .optional(), @@ -2096,7 +2082,7 @@ export const unmarshalMaterializedFeatureSchema: z.ZodType export const unmarshalMaxFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -2104,7 +2090,7 @@ export const unmarshalMaxFunctionSchema: z.ZodType = z export const unmarshalMinFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -2112,17 +2098,11 @@ export const unmarshalMinFunctionSchema: z.ZodType = z export const unmarshalMtlsConfigSchema: z.ZodType = z .object({ - keystore_location: z.string().optional(), - keystore_password_ref: z - .lazy(() => unmarshalSecretScopeReferenceSchema) - .optional(), - key_password_ref: z - .lazy(() => unmarshalSecretScopeReferenceSchema) - .optional(), - truststore_location: z.string().optional(), - truststore_password_ref: z - .lazy(() => unmarshalSecretScopeReferenceSchema) - .optional(), + keystore_location: z.string(), + keystore_password_ref: z.lazy(() => unmarshalSecretScopeReferenceSchema), + key_password_ref: z.lazy(() => unmarshalSecretScopeReferenceSchema), + truststore_location: z.string(), + truststore_password_ref: z.lazy(() => unmarshalSecretScopeReferenceSchema), disable_hostname_verification: z.boolean().optional(), }) .transform(d => ({ @@ -2137,9 +2117,9 @@ export const unmarshalMtlsConfigSchema: z.ZodType = z export const unmarshalOfflineStoreConfigSchema: z.ZodType = z .object({ - catalog_name: z.string().optional(), - schema_name: z.string().optional(), - table_name_prefix: z.string().optional(), + catalog_name: z.string(), + schema_name: z.string(), + table_name_prefix: z.string(), }) .transform(d => ({ catalogName: d.catalog_name, @@ -2149,10 +2129,10 @@ export const unmarshalOfflineStoreConfigSchema: z.ZodType = export const unmarshalOnlineStoreConfigSchema: z.ZodType = z .object({ - catalog_name: z.string().optional(), - schema_name: z.string().optional(), - table_name_prefix: z.string().optional(), - online_store_name: z.string().optional(), + catalog_name: z.string(), + schema_name: z.string(), + table_name_prefix: z.string(), + online_store_name: z.string(), }) .transform(d => ({ catalogName: d.catalog_name, @@ -2163,8 +2143,8 @@ export const unmarshalOnlineStoreConfigSchema: z.ZodType = z export const unmarshalProtoSchemaSpecSchema: z.ZodType = z .object({ - schema_text: z.string().optional(), - message_name: z.string().optional(), + schema_text: z.string(), + message_name: z.string(), }) .transform(d => ({ schemaText: d.schema_text, @@ -2236,7 +2216,7 @@ export const unmarshalSchemaLocatorSchema: z.ZodType = z confluent_schema: z .lazy(() => unmarshalSchemaLocator_ConfluentSchemaSchema) .optional(), - format: z.string().optional(), + format: z.string(), }) .transform(d => ({ registrySchema: @@ -2253,7 +2233,7 @@ export const unmarshalSchemaLocatorSchema: z.ZodType = z export const unmarshalSchemaLocator_ConfluentSchemaSchema: z.ZodType = z .object({ - subject: z.string().optional(), + subject: z.string(), }) .transform(d => ({ subject: d.subject, @@ -2263,9 +2243,7 @@ export const unmarshalSchemaRegistryConfigSchema: z.ZodType unmarshalSecretScopeReferenceSchema) - .optional(), + api_secret_ref: z.lazy(() => unmarshalSecretScopeReferenceSchema), payload_schema_locator: z .lazy(() => unmarshalSchemaLocatorSchema) .optional(), @@ -2281,8 +2259,8 @@ export const unmarshalSchemaRegistryConfigSchema: z.ZodType = z .object({ - scope: z.string().optional(), - key: z.string().optional(), + scope: z.string(), + key: z.string(), }) .transform(d => ({ scope: d.scope, @@ -2297,8 +2275,7 @@ export const unmarshalSlidingWindowSchema: z.ZodType = z .optional(), slide_duration: z .string() - .transform(s => Temporal.Duration.from('PT' + s.toUpperCase())) - .optional(), + .transform(s => Temporal.Duration.from('PT' + s.toUpperCase())), delay: z .string() .transform(s => Temporal.Duration.from('PT' + s.toUpperCase())) @@ -2328,7 +2305,7 @@ export const unmarshalSourceLatenessSchema: z.ZodType = z export const unmarshalStddevPopFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -2337,7 +2314,7 @@ export const unmarshalStddevPopFunctionSchema: z.ZodType = z export const unmarshalStddevSampFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -2345,14 +2322,12 @@ export const unmarshalStddevSampFunctionSchema: z.ZodType = export const unmarshalStreamSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), - source_config: z.lazy(() => unmarshalStreamSourceConfigSchema).optional(), - connection_config: z - .lazy(() => unmarshalStreamConnectionConfigSchema) - .optional(), - schema_config: z.lazy(() => unmarshalStreamSchemaConfigSchema).optional(), - ingestion_config: z.lazy(() => unmarshalIngestionConfigSchema).optional(), + source_config: z.lazy(() => unmarshalStreamSourceConfigSchema), + connection_config: z.lazy(() => unmarshalStreamConnectionConfigSchema), + schema_config: z.lazy(() => unmarshalStreamSchemaConfigSchema), + ingestion_config: z.lazy(() => unmarshalIngestionConfigSchema), create_time: z .string() .transform(s => Temporal.Instant.from(s)) @@ -2440,7 +2415,7 @@ export const unmarshalStreamSchemaConfigSchema: z.ZodType = export const unmarshalStreamSourceSchema: z.ZodType = z .object({ - full_name: z.string().optional(), + full_name: z.string(), filter_condition: z.string().optional(), transformation_sql: z.string().optional(), dataframe_schema: z.string().optional(), @@ -2509,7 +2484,7 @@ export const unmarshalSubscriptionModeSchema: z.ZodType = z export const unmarshalSumFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -2546,7 +2521,7 @@ export const unmarshalTimeWindowSchema: z.ZodType = z export const unmarshalTimeseriesColumnSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -2556,8 +2531,7 @@ export const unmarshalTumblingWindowSchema: z.ZodType = z .object({ window_duration: z .string() - .transform(s => Temporal.Duration.from('PT' + s.toUpperCase())) - .optional(), + .transform(s => Temporal.Duration.from('PT' + s.toUpperCase())), delay: z .string() .transform(s => Temporal.Duration.from('PT' + s.toUpperCase())) @@ -2575,7 +2549,7 @@ export const unmarshalTumblingWindowSchema: z.ZodType = z export const unmarshalVarPopFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -2583,7 +2557,7 @@ export const unmarshalVarPopFunctionSchema: z.ZodType = z export const unmarshalVarSampFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -2704,7 +2678,7 @@ export const marshalAggregationFunctionSchema: z.ZodType = z export const marshalApproxCountDistinctFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), relativeSd: z.number().optional(), }) .transform(d => ({ @@ -2714,8 +2688,8 @@ export const marshalApproxCountDistinctFunctionSchema: z.ZodType = z export const marshalApproxPercentileFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), - percentile: z.number().optional(), + input: z.string(), + percentile: z.number(), accuracy: z.bigint().optional(), }) .transform(d => ({ @@ -2750,7 +2724,7 @@ export const marshalAuthConfigSchema: z.ZodType = z export const marshalAvgFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -2782,9 +2756,9 @@ export const marshalBackfillSourceSchema: z.ZodType = z export const marshalBatchCreateMaterializedFeaturesRequestSchema: z.ZodType = z .object({ - requests: z - .array(z.lazy(() => marshalCreateMaterializedFeatureRequestSchema)) - .optional(), + requests: z.array( + z.lazy(() => marshalCreateMaterializedFeatureRequestSchema) + ), }) .transform(d => ({ requests: d.requests, @@ -2792,7 +2766,7 @@ export const marshalBatchCreateMaterializedFeaturesRequestSchema: z.ZodType = z export const marshalColumnSelectionSchema: z.ZodType = z .object({ - column: z.string().optional(), + column: z.string(), }) .transform(d => ({ column: d.column, @@ -2800,7 +2774,7 @@ export const marshalColumnSelectionSchema: z.ZodType = z export const marshalCountFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -2808,9 +2782,7 @@ export const marshalCountFunctionSchema: z.ZodType = z export const marshalCreateMaterializedFeatureRequestSchema: z.ZodType = z .object({ - materializedFeature: z - .lazy(() => marshalMaterializedFeatureSchema) - .optional(), + materializedFeature: z.lazy(() => marshalMaterializedFeatureSchema), }) .transform(d => ({ materialized_feature: d.materializedFeature, @@ -2826,7 +2798,7 @@ export const marshalCronScheduleSchema: z.ZodType = z export const marshalCustomUdfSchema: z.ZodType = z .object({ - functionPath: z.string().optional(), + functionPath: z.string(), inputBindings: z.array(z.lazy(() => marshalInputBindingSchema)).optional(), }) .transform(d => ({ @@ -2876,7 +2848,7 @@ export const marshalDataSourceSchema: z.ZodType = z export const marshalDeltaTableSourceSchema: z.ZodType = z .object({ - fullName: z.string().optional(), + fullName: z.string(), filterCondition: z.string().optional(), transformationSql: z.string().optional(), dataframeSchema: z.string().optional(), @@ -2890,8 +2862,8 @@ export const marshalDeltaTableSourceSchema: z.ZodType = z export const marshalDirectMtlsConfigSchema: z.ZodType = z .object({ - bootstrapServers: z.string().optional(), - mtlsConfig: z.lazy(() => marshalMtlsConfigSchema).optional(), + bootstrapServers: z.string(), + mtlsConfig: z.lazy(() => marshalMtlsConfigSchema), }) .transform(d => ({ bootstrap_servers: d.bootstrapServers, @@ -2910,7 +2882,7 @@ export const marshalDirectSchemasSchema: z.ZodType = z export const marshalEntityColumnSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -2918,9 +2890,9 @@ export const marshalEntityColumnSchema: z.ZodType = z export const marshalFeatureSchema: z.ZodType = z .object({ - fullName: z.string().optional(), - source: z.lazy(() => marshalDataSourceSchema).optional(), - function: z.lazy(() => marshalFunctionSchema).optional(), + fullName: z.string(), + source: z.lazy(() => marshalDataSourceSchema), + function: z.lazy(() => marshalFunctionSchema), description: z.string().optional(), lineageContext: z.lazy(() => marshalLineageContextSchema).optional(), entities: z.array(z.lazy(() => marshalEntityColumnSchema)).optional(), @@ -2951,8 +2923,8 @@ export const marshalFeatureSchema: z.ZodType = z export const marshalFieldDefinitionSchema: z.ZodType = z .object({ - name: z.string().optional(), - dataType: z.string().optional(), + name: z.string(), + dataType: z.string(), }) .transform(d => ({ name: d.name, @@ -2961,8 +2933,8 @@ export const marshalFieldDefinitionSchema: z.ZodType = z export const marshalFirstDistinctFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), - n: z.bigint().optional(), + input: z.string(), + n: z.bigint(), }) .transform(d => ({ input: d.input, @@ -2971,7 +2943,7 @@ export const marshalFirstDistinctFunctionSchema: z.ZodType = z export const marshalFirstFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -2979,8 +2951,8 @@ export const marshalFirstFunctionSchema: z.ZodType = z export const marshalFirstNFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), - n: z.bigint().optional(), + input: z.string(), + n: z.bigint(), }) .transform(d => ({ input: d.input, @@ -2989,7 +2961,7 @@ export const marshalFirstNFunctionSchema: z.ZodType = z export const marshalFlatSchemaSchema: z.ZodType = z .object({ - fields: z.array(z.lazy(() => marshalFieldDefinitionSchema)).optional(), + fields: z.array(z.lazy(() => marshalFieldDefinitionSchema)), }) .transform(d => ({ fields: d.fields, @@ -3028,9 +3000,7 @@ export const marshalFunctionSchema: z.ZodType = z export const marshalIngestionConfigSchema: z.ZodType = z .object({ - ingestionDestination: z - .lazy(() => marshalIngestionDestinationSchema) - .optional(), + ingestionDestination: z.lazy(() => marshalIngestionDestinationSchema), backfillSource: z.lazy(() => marshalBackfillSourceSchema).optional(), deduplicationColumns: z.array(z.string()).optional(), ingestionPipelineId: z.string().optional(), @@ -3065,8 +3035,8 @@ export const marshalIngestionDestinationSchema: z.ZodType = z export const marshalInputBindingSchema: z.ZodType = z .object({ - parameter: z.string().optional(), - column: z.string().optional(), + parameter: z.string(), + column: z.string(), }) .transform(d => ({ parameter: d.parameter, @@ -3085,10 +3055,10 @@ export const marshalJobContextSchema: z.ZodType = z export const marshalKafkaConfigSchema: z.ZodType = z .object({ - name: z.string().optional(), - bootstrapServers: z.string().optional(), - subscriptionMode: z.lazy(() => marshalSubscriptionModeSchema).optional(), - authConfig: z.lazy(() => marshalAuthConfigSchema).optional(), + name: z.string(), + bootstrapServers: z.string(), + subscriptionMode: z.lazy(() => marshalSubscriptionModeSchema), + authConfig: z.lazy(() => marshalAuthConfigSchema), keySchema: z.lazy(() => marshalSchemaConfigSchema).optional(), valueSchema: z.lazy(() => marshalSchemaConfigSchema).optional(), extraOptions: z.record(z.string(), z.string()).optional(), @@ -3109,7 +3079,7 @@ export const marshalKafkaConfigSchema: z.ZodType = z export const marshalKafkaSourceSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), filterCondition: z.string().optional(), }) .transform(d => ({ @@ -3119,9 +3089,7 @@ export const marshalKafkaSourceSchema: z.ZodType = z export const marshalKafkaStreamConfigSchema: z.ZodType = z .object({ - subscriptionMode: z - .lazy(() => marshalKafkaSubscriptionModeSchema) - .optional(), + subscriptionMode: z.lazy(() => marshalKafkaSubscriptionModeSchema), extraOptions: z.record(z.string(), z.string()).optional(), }) .transform(d => ({ @@ -3182,8 +3150,8 @@ export const marshalKinesisStreamConfigSchema: z.ZodType = z export const marshalLastDistinctFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), - n: z.bigint().optional(), + input: z.string(), + n: z.bigint(), }) .transform(d => ({ input: d.input, @@ -3192,7 +3160,7 @@ export const marshalLastDistinctFunctionSchema: z.ZodType = z export const marshalLastFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -3200,8 +3168,8 @@ export const marshalLastFunctionSchema: z.ZodType = z export const marshalLastNFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), - n: z.bigint().optional(), + input: z.string(), + n: z.bigint(), }) .transform(d => ({ input: d.input, @@ -3221,7 +3189,7 @@ export const marshalLineageContextSchema: z.ZodType = z export const marshalMaterializedFeatureSchema: z.ZodType = z .object({ materializedFeatureId: z.string().optional(), - featureName: z.string().optional(), + featureName: z.string(), destination: z .discriminatedUnion('$case', [ z.object({ @@ -3284,7 +3252,7 @@ export const marshalMaterializedFeatureSchema: z.ZodType = z export const marshalMaxFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -3292,7 +3260,7 @@ export const marshalMaxFunctionSchema: z.ZodType = z export const marshalMinFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -3300,15 +3268,11 @@ export const marshalMinFunctionSchema: z.ZodType = z export const marshalMtlsConfigSchema: z.ZodType = z .object({ - keystoreLocation: z.string().optional(), - keystorePasswordRef: z - .lazy(() => marshalSecretScopeReferenceSchema) - .optional(), - keyPasswordRef: z.lazy(() => marshalSecretScopeReferenceSchema).optional(), - truststoreLocation: z.string().optional(), - truststorePasswordRef: z - .lazy(() => marshalSecretScopeReferenceSchema) - .optional(), + keystoreLocation: z.string(), + keystorePasswordRef: z.lazy(() => marshalSecretScopeReferenceSchema), + keyPasswordRef: z.lazy(() => marshalSecretScopeReferenceSchema), + truststoreLocation: z.string(), + truststorePasswordRef: z.lazy(() => marshalSecretScopeReferenceSchema), disableHostnameVerification: z.boolean().optional(), }) .transform(d => ({ @@ -3322,9 +3286,9 @@ export const marshalMtlsConfigSchema: z.ZodType = z export const marshalOfflineStoreConfigSchema: z.ZodType = z .object({ - catalogName: z.string().optional(), - schemaName: z.string().optional(), - tableNamePrefix: z.string().optional(), + catalogName: z.string(), + schemaName: z.string(), + tableNamePrefix: z.string(), }) .transform(d => ({ catalog_name: d.catalogName, @@ -3334,10 +3298,10 @@ export const marshalOfflineStoreConfigSchema: z.ZodType = z export const marshalOnlineStoreConfigSchema: z.ZodType = z .object({ - catalogName: z.string().optional(), - schemaName: z.string().optional(), - tableNamePrefix: z.string().optional(), - onlineStoreName: z.string().optional(), + catalogName: z.string(), + schemaName: z.string(), + tableNamePrefix: z.string(), + onlineStoreName: z.string(), }) .transform(d => ({ catalog_name: d.catalogName, @@ -3348,8 +3312,8 @@ export const marshalOnlineStoreConfigSchema: z.ZodType = z export const marshalProtoSchemaSpecSchema: z.ZodType = z .object({ - schemaText: z.string().optional(), - messageName: z.string().optional(), + schemaText: z.string(), + messageName: z.string(), }) .transform(d => ({ schema_text: d.schemaText, @@ -3436,7 +3400,7 @@ export const marshalSchemaLocatorSchema: z.ZodType = z }), ]) .optional(), - format: z.string().optional(), + format: z.string(), }) .transform(d => ({ ...(d.registrySchema?.$case === 'confluentSchema' && { @@ -3448,7 +3412,7 @@ export const marshalSchemaLocatorSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalSchemaLocator_ConfluentSchemaSchema: z.ZodType = z .object({ - subject: z.string().optional(), + subject: z.string(), }) .transform(d => ({ subject: d.subject, @@ -3457,7 +3421,7 @@ export const marshalSchemaLocator_ConfluentSchemaSchema: z.ZodType = z export const marshalSchemaRegistryConfigSchema: z.ZodType = z .object({ ucConnection: z.string().optional(), - apiSecretRef: z.lazy(() => marshalSecretScopeReferenceSchema).optional(), + apiSecretRef: z.lazy(() => marshalSecretScopeReferenceSchema), payloadSchemaLocator: z.lazy(() => marshalSchemaLocatorSchema).optional(), keySchemaLocator: z.lazy(() => marshalSchemaLocatorSchema).optional(), }) @@ -3470,8 +3434,8 @@ export const marshalSchemaRegistryConfigSchema: z.ZodType = z export const marshalSecretScopeReferenceSchema: z.ZodType = z .object({ - scope: z.string().optional(), - key: z.string().optional(), + scope: z.string(), + key: z.string(), }) .transform(d => ({ scope: d.scope, @@ -3486,8 +3450,7 @@ export const marshalSlidingWindowSchema: z.ZodType = z .optional(), slideDuration: z .any() - .transform((d: Temporal.Duration) => d.toString().slice(2).toLowerCase()) - .optional(), + .transform((d: Temporal.Duration) => d.toString().slice(2).toLowerCase()), delay: z .any() .transform((d: Temporal.Duration) => d.toString().slice(2).toLowerCase()) @@ -3517,7 +3480,7 @@ export const marshalSourceLatenessSchema: z.ZodType = z export const marshalStddevPopFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -3525,7 +3488,7 @@ export const marshalStddevPopFunctionSchema: z.ZodType = z export const marshalStddevSampFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -3533,14 +3496,12 @@ export const marshalStddevSampFunctionSchema: z.ZodType = z export const marshalStreamSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), - sourceConfig: z.lazy(() => marshalStreamSourceConfigSchema).optional(), - connectionConfig: z - .lazy(() => marshalStreamConnectionConfigSchema) - .optional(), - schemaConfig: z.lazy(() => marshalStreamSchemaConfigSchema).optional(), - ingestionConfig: z.lazy(() => marshalIngestionConfigSchema).optional(), + sourceConfig: z.lazy(() => marshalStreamSourceConfigSchema), + connectionConfig: z.lazy(() => marshalStreamConnectionConfigSchema), + schemaConfig: z.lazy(() => marshalStreamSchemaConfigSchema), + ingestionConfig: z.lazy(() => marshalIngestionConfigSchema), createTime: z .any() .transform((d: Temporal.Instant) => d.toString()) @@ -3633,7 +3594,7 @@ export const marshalStreamSchemaConfigSchema: z.ZodType = z export const marshalStreamSourceSchema: z.ZodType = z .object({ - fullName: z.string().optional(), + fullName: z.string(), filterCondition: z.string().optional(), transformationSql: z.string().optional(), dataframeSchema: z.string().optional(), @@ -3706,7 +3667,7 @@ export const marshalSubscriptionModeSchema: z.ZodType = z export const marshalSumFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -3755,7 +3716,7 @@ export const marshalTimeWindowSchema: z.ZodType = z export const marshalTimeseriesColumnSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -3765,8 +3726,7 @@ export const marshalTumblingWindowSchema: z.ZodType = z .object({ windowDuration: z .any() - .transform((d: Temporal.Duration) => d.toString().slice(2).toLowerCase()) - .optional(), + .transform((d: Temporal.Duration) => d.toString().slice(2).toLowerCase()), delay: z .any() .transform((d: Temporal.Duration) => d.toString().slice(2).toLowerCase()) @@ -3784,7 +3744,7 @@ export const marshalTumblingWindowSchema: z.ZodType = z export const marshalVarPopFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, @@ -3792,7 +3752,7 @@ export const marshalVarPopFunctionSchema: z.ZodType = z export const marshalVarSampFunctionSchema: z.ZodType = z .object({ - input: z.string().optional(), + input: z.string(), }) .transform(d => ({ input: d.input, diff --git a/packages/featurestore/src/v1/model.ts b/packages/featurestore/src/v1/model.ts index f2bf0fdf7..a510e9302 100644 --- a/packages/featurestore/src/v1/model.ts +++ b/packages/featurestore/src/v1/model.ts @@ -54,22 +54,22 @@ export type PublishSpec_PublishMode = export interface CreateOnlineStoreRequest { /** Online store to create. */ - onlineStore?: OnlineStore | undefined; + onlineStore: OnlineStore; } export interface DeleteOnlineStoreRequest { /** Name of the online store to delete. */ - name?: string | undefined; + name: string; } export interface DeleteOnlineTableRequest { /** The full three-part (catalog, schema, table) name of the online table. */ - onlineTableName?: string | undefined; + onlineTableName: string; } export interface GetOnlineStoreRequest { /** Name of the online store to get. */ - name?: string | undefined; + name: string; } export interface ListOnlineStoresRequest { @@ -89,7 +89,7 @@ export interface ListOnlineStoresResponse { /** An OnlineStore is a logical database instance that stores and serves features online. */ export interface OnlineStore { /** The name of the online store. This is the unique identifier for the online store. */ - name?: string | undefined; + name: string; /** The email of the creator of the online store. */ creator?: string | undefined; /** The timestamp when the online store was created. */ @@ -97,7 +97,7 @@ export interface OnlineStore { /** The current state of the online store. */ state?: OnlineStore_State | undefined; /** The capacity of the online store. Valid values are "CU_1", "CU_2", "CU_4", "CU_8". */ - capacity?: string | undefined; + capacity: string; /** The number of read replicas for the online store. Defaults to 0. */ readReplicaCount?: number | undefined; /** The usage policy applied to the online store to track billing. */ @@ -106,18 +106,18 @@ export interface OnlineStore { export interface PublishSpec { /** The name of the target online store. */ - onlineStore?: string | undefined; + onlineStore: string; /** The full three-part (catalog, schema, table) name of the online table. */ - onlineTableName?: string | undefined; + onlineTableName: string; /** The publish mode of the pipeline that syncs the online table with the source table. */ - publishMode?: PublishSpec_PublishMode | undefined; + publishMode: PublishSpec_PublishMode; } export interface PublishTableRequest { /** The full three-part (catalog, schema, table) name of the source table. */ - sourceTableName?: string | undefined; + sourceTableName: string; /** The specification for publishing the online table from the source table. */ - publishSpec?: PublishSpec | undefined; + publishSpec: PublishSpec; } export interface PublishTableResponse { @@ -129,9 +129,9 @@ export interface PublishTableResponse { export interface UpdateOnlineStoreRequest { /** Online store to update. */ - onlineStore?: OnlineStore | undefined; + onlineStore: OnlineStore; /** The list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export const unmarshalListOnlineStoresResponseSchema: z.ZodType = @@ -149,14 +149,14 @@ export const unmarshalListOnlineStoresResponseSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), creator: z.string().optional(), creation_time: z .string() .transform(s => Temporal.Instant.from(s)) .optional(), state: z.string().optional(), - capacity: z.string().optional(), + capacity: z.string(), read_replica_count: z.number().optional(), usage_policy_id: z.string().optional(), }) @@ -183,14 +183,14 @@ export const unmarshalPublishTableResponseSchema: z.ZodType d.toString()) .optional(), state: z.string().optional(), - capacity: z.string().optional(), + capacity: z.string(), readReplicaCount: z.number().optional(), usagePolicyId: z.string().optional(), }) @@ -206,9 +206,9 @@ export const marshalOnlineStoreSchema: z.ZodType = z export const marshalPublishSpecSchema: z.ZodType = z .object({ - onlineStore: z.string().optional(), - onlineTableName: z.string().optional(), - publishMode: z.string().optional(), + onlineStore: z.string(), + onlineTableName: z.string(), + publishMode: z.string(), }) .transform(d => ({ online_store: d.onlineStore, @@ -218,8 +218,8 @@ export const marshalPublishSpecSchema: z.ZodType = z export const marshalPublishTableRequestSchema: z.ZodType = z .object({ - sourceTableName: z.string().optional(), - publishSpec: z.lazy(() => marshalPublishSpecSchema).optional(), + sourceTableName: z.string(), + publishSpec: z.lazy(() => marshalPublishSpecSchema), }) .transform(d => ({ source_table_name: d.sourceTableName, diff --git a/packages/files/src/v2/model.ts b/packages/files/src/v2/model.ts index f6d2cf3c7..dec64b9cf 100644 --- a/packages/files/src/v2/model.ts +++ b/packages/files/src/v2/model.ts @@ -4,9 +4,9 @@ import {z} from 'zod'; export interface AddBlockRequest { /** The handle on an open stream. */ - handle?: bigint | undefined; + handle: bigint; /** The base64-encoded data to append to the stream. This has a limit of 1 MB. */ - data?: Uint8Array | undefined; + data: Uint8Array; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -14,7 +14,7 @@ export interface AddBlockResponse {} export interface CloseRequest { /** The handle on an open stream. */ - handle?: bigint | undefined; + handle: bigint; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -23,7 +23,7 @@ export interface CloseResponse {} /** Create a directory */ export interface CreateDirectoryRequest { /** The absolute path of a directory. */ - directoryPath?: string | undefined; + directoryPath: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -31,7 +31,7 @@ export interface CreateDirectoryResponse {} export interface CreateRequest { /** The path of the new file. The path should be the absolute DBFS path. */ - path?: string | undefined; + path: string; /** The flag that specifies whether to overwrite existing file/files. */ overwrite?: boolean | undefined; } @@ -44,7 +44,7 @@ export interface CreateResponse { /** Delete a directory */ export interface DeleteDirectoryRequest { /** The absolute path of a directory. */ - directoryPath?: string | undefined; + directoryPath: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -53,7 +53,7 @@ export interface DeleteDirectoryResponse {} /** Delete a file */ export interface DeleteFileRequest { /** The absolute path of the file. */ - filePath?: string | undefined; + filePath: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -61,7 +61,7 @@ export interface DeleteFileResponse {} export interface DeleteRequest { /** The path of the file or directory to delete. The path should be the absolute DBFS path. */ - path?: string | undefined; + path: string; /** Whether or not to recursively delete the directory's contents. Deleting empty directories can be done without providing the recursive flag. */ recursive?: boolean | undefined; } @@ -85,7 +85,7 @@ export interface DirectoryEntry { /** Download a file */ export interface DownloadFileRequest { /** The absolute path of the file. */ - filePath?: string | undefined; + filePath: string; /** * The range of bytes to retrieve. * The range is inclusive and zero-based, see @@ -124,7 +124,7 @@ export interface FileInfo { /** Get directory metadata */ export interface GetDirectoryMetadataRequest { /** The absolute path of a directory. */ - directoryPath?: string | undefined; + directoryPath: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -133,7 +133,7 @@ export interface GetDirectoryMetadataResponse {} /** Get file metadata */ export interface GetFileMetadataRequest { /** The absolute path of the file. */ - filePath?: string | undefined; + filePath: string; /** * The range of bytes to retrieve. * The range is inclusive and zero-based, see @@ -158,7 +158,7 @@ export interface GetFileMetadataResponse { export interface GetStatusRequest { /** The path of the file or directory. The path should be the absolute DBFS path. */ - path?: string | undefined; + path: string; } export interface GetStatusResponse { @@ -175,7 +175,7 @@ export interface GetStatusResponse { /** List directory contents */ export interface ListDirectoryContentsRequest { /** The absolute path of a directory. */ - directoryPath?: string | undefined; + directoryPath: string; /** * The maximum number of directory entries to return. The response may contain fewer * entries. If the response contains a `next_page_token`, there may be more entries, @@ -210,7 +210,7 @@ export interface ListDirectoryResponse { export interface ListStatusRequest { /** The path of the file or directory. The path should be the absolute DBFS path. */ - path?: string | undefined; + path: string; } export interface ListStatusResponse { @@ -220,7 +220,7 @@ export interface ListStatusResponse { export interface MkDirsRequest { /** The path of the new directory. The path should be the absolute DBFS path. */ - path?: string | undefined; + path: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -228,9 +228,9 @@ export interface MkDirsResponse {} export interface MoveRequest { /** The source path of the file or directory. The path should be the absolute DBFS path. */ - sourcePath?: string | undefined; + sourcePath: string; /** The destination path of the file or directory. The path should be the absolute DBFS path. */ - destinationPath?: string | undefined; + destinationPath: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -238,7 +238,7 @@ export interface MoveResponse {} export interface PutRequest { /** The path of the new file. The path should be the absolute DBFS path. */ - path?: string | undefined; + path: string; /** This parameter might be absent, and instead a posted file will be used. */ contents?: Uint8Array | undefined; /** The flag that specifies whether to overwrite existing file/files. */ @@ -250,7 +250,7 @@ export interface PutResponse {} export interface ReadRequest { /** The path of the file to read. The path should be the absolute DBFS path. */ - path?: string | undefined; + path: string; /** The offset to read from in bytes. */ offset?: bigint | undefined; /** @@ -273,7 +273,7 @@ export interface ReadResponse { /** Upload a file */ export interface UploadFileRequest { /** The absolute path of the file. */ - filePath?: string | undefined; + filePath: string; contents?: ReadableStream | undefined; /** If true or unspecified, an existing file will be overwritten. If false, an error will be returned if the path points to an existing file. */ overwrite?: boolean | undefined; @@ -437,13 +437,12 @@ export const unmarshalUploadFileResponseSchema: z.ZodType = export const marshalAddBlockRequestSchema: z.ZodType = z .object({ - handle: z.bigint().optional(), + handle: z.bigint(), data: z .any() .transform((d: Uint8Array) => btoa(Array.from(d, b => String.fromCharCode(b)).join('')) - ) - .optional(), + ), }) .transform(d => ({ handle: d.handle, @@ -452,7 +451,7 @@ export const marshalAddBlockRequestSchema: z.ZodType = z export const marshalCloseRequestSchema: z.ZodType = z .object({ - handle: z.bigint().optional(), + handle: z.bigint(), }) .transform(d => ({ handle: d.handle, @@ -460,7 +459,7 @@ export const marshalCloseRequestSchema: z.ZodType = z export const marshalCreateRequestSchema: z.ZodType = z .object({ - path: z.string().optional(), + path: z.string(), overwrite: z.boolean().optional(), }) .transform(d => ({ @@ -470,7 +469,7 @@ export const marshalCreateRequestSchema: z.ZodType = z export const marshalDeleteRequestSchema: z.ZodType = z .object({ - path: z.string().optional(), + path: z.string(), recursive: z.boolean().optional(), }) .transform(d => ({ @@ -480,7 +479,7 @@ export const marshalDeleteRequestSchema: z.ZodType = z export const marshalMkDirsRequestSchema: z.ZodType = z .object({ - path: z.string().optional(), + path: z.string(), }) .transform(d => ({ path: d.path, @@ -488,8 +487,8 @@ export const marshalMkDirsRequestSchema: z.ZodType = z export const marshalMoveRequestSchema: z.ZodType = z .object({ - sourcePath: z.string().optional(), - destinationPath: z.string().optional(), + sourcePath: z.string(), + destinationPath: z.string(), }) .transform(d => ({ source_path: d.sourcePath, @@ -498,7 +497,7 @@ export const marshalMoveRequestSchema: z.ZodType = z export const marshalPutRequestSchema: z.ZodType = z .object({ - path: z.string().optional(), + path: z.string(), contents: z .any() .transform((d: Uint8Array) => diff --git a/packages/forecasting/src/v1/model.ts b/packages/forecasting/src/v1/model.ts index ac8a87053..32ac834cb 100644 --- a/packages/forecasting/src/v1/model.ts +++ b/packages/forecasting/src/v1/model.ts @@ -22,18 +22,18 @@ export type ForecastingExperiment_State = export interface CreateForecastingExperimentRequest { /** The fully qualified path of a Unity Catalog table, formatted as catalog_name.schema_name.table_name, used as training data for the forecasting model. */ - trainDataPath?: string | undefined; + trainDataPath: string; /** The column in the input training table used as the prediction target for model training. The values in this column are used as the ground truth for model training. */ - targetColumn?: string | undefined; + targetColumn: string; /** The column in the input training table that represents each row's timestamp. */ - timeColumn?: string | undefined; + timeColumn: string; /** * The time interval between consecutive rows in the time series data. * Possible values include: '1 second', '1 minute', '5 minutes', '10 minutes', '15 minutes', '30 minutes', 'Hourly', 'Daily', 'Weekly', 'Monthly', 'Quarterly', 'Yearly'. */ - forecastGranularity?: string | undefined; + forecastGranularity: string; /** The number of time steps into the future to make predictions, calculated as a multiple of forecast_granularity. This value represents how far ahead the model should forecast. */ - forecastHorizon?: bigint | undefined; + forecastHorizon: bigint; /** The evaluation metric used to optimize the forecasting model. */ primaryMetric?: string | undefined; /** List of frameworks to include for model tuning. Possible values are 'Prophet', 'ARIMA', 'DeepAR'. An empty list includes all supported frameworks. */ @@ -84,7 +84,7 @@ export interface ForecastingExperiment { export interface GetForecastingExperimentRequest { /** The unique ID of a forecasting experiment */ - experimentId?: string | undefined; + experimentId: string; } export const unmarshalCreateForecastingExperimentResponseSchema: z.ZodType = @@ -111,11 +111,11 @@ export const unmarshalForecastingExperimentSchema: z.ZodType { + const {host, workspaceId, httpClient} = await this.resolveConfig(); + const url = `${host}/api/2.0/genie/agents/${req.agentId ?? ''}/conversations/${req.conversationId ?? ''}/responses/${req.responseId ?? ''}/cancel`; + const body = marshalRequest(req, marshalGenieCancelResponseRequestSchema); + let resp: GenieMessage | undefined; + const call = async (callSignal?: AbortSignal): Promise => { + const headers = new Headers({'Content-Type': 'application/json'}); + if (workspaceId !== undefined) { + headers.set('X-Databricks-Workspace-Id', workspaceId); + } + headers.set('User-Agent', this.userAgent); + const httpReq = buildHttpRequest('POST', url, headers, callSignal, body); + const respBody = await executeHttpCall({ + request: httpReq, + httpClient, + logger: this.logger, + }); + resp = parseResponse(respBody, unmarshalGenieMessageSchema); + }; + await executeCall(call, options); + if (resp === undefined) { + throw new Error('operation completed without a result.'); + } + return resp; + } + /** * Create new message in a [conversation](:method:genie/startconversation). * The AI response uses all previously created messages in the conversation to respond. diff --git a/packages/genie/src/v1/index.ts b/packages/genie/src/v1/index.ts index 03c8366be..2c898ec1e 100644 --- a/packages/genie/src/v1/index.ts +++ b/packages/genie/src/v1/index.ts @@ -37,6 +37,7 @@ export type { DownloadMessageAttachmentVisualizationResponse, ExternalLink, GenieAttachment, + GenieCancelResponseRequest, GenieConversation, GenieConversationSummary, GenieCreateConversationMessageRequest, diff --git a/packages/genie/src/v1/model.ts b/packages/genie/src/v1/model.ts index 779a9f5ac..6ace44092 100644 --- a/packages/genie/src/v1/model.ts +++ b/packages/genie/src/v1/model.ts @@ -926,9 +926,9 @@ export interface ColumnMask { */ usingColumnNames?: string[] | undefined; /** - * The list of additional table columns or literals to be passed as additional arguments to - * a column mask function. This is the replacement of the deprecated using_column_names field and - * carries information about the types (alias or constant) of the arguments to the mask function. + * The list of table columns or literals to be passed as additional arguments to a column mask + * function, carrying the type (column reference vs constant literal) of each argument. + * Deprecated: use using_column_names instead. */ usingArguments?: PolicyFunctionArgument[] | undefined; } @@ -950,7 +950,7 @@ export interface DownloadMessageAttachmentVisualizationRequest { * The resource name of the attachment to render, in the format * `spaces/{space_id}/conversations/{conversation_id}/messages/{message_id}/attachments/{attachment_id}`. */ - name?: string | undefined; + name: string; } export interface DownloadMessageAttachmentVisualizationResponse { @@ -1038,6 +1038,16 @@ export interface GenieAttachment { attachmentId?: string | undefined; } +/** Request to cancel an in-flight agent-mode response. */ +export interface GenieCancelResponseRequest { + /** The ID of the Genie agent (synonymous with the Genie space ID). */ + agentId: string; + /** The ID of the conversation containing the response. */ + conversationId: string; + /** The ID of the response to cancel (the id from the `response.created` event). */ + responseId: string; +} + export interface GenieConversation { /** * Conversation ID. @@ -1045,7 +1055,7 @@ export interface GenieConversation { */ id?: string | undefined; /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** ID of the user who created the conversation */ userId?: bigint | undefined; /** Timestamp when the message was created */ @@ -1053,13 +1063,13 @@ export interface GenieConversation { /** Timestamp when the message was last updated */ lastUpdatedTimestamp?: bigint | undefined; /** Conversation title */ - title?: string | undefined; + title: string; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; } export interface GenieConversationSummary { - conversationId?: string | undefined; + conversationId: string; title?: string | undefined; createdTimestamp?: bigint | undefined; /** @@ -1071,36 +1081,36 @@ export interface GenieConversationSummary { export interface GenieCreateConversationMessageRequest { /** The ID associated with the Genie space where the conversation is started. */ - spaceId?: string | undefined; + spaceId: string; /** The ID associated with the conversation. */ - conversationId?: string | undefined; + conversationId: string; /** User message content. */ - content?: string | undefined; + content: string; /** Enable visualization generation. */ enableVisualization?: boolean | undefined; } export interface GenieCreateEvalRunRequest { /** The ID associated with the Genie space where the evaluations will be executed. */ - spaceId?: string | undefined; + spaceId: string; /** List of benchmark question IDs to evaluate. These questions must exist in the specified Genie space. If none are specified, then all benchmark questions are evaluated. */ benchmarkQuestionIds?: string[] | undefined; } export interface GenieCreateMessageCommentRequest { /** The ID associated with the Genie space. */ - spaceId?: string | undefined; + spaceId: string; /** The ID associated with the conversation. */ - conversationId?: string | undefined; + conversationId: string; /** The ID associated with the message. */ - messageId?: string | undefined; + messageId: string; /** Comment text content. */ - content?: string | undefined; + content: string; } export interface GenieCreateSpaceRequest { /** Warehouse to associate with the new space */ - warehouseId?: string | undefined; + warehouseId: string; /** Parent folder path where the space will be registered */ parentPath?: string | undefined; /** @@ -1108,7 +1118,7 @@ export interface GenieCreateSpaceRequest { * Use the [Get Genie Space](:method:genie/getspace) API to retrieve an example response, which includes the `serialized_space` field. * This field provides the structure of the JSON string that represents the space's layout and components. */ - serializedSpace?: string | undefined; + serializedSpace: string; /** Optional title override */ title?: string | undefined; /** Optional description */ @@ -1117,18 +1127,18 @@ export interface GenieCreateSpaceRequest { export interface GenieDeleteConversationMessageRequest { /** The ID associated with the Genie space where the message is located. */ - spaceId?: string | undefined; + spaceId: string; /** The ID associated with the conversation. */ - conversationId?: string | undefined; + conversationId: string; /** The ID associated with the message to delete. */ - messageId?: string | undefined; + messageId: string; } export interface GenieDeleteConversationRequest { /** The ID associated with the Genie space where the conversation is located. */ - spaceId?: string | undefined; + spaceId: string; /** The ID of the conversation to delete. */ - conversationId?: string | undefined; + conversationId: string; } export interface GenieEvalResponse { @@ -1146,11 +1156,11 @@ export interface GenieEvalResponse { */ export interface GenieEvalResult { /** Unique identifier for this evaluation result. */ - resultId?: string | undefined; + resultId: string; /** The ID of the space the evaluation result belongs to. */ - spaceId?: string | undefined; + spaceId: string; /** The ID of the benchmark question that was evaluated. */ - benchmarkQuestionId?: string | undefined; + benchmarkQuestionId: string; /** Current status of this evaluation result. */ status?: EvaluationStatusType | undefined; /** Stored snapshot of original benchmark question text. */ @@ -1164,11 +1174,11 @@ export interface GenieEvalResult { /** Shows detailed information for an evaluation result. */ export interface GenieEvalResultDetails { /** The unique identifier for the evaluation result. */ - resultId?: string | undefined; + resultId: string; /** The ID of the space the evaluation result belongs to. */ - spaceId?: string | undefined; + spaceId: string; /** The ID of the benchmark question that was evaluated. */ - benchmarkQuestionId?: string | undefined; + benchmarkQuestionId: string; /** Current status of the evaluation run. */ evalRunStatus?: EvaluationStatusType | undefined; /** Assessment of the evaluation result: good, bad, or needs review */ @@ -1220,7 +1230,7 @@ export interface GenieEvalResultDetails { export interface GenieEvalRunResponse { /** The unique identifier for the evaluation run. */ - evalRunId?: string | undefined; + evalRunId: string; /** Current status of the evaluation run. */ evalRunStatus?: EvaluationStatusType | undefined; /** User ID who initiated the evaluation run. */ @@ -1241,22 +1251,22 @@ export interface GenieEvalRunResponse { export interface GenieExecuteMessageAttachmentQueryRequest { /** Message ID */ - messageId?: string | undefined; + messageId: string; /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; /** Attachment ID */ - attachmentId?: string | undefined; + attachmentId: string; } export interface GenieExecuteMessageQueryRequest { /** Message ID */ - messageId?: string | undefined; + messageId: string; /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; } /** Feedback containing rating and optional comment */ @@ -1269,13 +1279,13 @@ export interface GenieFeedback { export interface GenieGenerateDownloadFullQueryResultRequest { /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; /** Message ID */ - messageId?: string | undefined; + messageId: string; /** Attachment ID */ - attachmentId?: string | undefined; + attachmentId: string; } export interface GenieGenerateDownloadFullQueryResultResponse { @@ -1287,26 +1297,26 @@ export interface GenieGenerateDownloadFullQueryResultResponse { export interface GenieGetConversationMessageRequest { /** The ID associated with the Genie space where the target conversation is located. */ - spaceId?: string | undefined; + spaceId: string; /** The ID associated with the target conversation. */ - conversationId?: string | undefined; + conversationId: string; /** The ID associated with the target message from the identified conversation. */ - messageId?: string | undefined; + messageId: string; } export interface GenieGetDownloadFullQueryResultRequest { /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; /** Message ID */ - messageId?: string | undefined; + messageId: string; /** Attachment ID */ - attachmentId?: string | undefined; + attachmentId: string; /** Download ID. This ID is provided by the [Generate Download endpoint](:method:genie/generateDownloadFullQueryResult) */ - downloadId?: string | undefined; + downloadId: string; /** JWT signature for the download_id to ensure secure access to query results */ - downloadIdSignature?: string | undefined; + downloadIdSignature: string; } export interface GenieGetDownloadFullQueryResultResponse { @@ -1316,37 +1326,37 @@ export interface GenieGetDownloadFullQueryResultResponse { export interface GenieGetEvalResultDetailsRequest { /** The ID associated with the Genie space where the evaluation run is located. */ - spaceId?: string | undefined; + spaceId: string; /** The unique identifier for the evaluation run. */ - evalRunId?: string | undefined; + evalRunId: string; /** The unique identifier for the evaluation result. */ - resultId?: string | undefined; + resultId: string; } export interface GenieGetEvalRunRequest { /** The ID associated with the Genie space where the evaluation run is located. */ - spaceId?: string | undefined; - evalRunId?: string | undefined; + spaceId: string; + evalRunId: string; } export interface GenieGetMessageAttachmentQueryResultRequest { /** Message ID */ - messageId?: string | undefined; + messageId: string; /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; /** Attachment ID */ - attachmentId?: string | undefined; + attachmentId: string; } export interface GenieGetMessageQueryResultRequest { /** Message ID */ - messageId?: string | undefined; + messageId: string; /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; } export interface GenieGetMessageQueryResultResponse { @@ -1356,18 +1366,18 @@ export interface GenieGetMessageQueryResultResponse { export interface GenieGetQueryResultByAttachmentRequest { /** Message ID */ - messageId?: string | undefined; + messageId: string; /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; /** Attachment ID */ - attachmentId?: string | undefined; + attachmentId: string; } export interface GenieGetSpaceRequest { /** The ID associated with the Genie space */ - spaceId?: string | undefined; + spaceId: string; /** * Whether to include the serialized space export in the response. * Requires at least CAN EDIT permission on the space. @@ -1377,9 +1387,9 @@ export interface GenieGetSpaceRequest { export interface GenieListConversationCommentsRequest { /** The ID associated with the Genie space. */ - spaceId?: string | undefined; + spaceId: string; /** The ID associated with the conversation. */ - conversationId?: string | undefined; + conversationId: string; /** Maximum number of comments to return per page. */ pageSize?: number | undefined; /** Pagination token for getting the next page of results. */ @@ -1395,9 +1405,9 @@ export interface GenieListConversationCommentsResponse { export interface GenieListConversationMessagesRequest { /** The ID associated with the Genie space where the conversation is located */ - spaceId?: string | undefined; + spaceId: string; /** The ID of the conversation to list messages from */ - conversationId?: string | undefined; + conversationId: string; /** Maximum number of messages to return per page */ pageSize?: number | undefined; /** Token to get the next page of results */ @@ -1413,7 +1423,7 @@ export interface GenieListConversationMessagesResponse { export interface GenieListConversationsRequest { /** The ID of the Genie space to retrieve conversations from. */ - spaceId?: string | undefined; + spaceId: string; /** Maximum number of conversations to return per page */ pageSize?: number | undefined; /** Token to get the next page of results */ @@ -1434,9 +1444,9 @@ export interface GenieListConversationsResponse { export interface GenieListEvalResultsRequest { /** The ID associated with the Genie space where the evaluation run is located. */ - spaceId?: string | undefined; + spaceId: string; /** The unique identifier for the evaluation run. */ - evalRunId?: string | undefined; + evalRunId: string; /** Maximum number of eval results to return per page. */ pageSize?: number | undefined; /** Opaque token to retrieve the next page of results. */ @@ -1452,7 +1462,7 @@ export interface GenieListEvalResultsResponse { export interface GenieListEvalRunsRequest { /** The ID associated with the Genie space where the evaluation run is located. */ - spaceId?: string | undefined; + spaceId: string; /** Maximum number of evaluation runs to return per page */ pageSize?: number | undefined; /** Token to get the next page of results */ @@ -1468,11 +1478,11 @@ export interface GenieListEvalRunsResponse { export interface GenieListMessageCommentsRequest { /** The ID associated with the Genie space. */ - spaceId?: string | undefined; + spaceId: string; /** The ID associated with the conversation. */ - conversationId?: string | undefined; + conversationId: string; /** The ID associated with the message. */ - messageId?: string | undefined; + messageId: string; /** Maximum number of comments to return per page. */ pageSize?: number | undefined; /** Pagination token for getting the next page of results. */ @@ -1507,9 +1517,9 @@ export interface GenieMessage { */ id?: string | undefined; /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; /** ID of the user who created the message */ userId?: bigint | undefined; /** Timestamp when the message was created */ @@ -1518,7 +1528,7 @@ export interface GenieMessage { lastUpdatedTimestamp?: bigint | undefined; status?: MessageStatus_MessageStatus | undefined; /** User message content */ - content?: string | undefined; + content: string; /** AI-generated response to the message */ attachments?: GenieAttachment[] | undefined; /** @@ -1529,7 +1539,7 @@ export interface GenieMessage { /** Error message if Genie failed to respond to the message */ error?: MessageError | undefined; /** Message ID */ - messageId?: string | undefined; + messageId: string; /** User feedback for the message if provided */ feedback?: GenieFeedback | undefined; } @@ -1537,17 +1547,17 @@ export interface GenieMessage { /** A comment on a Genie conversation message. */ export interface GenieMessageComment { /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; /** Message ID */ - messageId?: string | undefined; + messageId: string; /** Comment ID */ - messageCommentId?: string | undefined; + messageCommentId: string; /** ID of the user who created the comment */ userId?: bigint | undefined; /** Comment text content */ - content?: string | undefined; + content: string; /** Timestamp when the comment was created */ createdTimestamp?: bigint | undefined; } @@ -1580,22 +1590,22 @@ export interface GenieResultMetadata { export interface GenieSendMessageFeedbackRequest { /** The ID associated with the Genie space where the message is located. */ - spaceId?: string | undefined; + spaceId: string; /** The ID associated with the conversation. */ - conversationId?: string | undefined; + conversationId: string; /** The ID associated with the message to provide feedback for. */ - messageId?: string | undefined; + messageId: string; /** The rating (POSITIVE, NEGATIVE, or NONE). */ - rating?: GenieFeedbackRating | undefined; + rating: GenieFeedbackRating; /** Optional text feedback that will be stored as a comment. */ comment?: string | undefined; } export interface GenieSpace { /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** Title of the Genie Space */ - title?: string | undefined; + title: string; /** Description of the Genie Space */ description?: string | undefined; /** Warehouse associated with the Genie Space */ @@ -1622,19 +1632,19 @@ export interface GenieSpace { export interface GenieStartConversationRequest { /** The ID associated with the Genie space where you want to start a conversation. */ - spaceId?: string | undefined; + spaceId: string; /** The text of the message that starts the conversation. */ - content?: string | undefined; + content: string; /** Enable visualization generation. */ enableVisualization?: boolean | undefined; } export interface GenieStartConversationResponse { /** Message ID */ - messageId?: string | undefined; + messageId: string; message?: GenieMessage | undefined; /** Conversation ID */ - conversationId?: string | undefined; + conversationId: string; conversation?: GenieConversation | undefined; } @@ -1646,12 +1656,12 @@ export interface GenieSuggestedQuestionsAttachment { export interface GenieTrashSpaceRequest { /** The ID associated with the Genie space to be sent to the trash. */ - spaceId?: string | undefined; + spaceId: string; } export interface GenieUpdateSpaceRequest { /** Genie space ID */ - spaceId?: string | undefined; + spaceId: string; /** * The contents of the Genie Space in serialized string form (full replacement). * Use the [Get Genie Space](:method:genie/getspace) API to retrieve an example response, which includes the `serialized_space` field. @@ -2089,7 +2099,7 @@ export const unmarshalGenieAttachmentSchema: z.ZodType = z export const unmarshalGenieConversationSchema: z.ZodType = z .object({ id: z.string().optional(), - space_id: z.string().optional(), + space_id: z.string(), user_id: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) @@ -2102,8 +2112,8 @@ export const unmarshalGenieConversationSchema: z.ZodType = z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) .optional(), - title: z.string().optional(), - conversation_id: z.string().optional(), + title: z.string(), + conversation_id: z.string(), }) .transform(d => ({ id: d.id, @@ -2118,7 +2128,7 @@ export const unmarshalGenieConversationSchema: z.ZodType = z export const unmarshalGenieConversationSummarySchema: z.ZodType = z .object({ - conversation_id: z.string().optional(), + conversation_id: z.string(), title: z.string().optional(), created_timestamp: z .union([z.number(), z.bigint(), z.string()]) @@ -2149,9 +2159,9 @@ export const unmarshalGenieEvalResponseSchema: z.ZodType = z export const unmarshalGenieEvalResultSchema: z.ZodType = z .object({ - result_id: z.string().optional(), - space_id: z.string().optional(), - benchmark_question_id: z.string().optional(), + result_id: z.string(), + space_id: z.string(), + benchmark_question_id: z.string(), status: z.string().optional(), question: z.string().optional(), benchmark_answer: z.string().optional(), @@ -2173,9 +2183,9 @@ export const unmarshalGenieEvalResultSchema: z.ZodType = z export const unmarshalGenieEvalResultDetailsSchema: z.ZodType = z .object({ - result_id: z.string().optional(), - space_id: z.string().optional(), - benchmark_question_id: z.string().optional(), + result_id: z.string(), + space_id: z.string(), + benchmark_question_id: z.string(), eval_run_status: z.string().optional(), assessment: z.string().optional(), manual_assessment: z.boolean().optional(), @@ -2202,7 +2212,7 @@ export const unmarshalGenieEvalResultDetailsSchema: z.ZodType = z .object({ - eval_run_id: z.string().optional(), + eval_run_id: z.string(), eval_run_status: z.string().optional(), run_by_user: z .union([z.number(), z.bigint(), z.string()]) @@ -2378,8 +2388,8 @@ export const unmarshalGenieListSpacesResponseSchema: z.ZodType = z .object({ id: z.string().optional(), - space_id: z.string().optional(), - conversation_id: z.string().optional(), + space_id: z.string(), + conversation_id: z.string(), user_id: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) @@ -2393,13 +2403,13 @@ export const unmarshalGenieMessageSchema: z.ZodType = z .transform(v => BigInt(v)) .optional(), status: z.string().optional(), - content: z.string().optional(), + content: z.string(), attachments: z .array(z.lazy(() => unmarshalGenieAttachmentSchema)) .optional(), query_result: z.lazy(() => unmarshalResultSchema).optional(), error: z.lazy(() => unmarshalMessageErrorSchema).optional(), - message_id: z.string().optional(), + message_id: z.string(), feedback: z.lazy(() => unmarshalGenieFeedbackSchema).optional(), }) .transform(d => ({ @@ -2421,15 +2431,15 @@ export const unmarshalGenieMessageSchema: z.ZodType = z export const unmarshalGenieMessageCommentSchema: z.ZodType = z .object({ - space_id: z.string().optional(), - conversation_id: z.string().optional(), - message_id: z.string().optional(), - message_comment_id: z.string().optional(), + space_id: z.string(), + conversation_id: z.string(), + message_id: z.string(), + message_comment_id: z.string(), user_id: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) .optional(), - content: z.string().optional(), + content: z.string(), created_timestamp: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) @@ -2493,8 +2503,8 @@ export const unmarshalGenieResultMetadataSchema: z.ZodType export const unmarshalGenieSpaceSchema: z.ZodType = z .object({ - space_id: z.string().optional(), - title: z.string().optional(), + space_id: z.string(), + title: z.string(), description: z.string().optional(), warehouse_id: z.string().optional(), parent_path: z.string().optional(), @@ -2524,9 +2534,9 @@ export const unmarshalGenieSpaceSchema: z.ZodType = z export const unmarshalGenieStartConversationResponseSchema: z.ZodType = z .object({ - message_id: z.string().optional(), + message_id: z.string(), message: z.lazy(() => unmarshalGenieMessageSchema).optional(), - conversation_id: z.string().optional(), + conversation_id: z.string(), conversation: z.lazy(() => unmarshalGenieConversationSchema).optional(), }) .transform(d => ({ @@ -2785,11 +2795,23 @@ export const unmarshalValueSchema: z.ZodType = z : undefined, })); +export const marshalGenieCancelResponseRequestSchema: z.ZodType = z + .object({ + agentId: z.string(), + conversationId: z.string(), + responseId: z.string(), + }) + .transform(d => ({ + agent_id: d.agentId, + conversation_id: d.conversationId, + response_id: d.responseId, + })); + export const marshalGenieCreateConversationMessageRequestSchema: z.ZodType = z .object({ - spaceId: z.string().optional(), - conversationId: z.string().optional(), - content: z.string().optional(), + spaceId: z.string(), + conversationId: z.string(), + content: z.string(), enableVisualization: z.boolean().optional(), }) .transform(d => ({ @@ -2801,7 +2823,7 @@ export const marshalGenieCreateConversationMessageRequestSchema: z.ZodType = z export const marshalGenieCreateEvalRunRequestSchema: z.ZodType = z .object({ - spaceId: z.string().optional(), + spaceId: z.string(), benchmarkQuestionIds: z.array(z.string()).optional(), }) .transform(d => ({ @@ -2811,10 +2833,10 @@ export const marshalGenieCreateEvalRunRequestSchema: z.ZodType = z export const marshalGenieCreateMessageCommentRequestSchema: z.ZodType = z .object({ - spaceId: z.string().optional(), - conversationId: z.string().optional(), - messageId: z.string().optional(), - content: z.string().optional(), + spaceId: z.string(), + conversationId: z.string(), + messageId: z.string(), + content: z.string(), }) .transform(d => ({ space_id: d.spaceId, @@ -2825,9 +2847,9 @@ export const marshalGenieCreateMessageCommentRequestSchema: z.ZodType = z export const marshalGenieCreateSpaceRequestSchema: z.ZodType = z .object({ - warehouseId: z.string().optional(), + warehouseId: z.string(), parentPath: z.string().optional(), - serializedSpace: z.string().optional(), + serializedSpace: z.string(), title: z.string().optional(), description: z.string().optional(), }) @@ -2842,10 +2864,10 @@ export const marshalGenieCreateSpaceRequestSchema: z.ZodType = z export const marshalGenieExecuteMessageAttachmentQueryRequestSchema: z.ZodType = z .object({ - messageId: z.string().optional(), - spaceId: z.string().optional(), - conversationId: z.string().optional(), - attachmentId: z.string().optional(), + messageId: z.string(), + spaceId: z.string(), + conversationId: z.string(), + attachmentId: z.string(), }) .transform(d => ({ message_id: d.messageId, @@ -2856,9 +2878,9 @@ export const marshalGenieExecuteMessageAttachmentQueryRequestSchema: z.ZodType = export const marshalGenieExecuteMessageQueryRequestSchema: z.ZodType = z .object({ - messageId: z.string().optional(), - spaceId: z.string().optional(), - conversationId: z.string().optional(), + messageId: z.string(), + spaceId: z.string(), + conversationId: z.string(), }) .transform(d => ({ message_id: d.messageId, @@ -2869,10 +2891,10 @@ export const marshalGenieExecuteMessageQueryRequestSchema: z.ZodType = z export const marshalGenieGenerateDownloadFullQueryResultRequestSchema: z.ZodType = z .object({ - spaceId: z.string().optional(), - conversationId: z.string().optional(), - messageId: z.string().optional(), - attachmentId: z.string().optional(), + spaceId: z.string(), + conversationId: z.string(), + messageId: z.string(), + attachmentId: z.string(), }) .transform(d => ({ space_id: d.spaceId, @@ -2883,10 +2905,10 @@ export const marshalGenieGenerateDownloadFullQueryResultRequestSchema: z.ZodType export const marshalGenieSendMessageFeedbackRequestSchema: z.ZodType = z .object({ - spaceId: z.string().optional(), - conversationId: z.string().optional(), - messageId: z.string().optional(), - rating: z.string().optional(), + spaceId: z.string(), + conversationId: z.string(), + messageId: z.string(), + rating: z.string(), comment: z.string().optional(), }) .transform(d => ({ @@ -2899,8 +2921,8 @@ export const marshalGenieSendMessageFeedbackRequestSchema: z.ZodType = z export const marshalGenieStartConversationRequestSchema: z.ZodType = z .object({ - spaceId: z.string().optional(), - content: z.string().optional(), + spaceId: z.string(), + content: z.string(), enableVisualization: z.boolean().optional(), }) .transform(d => ({ @@ -2911,7 +2933,7 @@ export const marshalGenieStartConversationRequestSchema: z.ZodType = z export const marshalGenieUpdateSpaceRequestSchema: z.ZodType = z .object({ - spaceId: z.string().optional(), + spaceId: z.string(), serializedSpace: z.string().optional(), title: z.string().optional(), description: z.string().optional(), diff --git a/packages/gitcredentials/src/v1/model.ts b/packages/gitcredentials/src/v1/model.ts index b9b7d6d8b..bfd2778d0 100644 --- a/packages/gitcredentials/src/v1/model.ts +++ b/packages/gitcredentials/src/v1/model.ts @@ -9,7 +9,7 @@ export interface CreateCredentialsRequest { * Microsoft Entra ID authentication), `gitHubEnterprise`, `bitbucketServer` (Bitbucket * Data Center), `gitLabEnterpriseEdition` (GitLab Self-Managed), and `awsCodeCommit`. */ - gitProvider?: string | undefined; + gitProvider: string; /** * The username provided with your Git provider account and associated with the * credential. For most Git providers it is only used to set the Git committer & author names for commits, @@ -40,9 +40,9 @@ export interface CreateCredentialsRequest { export interface CreateCredentialsResponse { /** ID of the credential object in the workspace. */ - credentialId?: bigint | undefined; + credentialId: bigint; /** The Git provider associated with the credential. */ - gitProvider?: string | undefined; + gitProvider: string; /** * The username provided with your Git provider account and associated with the * credential. For most Git providers it is only used to set the Git committer & author names for commits, @@ -65,7 +65,7 @@ export interface CreateCredentialsResponse { export interface Credential { /** ID of the credential object in the workspace. */ - credentialId?: bigint | undefined; + credentialId: bigint; /** * The Git provider associated with the credential. One of `gitHub`, `bitbucketCloud`, * `gitLab`, `azureDevOpsServices` (Azure DevOps Services, including Microsoft Entra ID @@ -95,7 +95,7 @@ export interface Credential { export interface DeleteCredentialsRequest { /** The ID for the corresponding credential to access. */ - id?: bigint | undefined; + id: bigint; /** The ID of the service principal whose credentials will be modified. Only service principal managers can perform this action. */ principalId?: bigint | undefined; } @@ -105,14 +105,14 @@ export interface DeleteCredentialsResponse {} export interface GetCredentialsRequest { /** The ID for the corresponding credential to access. */ - id?: bigint | undefined; + id: bigint; /** The ID of the service principal whose credentials will be modified. Only service principal managers can perform this action. */ principalId?: bigint | undefined; } export interface GetCredentialsResponse { /** ID of the credential object in the workspace. */ - credentialId?: bigint | undefined; + credentialId: bigint; /** The Git provider associated with the credential. */ gitProvider?: string | undefined; /** @@ -147,7 +147,7 @@ export interface ListCredentialsResponse { export interface UpdateCredentialsRequest { /** The ID for the corresponding credential to access. */ - id?: bigint | undefined; + id: bigint; /** * The personal access token used to authenticate to the corresponding Git provider. * For certain providers, support may exist for other types of scoped access tokens. @@ -160,7 +160,7 @@ export interface UpdateCredentialsRequest { * Microsoft Entra ID authentication), `gitHubEnterprise`, `bitbucketServer` (Bitbucket * Data Center), `gitLabEnterpriseEdition` (GitLab Self-Managed), and `awsCodeCommit`. */ - gitProvider?: string | undefined; + gitProvider: string; /** * The username provided with your Git provider account and associated with the * credential. For most Git providers it is only used to set the Git committer & author names for commits, @@ -191,9 +191,8 @@ export const unmarshalCreateCredentialsResponseSchema: z.ZodType BigInt(v)) - .optional(), - git_provider: z.string().optional(), + .transform(v => BigInt(v)), + git_provider: z.string(), git_username: z.string().optional(), name: z.string().optional(), is_default_for_provider: z.boolean().optional(), @@ -212,8 +211,7 @@ export const unmarshalCredentialSchema: z.ZodType = z .object({ credential_id: z .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), + .transform(v => BigInt(v)), git_provider: z.string().optional(), git_username: z.string().optional(), name: z.string().optional(), @@ -237,8 +235,7 @@ export const unmarshalGetCredentialsResponseSchema: z.ZodType BigInt(v)) - .optional(), + .transform(v => BigInt(v)), git_provider: z.string().optional(), git_username: z.string().optional(), name: z.string().optional(), @@ -268,7 +265,7 @@ export const unmarshalUpdateCredentialsResponseSchema: z.ZodType btoa(Array.from(d, b => String.fromCharCode(b)).join('')) - ) - .optional(), + ), position: z.number().optional(), enabled: z.boolean().optional(), }) @@ -168,14 +167,13 @@ export const marshalCreateGlobalInitScriptRequestSchema: z.ZodType = z export const marshalUpdateGlobalInitScriptRequestSchema: z.ZodType = z .object({ - scriptId: z.string().optional(), - name: z.string().optional(), + scriptId: z.string(), + name: z.string(), script: z .any() .transform((d: Uint8Array) => btoa(Array.from(d, b => String.fromCharCode(b)).join('')) - ) - .optional(), + ), position: z.number().optional(), enabled: z.boolean().optional(), }) diff --git a/packages/instancepools/src/v2/model.ts b/packages/instancepools/src/v2/model.ts index ef7595c15..74bb3ab94 100644 --- a/packages/instancepools/src/v2/model.ts +++ b/packages/instancepools/src/v2/model.ts @@ -195,7 +195,7 @@ export interface CreateInstancePoolResponse { export interface DeleteInstancePoolRequest { /** The instance pool to be terminated. */ - instancePoolId?: string | undefined; + instancePoolId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -276,7 +276,7 @@ export interface DockerImage { export interface EditInstancePoolRequest { /** Instance pool ID */ - instancePoolId?: string | undefined; + instancePoolId: string; /** * Pool name requested by the user. Pool name must be unique. Length must be between 1 and 100 * characters. @@ -358,7 +358,7 @@ export interface EditInstancePoolResponse {} export interface GetInstancePoolRequest { /** The canonical unique identifier for the instance pool. */ - instancePoolId?: string | undefined; + instancePoolId: string; } export interface GetInstancePoolResponse { @@ -680,6 +680,11 @@ export interface ListInstancePoolsResponse { export interface NodeTypeFlexibility { /** A list of node type IDs to use as fallbacks when the primary node type is unavailable. */ alternateNodeTypeIds?: string[] | undefined; + /** + * The AWS Context ID for EC2 Fleet. + * When set (non-empty), the value is passed to AWS CreateFleet API to create the EC2 Fleet. + */ + awsContextId?: string | undefined; } /** Error message of a failed pending instances */ @@ -960,9 +965,11 @@ export const unmarshalNodeTypeFlexibilitySchema: z.ZodType z .object({ alternate_node_type_ids: z.array(z.string()).optional(), + aws_context_id: z.string().optional(), }) .transform(d => ({ alternateNodeTypeIds: d.alternate_node_type_ids, + awsContextId: d.aws_context_id, })); export const unmarshalPendingInstanceErrorSchema: z.ZodType = @@ -1026,7 +1033,7 @@ export const marshalCreateInstancePoolRequestSchema: z.ZodType = z export const marshalDeleteInstancePoolRequestSchema: z.ZodType = z .object({ - instancePoolId: z.string().optional(), + instancePoolId: z.string(), }) .transform(d => ({ instance_pool_id: d.instancePoolId, @@ -1103,7 +1110,7 @@ export const marshalDockerImageSchema: z.ZodType = z export const marshalEditInstancePoolRequestSchema: z.ZodType = z .object({ - instancePoolId: z.string().optional(), + instancePoolId: z.string(), instancePoolName: z.string().optional(), minIdleInstances: z.number().optional(), maxCapacity: z.number().optional(), @@ -1192,7 +1199,9 @@ export const marshalInstancePoolGcpAttributesSchema: z.ZodType = z export const marshalNodeTypeFlexibilitySchema: z.ZodType = z .object({ alternateNodeTypeIds: z.array(z.string()).optional(), + awsContextId: z.string().optional(), }) .transform(d => ({ alternate_node_type_ids: d.alternateNodeTypeIds, + aws_context_id: d.awsContextId, })); diff --git a/packages/instanceprofiles/src/v2/model.ts b/packages/instanceprofiles/src/v2/model.ts index c08e593ec..74b07efae 100644 --- a/packages/instanceprofiles/src/v2/model.ts +++ b/packages/instanceprofiles/src/v2/model.ts @@ -13,7 +13,7 @@ export interface AddInstanceProfileRequest { */ skipValidation?: boolean | undefined; /** The AWS ARN of the instance profile to register with . This field is required. */ - instanceProfileArn?: string | undefined; + instanceProfileArn: string; /** * Boolean flag indicating whether the instance profile should only be used in credential * passthrough scenarios. If true, it means the instance profile contains an meta IAM role @@ -38,7 +38,7 @@ export interface AddInstanceProfileResponse {} export interface EditInstanceProfileRequest { /** The AWS ARN of the instance profile to register with . This field is required. */ - instanceProfileArn?: string | undefined; + instanceProfileArn: string; /** * Boolean flag indicating whether the instance profile should only be used in credential * passthrough scenarios. If true, it means the instance profile contains an meta IAM role @@ -63,7 +63,7 @@ export interface EditInstanceProfileResponse {} export interface InstanceProfile { /** The AWS ARN of the instance profile to register with . This field is required. */ - instanceProfileArn?: string | undefined; + instanceProfileArn: string; /** * Boolean flag indicating whether the instance profile should only be used in credential * passthrough scenarios. If true, it means the instance profile contains an meta IAM role @@ -93,7 +93,7 @@ export interface ListInstanceProfilesResponse { export interface RemoveInstanceProfileRequest { /** The ARN of the instance profile to remove. This field is required. */ - instanceProfileArn?: string | undefined; + instanceProfileArn: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -107,7 +107,7 @@ export const unmarshalEditInstanceProfileResponseSchema: z.ZodType = z .object({ - instance_profile_arn: z.string().optional(), + instance_profile_arn: z.string(), is_meta_instance_profile: z.boolean().optional(), iam_role_arn: z.string().optional(), }) @@ -134,7 +134,7 @@ export const unmarshalRemoveInstanceProfileResponseSchema: z.ZodType ({ instance_profile_arn: d.instanceProfileArn, diff --git a/packages/jobs/src/v2/index.ts b/packages/jobs/src/v2/index.ts index 403ec3d58..260da5212 100644 --- a/packages/jobs/src/v2/index.ts +++ b/packages/jobs/src/v2/index.ts @@ -19,6 +19,7 @@ export { ComputeKind, ConfidentialComputeType, DataSecurityMode, + DayOfWeek, DbtPlatformRunStatus, DependencyMode, EbsVolumeType, @@ -162,6 +163,7 @@ export type { ListRunsResponse, LocalFileInfo, LogAnalyticsInfo, + MaintenanceWindow, MavenLibrary, ModelTriggerConfiguration, ModelTriggerState, diff --git a/packages/jobs/src/v2/model.ts b/packages/jobs/src/v2/model.ts index c5538e360..c3a0ac601 100644 --- a/packages/jobs/src/v2/model.ts +++ b/packages/jobs/src/v2/model.ts @@ -151,6 +151,30 @@ export type DataSecurityMode = | (typeof DataSecurityMode)[keyof typeof DataSecurityMode] | (string & {}); +/** Days of week that can be referenced by Jobs scheduling settings. */ +// eslint-disable-next-line @typescript-eslint/naming-convention -- Enum-style const object. +export const DayOfWeek = { + /** No specific day of week is specified. */ + DAY_OF_WEEK_UNSPECIFIED: 'DAY_OF_WEEK_UNSPECIFIED', + /** The day of week is Monday. */ + MONDAY: 'MONDAY', + /** The day of week is Tuesday. */ + TUESDAY: 'TUESDAY', + /** The day of week is Wednesday. */ + WEDNESDAY: 'WEDNESDAY', + /** The day of week is Thursday. */ + THURSDAY: 'THURSDAY', + /** The day of week is Friday. */ + FRIDAY: 'FRIDAY', + /** The day of week is Saturday. */ + SATURDAY: 'SATURDAY', + /** The day of week is Sunday. */ + SUNDAY: 'SUNDAY', +} as const; +export type DayOfWeek = + | (typeof DayOfWeek)[keyof typeof DayOfWeek] + | (string & {}); + /** Response enumeration from calling the dbt platform API, for inclusion in output */ // eslint-disable-next-line @typescript-eslint/naming-convention -- Enum-style const object. export const DbtPlatformRunStatus = { @@ -231,6 +255,8 @@ export const HardwareAcceleratorType = { GPU_1X_A10: 'GPU_1xA10', /** GPU_8xH100: 8x H100 GPU configuration. */ GPU_8X_H100: 'GPU_8xH100', + /** GPU_1xH100: Single H100 GPU configuration. */ + GPU_1X_H100: 'GPU_1xH100', } as const; export type HardwareAcceleratorType = | (typeof HardwareAcceleratorType)[keyof typeof HardwareAcceleratorType] @@ -936,7 +962,7 @@ export interface AccessControlRequest { /** A storage location in Adls Gen2 */ export interface Adlsgen2Info { /** abfss destination, e.g. `abfss://@.dfs.core.windows.net/`. */ - destination?: string | undefined; + destination: string; } /** @@ -957,7 +983,7 @@ export interface AiRuntimeTask { * storage location (for example, when running as a service principal), set * `mlflow_experiment_directory`. */ - experiment?: string | undefined; + experiment: string; /** * Deployment specs for this task. Exactly one deployment is currently * supported (a single entry where every node runs the same command); this @@ -965,7 +991,7 @@ export interface AiRuntimeTask { * parameter server, separate eval node, etc.) with multiple entries are the * eventual intent but not yet supported. */ - deployments?: DeploymentSpec[] | undefined; + deployments: DeploymentSpec[]; /** * Workspace or UC volume path of the code-source archive, unpacked on * each node and exposed through `$CODE_SOURCE`. Set by first-party @@ -1048,6 +1074,15 @@ export interface AlertTask { * The number of subscriptions is limited to 100. */ subscribers?: AlertTaskSubscriber[] | undefined; + /** + * Per-run parameter overrides, keyed by parameter name, applied onto the alert's stored + * query parameters before the query is executed. Only scalar values are supported. Values + * may reference job parameters with `{{job.parameters.*}}`, which are resolved before the + * task runs. An override whose key does not match a stored parameter fails the task run. + * Limited to 10000 characters when serialized as JSON; keys must be 1-100 characters and + * contain only letters, digits, underscores, dashes, and periods. + */ + parameters?: Record | undefined; } export interface AlertTaskOutput { @@ -1362,7 +1397,7 @@ export interface CancelAllRunsResponse {} export interface CancelRunRequest { /** This field is required. */ - runId?: bigint | undefined; + runId: bigint; } /** Run was cancelled successfully. */ @@ -1393,9 +1428,9 @@ export interface CleanRoomTaskRunState { */ export interface CleanRoomsNotebookTask { /** The clean room that the notebook belongs to. */ - cleanRoomName?: string | undefined; + cleanRoomName: string; /** Name of the notebook being run. */ - notebookName?: string | undefined; + notebookName: string; /** * Checksum to validate the freshness of the notebook resource (i.e. the notebook being run is the latest version). * It can be fetched by calling the :method:cleanroomassets/get API. @@ -1683,7 +1718,7 @@ export interface Compute { export interface ComputeConfig { /** Number of GPUs. */ - numGpus?: number | undefined; + numGpus: number; /** IDof the GPU pool to use. */ gpuNodePoolId?: string | undefined; /** GPU type. */ @@ -1700,14 +1735,14 @@ export interface ComputeSpec { * The number of accelerators per node is encoded in the enum value — * `GPU_8xH100` means 8 H100 GPUs per node. */ - acceleratorType?: ComputeSpec_AcceleratorType | undefined; + acceleratorType: ComputeSpec_AcceleratorType; /** * Total number of accelerators across all nodes. Must be a positive * multiple of the per-node accelerator count encoded in `accelerator_type`. * For example, `GPU_8xH100` with `accelerator_count: 16` allocates 2 nodes * (8 GPUs per node). */ - acceleratorCount?: number | undefined; + acceleratorCount: number; } export interface ConditionTask { @@ -1717,11 +1752,11 @@ export interface ConditionTask { * * The boolean comparison to task values can be implemented with operators `EQUAL_TO`, `NOT_EQUAL`. If a task value was set to a boolean value, it will be serialized to `“true”` or `“false”` for the comparison. */ - op?: ConditionTask_ConditionTaskOperator | undefined; + op: ConditionTask_ConditionTaskOperator; /** The left operand of the condition task. Can be either a string value or a job state or parameter reference. */ - left?: string | undefined; + left: string; /** The right operand of the condition task. Can be either a string value or a job state or parameter reference. */ - right?: string | undefined; + right: string; /** The condition expression evaluation result. Filled in if the task was successfully completed. Can be `"true"` or `"false"` */ outcome?: string | undefined; } @@ -1731,6 +1766,8 @@ export interface ContinuousSettings { pauseStatus?: SchedulePauseStatus | undefined; /** Indicate whether the continuous job is applying task level retries or not. Defaults to NEVER. */ taskRetryMode?: TaskRetryMode | undefined; + /** Defines when platform-initiated maintenance may run for this job. If unspecified, maintenance may run at any time. */ + maintenanceWindow?: MaintenanceWindow | undefined; } /** @@ -1740,6 +1777,11 @@ export interface ContinuousSettings { export interface ContinuousTriggerConfiguration { /** Whether the continuous job applies task-level retries. Defaults to NEVER. */ taskRetryMode?: TaskRetryMode | undefined; + /** + * Defines when platform-initiated maintenance may run for this trigger. If unspecified, + * maintenance may run at any time. + */ + maintenanceWindow?: MaintenanceWindow | undefined; } export interface ContinuousTriggerState { @@ -1876,9 +1918,9 @@ export interface CreateJobResponse { export interface CronSchedule { /** A Cron expression using Quartz syntax that describes the schedule for a job. See [Cron Trigger](http://www.quartz-scheduler.org/documentation/quartz-2.3.0/tutorials/crontrigger.html) for details. This field is required. */ - quartzCronExpression?: string | undefined; + quartzCronExpression: string; /** A Java timezone ID. The schedule for a job is resolved with respect to this timezone. See [Java TimeZone](https://docs.oracle.com/javase/7/docs/api/java/util/TimeZone.html) for details. This field is required. */ - timezoneId?: string | undefined; + timezoneId: string; /** Indicate whether this schedule is paused or not. */ pauseStatus?: SchedulePauseStatus | undefined; /** @@ -1897,12 +1939,12 @@ export interface CronTriggerConfiguration { * A Cron expression using Quartz syntax that describes the schedule for this trigger. See * [Cron Trigger](http://www.quartz-scheduler.org/documentation/quartz-2.3.0/tutorials/crontrigger.html) for details. */ - quartzCronExpression?: string | undefined; + quartzCronExpression: string; /** * A Java timezone ID. The schedule is resolved with respect to this timezone. See * [Java TimeZone](https://docs.oracle.com/javase/7/docs/api/java/util/TimeZone.html) for details. */ - timezoneId?: string | undefined; + timezoneId: string; } export interface DashboardPageSnapshot { @@ -1940,7 +1982,7 @@ export interface DashboardTaskOutput { /** A storage location in DBFS */ export interface DbfsStorageInfo { /** dbfs destination, e.g. `dbfs:/my/path` */ - destination?: string | undefined; + destination: string; } /** @@ -2017,7 +2059,7 @@ export interface DbtTask { */ projectDirectory?: string | undefined; /** A list of dbt commands to execute. All commands must start with `dbt`. This parameter must not be empty. A maximum of up to 10 commands can be provided. */ - commands?: string[] | undefined; + commands: string[]; /** Optional schema to write to. This parameter is only used when a warehouse_id is also provided. If not provided, the `default` schema is used. */ schema?: string | undefined; /** ID of the SQL warehouse to connect to. If provided, we automatically generate and provide the profile and connection details to dbt. It can be overridden on a per-command basis by using the `--profiles-dir` command line argument. */ @@ -2047,7 +2089,7 @@ export interface DbtTask_DbtTaskOutput { export interface DeleteJobRequest { /** The canonical identifier of the job to delete. This field is required. */ - jobId?: bigint | undefined; + jobId: bigint; } /** Job was deleted successfully. */ @@ -2056,7 +2098,7 @@ export interface DeleteJobResponse {} export interface DeleteRunRequest { /** ID of the run to delete. */ - runId?: bigint | undefined; + runId: bigint; } /** Run was deleted successfully. */ @@ -2089,9 +2131,9 @@ export interface DeploymentSpec { * # Distributed via torchrun: * torchrun --nproc_per_node=8 train.py */ - commandPath?: string | undefined; + commandPath: string; /** Compute resources allocated to each node in this deployment. */ - compute?: ComputeSpec | undefined; + compute: ComputeSpec; /** * Optional human-readable name for this deployment (for example, `driver`, * `worker`, `param_server`). Used for log and UI display. Distinct names @@ -2122,7 +2164,7 @@ export interface DockerImage { export interface EnforcePolicyComplianceForJob { /** The ID of the job you want to enforce policy compliance on. */ - jobId?: bigint | undefined; + jobId: bigint; /** * If set, previews changes made to the job to comply with its policy, but * does not update the job. @@ -2216,7 +2258,7 @@ export interface Environment { /** Retrieves the export of a job run task. */ export interface ExportRunRequest { /** The canonical identifier for the run. This field is required. */ - runId?: bigint | undefined; + runId: bigint; /** Which views to export (CODE, DASHBOARDS, or ALL). Defaults to CODE. */ viewsToExport?: ViewsToExport | undefined; } @@ -2229,7 +2271,7 @@ export interface ExportRunResponse { export interface FileArrivalTriggerConfiguration { /** URL to be monitored for file arrivals. The path must point to the root or a subpath of the external location. */ - url?: string | undefined; + url: string; /** * If set, the trigger starts a run only after the specified amount of time passed since * the last time the trigger fired. The minimum allowed value is 60 seconds @@ -2253,14 +2295,14 @@ export interface ForEachTask { * Array for task to iterate on. This can be a JSON string or a reference to * an array parameter. */ - inputs?: string | undefined; + inputs: string; /** * An optional maximum allowed number of concurrent runs of the task. * Set this value if you want to be able to execute multiple runs of the task concurrently. */ concurrency?: number | undefined; /** Configuration for the task that will be run for each element in the array */ - task?: TaskSettings | undefined; + task: TaskSettings; } /** Attributes set during cluster creation which are related to GCP. */ @@ -2323,7 +2365,7 @@ export interface GcpAttributes { /** A storage location in Google Cloud Platform's GCS */ export interface GcsStorageInfo { /** GCS destination/URI, e.g. `gs://my-bucket/some-prefix` */ - destination?: string | undefined; + destination: string; } /** @@ -2336,7 +2378,7 @@ export interface GcsStorageInfo { */ export interface GenAiComputeTask { /** Runtime image */ - dlRuntimeImage?: string | undefined; + dlRuntimeImage: string; compute?: ComputeConfig | undefined; /** Command launcher to run the actual script, e.g. bash, python etc. */ command?: string | undefined; @@ -2366,7 +2408,7 @@ export interface GenAiComputeTask { /** Retrieves information about a single job. */ export interface GetJobRequest { /** The canonical identifier of the job to retrieve information about. This field is required. */ - jobId?: bigint | undefined; + jobId: bigint; /** Flag that indicates that trigger state should be included in the response. */ includeTriggerState?: boolean | undefined; /** Use `next_page_token` returned from the previous GetJob response to request the next page of the job's array properties. */ @@ -2419,7 +2461,7 @@ export interface GetJobResponse { export interface GetPolicyComplianceForJobRequest { /** The ID of the job whose compliance status you are requesting. */ - jobId?: bigint | undefined; + jobId: bigint; } export interface GetPolicyComplianceForJobResponse { @@ -2443,7 +2485,7 @@ export interface GetPolicyComplianceForJobResponse { /** Retrieves both the output and the metadata of a run. */ export interface GetRunOutputRequest { /** The canonical identifier for the run. */ - runId?: bigint | undefined; + runId: bigint; } /** Run output was retrieved successfully. */ @@ -2533,7 +2575,7 @@ export interface GetRunRequest { * The canonical identifier of the run for which to retrieve the metadata. * This field is required. */ - runId?: bigint | undefined; + runId: bigint; /** Whether to include the repair history in the response. */ includeHistory?: boolean | undefined; /** Whether to include resolved parameter values in the response. */ @@ -2663,9 +2705,9 @@ export interface GitMetadataSnapshot { */ export interface GitSource { /** URL of the repository to be cloned by this job. */ - gitUrl?: string | undefined; + gitUrl: string; /** Unique identifier of the service used to host the Git repository. The value is case insensitive. */ - gitProvider?: string | undefined; + gitProvider: string; gitReference?: | { $case: 'gitBranch'; @@ -2758,7 +2800,7 @@ export interface JobCluster { * A unique name for the job cluster. This field is required and must be unique within the job. * `JobTaskSettings` may refer to this field to determine which cluster to launch for the task execution. */ - jobClusterKey?: string | undefined; + jobClusterKey: string; /** If new_cluster, a description of a cluster that is created for each task. */ newCluster?: ClusterSpec_NewCluster | undefined; /** @@ -2776,7 +2818,7 @@ export interface JobDeployment { * * `BUNDLE`: The job is managed by Databricks Asset Bundle. * * `SYSTEM_MANAGED`: The job is managed by and is read-only. */ - kind?: JobDeployment_DeploymentKind | undefined; + kind: JobDeployment_DeploymentKind; /** Path of the file that contains deployment metadata. */ metadataFilePath?: string | undefined; /** @@ -2817,15 +2859,15 @@ export interface JobEmailNotifications { export interface JobEnvironment { /** The key of an environment. It has to be unique within a job. */ - environmentKey?: string | undefined; + environmentKey: string; spec?: Environment | undefined; } export interface JobLevelParameter { /** The name of the defined parameter. May only contain alphanumeric characters, `_`, `-`, and `.` */ - name?: string | undefined; + name: string; /** Default value of the parameter. */ - default?: string | undefined; + default: string; } /** @@ -2974,7 +3016,7 @@ export interface JobSettings { /** The source of the job specification in the remote repository when the job is source controlled. */ export interface JobSource { /** Path of the job YAML file that contains the job specification. */ - jobConfigPath?: string | undefined; + jobConfigPath: string; importFromGitReference?: | { $case: 'importFromGitBranch'; @@ -2993,10 +3035,10 @@ export interface JobSource { } export interface JobsHealthRule { - metric?: JobsHealthMetric | undefined; - op?: JobsHealthOperator | undefined; + metric: JobsHealthMetric; + op: JobsHealthOperator; /** Specifies the threshold value that the health metric should obey to satisfy the health rule. */ - value?: bigint | undefined; + value: bigint; } /** An optional set of health rules that can be defined for this job. */ @@ -3067,7 +3109,7 @@ export interface Library { export interface ListJobComplianceForPolicy { /** Canonical unique identifier for the cluster policy. */ - policyId?: string | undefined; + policyId: string; /** * A page token that can be used to navigate to the next page or previous page as * returned by `next_page_token` or `prev_page_token`. @@ -3084,7 +3126,7 @@ export interface ListJobComplianceForPolicy { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface ListJobComplianceForPolicy_JobCompliance { /** Canonical unique identifier for a job. */ - jobId?: bigint | undefined; + jobId: bigint; /** Whether this job is in compliance with the latest version of its policy. */ isCompliant?: boolean | undefined; /** @@ -3214,7 +3256,7 @@ export interface ListRunsResponse { export interface LocalFileInfo { /** local file destination, e.g. `file:/my/local/file.sh` */ - destination?: string | undefined; + destination: string; } export interface LogAnalyticsInfo { @@ -3222,9 +3264,26 @@ export interface LogAnalyticsInfo { logAnalyticsPrimaryKey?: string | undefined; } +/** + * A recurring weekly time window during which platform-initiated maintenance is + * allowed to run for a continuous job. + */ +export interface MaintenanceWindow { + /** + * An integer between 0 and 23 denoting the start hour for the maintenance window in the 24-hour day. + * Platform-initiated maintenance is triggered only within a one-hour window starting at this hour. + * This field is required. + */ + startHour: number; + /** The day of week on which maintenance is allowed to happen. This field is required. */ + dayOfWeek: DayOfWeek; + /** A Java timezone ID. The maintenance window is resolved with respect to this timezone. See [Java TimeZone](https://docs.oracle.com/javase/7/docs/api/java/util/TimeZone.html) for details. This field is required. */ + timezoneId: string; +} + export interface MavenLibrary { /** Gradle-style maven coordinates. For example: "org.jsoup:jsoup:1.7.2". */ - coordinates?: string | undefined; + coordinates: string; /** * Maven repo to install the Maven package from. If omitted, both Maven Central Repository * and Spark Packages are searched. @@ -3248,7 +3307,7 @@ export interface ModelTriggerConfiguration { /** Aliases of the model versions to monitor. Can only be used in conjunction with condition MODEL_ALIAS_SET. */ aliases?: string[] | undefined; /** The condition based on which to trigger a job run. */ - condition?: ModelTriggerConfiguration_ModelTriggerCondition | undefined; + condition: ModelTriggerConfiguration_ModelTriggerCondition; /** * If set, the trigger starts a run only after the specified amount of time has passed since * the last time the trigger fired. The minimum allowed value is 60 seconds. @@ -3273,6 +3332,11 @@ export interface ModelTriggerState {} export interface NodeTypeFlexibility { /** A list of node type IDs to use as fallbacks when the primary node type is unavailable. */ alternateNodeTypeIds?: string[] | undefined; + /** + * The AWS Context ID for EC2 Fleet. + * When set (non-empty), the value is passed to AWS CreateFleet API to create the EC2 Fleet. + */ + awsContextId?: string | undefined; } export interface NotebookTask { @@ -3281,7 +3345,7 @@ export interface NotebookTask { * For notebooks stored in the workspace, the path must be absolute and begin with a slash. * For notebooks stored in a remote repository, the path must be relative. This field is required. */ - notebookPath?: string | undefined; + notebookPath: string; /** * Base parameters to be used for each run of this job. If the run is initiated by a call to :method:jobs/run * Now with parameters specified, the two parameters maps are merged. If the same key is specified in @@ -3348,7 +3412,7 @@ export interface OutputSchemaInfo { */ export interface PerTriggerState { /** - * (-- Next ID: 9. --) + * (-- Next ID: 10. --) * Runtime-state variant for the corresponding trigger; exactly one field is set, * matching the trigger's type in `TriggerConfiguration`. */ @@ -3371,9 +3435,9 @@ export interface PerformanceTarget {} export interface PeriodicTriggerConfiguration { /** The interval at which the trigger should run. */ - interval?: number | undefined; + interval: number; /** The unit of time for the interval. */ - unit?: PeriodicTriggerConfiguration_TimeUnit | undefined; + unit: PeriodicTriggerConfiguration_TimeUnit; } export interface PeriodicTriggerState { @@ -3398,7 +3462,7 @@ export interface PipelineParameters { export interface PipelineTask { /** The full name of the pipeline task to execute. */ - pipelineId?: string | undefined; + pipelineId: string; /** * Key/value-map of parameters passed to the pipeline execution. * Limited to 10k characters in total. @@ -3480,7 +3544,7 @@ export interface PythonPyPiLibrary { * The name of the pypi package to install. An optional exact version specification is also * supported. Examples: "simplejson" and "simplejson==3.8.0". */ - package?: string | undefined; + package: string; /** * The repository where the package can be found. If not specified, the default pip index is * used. @@ -3490,9 +3554,9 @@ export interface PythonPyPiLibrary { export interface PythonWheelTask { /** Name of the package to execute */ - packageName?: string | undefined; + packageName: string; /** Named entry point to use, if it does not exist in the metadata of the package it executes the function from the package directly using `$packageName.$entryPoint()` */ - entryPoint?: string | undefined; + entryPoint: string; /** Command-line parameters passed to Python wheel task. Leave it empty if `named_parameters` is not null. */ parameters?: string[] | undefined; /** Command-line parameters passed to Python wheel task in the form of `["--name=task", "--data=dbfs:/path/to/data.json"]`. Leave it empty if `parameters` is not null. */ @@ -3513,12 +3577,12 @@ export interface QueueDetailsCode {} export interface QueueSettings { /** If true, enable queueing for the job. This is a required field. */ - enabled?: boolean | undefined; + enabled: boolean; } export interface RCranLibrary { /** The name of the CRAN package to install. */ - package?: string | undefined; + package: string; /** The repository where the package can be found. If not specified, the default CRAN repo is used. */ repo?: string | undefined; } @@ -3548,7 +3612,7 @@ export interface Repair { export interface RepairRunRequest { /** The job run ID of the run to repair. The run must not be in progress. */ - runId?: bigint | undefined; + runId: bigint; /** The ID of the latest repair. This parameter is not required when repairing a run for the first time, but must be provided on subsequent requests to repair the same run. */ latestRepairId?: bigint | undefined; /** The task keys of the task runs to repair. */ @@ -3642,13 +3706,13 @@ export interface RepairRunResponse { export interface ResetJobRequest { /** The canonical identifier of the job to reset. This field is required. */ - jobId?: bigint | undefined; + jobId: bigint; /** * The new settings of the job. These settings completely replace the old settings. * * Changes to the field `JobBaseSettings.timeout_seconds` are applied to active runs. Changes to other fields are applied to future runs only. */ - newSettings?: JobSettings | undefined; + newSettings: JobSettings; } /** Job was overwritten successfully. */ @@ -3885,7 +3949,7 @@ export interface Run_JobLevelParameters { export interface RunJobTask { /** ID of the job to trigger. */ - jobId?: bigint | undefined; + jobId: bigint; /** Job-level parameters used to trigger the job. */ jobParameters?: Record | undefined; /** Controls whether the pipeline should perform a full refresh */ @@ -3970,7 +4034,7 @@ export interface RunLifecycleStateV2 {} export interface RunNowRequest { /** The ID of the job to be executed */ - jobId?: bigint | undefined; + jobId: bigint; /** Job-level parameters used in the run. for example `"param": "overriding_val"` */ jobParameters?: Record | undefined; /** @@ -4205,7 +4269,7 @@ export interface RunTask { * This field is required and must be unique within its parent job. * On Update or Reset, this field is used to reference the tasks to be updated or reset. */ - taskKey?: string | undefined; + taskKey: string; /** An optional description for this task. */ description?: string | undefined; /** @@ -4403,7 +4467,7 @@ export interface RunTaskSettings { * This field is required and must be unique within its parent job. * On Update or Reset, this field is used to reference the tasks to be updated or reset. */ - taskKey?: string | undefined; + taskKey: string; /** An optional description for this task. */ description?: string | undefined; /** @@ -4596,7 +4660,7 @@ export interface S3StorageInfo { * cluster iam role, please make sure you set cluster iam role and the role has write access to the * destination. Please also note that you cannot use AWS keys to deliver logs. */ - destination?: string | undefined; + destination: string; /** * S3 region, e.g. `us-west-2`. Either region or endpoint needs to be set. If both are set, * endpoint will be used. @@ -4660,7 +4724,7 @@ export interface SparkJarTask { export interface SparkPythonTask { /** The Python file to be executed. Cloud file URIs (such as dbfs:/, s3:/, adls:/, gcs:/) and workspace paths are supported. For python files stored in the workspace, the path must be absolute and begin with `/`. For files stored in a remote repository, the path must be relative. This field is required. */ - pythonFile?: string | undefined; + pythonFile: string; /** * Command line parameters passed to the Python file. * @@ -4697,9 +4761,9 @@ export interface SqlAlertState {} export interface SqlConditionConfiguration { /** The ID of the SQL query to evaluate as the trigger condition. */ - sqlQueryId?: string | undefined; + sqlQueryId: string; /** The canonical identifier of the SQL warehouse to run the condition query against. */ - warehouseId?: string | undefined; + warehouseId: string; /** * Determines how the SQL query result is interpreted to decide whether the condition fires. * Must be set to a recognized value when provided. @@ -4768,7 +4832,7 @@ export interface SqlTask { } | undefined; /** The canonical identifier of the SQL warehouse. Recommended to use with serverless or pro SQL warehouses. Classic SQL warehouses are only supported for SQL alert, dashboard and query tasks and are limited to scheduled single-task jobs. */ - warehouseId?: string | undefined; + warehouseId: string; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. @@ -4858,7 +4922,7 @@ export interface SqlTask_SqlStatementOutput { export interface SqlTaskAlert { /** The canonical identifier of the SQL alert. */ - alertId?: string | undefined; + alertId: string; /** If specified, alert notifications are sent to subscribers. */ subscriptions?: SqlTaskSubscription[] | undefined; /** If true, the alert notifications are not sent to subscribers. */ @@ -4867,7 +4931,7 @@ export interface SqlTaskAlert { export interface SqlTaskDashboard { /** The canonical identifier of the SQL dashboard. */ - dashboardId?: string | undefined; + dashboardId: string; /** If specified, dashboard snapshots are sent to subscriptions. */ subscriptions?: SqlTaskSubscription[] | undefined; /** Subject of the email sent to subscribers of this task. */ @@ -4878,7 +4942,7 @@ export interface SqlTaskDashboard { export interface SqlTaskFile { /** Path of the SQL file. Must be relative if the source is a remote Git repository and absolute for workspace paths. */ - path?: string | undefined; + path: string; /** * Optional location type of the SQL file. When set to `WORKSPACE`, the SQL file will be retrieved * from the local workspace. When set to `GIT`, the SQL file will be retrieved from a Git repository @@ -5021,7 +5085,7 @@ export interface TableState { export interface TableTriggerConfiguration { /** A list of tables to monitor for changes. The table name must be in the format `catalog_name.schema_name.table_name`. */ - tableNames?: string[] | undefined; + tableNames: string[]; /** * If set, the trigger starts a run only after the specified amount of time has passed since * the last time the trigger fired. The minimum allowed value is 60 seconds. @@ -5045,7 +5109,7 @@ export interface TableTriggerState { export interface TaskDependency { /** The name of the task this task depends on. */ - taskKey?: string | undefined; + taskKey: string; /** Can only be specified on condition task dependencies. The outcome of the dependent task that must be met for this task to run. */ outcome?: string | undefined; } @@ -5056,7 +5120,7 @@ export interface TaskSettings { * This field is required and must be unique within its parent job. * On Update or Reset, this field is used to reference the tasks to be updated or reset. */ - taskKey?: string | undefined; + taskKey: string; /** * An optional array of objects specifying the dependency graph of the task. All tasks specified in this field must complete before executing this task. The task will run only if the `run_if` condition is true. * The key is `task_key`, and the value is the name assigned to the dependent task. @@ -5258,9 +5322,9 @@ export interface TerminationType {} /** * A single trigger attached to a job via `JobSettings.triggers`. Exactly one of the trigger-type fields - * (`periodic`, `schedule`, `continuous`, `file_arrival`, `table_update`, `model`) must be set; mutual exclusivity - * is enforced in the API handler rather than via `oneof` so that codegen, validation, and JSON serialization - * across SDKs and Terraform behave consistently. + * (`periodic`, `schedule`, `continuous`, `file_arrival`, `table_update`, `model`, `job_completion`) must be set; + * mutual exclusivity is enforced in the API handler rather than via `oneof` so that codegen, validation, and JSON + * serialization across SDKs and Terraform behave consistently. */ export interface TriggerConfiguration { /** Whether this trigger is paused. Defaults to UNPAUSED when unset; the server always returns an explicit value on read. */ @@ -5339,7 +5403,7 @@ export interface TriggerSettings { } export interface TriggerState { - /** (-- Next ID: 7. --) */ + /** (-- Next ID: 8. --) */ triggerType?: | {$case: 'table'; table: TableTriggerState} | {$case: 'fileArrival'; fileArrival: FileArrivalTriggerState} @@ -5356,7 +5420,7 @@ export interface TriggerState { export interface UpdateJobRequest { /** The canonical identifier of the job to update. This field is required. */ - jobId?: bigint | undefined; + jobId: bigint; /** * The new settings for the job. * @@ -5390,11 +5454,11 @@ export interface VolumesStorageInfo { * UC Volumes destination, e.g. `/Volumes/catalog/schema/vol1/init-scripts/setup-datadog.sh` * or `dbfs:/Volumes/catalog/schema/vol1/init-scripts/setup-datadog.sh` */ - destination?: string | undefined; + destination: string; } export interface Webhook { - id?: string | undefined; + id: string; } export interface WebhookNotifications { @@ -5422,7 +5486,7 @@ export interface WidgetErrorDetail { /** Cluster Attributes showing for clusters workload types. */ export interface WorkloadType { /** defined what type of clients can use the cluster. E.g. Notebooks, Jobs */ - clients?: WorkloadType_ClientsTypes | undefined; + clients: WorkloadType_ClientsTypes; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. @@ -5436,12 +5500,12 @@ export interface WorkloadType_ClientsTypes { /** A storage location in Workspace Filesystem (WSFS) */ export interface WorkspaceStorageInfo { /** wsfs destination, e.g. `workspace:/cluster-init-scripts/setup-datadog.sh` */ - destination?: string | undefined; + destination: string; } export const unmarshalAdlsgen2InfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -5449,10 +5513,8 @@ export const unmarshalAdlsgen2InfoSchema: z.ZodType = z export const unmarshalAiRuntimeTaskSchema: z.ZodType = z .object({ - experiment: z.string().optional(), - deployments: z - .array(z.lazy(() => unmarshalDeploymentSpecSchema)) - .optional(), + experiment: z.string(), + deployments: z.array(z.lazy(() => unmarshalDeploymentSpecSchema)), code_source_path: z.string().optional(), mlflow_run: z.string().optional(), mlflow_experiment_directory: z.string().optional(), @@ -5490,12 +5552,14 @@ export const unmarshalAlertTaskSchema: z.ZodType = z subscribers: z .array(z.lazy(() => unmarshalAlertTaskSubscriberSchema)) .optional(), + parameters: z.record(z.string(), z.string()).optional(), }) .transform(d => ({ alertId: d.alert_id, warehouseId: d.warehouse_id, workspacePath: d.workspace_path, subscribers: d.subscribers, + parameters: d.parameters, })); export const unmarshalAlertTaskOutputSchema: z.ZodType = z @@ -5747,8 +5811,8 @@ export const unmarshalCleanRoomTaskRunStateSchema: z.ZodType = z .object({ - clean_room_name: z.string().optional(), - notebook_name: z.string().optional(), + clean_room_name: z.string(), + notebook_name: z.string(), etag: z.string().optional(), notebook_base_parameters: z.record(z.string(), z.string()).optional(), }) @@ -5929,7 +5993,7 @@ export const unmarshalComputeSchema: z.ZodType = z export const unmarshalComputeConfigSchema: z.ZodType = z .object({ - num_gpus: z.number().optional(), + num_gpus: z.number(), gpu_node_pool_id: z.string().optional(), gpu_type: z.string().optional(), }) @@ -5941,8 +6005,8 @@ export const unmarshalComputeConfigSchema: z.ZodType = z export const unmarshalComputeSpecSchema: z.ZodType = z .object({ - accelerator_type: z.string().optional(), - accelerator_count: z.number().optional(), + accelerator_type: z.string(), + accelerator_count: z.number(), }) .transform(d => ({ acceleratorType: d.accelerator_type, @@ -5951,9 +6015,9 @@ export const unmarshalComputeSpecSchema: z.ZodType = z export const unmarshalConditionTaskSchema: z.ZodType = z .object({ - op: z.string().optional(), - left: z.string().optional(), - right: z.string().optional(), + op: z.string(), + left: z.string(), + right: z.string(), outcome: z.string().optional(), }) .transform(d => ({ @@ -5968,19 +6032,27 @@ export const unmarshalContinuousSettingsSchema: z.ZodType = .object({ pause_status: z.string().optional(), task_retry_mode: z.string().optional(), + maintenance_window: z + .lazy(() => unmarshalMaintenanceWindowSchema) + .optional(), }) .transform(d => ({ pauseStatus: d.pause_status, taskRetryMode: d.task_retry_mode, + maintenanceWindow: d.maintenance_window, })); export const unmarshalContinuousTriggerConfigurationSchema: z.ZodType = z .object({ task_retry_mode: z.string().optional(), + maintenance_window: z + .lazy(() => unmarshalMaintenanceWindowSchema) + .optional(), }) .transform(d => ({ taskRetryMode: d.task_retry_mode, + maintenanceWindow: d.maintenance_window, })); export const unmarshalContinuousTriggerStateSchema: z.ZodType = @@ -6012,8 +6084,8 @@ export const unmarshalCreateJobResponseSchema: z.ZodType = z export const unmarshalCronScheduleSchema: z.ZodType = z .object({ - quartz_cron_expression: z.string().optional(), - timezone_id: z.string().optional(), + quartz_cron_expression: z.string(), + timezone_id: z.string(), pause_status: z.string().optional(), sql_condition: z .lazy(() => unmarshalSqlConditionConfigurationSchema) @@ -6029,8 +6101,8 @@ export const unmarshalCronScheduleSchema: z.ZodType = z export const unmarshalCronTriggerConfigurationSchema: z.ZodType = z .object({ - quartz_cron_expression: z.string().optional(), - timezone_id: z.string().optional(), + quartz_cron_expression: z.string(), + timezone_id: z.string(), }) .transform(d => ({ quartzCronExpression: d.quartz_cron_expression, @@ -6077,7 +6149,7 @@ export const unmarshalDashboardTaskOutputSchema: z.ZodType export const unmarshalDbfsStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -6178,7 +6250,7 @@ export const unmarshalDbtPlatformTaskOutputSchema: z.ZodType = z .object({ project_directory: z.string().optional(), - commands: z.array(z.string()).optional(), + commands: z.array(z.string()), schema: z.string().optional(), warehouse_id: z.string().optional(), profiles_directory: z.string().optional(), @@ -6215,8 +6287,8 @@ export const unmarshalDeleteRunResponseSchema: z.ZodType = export const unmarshalDeploymentSpecSchema: z.ZodType = z .object({ - command_path: z.string().optional(), - compute: z.lazy(() => unmarshalComputeSpecSchema).optional(), + command_path: z.string(), + compute: z.lazy(() => unmarshalComputeSpecSchema), name: z.string().optional(), }) .transform(d => ({ @@ -6309,7 +6381,7 @@ export const unmarshalExportRunResponseSchema: z.ZodType = z export const unmarshalFileArrivalTriggerConfigurationSchema: z.ZodType = z .object({ - url: z.string().optional(), + url: z.string(), min_time_between_triggers_seconds: z.number().optional(), wait_after_last_change_seconds: z.number().optional(), }) @@ -6330,9 +6402,9 @@ export const unmarshalFileArrivalTriggerStateSchema: z.ZodType = z .object({ - inputs: z.string().optional(), + inputs: z.string(), concurrency: z.number().optional(), - task: z.lazy(() => unmarshalTaskSettingsSchema).optional(), + task: z.lazy(() => unmarshalTaskSettingsSchema), }) .transform(d => ({ inputs: d.inputs, @@ -6364,7 +6436,7 @@ export const unmarshalGcpAttributesSchema: z.ZodType = z export const unmarshalGcsStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -6372,7 +6444,7 @@ export const unmarshalGcsStorageInfoSchema: z.ZodType = z export const unmarshalGenAiComputeTaskSchema: z.ZodType = z .object({ - dl_runtime_image: z.string().optional(), + dl_runtime_image: z.string(), compute: z.lazy(() => unmarshalComputeConfigSchema).optional(), command: z.string().optional(), source: z.string().optional(), @@ -6662,8 +6734,8 @@ export const unmarshalGitMetadataSnapshotSchema: z.ZodType export const unmarshalGitSourceSchema: z.ZodType = z .object({ - git_url: z.string().optional(), - git_provider: z.string().optional(), + git_url: z.string(), + git_provider: z.string(), git_branch: z.string().optional(), git_tag: z.string().optional(), git_commit: z.string().optional(), @@ -6718,7 +6790,7 @@ export const unmarshalInitScriptInfoSchema: z.ZodType = z export const unmarshalJobClusterSchema: z.ZodType = z .object({ - job_cluster_key: z.string().optional(), + job_cluster_key: z.string(), new_cluster: z.lazy(() => unmarshalClusterSpec_NewClusterSchema).optional(), serverless_compute_id: z.string().optional(), }) @@ -6730,7 +6802,7 @@ export const unmarshalJobClusterSchema: z.ZodType = z export const unmarshalJobDeploymentSchema: z.ZodType = z .object({ - kind: z.string().optional(), + kind: z.string(), metadata_file_path: z.string().optional(), deployment_id: z.string().optional(), version_id: z.string().optional(), @@ -6764,7 +6836,7 @@ export const unmarshalJobEmailNotificationsSchema: z.ZodType = z .object({ - environment_key: z.string().optional(), + environment_key: z.string(), spec: z.lazy(() => unmarshalEnvironmentSchema).optional(), }) .transform(d => ({ @@ -6774,8 +6846,8 @@ export const unmarshalJobEnvironmentSchema: z.ZodType = z export const unmarshalJobLevelParameterSchema: z.ZodType = z .object({ - name: z.string().optional(), - default: z.string().optional(), + name: z.string(), + default: z.string(), }) .transform(d => ({ name: d.name, @@ -6884,7 +6956,7 @@ export const unmarshalJobSettingsSchema: z.ZodType = z export const unmarshalJobSourceSchema: z.ZodType = z .object({ - job_config_path: z.string().optional(), + job_config_path: z.string(), import_from_git_branch: z.string().optional(), dirty_state: z.string().optional(), }) @@ -6902,12 +6974,11 @@ export const unmarshalJobSourceSchema: z.ZodType = z export const unmarshalJobsHealthRuleSchema: z.ZodType = z .object({ - metric: z.string().optional(), - op: z.string().optional(), + metric: z.string(), + op: z.string(), value: z .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), + .transform(v => BigInt(v)), }) .transform(d => ({ metric: d.metric, @@ -6961,8 +7032,7 @@ export const unmarshalListJobComplianceForPolicy_JobComplianceSchema: z.ZodType< .object({ job_id: z .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), + .transform(v => BigInt(v)), is_compliant: z.boolean().optional(), violations: z.record(z.string(), z.string()).optional(), }) @@ -7019,7 +7089,7 @@ export const unmarshalListRunsResponseSchema: z.ZodType = z export const unmarshalLocalFileInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -7035,9 +7105,21 @@ export const unmarshalLogAnalyticsInfoSchema: z.ZodType = z logAnalyticsPrimaryKey: d.log_analytics_primary_key, })); +export const unmarshalMaintenanceWindowSchema: z.ZodType = z + .object({ + start_hour: z.number(), + day_of_week: z.string(), + timezone_id: z.string(), + }) + .transform(d => ({ + startHour: d.start_hour, + dayOfWeek: d.day_of_week, + timezoneId: d.timezone_id, + })); + export const unmarshalMavenLibrarySchema: z.ZodType = z .object({ - coordinates: z.string().optional(), + coordinates: z.string(), repo: z.string().optional(), exclusions: z.array(z.string()).optional(), }) @@ -7052,7 +7134,7 @@ export const unmarshalModelTriggerConfigurationSchema: z.ZodType z .object({ alternate_node_type_ids: z.array(z.string()).optional(), + aws_context_id: z.string().optional(), }) .transform(d => ({ alternateNodeTypeIds: d.alternate_node_type_ids, + awsContextId: d.aws_context_id, })); export const unmarshalNotebookTaskSchema: z.ZodType = z .object({ - notebook_path: z.string().optional(), + notebook_path: z.string(), base_parameters: z.record(z.string(), z.string()).optional(), source: z.string().optional(), warehouse_id: z.string().optional(), @@ -7165,8 +7249,8 @@ export const unmarshalPerTriggerStateSchema: z.ZodType = z export const unmarshalPeriodicTriggerConfigurationSchema: z.ZodType = z .object({ - interval: z.number().optional(), - unit: z.string().optional(), + interval: z.number(), + unit: z.string(), }) .transform(d => ({ interval: d.interval, @@ -7204,7 +7288,7 @@ export const unmarshalPipelineParametersSchema: z.ZodType = export const unmarshalPipelineTaskSchema: z.ZodType = z .object({ - pipeline_id: z.string().optional(), + pipeline_id: z.string(), parameters: z.record(z.string(), z.string()).optional(), full_refresh: z.boolean().optional(), refresh_selection: z.array(z.string()).optional(), @@ -7295,7 +7379,7 @@ export const unmarshalPythonOperatorTask_ParameterSchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -7305,8 +7389,8 @@ export const unmarshalPythonPyPiLibrarySchema: z.ZodType = z export const unmarshalPythonWheelTaskSchema: z.ZodType = z .object({ - package_name: z.string().optional(), - entry_point: z.string().optional(), + package_name: z.string(), + entry_point: z.string(), parameters: z.array(z.string()).optional(), named_parameters: z.record(z.string(), z.string()).optional(), }) @@ -7329,7 +7413,7 @@ export const unmarshalQueueDetailsSchema: z.ZodType = z export const unmarshalQueueSettingsSchema: z.ZodType = z .object({ - enabled: z.boolean().optional(), + enabled: z.boolean(), }) .transform(d => ({ enabled: d.enabled, @@ -7337,7 +7421,7 @@ export const unmarshalQueueSettingsSchema: z.ZodType = z export const unmarshalRCranLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -7730,8 +7814,7 @@ export const unmarshalRunJobTaskSchema: z.ZodType = z .object({ job_id: z .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), + .transform(v => BigInt(v)), job_parameters: z.record(z.string(), z.string()).optional(), pipeline_params: z.lazy(() => unmarshalPipelineParametersSchema).optional(), jar_params: z.array(z.string()).optional(), @@ -7851,7 +7934,7 @@ export const unmarshalRunTaskSchema: z.ZodType = z status: z.lazy(() => unmarshalRunStatusSchema).optional(), effective_performance_target: z.string().optional(), effective_serverless_compute_id: z.string().optional(), - task_key: z.string().optional(), + task_key: z.string(), description: z.string().optional(), depends_on: z.array(z.lazy(() => unmarshalTaskDependencySchema)).optional(), run_if: z.string().optional(), @@ -8099,7 +8182,7 @@ export const unmarshalRunTriggerInfoSchema: z.ZodType = z export const unmarshalS3StorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), region: z.string().optional(), endpoint: z.string().optional(), enable_encryption: z.boolean().optional(), @@ -8136,7 +8219,7 @@ export const unmarshalSparkJarTaskSchema: z.ZodType = z export const unmarshalSparkPythonTaskSchema: z.ZodType = z .object({ - python_file: z.string().optional(), + python_file: z.string(), parameters: z.array(z.string()).optional(), source: z.string().optional(), }) @@ -8165,8 +8248,8 @@ export const unmarshalSparseCheckoutSchema: z.ZodType = z export const unmarshalSqlConditionConfigurationSchema: z.ZodType = z .object({ - sql_query_id: z.string().optional(), - warehouse_id: z.string().optional(), + sql_query_id: z.string(), + warehouse_id: z.string(), trigger_mode: z.string().optional(), }) .transform(d => ({ @@ -8210,7 +8293,7 @@ export const unmarshalSqlTaskSchema: z.ZodType = z dashboard: z.lazy(() => unmarshalSqlTaskDashboardSchema).optional(), alert: z.lazy(() => unmarshalSqlTaskAlertSchema).optional(), file: z.lazy(() => unmarshalSqlTaskFileSchema).optional(), - warehouse_id: z.string().optional(), + warehouse_id: z.string(), }) .transform(d => ({ parameters: d.parameters, @@ -8358,7 +8441,7 @@ export const unmarshalSqlTask_SqlStatementOutputSchema: z.ZodType = z .object({ - alert_id: z.string().optional(), + alert_id: z.string(), subscriptions: z .array(z.lazy(() => unmarshalSqlTaskSubscriptionSchema)) .optional(), @@ -8372,7 +8455,7 @@ export const unmarshalSqlTaskAlertSchema: z.ZodType = z export const unmarshalSqlTaskDashboardSchema: z.ZodType = z .object({ - dashboard_id: z.string().optional(), + dashboard_id: z.string(), subscriptions: z .array(z.lazy(() => unmarshalSqlTaskSubscriptionSchema)) .optional(), @@ -8388,7 +8471,7 @@ export const unmarshalSqlTaskDashboardSchema: z.ZodType = z export const unmarshalSqlTaskFileSchema: z.ZodType = z .object({ - path: z.string().optional(), + path: z.string(), source: z.string().optional(), }) .transform(d => ({ @@ -8476,7 +8559,7 @@ export const unmarshalTableStateSchema: z.ZodType = z export const unmarshalTableTriggerConfigurationSchema: z.ZodType = z .object({ - table_names: z.array(z.string()).optional(), + table_names: z.array(z.string()), min_time_between_triggers_seconds: z.number().optional(), wait_after_last_change_seconds: z.number().optional(), condition: z.string().optional(), @@ -8502,7 +8585,7 @@ export const unmarshalTableTriggerStateSchema: z.ZodType = z export const unmarshalTaskDependencySchema: z.ZodType = z .object({ - task_key: z.string().optional(), + task_key: z.string(), outcome: z.string().optional(), }) .transform(d => ({ @@ -8512,7 +8595,7 @@ export const unmarshalTaskDependencySchema: z.ZodType = z export const unmarshalTaskSettingsSchema: z.ZodType = z .object({ - task_key: z.string().optional(), + task_key: z.string(), depends_on: z.array(z.lazy(() => unmarshalTaskDependencySchema)).optional(), run_if: z.string().optional(), timeout_seconds: z.number().optional(), @@ -8858,7 +8941,7 @@ export const unmarshalViewItemSchema: z.ZodType = z export const unmarshalVolumesStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -8866,7 +8949,7 @@ export const unmarshalVolumesStorageInfoSchema: z.ZodType = export const unmarshalWebhookSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), }) .transform(d => ({ id: d.id, @@ -8904,7 +8987,7 @@ export const unmarshalWidgetErrorDetailSchema: z.ZodType = z export const unmarshalWorkloadTypeSchema: z.ZodType = z .object({ - clients: z.lazy(() => unmarshalWorkloadType_ClientsTypesSchema).optional(), + clients: z.lazy(() => unmarshalWorkloadType_ClientsTypesSchema), }) .transform(d => ({ clients: d.clients, @@ -8925,7 +9008,7 @@ export const unmarshalWorkloadType_ClientsTypesSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -8960,7 +9043,7 @@ export const marshalAccessControlRequestSchema: z.ZodType = z export const marshalAdlsgen2InfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -8968,8 +9051,8 @@ export const marshalAdlsgen2InfoSchema: z.ZodType = z export const marshalAiRuntimeTaskSchema: z.ZodType = z .object({ - experiment: z.string().optional(), - deployments: z.array(z.lazy(() => marshalDeploymentSpecSchema)).optional(), + experiment: z.string(), + deployments: z.array(z.lazy(() => marshalDeploymentSpecSchema)), codeSourcePath: z.string().optional(), mlflowRun: z.string().optional(), mlflowExperimentDirectory: z.string().optional(), @@ -8994,12 +9077,14 @@ export const marshalAlertTaskSchema: z.ZodType = z subscribers: z .array(z.lazy(() => marshalAlertTaskSubscriberSchema)) .optional(), + parameters: z.record(z.string(), z.string()).optional(), }) .transform(d => ({ alert_id: d.alertId, warehouse_id: d.warehouseId, workspace_path: d.workspacePath, subscribers: d.subscribers, + parameters: d.parameters, })); export const marshalAlertTaskSubscriberSchema: z.ZodType = z @@ -9087,7 +9172,7 @@ export const marshalCancelAllRunsRequestSchema: z.ZodType = z export const marshalCancelRunRequestSchema: z.ZodType = z .object({ - runId: z.bigint().optional(), + runId: z.bigint(), }) .transform(d => ({ run_id: d.runId, @@ -9095,8 +9180,8 @@ export const marshalCancelRunRequestSchema: z.ZodType = z export const marshalCleanRoomsNotebookTaskSchema: z.ZodType = z .object({ - cleanRoomName: z.string().optional(), - notebookName: z.string().optional(), + cleanRoomName: z.string(), + notebookName: z.string(), etag: z.string().optional(), notebookBaseParameters: z.record(z.string(), z.string()).optional(), }) @@ -9230,7 +9315,7 @@ export const marshalComputeSchema: z.ZodType = z export const marshalComputeConfigSchema: z.ZodType = z .object({ - numGpus: z.number().optional(), + numGpus: z.number(), gpuNodePoolId: z.string().optional(), gpuType: z.string().optional(), }) @@ -9242,8 +9327,8 @@ export const marshalComputeConfigSchema: z.ZodType = z export const marshalComputeSpecSchema: z.ZodType = z .object({ - acceleratorType: z.string().optional(), - acceleratorCount: z.number().optional(), + acceleratorType: z.string(), + acceleratorCount: z.number(), }) .transform(d => ({ accelerator_type: d.acceleratorType, @@ -9252,9 +9337,9 @@ export const marshalComputeSpecSchema: z.ZodType = z export const marshalConditionTaskSchema: z.ZodType = z .object({ - op: z.string().optional(), - left: z.string().optional(), - right: z.string().optional(), + op: z.string(), + left: z.string(), + right: z.string(), outcome: z.string().optional(), }) .transform(d => ({ @@ -9268,18 +9353,22 @@ export const marshalContinuousSettingsSchema: z.ZodType = z .object({ pauseStatus: z.string().optional(), taskRetryMode: z.string().optional(), + maintenanceWindow: z.lazy(() => marshalMaintenanceWindowSchema).optional(), }) .transform(d => ({ pause_status: d.pauseStatus, task_retry_mode: d.taskRetryMode, + maintenance_window: d.maintenanceWindow, })); export const marshalContinuousTriggerConfigurationSchema: z.ZodType = z .object({ taskRetryMode: z.string().optional(), + maintenanceWindow: z.lazy(() => marshalMaintenanceWindowSchema).optional(), }) .transform(d => ({ task_retry_mode: d.taskRetryMode, + maintenance_window: d.maintenanceWindow, })); export const marshalCreateJobRequestSchema: z.ZodType = z @@ -9366,8 +9455,8 @@ export const marshalCreateJobRequestSchema: z.ZodType = z export const marshalCronScheduleSchema: z.ZodType = z .object({ - quartzCronExpression: z.string().optional(), - timezoneId: z.string().optional(), + quartzCronExpression: z.string(), + timezoneId: z.string(), pauseStatus: z.string().optional(), sqlCondition: z .lazy(() => marshalSqlConditionConfigurationSchema) @@ -9382,8 +9471,8 @@ export const marshalCronScheduleSchema: z.ZodType = z export const marshalCronTriggerConfigurationSchema: z.ZodType = z .object({ - quartzCronExpression: z.string().optional(), - timezoneId: z.string().optional(), + quartzCronExpression: z.string(), + timezoneId: z.string(), }) .transform(d => ({ quartz_cron_expression: d.quartzCronExpression, @@ -9406,7 +9495,7 @@ export const marshalDashboardTaskSchema: z.ZodType = z export const marshalDbfsStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -9435,7 +9524,7 @@ export const marshalDbtPlatformTaskSchema: z.ZodType = z export const marshalDbtTaskSchema: z.ZodType = z .object({ projectDirectory: z.string().optional(), - commands: z.array(z.string()).optional(), + commands: z.array(z.string()), schema: z.string().optional(), warehouseId: z.string().optional(), profilesDirectory: z.string().optional(), @@ -9454,7 +9543,7 @@ export const marshalDbtTaskSchema: z.ZodType = z export const marshalDeleteJobRequestSchema: z.ZodType = z .object({ - jobId: z.bigint().optional(), + jobId: z.bigint(), }) .transform(d => ({ job_id: d.jobId, @@ -9462,7 +9551,7 @@ export const marshalDeleteJobRequestSchema: z.ZodType = z export const marshalDeleteRunRequestSchema: z.ZodType = z .object({ - runId: z.bigint().optional(), + runId: z.bigint(), }) .transform(d => ({ run_id: d.runId, @@ -9470,8 +9559,8 @@ export const marshalDeleteRunRequestSchema: z.ZodType = z export const marshalDeploymentSpecSchema: z.ZodType = z .object({ - commandPath: z.string().optional(), - compute: z.lazy(() => marshalComputeSpecSchema).optional(), + commandPath: z.string(), + compute: z.lazy(() => marshalComputeSpecSchema), name: z.string().optional(), }) .transform(d => ({ @@ -9511,7 +9600,7 @@ export const marshalDockerImageSchema: z.ZodType = z export const marshalEnforcePolicyComplianceForJobSchema: z.ZodType = z .object({ - jobId: z.bigint().optional(), + jobId: z.bigint(), validateOnly: z.boolean().optional(), }) .transform(d => ({ @@ -9537,7 +9626,7 @@ export const marshalEnvironmentSchema: z.ZodType = z export const marshalFileArrivalTriggerConfigurationSchema: z.ZodType = z .object({ - url: z.string().optional(), + url: z.string(), minTimeBetweenTriggersSeconds: z.number().optional(), waitAfterLastChangeSeconds: z.number().optional(), }) @@ -9549,9 +9638,9 @@ export const marshalFileArrivalTriggerConfigurationSchema: z.ZodType = z export const marshalForEachTaskSchema: z.ZodType = z .object({ - inputs: z.string().optional(), + inputs: z.string(), concurrency: z.number().optional(), - task: z.lazy(() => marshalTaskSettingsSchema).optional(), + task: z.lazy(() => marshalTaskSettingsSchema), }) .transform(d => ({ inputs: d.inputs, @@ -9583,7 +9672,7 @@ export const marshalGcpAttributesSchema: z.ZodType = z export const marshalGcsStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -9591,7 +9680,7 @@ export const marshalGcsStorageInfoSchema: z.ZodType = z export const marshalGenAiComputeTaskSchema: z.ZodType = z .object({ - dlRuntimeImage: z.string().optional(), + dlRuntimeImage: z.string(), compute: z.lazy(() => marshalComputeConfigSchema).optional(), command: z.string().optional(), source: z.string().optional(), @@ -9621,8 +9710,8 @@ export const marshalGitMetadataSnapshotSchema: z.ZodType = z export const marshalGitSourceSchema: z.ZodType = z .object({ - gitUrl: z.string().optional(), - gitProvider: z.string().optional(), + gitUrl: z.string(), + gitProvider: z.string(), gitReference: z .discriminatedUnion('$case', [ z.object({$case: z.literal('gitBranch'), gitBranch: z.string()}), @@ -9698,7 +9787,7 @@ export const marshalInitScriptInfoSchema: z.ZodType = z export const marshalJobClusterSchema: z.ZodType = z .object({ - jobClusterKey: z.string().optional(), + jobClusterKey: z.string(), newCluster: z.lazy(() => marshalClusterSpec_NewClusterSchema).optional(), serverlessComputeId: z.string().optional(), }) @@ -9710,7 +9799,7 @@ export const marshalJobClusterSchema: z.ZodType = z export const marshalJobDeploymentSchema: z.ZodType = z .object({ - kind: z.string().optional(), + kind: z.string(), metadataFilePath: z.string().optional(), deploymentId: z.string().optional(), versionId: z.string().optional(), @@ -9743,7 +9832,7 @@ export const marshalJobEmailNotificationsSchema: z.ZodType = z export const marshalJobEnvironmentSchema: z.ZodType = z .object({ - environmentKey: z.string().optional(), + environmentKey: z.string(), spec: z.lazy(() => marshalEnvironmentSchema).optional(), }) .transform(d => ({ @@ -9753,8 +9842,8 @@ export const marshalJobEnvironmentSchema: z.ZodType = z export const marshalJobLevelParameterSchema: z.ZodType = z .object({ - name: z.string().optional(), - default: z.string().optional(), + name: z.string(), + default: z.string(), }) .transform(d => ({ name: d.name, @@ -9864,7 +9953,7 @@ export const marshalJobSettingsSchema: z.ZodType = z export const marshalJobSourceSchema: z.ZodType = z .object({ - jobConfigPath: z.string().optional(), + jobConfigPath: z.string(), importFromGitReference: z .discriminatedUnion('$case', [ z.object({ @@ -9885,9 +9974,9 @@ export const marshalJobSourceSchema: z.ZodType = z export const marshalJobsHealthRuleSchema: z.ZodType = z .object({ - metric: z.string().optional(), - op: z.string().optional(), - value: z.bigint().optional(), + metric: z.string(), + op: z.string(), + value: z.bigint(), }) .transform(d => ({ metric: d.metric, @@ -9938,7 +10027,7 @@ export const marshalLibrarySchema: z.ZodType = z export const marshalLocalFileInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -9954,9 +10043,21 @@ export const marshalLogAnalyticsInfoSchema: z.ZodType = z log_analytics_primary_key: d.logAnalyticsPrimaryKey, })); +export const marshalMaintenanceWindowSchema: z.ZodType = z + .object({ + startHour: z.number(), + dayOfWeek: z.string(), + timezoneId: z.string(), + }) + .transform(d => ({ + start_hour: d.startHour, + day_of_week: d.dayOfWeek, + timezone_id: d.timezoneId, + })); + export const marshalMavenLibrarySchema: z.ZodType = z .object({ - coordinates: z.string().optional(), + coordinates: z.string(), repo: z.string().optional(), exclusions: z.array(z.string()).optional(), }) @@ -9970,7 +10071,7 @@ export const marshalModelTriggerConfigurationSchema: z.ZodType = z .object({ securableName: z.string().optional(), aliases: z.array(z.string()).optional(), - condition: z.string().optional(), + condition: z.string(), minTimeBetweenTriggersSeconds: z.number().optional(), waitAfterLastChangeSeconds: z.number().optional(), }) @@ -9985,14 +10086,16 @@ export const marshalModelTriggerConfigurationSchema: z.ZodType = z export const marshalNodeTypeFlexibilitySchema: z.ZodType = z .object({ alternateNodeTypeIds: z.array(z.string()).optional(), + awsContextId: z.string().optional(), }) .transform(d => ({ alternate_node_type_ids: d.alternateNodeTypeIds, + aws_context_id: d.awsContextId, })); export const marshalNotebookTaskSchema: z.ZodType = z .object({ - notebookPath: z.string().optional(), + notebookPath: z.string(), baseParameters: z.record(z.string(), z.string()).optional(), source: z.string().optional(), warehouseId: z.string().optional(), @@ -10018,8 +10121,8 @@ export const marshalNotificationSettingsSchema: z.ZodType = z export const marshalPeriodicTriggerConfigurationSchema: z.ZodType = z .object({ - interval: z.number().optional(), - unit: z.string().optional(), + interval: z.number(), + unit: z.string(), }) .transform(d => ({ interval: d.interval, @@ -10044,7 +10147,7 @@ export const marshalPipelineParametersSchema: z.ZodType = z export const marshalPipelineTaskSchema: z.ZodType = z .object({ - pipelineId: z.string().optional(), + pipelineId: z.string(), pipelineTaskParameters: z.record(z.string(), z.string()).optional(), fullRefresh: z.boolean().optional(), refreshSelection: z.array(z.string()).optional(), @@ -10133,7 +10236,7 @@ export const marshalPythonOperatorTask_ParameterSchema: z.ZodType = z export const marshalPythonPyPiLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -10143,8 +10246,8 @@ export const marshalPythonPyPiLibrarySchema: z.ZodType = z export const marshalPythonWheelTaskSchema: z.ZodType = z .object({ - packageName: z.string().optional(), - entryPoint: z.string().optional(), + packageName: z.string(), + entryPoint: z.string(), parameters: z.array(z.string()).optional(), namedParameters: z.record(z.string(), z.string()).optional(), }) @@ -10157,7 +10260,7 @@ export const marshalPythonWheelTaskSchema: z.ZodType = z export const marshalQueueSettingsSchema: z.ZodType = z .object({ - enabled: z.boolean().optional(), + enabled: z.boolean(), }) .transform(d => ({ enabled: d.enabled, @@ -10165,7 +10268,7 @@ export const marshalQueueSettingsSchema: z.ZodType = z export const marshalRCranLibrarySchema: z.ZodType = z .object({ - package: z.string().optional(), + package: z.string(), repo: z.string().optional(), }) .transform(d => ({ @@ -10175,7 +10278,7 @@ export const marshalRCranLibrarySchema: z.ZodType = z export const marshalRepairRunRequestSchema: z.ZodType = z .object({ - runId: z.bigint().optional(), + runId: z.bigint(), latestRepairId: z.bigint().optional(), rerunTasks: z.array(z.string()).optional(), jobParameters: z.record(z.string(), z.string()).optional(), @@ -10211,8 +10314,8 @@ export const marshalRepairRunRequestSchema: z.ZodType = z export const marshalResetJobRequestSchema: z.ZodType = z .object({ - jobId: z.bigint().optional(), - newSettings: z.lazy(() => marshalJobSettingsSchema).optional(), + jobId: z.bigint(), + newSettings: z.lazy(() => marshalJobSettingsSchema), }) .transform(d => ({ job_id: d.jobId, @@ -10221,7 +10324,7 @@ export const marshalResetJobRequestSchema: z.ZodType = z export const marshalRunJobTaskSchema: z.ZodType = z .object({ - jobId: z.bigint().optional(), + jobId: z.bigint(), jobParameters: z.record(z.string(), z.string()).optional(), pipelineParams: z.lazy(() => marshalPipelineParametersSchema).optional(), jarParams: z.array(z.string()).optional(), @@ -10247,7 +10350,7 @@ export const marshalRunJobTaskSchema: z.ZodType = z export const marshalRunNowRequestSchema: z.ZodType = z .object({ - jobId: z.bigint().optional(), + jobId: z.bigint(), jobParameters: z.record(z.string(), z.string()).optional(), idempotencyToken: z.string().optional(), queue: z.lazy(() => marshalQueueSettingsSchema).optional(), @@ -10281,7 +10384,7 @@ export const marshalRunNowRequestSchema: z.ZodType = z export const marshalRunTaskSettingsSchema: z.ZodType = z .object({ - taskKey: z.string().optional(), + taskKey: z.string(), description: z.string().optional(), dependsOn: z.array(z.lazy(() => marshalTaskDependencySchema)).optional(), runIf: z.string().optional(), @@ -10493,7 +10596,7 @@ export const marshalRunTaskSettingsSchema: z.ZodType = z export const marshalS3StorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), region: z.string().optional(), endpoint: z.string().optional(), enableEncryption: z.boolean().optional(), @@ -10527,7 +10630,7 @@ export const marshalSparkJarTaskSchema: z.ZodType = z export const marshalSparkPythonTaskSchema: z.ZodType = z .object({ - pythonFile: z.string().optional(), + pythonFile: z.string(), parameters: z.array(z.string()).optional(), source: z.string().optional(), }) @@ -10555,8 +10658,8 @@ export const marshalSparseCheckoutSchema: z.ZodType = z export const marshalSqlConditionConfigurationSchema: z.ZodType = z .object({ - sqlQueryId: z.string().optional(), - warehouseId: z.string().optional(), + sqlQueryId: z.string(), + warehouseId: z.string(), triggerMode: z.string().optional(), }) .transform(d => ({ @@ -10588,7 +10691,7 @@ export const marshalSqlTaskSchema: z.ZodType = z }), ]) .optional(), - warehouseId: z.string().optional(), + warehouseId: z.string(), }) .transform(d => ({ parameters: d.parameters, @@ -10603,7 +10706,7 @@ export const marshalSqlTaskSchema: z.ZodType = z export const marshalSqlTaskAlertSchema: z.ZodType = z .object({ - alertId: z.string().optional(), + alertId: z.string(), subscriptions: z .array(z.lazy(() => marshalSqlTaskSubscriptionSchema)) .optional(), @@ -10617,7 +10720,7 @@ export const marshalSqlTaskAlertSchema: z.ZodType = z export const marshalSqlTaskDashboardSchema: z.ZodType = z .object({ - dashboardId: z.string().optional(), + dashboardId: z.string(), subscriptions: z .array(z.lazy(() => marshalSqlTaskSubscriptionSchema)) .optional(), @@ -10633,7 +10736,7 @@ export const marshalSqlTaskDashboardSchema: z.ZodType = z export const marshalSqlTaskFileSchema: z.ZodType = z .object({ - path: z.string().optional(), + path: z.string(), source: z.string().optional(), }) .transform(d => ({ @@ -10758,7 +10861,7 @@ export const marshalSubscription_SubscriberSchema: z.ZodType = z export const marshalTableTriggerConfigurationSchema: z.ZodType = z .object({ - tableNames: z.array(z.string()).optional(), + tableNames: z.array(z.string()), minTimeBetweenTriggersSeconds: z.number().optional(), waitAfterLastChangeSeconds: z.number().optional(), condition: z.string().optional(), @@ -10772,7 +10875,7 @@ export const marshalTableTriggerConfigurationSchema: z.ZodType = z export const marshalTaskDependencySchema: z.ZodType = z .object({ - taskKey: z.string().optional(), + taskKey: z.string(), outcome: z.string().optional(), }) .transform(d => ({ @@ -10782,7 +10885,7 @@ export const marshalTaskDependencySchema: z.ZodType = z export const marshalTaskSettingsSchema: z.ZodType = z .object({ - taskKey: z.string().optional(), + taskKey: z.string(), dependsOn: z.array(z.lazy(() => marshalTaskDependencySchema)).optional(), runIf: z.string().optional(), timeoutSeconds: z.number().optional(), @@ -11070,7 +11173,7 @@ export const marshalTriggerSettingsSchema: z.ZodType = z export const marshalUpdateJobRequestSchema: z.ZodType = z .object({ - jobId: z.bigint().optional(), + jobId: z.bigint(), newSettings: z.lazy(() => marshalJobSettingsSchema).optional(), fieldsToRemove: z.array(z.string()).optional(), }) @@ -11082,7 +11185,7 @@ export const marshalUpdateJobRequestSchema: z.ZodType = z export const marshalVolumesStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, @@ -11090,7 +11193,7 @@ export const marshalVolumesStorageInfoSchema: z.ZodType = z export const marshalWebhookSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), }) .transform(d => ({ id: d.id, @@ -11119,7 +11222,7 @@ export const marshalWebhookNotificationsSchema: z.ZodType = z export const marshalWorkloadTypeSchema: z.ZodType = z .object({ - clients: z.lazy(() => marshalWorkloadType_ClientsTypesSchema).optional(), + clients: z.lazy(() => marshalWorkloadType_ClientsTypesSchema), }) .transform(d => ({ clients: d.clients, @@ -11138,7 +11241,7 @@ export const marshalWorkloadType_ClientsTypesSchema: z.ZodType = z export const marshalWorkspaceStorageInfoSchema: z.ZodType = z .object({ - destination: z.string().optional(), + destination: z.string(), }) .transform(d => ({ destination: d.destination, diff --git a/packages/keyconfigurations/src/v1/model.ts b/packages/keyconfigurations/src/v1/model.ts index a02dbd602..a810d1a23 100644 --- a/packages/keyconfigurations/src/v1/model.ts +++ b/packages/keyconfigurations/src/v1/model.ts @@ -15,7 +15,7 @@ export type CmkUseCase = export interface AwsKeyInfo { /** The AWS KMS key's Amazon Resource Name (ARN). */ - keyArn?: string | undefined; + keyArn: string; /** The AWS KMS key alias. */ keyAlias?: string | undefined; /** The AWS KMS key region. */ @@ -50,7 +50,7 @@ export interface AzureKeyInfo { export interface CreateAwsKeyInfo { /** The AWS KMS key's Amazon Resource Name (ARN). */ - keyArn?: string | undefined; + keyArn: string; /** The AWS KMS key alias. */ keyAlias?: string | undefined; /** The AWS KMS key region. */ @@ -84,7 +84,7 @@ export interface CreateAzureKeyInfo { } export interface CreateCustomerManagedKeyRequest { - accountId?: string | undefined; + accountId: string; /** * (-- The key information. Exactly one of aws_key_info, gcp_key_info, or * azure_key_info must be set, matching the cloud of the account. --) @@ -95,7 +95,7 @@ export interface CreateCustomerManagedKeyRequest { | {$case: 'azureKeyInfo'; azureKeyInfo: CreateAzureKeyInfo} | undefined; /** The cases that the key can be used for. */ - useCases?: CmkUseCase[] | undefined; + useCases: CmkUseCase[]; } export interface CreateGcpKeyInfo { @@ -103,7 +103,7 @@ export interface CreateGcpKeyInfo { * Globally unique kms key resource id of the form * projects/testProjectId/locations/us-east4/keyRings/gcpCmkKeyRing/cryptoKeys/cmk-eastus4 */ - kmsKeyId?: string | undefined; + kmsKeyId: string; /** * Globally unique service account email that has access to the KMS key. * The service account exists within the Databricks CP project. @@ -139,8 +139,8 @@ export interface CustomerManagedKey { export interface DeleteCustomerManagedKeyRequest { /** encryption key configuration ID. */ - customerManagedKeyId?: string | undefined; - accountId?: string | undefined; + customerManagedKeyId: string; + accountId: string; } export interface GcpKeyInfo { @@ -148,7 +148,7 @@ export interface GcpKeyInfo { * Globally unique kms key resource id of the form * projects/testProjectId/locations/us-east4/keyRings/gcpCmkKeyRing/cryptoKeys/cmk-eastus4 */ - kmsKeyId?: string | undefined; + kmsKeyId: string; /** * Globally unique service account email that has access to the KMS key. * The service account exists within the Databricks CP project. @@ -168,8 +168,8 @@ export interface GcpServiceAccount { export interface GetCustomerManagedKeyRequest { /** encryption key configuration ID. */ - customerManagedKeyId?: string | undefined; - accountId?: string | undefined; + customerManagedKeyId: string; + accountId: string; } /** The credential ID that is used to access the key vault. */ @@ -178,7 +178,7 @@ export interface KeyAccessConfiguration { } export interface ListCustomerManagedKeyRequest { - accountId?: string | undefined; + accountId: string; } export interface ListCustomerManagedKeyResponse { @@ -187,7 +187,7 @@ export interface ListCustomerManagedKeyResponse { export const unmarshalAwsKeyInfoSchema: z.ZodType = z .object({ - key_arn: z.string().optional(), + key_arn: z.string(), key_alias: z.string().optional(), key_region: z.string().optional(), reuse_key_for_cluster_volumes: z.boolean().optional(), @@ -250,7 +250,7 @@ export const unmarshalCustomerManagedKeySchema: z.ZodType = export const unmarshalGcpKeyInfoSchema: z.ZodType = z .object({ - kms_key_id: z.string().optional(), + kms_key_id: z.string(), gcp_service_account: z .lazy(() => unmarshalGcpServiceAccountSchema) .optional(), @@ -281,7 +281,7 @@ export const unmarshalKeyAccessConfigurationSchema: z.ZodType ({ account_id: d.accountId, @@ -350,7 +350,7 @@ export const marshalCreateCustomerManagedKeyRequestSchema: z.ZodType = z export const marshalCreateGcpKeyInfoSchema: z.ZodType = z .object({ - kmsKeyId: z.string().optional(), + kmsKeyId: z.string(), gcpServiceAccount: z.lazy(() => marshalGcpServiceAccountSchema).optional(), manual: z.boolean().optional(), }) diff --git a/packages/knowledgeassistants/src/v1/model.ts b/packages/knowledgeassistants/src/v1/model.ts index 837573691..e173b000e 100644 --- a/packages/knowledgeassistants/src/v1/model.ts +++ b/packages/knowledgeassistants/src/v1/model.ts @@ -35,14 +35,14 @@ export interface CreateExampleRequest { * Parent resource where this example will be created. * Format: knowledge-assistants/{knowledge_assistant_id} */ - parent?: string | undefined; + parent: string; /** The example to create under the parent Knowledge Assistant. */ - example?: Example | undefined; + example: Example; } export interface CreateKnowledgeAssistantRequest { /** The Knowledge Assistant to create. */ - knowledgeAssistant?: KnowledgeAssistant | undefined; + knowledgeAssistant: KnowledgeAssistant; } export interface CreateKnowledgeSourceRequest { @@ -50,8 +50,8 @@ export interface CreateKnowledgeSourceRequest { * Parent resource where this source will be created. * Format: knowledge-assistants/{knowledge_assistant_id} */ - parent?: string | undefined; - knowledgeSource?: KnowledgeSource | undefined; + parent: string; + knowledgeSource: KnowledgeSource; } /** Delete an example. */ @@ -60,7 +60,7 @@ export interface DeleteExampleRequest { * The resource name of the example to delete. * Format: knowledge-assistants/{knowledge_assistant_id}/examples/{example_id} */ - name?: string | undefined; + name: string; } /** A request to delete a Knowledge Assistant. */ @@ -69,7 +69,7 @@ export interface DeleteKnowledgeAssistantRequest { * The resource name of the knowledge assistant to be deleted. * Format: knowledge-assistants/{knowledge_assistant_id} */ - name?: string | undefined; + name: string; } export interface DeleteKnowledgeSourceRequest { @@ -77,7 +77,7 @@ export interface DeleteKnowledgeSourceRequest { * The resource name of the Knowledge Source to delete. * Format: knowledge-assistants/{knowledge_assistant_id}/knowledge-sources/{knowledge_source_id} */ - name?: string | undefined; + name: string; } /** @@ -91,7 +91,7 @@ export interface Example { */ name?: string | undefined; /** The example question. */ - question?: string | undefined; + question: string; /** * Guidelines for answering the question. Optional — examples may be created * with just a question; the front-end form does not require guidelines. @@ -108,15 +108,15 @@ export interface Example { /** FileTableSpec specifies a file table source configuration. */ export interface FileTableSpec { /** Full UC name of the table, in the format of {CATALOG}.{SCHEMA}.{TABLE_NAME}. */ - tableName?: string | undefined; + tableName: string; /** The name of the column containing BINARY file content to be indexed. */ - fileCol?: string | undefined; + fileCol: string; } /** FilesSpec specifies a files source configuration. */ export interface FilesSpec { /** A UC volume path that includes a list of files. */ - path?: string | undefined; + path: string; } /** Get an example. */ @@ -125,7 +125,7 @@ export interface GetExampleRequest { * The resource name of the example. * Format: knowledge-assistants/{knowledge_assistant_id}/examples/{example_id} */ - name?: string | undefined; + name: string; } /** A request to retrieve a Knowledge Assistant. */ @@ -134,7 +134,7 @@ export interface GetKnowledgeAssistantRequest { * The resource name of the knowledge assistant. * Format: knowledge-assistants/{knowledge_assistant_id} */ - name?: string | undefined; + name: string; } export interface GetKnowledgeSourceRequest { @@ -142,17 +142,17 @@ export interface GetKnowledgeSourceRequest { * The resource name of the Knowledge Source. * Format: knowledge-assistants/{knowledge_assistant_id}/knowledge-sources/{knowledge_source_id} */ - name?: string | undefined; + name: string; } /** IndexSpec specifies a vector search index source configuration. */ export interface IndexSpec { /** Full UC name of the vector search index, in the format of {CATALOG}.{SCHEMA}.{INDEX_NAME}. */ - indexName?: string | undefined; + indexName: string; /** The column that includes the document text for retrieval. */ - textCol?: string | undefined; + textCol: string; /** The column that specifies a link or reference to where the information came from. */ - docUriCol?: string | undefined; + docUriCol: string; } /** @@ -176,14 +176,14 @@ export interface KnowledgeAssistant { * When updating a Knowledge Assistant, optional unless included in * update_mask. */ - displayName?: string | undefined; + displayName: string; /** * Description of what this agent can do (user-facing). * Required when creating a Knowledge Assistant. * When updating a Knowledge Assistant, optional unless included in * update_mask. */ - description?: string | undefined; + description: string; /** * Additional global instructions on how the agent should generate answers. * Optional on create and update. @@ -220,19 +220,19 @@ export interface KnowledgeSource { * Required when creating a Knowledge Source. * When updating a Knowledge Source, optional unless included in update_mask. */ - displayName?: string | undefined; + displayName: string; /** * Description of the knowledge source. * Required when creating a Knowledge Source. * When updating a Knowledge Source, optional unless included in update_mask. */ - description?: string | undefined; + description: string; /** * The type of the source: "index", "files", or "file_table". * Required when creating a Knowledge Source. * When updating a Knowledge Source, this field is ignored. */ - sourceType?: string | undefined; + sourceType: string; /** Specification for the knowledge source type. */ spec?: | {$case: 'index'; index: IndexSpec} @@ -253,7 +253,7 @@ export interface ListExamplesRequest { * Parent resource to list from. * Format: knowledge-assistants/{knowledge_assistant_id} */ - parent?: string | undefined; + parent: string; /** * The maximum number of examples to return. * If unspecified, at most 100 examples will be returned. @@ -305,7 +305,7 @@ export interface ListKnowledgeSourcesRequest { * Parent resource to list from. * Format: knowledge-assistants/{knowledge_assistant_id} */ - parent?: string | undefined; + parent: string; pageSize?: number | undefined; pageToken?: string | undefined; } @@ -320,7 +320,7 @@ export interface SyncKnowledgeSourcesRequest { * The resource name of the Knowledge Assistant. * Format: knowledge-assistants/{knowledge_assistant_id} */ - name?: string | undefined; + name: string; } /** Update an example. */ @@ -329,8 +329,8 @@ export interface UpdateExampleRequest { * The resource name of the example to update. * Format: knowledge-assistants/{knowledge_assistant_id}/examples/{example_id} */ - name?: string | undefined; - example?: Example | undefined; + name: string; + example: Example; /** * Comma-delimited list of fields to update on the example. * Allowed values: `question`, `guidelines`. @@ -338,7 +338,7 @@ export interface UpdateExampleRequest { * - `question` * - `question,guidelines` */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateKnowledgeAssistantRequest { @@ -348,7 +348,7 @@ export interface UpdateKnowledgeAssistantRequest { * REQUIRED annotations on Knowledge Assistant fields describe create-time * requirements and do not mean all those fields are required for update. */ - knowledgeAssistant?: KnowledgeAssistant | undefined; + knowledgeAssistant: KnowledgeAssistant; /** * Comma-delimited list of fields to update on the Knowledge Assistant. * Allowed values: `display_name`, `description`, `instructions`. @@ -356,7 +356,7 @@ export interface UpdateKnowledgeAssistantRequest { * - `display_name` * - `description,instructions` */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateKnowledgeSourceRequest { @@ -364,14 +364,14 @@ export interface UpdateKnowledgeSourceRequest { * The resource name of the Knowledge Source to update. * Format: knowledge-assistants/{knowledge_assistant_id}/knowledge-sources/{knowledge_source_id} */ - name?: string | undefined; + name: string; /** * The Knowledge Source update payload. * Only fields listed in update_mask are updated. * REQUIRED annotations on Knowledge Source fields describe create-time * requirements and do not mean all those fields are required for update. */ - knowledgeSource?: KnowledgeSource | undefined; + knowledgeSource: KnowledgeSource; /** * Comma-delimited list of fields to update on the Knowledge Source. * Allowed values: `display_name`, `description`. @@ -379,13 +379,13 @@ export interface UpdateKnowledgeSourceRequest { * - `display_name` * - `display_name,description` */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export const unmarshalExampleSchema: z.ZodType = z .object({ name: z.string().optional(), - question: z.string().optional(), + question: z.string(), guidelines: z.array(z.string()).optional(), example_id: z.string().optional(), create_time: z @@ -408,8 +408,8 @@ export const unmarshalExampleSchema: z.ZodType = z export const unmarshalFileTableSpecSchema: z.ZodType = z .object({ - table_name: z.string().optional(), - file_col: z.string().optional(), + table_name: z.string(), + file_col: z.string(), }) .transform(d => ({ tableName: d.table_name, @@ -418,7 +418,7 @@ export const unmarshalFileTableSpecSchema: z.ZodType = z export const unmarshalFilesSpecSchema: z.ZodType = z .object({ - path: z.string().optional(), + path: z.string(), }) .transform(d => ({ path: d.path, @@ -426,9 +426,9 @@ export const unmarshalFilesSpecSchema: z.ZodType = z export const unmarshalIndexSpecSchema: z.ZodType = z .object({ - index_name: z.string().optional(), - text_col: z.string().optional(), - doc_uri_col: z.string().optional(), + index_name: z.string(), + text_col: z.string(), + doc_uri_col: z.string(), }) .transform(d => ({ indexName: d.index_name, @@ -442,8 +442,8 @@ export const unmarshalKnowledgeAssistantSchema: z.ZodType = name: z.string().optional(), state: z.string().optional(), id: z.string().optional(), - display_name: z.string().optional(), - description: z.string().optional(), + display_name: z.string(), + description: z.string(), instructions: z.string().optional(), creator: z.string().optional(), create_time: z @@ -471,9 +471,9 @@ export const unmarshalKnowledgeAssistantSchema: z.ZodType = export const unmarshalKnowledgeSourceSchema: z.ZodType = z .object({ name: z.string().optional(), - display_name: z.string().optional(), - description: z.string().optional(), - source_type: z.string().optional(), + display_name: z.string(), + description: z.string(), + source_type: z.string(), index: z.lazy(() => unmarshalIndexSpecSchema).optional(), files: z.lazy(() => unmarshalFilesSpecSchema).optional(), file_table: z.lazy(() => unmarshalFileTableSpecSchema).optional(), @@ -547,7 +547,7 @@ export const unmarshalListKnowledgeSourcesResponseSchema: z.ZodType ({ table_name: d.tableName, @@ -580,7 +580,7 @@ export const marshalFileTableSpecSchema: z.ZodType = z export const marshalFilesSpecSchema: z.ZodType = z .object({ - path: z.string().optional(), + path: z.string(), }) .transform(d => ({ path: d.path, @@ -588,9 +588,9 @@ export const marshalFilesSpecSchema: z.ZodType = z export const marshalIndexSpecSchema: z.ZodType = z .object({ - indexName: z.string().optional(), - textCol: z.string().optional(), - docUriCol: z.string().optional(), + indexName: z.string(), + textCol: z.string(), + docUriCol: z.string(), }) .transform(d => ({ index_name: d.indexName, @@ -603,8 +603,8 @@ export const marshalKnowledgeAssistantSchema: z.ZodType = z name: z.string().optional(), state: z.string().optional(), id: z.string().optional(), - displayName: z.string().optional(), - description: z.string().optional(), + displayName: z.string(), + description: z.string(), instructions: z.string().optional(), creator: z.string().optional(), createTime: z @@ -632,9 +632,9 @@ export const marshalKnowledgeAssistantSchema: z.ZodType = z export const marshalKnowledgeSourceSchema: z.ZodType = z .object({ name: z.string().optional(), - displayName: z.string().optional(), - description: z.string().optional(), - sourceType: z.string().optional(), + displayName: z.string(), + description: z.string(), + sourceType: z.string(), spec: z .discriminatedUnion('$case', [ z.object({ @@ -678,7 +678,7 @@ export const marshalKnowledgeSourceSchema: z.ZodType = z export const marshalSyncKnowledgeSourcesRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, diff --git a/packages/lakeview/src/v1/client.ts b/packages/lakeview/src/v1/client.ts index b4f1fc7e7..7a1fa6405 100644 --- a/packages/lakeview/src/v1/client.ts +++ b/packages/lakeview/src/v1/client.ts @@ -102,7 +102,11 @@ export class LakeviewClient { return this.config; } - /** Create a draft dashboard. */ + /** + * Create a draft dashboard. + * + * Requires the Databricks SQL access entitlement. + */ async createDashboard( req: CreateDashboardRequest, options?: CallOptions @@ -265,7 +269,11 @@ export class LakeviewClient { await executeCall(call, options); } - /** Get a draft dashboard. */ + /** + * Get a draft dashboard. + * + * Requires the Databricks SQL access entitlement. + */ async getDashboard( req: GetDashboardRequest, options?: CallOptions @@ -294,7 +302,12 @@ export class LakeviewClient { return resp; } - /** Get the current published dashboard. */ + /** + * Get the current published dashboard. + * + * Requires one of the following entitlements: Workspace access, + * Databricks SQL access, or Consumer access. + */ async getPublishedDashboard( req: GetPublishedDashboardRequest, options?: CallOptions @@ -323,7 +336,12 @@ export class LakeviewClient { return resp; } - /** Get a required authorization details and scopes of a published dashboard to mint an OAuth token. */ + /** + * Get a required authorization details and scopes of a published dashboard to mint an OAuth token. + * + * Requires one of the following entitlements: Workspace access, + * Databricks SQL access, or Consumer access. + */ async getPublishedDashboardTokenInfo( req: GetPublishedDashboardTokenInfoRequest, options?: CallOptions @@ -422,7 +440,11 @@ export class LakeviewClient { return resp; } - /** List dashboards. */ + /** + * List dashboards. + * + * Requires the Databricks SQL access entitlement. + */ async listDashboards( req: ListDashboardsRequest, options?: CallOptions @@ -623,7 +645,11 @@ export class LakeviewClient { return resp; } - /** Publish the current draft dashboard. */ + /** + * Publish the current draft dashboard. + * + * Requires the Databricks SQL access entitlement. + */ async publishDashboard( req: PublishDashboardRequest, options?: CallOptions @@ -653,7 +679,11 @@ export class LakeviewClient { return resp; } - /** Revert a dashboard's definition in draft mode to the last published version. */ + /** + * Revert a dashboard's definition in draft mode to the last published version. + * + * Requires the Databricks SQL access entitlement. + */ async revertDashboard( req: RevertDashboardRequest, options?: CallOptions @@ -683,7 +713,11 @@ export class LakeviewClient { return resp; } - /** Trash a dashboard. */ + /** + * Trash a dashboard. + * + * Requires the Databricks SQL access entitlement. + */ async trashDashboard( req: TrashDashboardRequest, options?: CallOptions @@ -712,7 +746,11 @@ export class LakeviewClient { return resp; } - /** Unpublish the dashboard. */ + /** + * Unpublish the dashboard. + * + * Requires the Databricks SQL access entitlement. + */ async unpublishDashboard( req: UnpublishDashboardRequest, options?: CallOptions @@ -741,7 +779,11 @@ export class LakeviewClient { return resp; } - /** Update a draft dashboard. */ + /** + * Update a draft dashboard. + * + * Requires the Databricks SQL access entitlement. + */ async updateDashboard( req: UpdateDashboardRequest, options?: CallOptions diff --git a/packages/lakeview/src/v1/model.ts b/packages/lakeview/src/v1/model.ts index 558d78d36..c75cd83db 100644 --- a/packages/lakeview/src/v1/model.ts +++ b/packages/lakeview/src/v1/model.ts @@ -64,7 +64,7 @@ export interface AuthorizationDetails_GrantRule { } export interface CreateDashboardRequest { - dashboard?: Dashboard | undefined; + dashboard: Dashboard; /** * Sets the default catalog for all datasets in this dashboard. * Does not impact table references that use fully qualified catalog names (ex: samples.nyctaxi.trips). @@ -81,12 +81,12 @@ export interface CreateDashboardRequest { export interface CreateScheduleRequest { /** The schedule to create. A dashboard is limited to 10 schedules. */ - schedule?: Schedule | undefined; + schedule: Schedule; } export interface CreateSubscriptionRequest { /** The subscription to create. A schedule is limited to 100 subscriptions. */ - subscription?: Subscription | undefined; + subscription: Subscription; } export interface CronSchedule { @@ -94,12 +94,12 @@ export interface CronSchedule { * A cron expression using quartz syntax. EX: `0 0 8 * * ?` represents everyday at 8am. * See [Cron Trigger](http://www.quartz-scheduler.org/documentation/quartz-2.3.0/tutorials/crontrigger.html) for details. */ - quartzCronExpression?: string | undefined; + quartzCronExpression: string; /** * A Java timezone id. The schedule will be resolved with respect to this timezone. * See [Java TimeZone](https://docs.oracle.com/javase/7/docs/api/java/util/TimeZone.html) for details. */ - timezoneId?: string | undefined; + timezoneId: string; } export interface Dashboard { @@ -149,9 +149,9 @@ export interface Dashboard { export interface DeleteScheduleRequest { /** UUID identifying the schedule. */ - scheduleId?: string | undefined; + scheduleId: string; /** UUID identifying the dashboard to which the schedule belongs. */ - dashboardId?: string | undefined; + dashboardId: string; /** * The etag for the schedule. Optionally, it can be provided to verify that the schedule has not * been modified from its last retrieval. @@ -161,11 +161,11 @@ export interface DeleteScheduleRequest { export interface DeleteSubscriptionRequest { /** UUID identifying the subscription. */ - subscriptionId?: string | undefined; + subscriptionId: string; /** UUID identifying the schedule which the subscription belongs. */ - scheduleId?: string | undefined; + scheduleId: string; /** UUID identifying the dashboard which the subscription belongs. */ - dashboardId?: string | undefined; + dashboardId: string; /** * The etag for the subscription. Can be optionally provided to ensure that the subscription has not been * modified since the last read. @@ -175,17 +175,17 @@ export interface DeleteSubscriptionRequest { export interface GetDashboardRequest { /** UUID identifying the dashboard. */ - dashboardId?: string | undefined; + dashboardId: string; } export interface GetPublishedDashboardRequest { /** UUID identifying the published dashboard. */ - dashboardId?: string | undefined; + dashboardId: string; } export interface GetPublishedDashboardTokenInfoRequest { /** UUID identifying the published dashboard. */ - dashboardId?: string | undefined; + dashboardId: string; /** Provided external value to be included in the custom claim. */ externalValue?: string | undefined; /** Provided external viewer id to be included in the custom claim. */ @@ -210,18 +210,18 @@ export interface GetPublishedDashboardTokenInfoResponse { export interface GetScheduleRequest { /** UUID identifying the schedule. */ - scheduleId?: string | undefined; + scheduleId: string; /** UUID identifying the dashboard to which the schedule belongs. */ - dashboardId?: string | undefined; + dashboardId: string; } export interface GetSubscriptionRequest { /** UUID identifying the subscription. */ - subscriptionId?: string | undefined; + subscriptionId: string; /** UUID identifying the schedule which the subscription belongs. */ - scheduleId?: string | undefined; + scheduleId: string; /** UUID identifying the dashboard which the subscription belongs. */ - dashboardId?: string | undefined; + dashboardId: string; } export interface ListDashboardsRequest { @@ -252,7 +252,7 @@ export interface ListDashboardsResponse { export interface ListSchedulesRequest { /** UUID identifying the dashboard to which the schedules belongs. */ - dashboardId?: string | undefined; + dashboardId: string; /** The number of schedules to return per page. */ pageSize?: number | undefined; /** @@ -273,9 +273,9 @@ export interface ListSchedulesResponse { export interface ListSubscriptionsRequest { /** UUID identifying the dashboard which the subscriptions belongs. */ - dashboardId?: string | undefined; + dashboardId: string; /** UUID identifying the schedule which the subscriptions belongs. */ - scheduleId?: string | undefined; + scheduleId: string; /** The number of subscriptions to return per page. */ pageSize?: number | undefined; /** @@ -296,7 +296,7 @@ export interface ListSubscriptionsResponse { export interface MigrateDashboardRequest { /** UUID of the dashboard to be migrated. */ - sourceDashboardId?: string | undefined; + sourceDashboardId: string; /** Display name for the new Lakeview dashboard. */ displayName?: string | undefined; /** The workspace path of the folder to contain the migrated Lakeview dashboard. */ @@ -310,7 +310,7 @@ export interface MigrateDashboardRequest { export interface PublishDashboardRequest { /** UUID identifying the dashboard to be published. */ - dashboardId?: string | undefined; + dashboardId: string; /** * Flag to indicate if the publisher's credentials should be embedded in the * published dashboard. These embedded credentials will be used to execute the @@ -338,7 +338,7 @@ export interface PublishedDashboard { /** Request to revert a dashboard draft to its last published state. */ export interface RevertDashboardRequest { /** UUID identifying the dashboard. */ - dashboardId?: string | undefined; + dashboardId: string; /** * The etag for the dashboard. Optionally, it can be provided to verify that the dashboard * has not been modified from its last retrieval. @@ -358,7 +358,7 @@ export interface Schedule { /** UUID identifying the dashboard to which the schedule belongs. */ dashboardId?: string | undefined; /** The cron expression describing the frequency of the periodic refresh for this schedule. */ - cronSchedule?: CronSchedule | undefined; + cronSchedule: CronSchedule; /** The status indicates whether this schedule is paused or not. */ pauseStatus?: SchedulePauseStatus | undefined; /** The display name for schedule. */ @@ -384,7 +384,7 @@ export interface Subscription { /** UUID identifying the dashboard to which the subscription belongs. */ dashboardId?: string | undefined; /** Subscriber details for users and destinations to be added as subscribers to the schedule. */ - subscriber?: Subscription_Subscriber | undefined; + subscriber: Subscription_Subscriber; /** UserId of the user who adds subscribers (users or notification destinations) to the dashboard's schedule. */ createdByUserId?: bigint | undefined; /** @@ -420,18 +420,18 @@ export interface Subscription_Subscriber { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface Subscription_Subscriber_Destination { /** The canonical identifier of the destination to receive email notification. */ - destinationId?: string | undefined; + destinationId: string; } // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface Subscription_Subscriber_User { /** UserId of the subscriber. */ - userId?: bigint | undefined; + userId: bigint; } export interface TrashDashboardRequest { /** UUID identifying the dashboard. */ - dashboardId?: string | undefined; + dashboardId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -439,14 +439,14 @@ export interface TrashDashboardResponse {} export interface UnpublishDashboardRequest { /** UUID identifying the published dashboard. */ - dashboardId?: string | undefined; + dashboardId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface UnpublishDashboardResponse {} export interface UpdateDashboardRequest { - dashboard?: Dashboard | undefined; + dashboard: Dashboard; /** * Sets the default catalog for all datasets in this dashboard. * Does not impact table references that use fully qualified catalog names (ex: samples.nyctaxi.trips). @@ -463,7 +463,7 @@ export interface UpdateDashboardRequest { export interface UpdateScheduleRequest { /** The schedule to update. */ - schedule?: Schedule | undefined; + schedule: Schedule; } export const unmarshalAuthorizationDetailsSchema: z.ZodType = @@ -495,8 +495,8 @@ export const unmarshalAuthorizationDetails_GrantRuleSchema: z.ZodType = z .object({ - quartz_cron_expression: z.string().optional(), - timezone_id: z.string().optional(), + quartz_cron_expression: z.string(), + timezone_id: z.string(), }) .transform(d => ({ quartzCronExpression: d.quartz_cron_expression, @@ -616,7 +616,7 @@ export const unmarshalScheduleSchema: z.ZodType = z .object({ schedule_id: z.string().optional(), dashboard_id: z.string().optional(), - cron_schedule: z.lazy(() => unmarshalCronScheduleSchema).optional(), + cron_schedule: z.lazy(() => unmarshalCronScheduleSchema), pause_status: z.string().optional(), display_name: z.string().optional(), etag: z.string().optional(), @@ -647,7 +647,7 @@ export const unmarshalSubscriptionSchema: z.ZodType = z subscription_id: z.string().optional(), schedule_id: z.string().optional(), dashboard_id: z.string().optional(), - subscriber: z.lazy(() => unmarshalSubscription_SubscriberSchema).optional(), + subscriber: z.lazy(() => unmarshalSubscription_SubscriberSchema), created_by_user_id: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) @@ -695,7 +695,7 @@ export const unmarshalSubscription_SubscriberSchema: z.ZodType = z .object({ - destination_id: z.string().optional(), + destination_id: z.string(), }) .transform(d => ({ destinationId: d.destination_id, @@ -707,8 +707,7 @@ export const unmarshalSubscription_Subscriber_UserSchema: z.ZodType BigInt(v)) - .optional(), + .transform(v => BigInt(v)), }) .transform(d => ({ userId: d.user_id, @@ -722,8 +721,8 @@ export const unmarshalUnpublishDashboardResponseSchema: z.ZodType ({ quartz_cron_expression: d.quartzCronExpression, @@ -764,7 +763,7 @@ export const marshalDashboardSchema: z.ZodType = z export const marshalMigrateDashboardRequestSchema: z.ZodType = z .object({ - sourceDashboardId: z.string().optional(), + sourceDashboardId: z.string(), displayName: z.string().optional(), parentPath: z.string().optional(), updateParameterSyntax: z.boolean().optional(), @@ -778,7 +777,7 @@ export const marshalMigrateDashboardRequestSchema: z.ZodType = z export const marshalPublishDashboardRequestSchema: z.ZodType = z .object({ - dashboardId: z.string().optional(), + dashboardId: z.string(), embedCredentials: z.boolean().optional(), warehouseId: z.string().optional(), }) @@ -790,7 +789,7 @@ export const marshalPublishDashboardRequestSchema: z.ZodType = z export const marshalRevertDashboardRequestSchema: z.ZodType = z .object({ - dashboardId: z.string().optional(), + dashboardId: z.string(), etag: z.string().optional(), }) .transform(d => ({ @@ -802,7 +801,7 @@ export const marshalScheduleSchema: z.ZodType = z .object({ scheduleId: z.string().optional(), dashboardId: z.string().optional(), - cronSchedule: z.lazy(() => marshalCronScheduleSchema).optional(), + cronSchedule: z.lazy(() => marshalCronScheduleSchema), pauseStatus: z.string().optional(), displayName: z.string().optional(), etag: z.string().optional(), @@ -833,7 +832,7 @@ export const marshalSubscriptionSchema: z.ZodType = z subscriptionId: z.string().optional(), scheduleId: z.string().optional(), dashboardId: z.string().optional(), - subscriber: z.lazy(() => marshalSubscription_SubscriberSchema).optional(), + subscriber: z.lazy(() => marshalSubscription_SubscriberSchema), createdByUserId: z.bigint().optional(), etag: z.string().optional(), createTime: z @@ -876,7 +875,7 @@ export const marshalSubscription_SubscriberSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalSubscription_Subscriber_DestinationSchema: z.ZodType = z .object({ - destinationId: z.string().optional(), + destinationId: z.string(), }) .transform(d => ({ destination_id: d.destinationId, @@ -885,7 +884,7 @@ export const marshalSubscription_Subscriber_DestinationSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalSubscription_Subscriber_UserSchema: z.ZodType = z .object({ - userId: z.bigint().optional(), + userId: z.bigint(), }) .transform(d => ({ user_id: d.userId, diff --git a/packages/logdelivery/src/v1/model.ts b/packages/logdelivery/src/v1/model.ts index 68bc28f90..19c9d4a07 100644 --- a/packages/logdelivery/src/v1/model.ts +++ b/packages/logdelivery/src/v1/model.ts @@ -90,19 +90,19 @@ export interface CreateLogDeliveryConfigurationParams { * * `BILLABLE_USAGE` — Configure [billable usage log delivery](https://docs.databricks.com/administration-guide/account-settings/billable-usage-delivery.html). For the CSV schema, see the [View billable usage](https://docs.databricks.com/administration-guide/account-settings/usage.html). * * `AUDIT_LOGS` — Configure [audit log delivery](https://docs.databricks.com/administration-guide/account-settings/audit-logs.html). For the JSON schema, see [Configure audit logging](https://docs.databricks.com/administration-guide/account-settings/audit-logs.html) */ - logType?: LogDeliveryType | undefined; + logType: LogDeliveryType; /** * The file type of log delivery. * * If `log_type` is `BILLABLE_USAGE`, this value must be `CSV`. Only the CSV (comma-separated values) format is supported. For the schema, see the [View billable usage](https://docs.databricks.com/administration-guide/account-settings/usage.html) * * If `log_type` is `AUDIT_LOGS`, this value must be `JSON`. Only the JSON (JavaScript Object Notation) format is supported. For the schema, see the [Configuring audit logs](https://docs.databricks.com/administration-guide/account-settings/audit-logs.html). */ - outputFormat?: LogDeliveryOutputFormat | undefined; + outputFormat: LogDeliveryOutputFormat; /** account ID. */ - accountId?: string | undefined; + accountId: string; /** The ID for a method:credentials/create that represents the AWS IAM role with policy and trust relationship as described in the main billable usage documentation page. See [Configure billable usage delivery](https://docs.databricks.com/administration-guide/account-settings/billable-usage-delivery.html). */ - credentialsId?: string | undefined; + credentialsId: string; /** The ID for a method:storage/create that represents the S3 bucket with bucket policy as described in the main billable usage documentation page. See [Configure billable usage delivery](https://docs.databricks.com/administration-guide/account-settings/billable-usage-delivery.html). */ - storageConfigurationId?: string | undefined; + storageConfigurationId: string; /** Optional filter that specifies workspace IDs to deliver logs for. By default the workspace filter is empty and log delivery applies at the account level, delivering workspace-level logs for all workspaces in your account, plus account level logs. You can optionally set this field to an array of workspace IDs (each one is an `int64`) to which log delivery should apply, in which case only workspace-level logs relating to the specified workspaces are delivered. If you plan to use different log delivery configurations for different workspaces, set this field explicitly. Be aware that delivery configurations mentioning specific workspaces won't apply to new workspaces created in the future, and delivery won't include account level logs. For some types of deployments there is only one workspace per account ID, so this field is unnecessary. */ workspaceIdsFilter?: bigint[] | undefined; /** The optional delivery path prefix within Amazon S3 storage. Defaults to empty, which means that logs are delivered to the root of the bucket. This must be a valid S3 object key. This must not start or end with a slash character. */ @@ -124,7 +124,7 @@ export interface CreateLogDeliveryConfigurationParams { * Properties of the new log delivery configuration. */ export interface CreateLogDeliveryConfigurationRequest { - logDeliveryConfiguration?: CreateLogDeliveryConfigurationParams | undefined; + logDeliveryConfiguration: CreateLogDeliveryConfigurationParams; } export interface CreateLogDeliveryConfigurationResponse { @@ -138,9 +138,9 @@ export interface CreateLogDeliveryConfigurationResponse { */ export interface GetLogDeliveryConfigurationRequest { /** The log delivery configuration id of customer */ - configId?: string | undefined; + configId: string; /** account ID. */ - accountId?: string | undefined; + accountId: string; } export interface GetLogDeliveryConfigurationResponse { @@ -154,7 +154,7 @@ export interface GetLogDeliveryConfigurationResponse { */ export interface ListLogDeliveryConfigurationRequest { /** account ID. */ - accountId?: string | undefined; + accountId: string; /** The Credentials id to filter the search results with */ credentialsId?: string | undefined; /** The Storage Configuration id to filter the search results with */ @@ -189,19 +189,19 @@ export interface LogDeliveryConfiguration { * * `BILLABLE_USAGE` — Configure [billable usage log delivery](https://docs.databricks.com/administration-guide/account-settings/billable-usage-delivery.html). For the CSV schema, see the [View billable usage](https://docs.databricks.com/administration-guide/account-settings/usage.html). * * `AUDIT_LOGS` — Configure [audit log delivery](https://docs.databricks.com/administration-guide/account-settings/audit-logs.html). For the JSON schema, see [Configure audit logging](https://docs.databricks.com/administration-guide/account-settings/audit-logs.html) */ - logType?: LogDeliveryType | undefined; + logType: LogDeliveryType; /** * The file type of log delivery. * * If `log_type` is `BILLABLE_USAGE`, this value must be `CSV`. Only the CSV (comma-separated values) format is supported. For the schema, see the [View billable usage](https://docs.databricks.com/administration-guide/account-settings/usage.html) * * If `log_type` is `AUDIT_LOGS`, this value must be `JSON`. Only the JSON (JavaScript Object Notation) format is supported. For the schema, see the [Configuring audit logs](https://docs.databricks.com/administration-guide/account-settings/audit-logs.html). */ - outputFormat?: LogDeliveryOutputFormat | undefined; + outputFormat: LogDeliveryOutputFormat; /** account ID. */ - accountId?: string | undefined; + accountId: string; /** The ID for a method:credentials/create that represents the AWS IAM role with policy and trust relationship as described in the main billable usage documentation page. See [Configure billable usage delivery](https://docs.databricks.com/administration-guide/account-settings/billable-usage-delivery.html). */ - credentialsId?: string | undefined; + credentialsId: string; /** The ID for a method:storage/create that represents the S3 bucket with bucket policy as described in the main billable usage documentation page. See [Configure billable usage delivery](https://docs.databricks.com/administration-guide/account-settings/billable-usage-delivery.html). */ - storageConfigurationId?: string | undefined; + storageConfigurationId: string; /** Optional filter that specifies workspace IDs to deliver logs for. By default the workspace filter is empty and log delivery applies at the account level, delivering workspace-level logs for all workspaces in your account, plus account level logs. You can optionally set this field to an array of workspace IDs (each one is an `int64`) to which log delivery should apply, in which case only workspace-level logs relating to the specified workspaces are delivered. If you plan to use different log delivery configurations for different workspaces, set this field explicitly. Be aware that delivery configurations mentioning specific workspaces won't apply to new workspaces created in the future, and delivery won't include account level logs. For some types of deployments there is only one workspace per account ID, so this field is unnecessary. */ workspaceIdsFilter?: bigint[] | undefined; /** The optional delivery path prefix within Amazon S3 storage. Defaults to empty, which means that logs are delivered to the root of the bucket. This must be a valid S3 object key. This must not start or end with a slash character. */ @@ -227,13 +227,13 @@ export interface LogDeliveryStatus { * * `SYSTEM_FAILURE`: The latest attempt of log delivery failed because of an internal error. Contact support if it doesn't go away soon. * * `NOT_FOUND`: The log delivery status as the configuration has been disabled since the release of this feature or there are no workspaces in the account. */ - status?: LogDeliveryStatusEnum | undefined; + status: LogDeliveryStatusEnum; /** The UTC time for the latest log delivery attempt. */ lastAttemptTime?: string | undefined; /** The UTC time for the latest successful log delivery. */ lastSuccessfulAttemptTime?: string | undefined; /** Informative message about the latest log delivery attempt. If the log delivery fails with USER_FAILURE, error details will be provided for fixing misconfigurations in cloud permissions. */ - message?: string | undefined; + message: string; } /** @@ -242,11 +242,11 @@ export interface LogDeliveryStatus { */ export interface UpdateLogDeliveryConfigurationRequest { /** The log delivery configuration id of customer */ - configId?: string | undefined; + configId: string; /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html). */ - accountId?: string | undefined; + accountId: string; /** Status of log delivery configuration. Set to `ENABLED` (enabled) or `DISABLED` (disabled). Defaults to `ENABLED`. You can [enable or disable the configuration](#operation/patch-log-delivery-config-status) later. Deletion of a configuration is not supported, so disable a log delivery configuration that is no longer needed. */ - status?: LogDeliveryConfigStatus | undefined; + status: LogDeliveryConfigStatus; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -292,11 +292,11 @@ export const unmarshalLogDeliveryConfigurationSchema: z.ZodType = z .object({ - status: z.string().optional(), + status: z.string(), last_attempt_time: z.string().optional(), last_successful_attempt_time: z.string().optional(), - message: z.string().optional(), + message: z.string(), }) .transform(d => ({ status: d.status, @@ -357,11 +357,11 @@ export const marshalCreateLogDeliveryConfigurationParamsSchema: z.ZodType = z .object({ configId: z.string().optional(), configName: z.string().optional(), - logType: z.string().optional(), - outputFormat: z.string().optional(), - accountId: z.string().optional(), - credentialsId: z.string().optional(), - storageConfigurationId: z.string().optional(), + logType: z.string(), + outputFormat: z.string(), + accountId: z.string(), + credentialsId: z.string(), + storageConfigurationId: z.string(), workspaceIdsFilter: z.array(z.bigint()).optional(), deliveryPathPrefix: z.string().optional(), deliveryStartTime: z.string().optional(), @@ -389,9 +389,9 @@ export const marshalCreateLogDeliveryConfigurationParamsSchema: z.ZodType = z export const marshalCreateLogDeliveryConfigurationRequestSchema: z.ZodType = z .object({ - logDeliveryConfiguration: z - .lazy(() => marshalCreateLogDeliveryConfigurationParamsSchema) - .optional(), + logDeliveryConfiguration: z.lazy( + () => marshalCreateLogDeliveryConfigurationParamsSchema + ), }) .transform(d => ({ log_delivery_configuration: d.logDeliveryConfiguration, @@ -399,10 +399,10 @@ export const marshalCreateLogDeliveryConfigurationRequestSchema: z.ZodType = z export const marshalLogDeliveryStatusSchema: z.ZodType = z .object({ - status: z.string().optional(), + status: z.string(), lastAttemptTime: z.string().optional(), lastSuccessfulAttemptTime: z.string().optional(), - message: z.string().optional(), + message: z.string(), }) .transform(d => ({ status: d.status, @@ -413,9 +413,9 @@ export const marshalLogDeliveryStatusSchema: z.ZodType = z export const marshalUpdateLogDeliveryConfigurationRequestSchema: z.ZodType = z .object({ - configId: z.string().optional(), - accountId: z.string().optional(), - status: z.string().optional(), + configId: z.string(), + accountId: z.string(), + status: z.string(), }) .transform(d => ({ config_id: d.configId, diff --git a/packages/marketplaces/src/v1/model.ts b/packages/marketplaces/src/v1/model.ts index 790abbd1c..c90b51e58 100644 --- a/packages/marketplaces/src/v1/model.ts +++ b/packages/marketplaces/src/v1/model.ts @@ -205,8 +205,8 @@ export type Visibility = | (string & {}); export interface AddExchangeForListingRequest { - listingId?: string | undefined; - exchangeId?: string | undefined; + listingId: string; + exchangeId: string; } export interface AddExchangeForListingResponse { @@ -230,7 +230,7 @@ export interface BatchGetProvidersResponse { } export interface ConsumerTerms { - version?: string | undefined; + version: string; } /** contact info for the consumer requesting data or performing a listing installation */ @@ -242,7 +242,7 @@ export interface ContactInfo { } export interface CreateExchangeFilterRequest { - filter?: ExchangeFilter | undefined; + filter: ExchangeFilter; } export interface CreateExchangeFilterResponse { @@ -250,7 +250,7 @@ export interface CreateExchangeFilterResponse { } export interface CreateExchangeRequest { - exchange?: Exchange | undefined; + exchange: Exchange; } export interface CreateExchangeResponse { @@ -258,9 +258,9 @@ export interface CreateExchangeResponse { } export interface CreateFileRequest { - fileParent?: FileParent | undefined; - marketplaceFileType?: MarketplaceFileType | undefined; - mimeType?: string | undefined; + fileParent: FileParent; + marketplaceFileType: MarketplaceFileType; + mimeType: string; displayName?: string | undefined; } @@ -271,7 +271,7 @@ export interface CreateFileResponse { } export interface CreateInstallationRequest { - listingId?: string | undefined; + listingId: string; shareName?: string | undefined; catalogName?: string | undefined; /** for git repo installations */ @@ -285,7 +285,7 @@ export interface CreateInstallationResponse { } export interface CreateListingRequest { - listing?: Listing | undefined; + listing: Listing; } export interface CreateListingResponse { @@ -297,15 +297,15 @@ export interface CreateListingResponse { * also creates a lead (maybe) */ export interface CreatePersonalizationRequest { - listingId?: string | undefined; + listingId: string; comment?: string | undefined; - intendedUse?: string | undefined; + intendedUse: string; firstName?: string | undefined; lastName?: string | undefined; company?: string | undefined; isFromLighthouse?: boolean | undefined; recipientType?: DeltaSharingRecipientType | undefined; - acceptedConsumerTerms?: ConsumerTerms | undefined; + acceptedConsumerTerms: ConsumerTerms; } export interface CreatePersonalizationResponse { @@ -316,11 +316,11 @@ export interface CreatePersonalizationResponse { export interface CreateProviderAnalyticsDashboardRequest {} export interface CreateProviderAnalyticsDashboardResponse { - id?: string | undefined; + id: string; } export interface CreateProviderRequest { - provider?: ProviderInfo | undefined; + provider: ProviderInfo; } export interface CreateProviderResponse { @@ -328,48 +328,48 @@ export interface CreateProviderResponse { } export interface DataRefreshInfo { - interval?: bigint | undefined; - unit?: DataRefresh | undefined; + interval: bigint; + unit: DataRefresh; } export interface DeleteExchangeFilterRequest { - id?: string | undefined; + id: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface DeleteExchangeFilterResponse {} export interface DeleteExchangeRequest { - id?: string | undefined; + id: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface DeleteExchangeResponse {} export interface DeleteFileRequest { - fileId?: string | undefined; + fileId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface DeleteFileResponse {} export interface DeleteInstallationRequest { - listingId?: string | undefined; - installationId?: string | undefined; + listingId: string; + installationId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface DeleteInstallationResponse {} export interface DeleteListingRequest { - id?: string | undefined; + id: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface DeleteListingResponse {} export interface DeleteProviderRequest { - id?: string | undefined; + id: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -377,7 +377,7 @@ export interface DeleteProviderResponse {} export interface Exchange { id?: string | undefined; - name?: string | undefined; + name: string; comment?: string | undefined; filters?: ExchangeFilter[] | undefined; createdAt?: bigint | undefined; @@ -389,14 +389,14 @@ export interface Exchange { export interface ExchangeFilter { id?: string | undefined; - exchangeId?: string | undefined; - filterValue?: string | undefined; + exchangeId: string; + filterValue: string; name?: string | undefined; createdAt?: bigint | undefined; createdBy?: string | undefined; updatedAt?: bigint | undefined; updatedBy?: string | undefined; - filterType?: ExchangeFilterType | undefined; + filterType: ExchangeFilterType; } export interface ExchangeListing { @@ -435,7 +435,7 @@ export interface GetAllPersonalizationRequestsForConsumerResponse { } export interface GetExchangeRequest { - id?: string | undefined; + id: string; } export interface GetExchangeResponse { @@ -443,7 +443,7 @@ export interface GetExchangeResponse { } export interface GetFileRequest { - fileId?: string | undefined; + fileId: string; } export interface GetFileResponse { @@ -451,7 +451,7 @@ export interface GetFileResponse { } export interface GetInstallationDetailsRequest { - listingId?: string | undefined; + listingId: string; pageToken?: string | undefined; pageSize?: number | undefined; } @@ -469,7 +469,7 @@ export interface GetLatestVersionProviderAnalyticsDashboardResponse { } export interface GetListingContentMetadataRequest { - listingId?: string | undefined; + listingId: string; pageToken?: string | undefined; pageSize?: number | undefined; } @@ -480,7 +480,7 @@ export interface GetListingContentMetadataResponse { } export interface GetListingRequest { - id?: string | undefined; + id: string; } export interface GetListingResponse { @@ -493,7 +493,7 @@ export interface GetListingsResponse { } export interface GetPersonalizationRequestsForConsumerRequest { - listingId?: string | undefined; + listingId: string; } export interface GetPersonalizationRequestsForConsumerResponse { @@ -511,7 +511,7 @@ export interface GetPersonalizationRequestsForProviderResponse { } export interface GetProviderRequest { - id?: string | undefined; + id: string; } export interface GetProviderResponse { @@ -519,7 +519,7 @@ export interface GetProviderResponse { } export interface GetPublishedListingForConsumerRequest { - id?: string | undefined; + id: string; } export interface GetPublishedListingForConsumerResponse { @@ -532,7 +532,7 @@ export interface GetPublishedListingsForConsumerResponse { } export interface GetPublishedProviderForConsumerRequest { - id?: string | undefined; + id: string; } export interface GetPublishedProviderForConsumerResponse { @@ -561,7 +561,7 @@ export interface ListAllInstallationsResponse { } export interface ListExchangeFiltersRequest { - exchangeId?: string | undefined; + exchangeId: string; pageToken?: string | undefined; pageSize?: number | undefined; } @@ -572,7 +572,7 @@ export interface ListExchangeFiltersResponse { } export interface ListExchangesForListingRequest { - listingId?: string | undefined; + listingId: string; pageToken?: string | undefined; pageSize?: number | undefined; } @@ -593,7 +593,7 @@ export interface ListExchangesResponse { } export interface ListFilesRequest { - fileParent?: FileParent | undefined; + fileParent: FileParent; pageToken?: string | undefined; pageSize?: number | undefined; } @@ -619,13 +619,13 @@ export interface ListInstallationsResponse { } export interface ListListingFulfillmentsRequest { - listingId?: string | undefined; + listingId: string; pageToken?: string | undefined; pageSize?: number | undefined; } export interface ListListingsForExchangeRequest { - exchangeId?: string | undefined; + exchangeId: string; pageToken?: string | undefined; pageSize?: number | undefined; } @@ -649,10 +649,10 @@ export interface ListPersonalizationRequestsForConsumerRequest { export interface ListProviderAnalyticsDashboardRequest {} export interface ListProviderAnalyticsDashboardResponse { - id?: string | undefined; + id: string; version?: bigint | undefined; /** dashboard_id will be used to open Lakeview dashboard. */ - dashboardId?: string | undefined; + dashboardId: string; } export interface ListProvidersRequest { @@ -698,7 +698,7 @@ export interface ListPublishedProvidersForConsumerResponse { export interface Listing { id?: string | undefined; - summary?: ListingSummary | undefined; + summary: ListingSummary; detail?: ListingDetail | undefined; } @@ -749,7 +749,7 @@ export interface ListingDetail { } export interface ListingFulfillment { - listingId?: string | undefined; + listingId: string; fulfillmentType?: FulfillmentType | undefined; shareInfo?: ShareInfo | undefined; repoInfo?: RepoInfo | undefined; @@ -761,7 +761,7 @@ export interface ListingSetting { } export interface ListingSummary { - name?: string | undefined; + name: string; subtitle?: string | undefined; status?: ListingStatus | undefined; share?: ShareInfo | undefined; @@ -774,7 +774,7 @@ export interface ListingSummary { publishedAt?: bigint | undefined; publishedBy?: string | undefined; categories?: Category[] | undefined; - listingType?: ListingType | undefined; + listingType: ListingType; createdById?: bigint | undefined; updatedById?: bigint | undefined; providerId?: string | undefined; @@ -792,7 +792,7 @@ export interface ListingTag { export interface PersonalizationRequest { id?: string | undefined; - consumerRegion?: RegionInfo | undefined; + consumerRegion: RegionInfo; contactInfo?: ContactInfo | undefined; comment?: string | undefined; intendedUse?: string | undefined; @@ -815,10 +815,10 @@ export interface PersonalizationRequest { export interface ProviderInfo { id?: string | undefined; - name?: string | undefined; + name: string; description?: string | undefined; iconFilePath?: string | undefined; - businessContactEmail?: string | undefined; + businessContactEmail: string; supportContactEmail?: string | undefined; /** is_featured is accessible by consumers only */ isFeatured?: boolean | undefined; @@ -826,8 +826,8 @@ export interface ProviderInfo { publishedBy?: string | undefined; companyWebsiteLink?: string | undefined; iconFileId?: string | undefined; - termOfServiceLink?: string | undefined; - privacyPolicyLink?: string | undefined; + termOfServiceLink: string; + privacyPolicyLink: string; darkModeIconFileId?: string | undefined; darkModeIconFilePath?: string | undefined; } @@ -838,7 +838,7 @@ export interface RegionInfo { } export interface RemoveExchangeForListingRequest { - id?: string | undefined; + id: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -846,22 +846,22 @@ export interface RemoveExchangeForListingResponse {} export interface RepoInfo { /** the git repo url e.g. https://github.com/databrickslabs/dolly.git */ - gitRepoUrl?: string | undefined; + gitRepoUrl: string; } export interface RepoInstallation { /** the user-specified repo name for their installed git repo listing */ - repoName?: string | undefined; + repoName: string; /** * refers to the full url file path that navigates the user to the repo's entrypoint (e.g. a README.md file, or the repo file view in the unified UI) * should just be a relative path */ - repoPath?: string | undefined; + repoPath: string; } export interface SearchPublishedListingsForConsumerRequest { /** Fuzzy matches query */ - query?: string | undefined; + query: string; isFree?: boolean | undefined; isPrivateExchange?: boolean | undefined; /** Matches any of the following provider ids */ @@ -880,8 +880,8 @@ export interface SearchPublishedListingsForConsumerResponse { } export interface ShareInfo { - name?: string | undefined; - type?: ListingShareType | undefined; + name: string; + type: ListingShareType; } export interface SharedDataObject { @@ -923,8 +923,8 @@ export interface TokenInfo { } export interface UpdateExchangeFilterRequest { - id?: string | undefined; - filter?: ExchangeFilter | undefined; + id: string; + filter: ExchangeFilter; } export interface UpdateExchangeFilterResponse { @@ -932,8 +932,8 @@ export interface UpdateExchangeFilterResponse { } export interface UpdateExchangeRequest { - id?: string | undefined; - exchange?: Exchange | undefined; + id: string; + exchange: Exchange; } export interface UpdateExchangeResponse { @@ -941,9 +941,9 @@ export interface UpdateExchangeResponse { } export interface UpdateInstallationRequest { - listingId?: string | undefined; - installationId?: string | undefined; - installation?: InstallationDetail | undefined; + listingId: string; + installationId: string; + installation: InstallationDetail; rotateToken?: boolean | undefined; } @@ -952,8 +952,8 @@ export interface UpdateInstallationResponse { } export interface UpdateListingRequest { - id?: string | undefined; - listing?: Listing | undefined; + id: string; + listing: Listing; } export interface UpdateListingResponse { @@ -961,9 +961,9 @@ export interface UpdateListingResponse { } export interface UpdatePersonalizationRequestStatusRequest { - listingId?: string | undefined; - requestId?: string | undefined; - status?: PersonalizationRequestStatus | undefined; + listingId: string; + requestId: string; + status: PersonalizationRequestStatus; reason?: string | undefined; share?: ShareInfo | undefined; } @@ -974,7 +974,7 @@ export interface UpdatePersonalizationRequestStatusResponse { export interface UpdateProviderAnalyticsDashboardRequest { /** id is immutable property and can't be updated. */ - id?: string | undefined; + id: string; /** * this is the version of the dashboard template we want to update our user to * current expectation is that it should be equal to latest version of the dashboard template @@ -984,15 +984,15 @@ export interface UpdateProviderAnalyticsDashboardRequest { export interface UpdateProviderAnalyticsDashboardResponse { /** id & version should be the same as the request */ - id?: string | undefined; + id: string; version?: bigint | undefined; /** this is newly created Lakeview dashboard for the user */ - dashboardId?: string | undefined; + dashboardId: string; } export interface UpdateProviderRequest { - id?: string | undefined; - provider?: ProviderInfo | undefined; + id: string; + provider: ProviderInfo; } export interface UpdateProviderResponse { @@ -1101,7 +1101,7 @@ export const unmarshalCreatePersonalizationResponseSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), }) .transform(d => ({ id: d.id, @@ -1120,9 +1120,8 @@ export const unmarshalDataRefreshInfoSchema: z.ZodType = z .object({ interval: z .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), - unit: z.string().optional(), + .transform(v => BigInt(v)), + unit: z.string(), }) .transform(d => ({ interval: d.interval, @@ -1150,7 +1149,7 @@ export const unmarshalDeleteProviderResponseSchema: z.ZodType = z .object({ id: z.string().optional(), - name: z.string().optional(), + name: z.string(), comment: z.string().optional(), filters: z.array(z.lazy(() => unmarshalExchangeFilterSchema)).optional(), created_at: z @@ -1182,8 +1181,8 @@ export const unmarshalExchangeSchema: z.ZodType = z export const unmarshalExchangeFilterSchema: z.ZodType = z .object({ id: z.string().optional(), - exchange_id: z.string().optional(), - filter_value: z.string().optional(), + exchange_id: z.string(), + filter_value: z.string(), name: z.string().optional(), created_at: z .union([z.number(), z.bigint(), z.string()]) @@ -1195,7 +1194,7 @@ export const unmarshalExchangeFilterSchema: z.ZodType = z .transform(v => BigInt(v)) .optional(), updated_by: z.string().optional(), - filter_type: z.string().optional(), + filter_type: z.string(), }) .transform(d => ({ id: d.id, @@ -1547,12 +1546,12 @@ export const unmarshalListListingsForExchangeResponseSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), version: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) .optional(), - dashboard_id: z.string().optional(), + dashboard_id: z.string(), }) .transform(d => ({ id: d.id, @@ -1585,7 +1584,7 @@ export const unmarshalListPublishedProvidersForConsumerResponseSchema: z.ZodType export const unmarshalListingSchema: z.ZodType = z .object({ id: z.string().optional(), - summary: z.lazy(() => unmarshalListingSummarySchema).optional(), + summary: z.lazy(() => unmarshalListingSummarySchema), detail: z.lazy(() => unmarshalListingDetailSchema).optional(), }) .transform(d => ({ @@ -1651,7 +1650,7 @@ export const unmarshalListingDetailSchema: z.ZodType = z export const unmarshalListingFulfillmentSchema: z.ZodType = z .object({ - listing_id: z.string().optional(), + listing_id: z.string(), fulfillment_type: z.string().optional(), share_info: z.lazy(() => unmarshalShareInfoSchema).optional(), repo_info: z.lazy(() => unmarshalRepoInfoSchema).optional(), @@ -1675,7 +1674,7 @@ export const unmarshalListingSettingSchema: z.ZodType = z export const unmarshalListingSummarySchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), subtitle: z.string().optional(), status: z.string().optional(), share: z.lazy(() => unmarshalShareInfoSchema).optional(), @@ -1697,7 +1696,7 @@ export const unmarshalListingSummarySchema: z.ZodType = z .optional(), published_by: z.string().optional(), categories: z.array(z.string()).optional(), - listingType: z.string().optional(), + listingType: z.string(), created_by_id: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) @@ -1746,7 +1745,7 @@ export const unmarshalPersonalizationRequestSchema: z.ZodType unmarshalRegionInfoSchema).optional(), + consumer_region: z.lazy(() => unmarshalRegionInfoSchema), contact_info: z.lazy(() => unmarshalContactInfoSchema).optional(), comment: z.string().optional(), intended_use: z.string().optional(), @@ -1790,17 +1789,17 @@ export const unmarshalPersonalizationRequestSchema: z.ZodType = z .object({ id: z.string().optional(), - name: z.string().optional(), + name: z.string(), description: z.string().optional(), icon_file_path: z.string().optional(), - business_contact_email: z.string().optional(), + business_contact_email: z.string(), support_contact_email: z.string().optional(), is_featured: z.boolean().optional(), published_by: z.string().optional(), company_website_link: z.string().optional(), icon_file_id: z.string().optional(), - term_of_service_link: z.string().optional(), - privacy_policy_link: z.string().optional(), + term_of_service_link: z.string(), + privacy_policy_link: z.string(), dark_mode_icon_file_id: z.string().optional(), dark_mode_icon_file_path: z.string().optional(), }) @@ -1836,7 +1835,7 @@ export const unmarshalRemoveExchangeForListingResponseSchema: z.ZodType = z .object({ - git_repo_url: z.string().optional(), + git_repo_url: z.string(), }) .transform(d => ({ gitRepoUrl: d.git_repo_url, @@ -1855,8 +1854,8 @@ export const unmarshalSearchPublishedListingsForConsumerResponseSchema: z.ZodTyp export const unmarshalShareInfoSchema: z.ZodType = z .object({ - name: z.string().optional(), - type: z.string().optional(), + name: z.string(), + type: z.string(), }) .transform(d => ({ name: d.name, @@ -1964,12 +1963,12 @@ export const unmarshalUpdatePersonalizationRequestStatusResponseSchema: z.ZodTyp export const unmarshalUpdateProviderAnalyticsDashboardResponseSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), version: z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) .optional(), - dashboard_id: z.string().optional(), + dashboard_id: z.string(), }) .transform(d => ({ id: d.id, @@ -1988,8 +1987,8 @@ export const unmarshalUpdateProviderResponseSchema: z.ZodType ({ listing_id: d.listingId, @@ -1998,7 +1997,7 @@ export const marshalAddExchangeForListingRequestSchema: z.ZodType = z export const marshalConsumerTermsSchema: z.ZodType = z .object({ - version: z.string().optional(), + version: z.string(), }) .transform(d => ({ version: d.version, @@ -2006,7 +2005,7 @@ export const marshalConsumerTermsSchema: z.ZodType = z export const marshalCreateExchangeFilterRequestSchema: z.ZodType = z .object({ - filter: z.lazy(() => marshalExchangeFilterSchema).optional(), + filter: z.lazy(() => marshalExchangeFilterSchema), }) .transform(d => ({ filter: d.filter, @@ -2014,7 +2013,7 @@ export const marshalCreateExchangeFilterRequestSchema: z.ZodType = z export const marshalCreateExchangeRequestSchema: z.ZodType = z .object({ - exchange: z.lazy(() => marshalExchangeSchema).optional(), + exchange: z.lazy(() => marshalExchangeSchema), }) .transform(d => ({ exchange: d.exchange, @@ -2022,9 +2021,9 @@ export const marshalCreateExchangeRequestSchema: z.ZodType = z export const marshalCreateFileRequestSchema: z.ZodType = z .object({ - fileParent: z.lazy(() => marshalFileParentSchema).optional(), - marketplaceFileType: z.string().optional(), - mimeType: z.string().optional(), + fileParent: z.lazy(() => marshalFileParentSchema), + marketplaceFileType: z.string(), + mimeType: z.string(), displayName: z.string().optional(), }) .transform(d => ({ @@ -2036,7 +2035,7 @@ export const marshalCreateFileRequestSchema: z.ZodType = z export const marshalCreateInstallationRequestSchema: z.ZodType = z .object({ - listingId: z.string().optional(), + listingId: z.string(), shareName: z.string().optional(), catalogName: z.string().optional(), repoDetail: z.lazy(() => marshalRepoInstallationSchema).optional(), @@ -2054,7 +2053,7 @@ export const marshalCreateInstallationRequestSchema: z.ZodType = z export const marshalCreateListingRequestSchema: z.ZodType = z .object({ - listing: z.lazy(() => marshalListingSchema).optional(), + listing: z.lazy(() => marshalListingSchema), }) .transform(d => ({ listing: d.listing, @@ -2062,15 +2061,15 @@ export const marshalCreateListingRequestSchema: z.ZodType = z export const marshalCreatePersonalizationRequestSchema: z.ZodType = z .object({ - listingId: z.string().optional(), + listingId: z.string(), comment: z.string().optional(), - intendedUse: z.string().optional(), + intendedUse: z.string(), firstName: z.string().optional(), lastName: z.string().optional(), company: z.string().optional(), isFromLighthouse: z.boolean().optional(), recipientType: z.string().optional(), - acceptedConsumerTerms: z.lazy(() => marshalConsumerTermsSchema).optional(), + acceptedConsumerTerms: z.lazy(() => marshalConsumerTermsSchema), }) .transform(d => ({ listing_id: d.listingId, @@ -2089,7 +2088,7 @@ export const marshalCreateProviderAnalyticsDashboardRequestSchema: z.ZodType = export const marshalCreateProviderRequestSchema: z.ZodType = z .object({ - provider: z.lazy(() => marshalProviderInfoSchema).optional(), + provider: z.lazy(() => marshalProviderInfoSchema), }) .transform(d => ({ provider: d.provider, @@ -2097,8 +2096,8 @@ export const marshalCreateProviderRequestSchema: z.ZodType = z export const marshalDataRefreshInfoSchema: z.ZodType = z .object({ - interval: z.bigint().optional(), - unit: z.string().optional(), + interval: z.bigint(), + unit: z.string(), }) .transform(d => ({ interval: d.interval, @@ -2108,7 +2107,7 @@ export const marshalDataRefreshInfoSchema: z.ZodType = z export const marshalExchangeSchema: z.ZodType = z .object({ id: z.string().optional(), - name: z.string().optional(), + name: z.string(), comment: z.string().optional(), filters: z.array(z.lazy(() => marshalExchangeFilterSchema)).optional(), createdAt: z.bigint().optional(), @@ -2134,14 +2133,14 @@ export const marshalExchangeSchema: z.ZodType = z export const marshalExchangeFilterSchema: z.ZodType = z .object({ id: z.string().optional(), - exchangeId: z.string().optional(), - filterValue: z.string().optional(), + exchangeId: z.string(), + filterValue: z.string(), name: z.string().optional(), createdAt: z.bigint().optional(), createdBy: z.string().optional(), updatedAt: z.bigint().optional(), updatedBy: z.string().optional(), - filterType: z.string().optional(), + filterType: z.string(), }) .transform(d => ({ id: d.id, @@ -2246,7 +2245,7 @@ export const marshalInstallationDetailSchema: z.ZodType = z export const marshalListingSchema: z.ZodType = z .object({ id: z.string().optional(), - summary: z.lazy(() => marshalListingSummarySchema).optional(), + summary: z.lazy(() => marshalListingSummarySchema), detail: z.lazy(() => marshalListingDetailSchema).optional(), }) .transform(d => ({ @@ -2313,7 +2312,7 @@ export const marshalListingSettingSchema: z.ZodType = z export const marshalListingSummarySchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), subtitle: z.string().optional(), status: z.string().optional(), share: z.lazy(() => marshalShareInfoSchema).optional(), @@ -2326,7 +2325,7 @@ export const marshalListingSummarySchema: z.ZodType = z publishedAt: z.bigint().optional(), publishedBy: z.string().optional(), categories: z.array(z.string()).optional(), - listingType: z.string().optional(), + listingType: z.string(), createdById: z.bigint().optional(), updatedById: z.bigint().optional(), providerId: z.string().optional(), @@ -2368,17 +2367,17 @@ export const marshalListingTagSchema: z.ZodType = z export const marshalProviderInfoSchema: z.ZodType = z .object({ id: z.string().optional(), - name: z.string().optional(), + name: z.string(), description: z.string().optional(), iconFilePath: z.string().optional(), - businessContactEmail: z.string().optional(), + businessContactEmail: z.string(), supportContactEmail: z.string().optional(), isFeatured: z.boolean().optional(), publishedBy: z.string().optional(), companyWebsiteLink: z.string().optional(), iconFileId: z.string().optional(), - termOfServiceLink: z.string().optional(), - privacyPolicyLink: z.string().optional(), + termOfServiceLink: z.string(), + privacyPolicyLink: z.string(), darkModeIconFileId: z.string().optional(), darkModeIconFilePath: z.string().optional(), }) @@ -2411,7 +2410,7 @@ export const marshalRegionInfoSchema: z.ZodType = z export const marshalRepoInfoSchema: z.ZodType = z .object({ - gitRepoUrl: z.string().optional(), + gitRepoUrl: z.string(), }) .transform(d => ({ git_repo_url: d.gitRepoUrl, @@ -2419,8 +2418,8 @@ export const marshalRepoInfoSchema: z.ZodType = z export const marshalRepoInstallationSchema: z.ZodType = z .object({ - repoName: z.string().optional(), - repoPath: z.string().optional(), + repoName: z.string(), + repoPath: z.string(), }) .transform(d => ({ repo_name: d.repoName, @@ -2429,8 +2428,8 @@ export const marshalRepoInstallationSchema: z.ZodType = z export const marshalShareInfoSchema: z.ZodType = z .object({ - name: z.string().optional(), - type: z.string().optional(), + name: z.string(), + type: z.string(), }) .transform(d => ({ name: d.name, @@ -2473,8 +2472,8 @@ export const marshalTokenInfoSchema: z.ZodType = z export const marshalUpdateExchangeFilterRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), - filter: z.lazy(() => marshalExchangeFilterSchema).optional(), + id: z.string(), + filter: z.lazy(() => marshalExchangeFilterSchema), }) .transform(d => ({ id: d.id, @@ -2483,8 +2482,8 @@ export const marshalUpdateExchangeFilterRequestSchema: z.ZodType = z export const marshalUpdateExchangeRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), - exchange: z.lazy(() => marshalExchangeSchema).optional(), + id: z.string(), + exchange: z.lazy(() => marshalExchangeSchema), }) .transform(d => ({ id: d.id, @@ -2493,9 +2492,9 @@ export const marshalUpdateExchangeRequestSchema: z.ZodType = z export const marshalUpdateInstallationRequestSchema: z.ZodType = z .object({ - listingId: z.string().optional(), - installationId: z.string().optional(), - installation: z.lazy(() => marshalInstallationDetailSchema).optional(), + listingId: z.string(), + installationId: z.string(), + installation: z.lazy(() => marshalInstallationDetailSchema), rotateToken: z.boolean().optional(), }) .transform(d => ({ @@ -2507,8 +2506,8 @@ export const marshalUpdateInstallationRequestSchema: z.ZodType = z export const marshalUpdateListingRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), - listing: z.lazy(() => marshalListingSchema).optional(), + id: z.string(), + listing: z.lazy(() => marshalListingSchema), }) .transform(d => ({ id: d.id, @@ -2518,9 +2517,9 @@ export const marshalUpdateListingRequestSchema: z.ZodType = z export const marshalUpdatePersonalizationRequestStatusRequestSchema: z.ZodType = z .object({ - listingId: z.string().optional(), - requestId: z.string().optional(), - status: z.string().optional(), + listingId: z.string(), + requestId: z.string(), + status: z.string(), reason: z.string().optional(), share: z.lazy(() => marshalShareInfoSchema).optional(), }) @@ -2534,7 +2533,7 @@ export const marshalUpdatePersonalizationRequestStatusRequestSchema: z.ZodType = export const marshalUpdateProviderAnalyticsDashboardRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), version: z.bigint().optional(), }) .transform(d => ({ @@ -2544,8 +2543,8 @@ export const marshalUpdateProviderAnalyticsDashboardRequestSchema: z.ZodType = z export const marshalUpdateProviderRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), - provider: z.lazy(() => marshalProviderInfoSchema).optional(), + id: z.string(), + provider: z.lazy(() => marshalProviderInfoSchema), }) .transform(d => ({ id: d.id, diff --git a/packages/modelregistry/src/v1/model.ts b/packages/modelregistry/src/v1/model.ts index bc78c4211..f0d592db9 100644 --- a/packages/modelregistry/src/v1/model.ts +++ b/packages/modelregistry/src/v1/model.ts @@ -226,9 +226,9 @@ export interface Activity { /** Details required to identify and approve a model version stage transition request. */ export interface ApproveTransitionRequest { /** Name of the model. */ - name?: string | undefined; + name: string; /** Version of the model. */ - version?: string | undefined; + version: string; /** * Target stage of the transition. Valid values are: * @@ -240,9 +240,9 @@ export interface ApproveTransitionRequest { * * * `Archived`: Archived stage. */ - stage?: string | undefined; + stage: string; /** Specifies whether to archive all current model versions in the target stage. */ - archiveExistingVersions?: boolean | undefined; + archiveExistingVersions: boolean; /** User-provided comment on the action. */ comment?: string | undefined; } @@ -302,11 +302,11 @@ export interface CommentObject { /** Details required to create a comment on a model version. */ export interface CreateCommentRequest { /** Name of the model. */ - name?: string | undefined; + name: string; /** Version of the model. */ - version?: string | undefined; + version: string; /** User-provided comment on the action. */ - comment?: string | undefined; + comment: string; } export interface CreateCommentResponse { @@ -316,9 +316,9 @@ export interface CreateCommentResponse { export interface CreateModelVersionRequest { /** Register model under this name */ - name?: string | undefined; + name: string; /** URI indicating the location of the model artifacts. */ - source?: string | undefined; + source: string; /** * MLflow run ID for correlation, if `source` was generated by an experiment run in * MLflow tracking server @@ -342,7 +342,7 @@ export interface CreateModelVersionResponse { export interface CreateRegisteredModelRequest { /** Register models under this name */ - name?: string | undefined; + name: string; /** Additional metadata for registered model. */ tags?: RegisteredModelTag[] | undefined; /** Optional description for registered model. */ @@ -383,7 +383,7 @@ export interface CreateRegistryWebhookRequest { * * * `TRANSITION_REQUEST_TO_ARCHIVED_CREATED`: A user requested a model version be archived. */ - events?: RegistryWebhookEvent[] | undefined; + events: RegistryWebhookEvent[]; /** User-specified description for the webhook. */ description?: string | undefined; /** @@ -408,9 +408,9 @@ export interface CreateRegistryWebhookResponse { /** Details required to create a model version stage transition request. */ export interface CreateTransitionRequest { /** Name of the model. */ - name?: string | undefined; + name: string; /** Version of the model. */ - version?: string | undefined; + version: string; /** * Target stage of the transition. Valid values are: * @@ -422,7 +422,7 @@ export interface CreateTransitionRequest { * * * `Archived`: Archived stage. */ - stage?: string | undefined; + stage: string; /** User-provided comment on the action. */ comment?: string | undefined; } @@ -434,7 +434,7 @@ export interface CreateTransitionResponse { export interface DeleteCommentRequest { /** Unique identifier of an activity */ - id?: string | undefined; + id: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -442,9 +442,9 @@ export interface DeleteCommentResponse {} export interface DeleteModelVersionRequest { /** Name of the registered model */ - name?: string | undefined; + name: string; /** Model version number */ - version?: string | undefined; + version: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -452,11 +452,11 @@ export interface DeleteModelVersionResponse {} export interface DeleteModelVersionTagRequest { /** Name of the registered model that the tag was logged under. */ - name?: string | undefined; + name: string; /** Model version number that the tag was logged under. */ - version?: string | undefined; + version: string; /** Name of the tag. The name must be an exact match; wild-card deletion is not supported. Maximum size is 250 bytes. */ - key?: string | undefined; + key: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -464,7 +464,7 @@ export interface DeleteModelVersionTagResponse {} export interface DeleteRegisteredModelRequest { /** Registered model unique name identifier. */ - name?: string | undefined; + name: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -472,9 +472,9 @@ export interface DeleteRegisteredModelResponse {} export interface DeleteRegisteredModelTagRequest { /** Name of the registered model that the tag was logged under. */ - name?: string | undefined; + name: string; /** Name of the tag. The name must be an exact match; wild-card deletion is not supported. Maximum size is 250 bytes. */ - key?: string | undefined; + key: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -486,7 +486,7 @@ export interface DeleteRegisteredModelTagResponse {} */ export interface DeleteRegistryWebhookRequest { /** Webhook ID required to delete a registry webhook. */ - id?: string | undefined; + id: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -494,9 +494,9 @@ export interface DeleteRegistryWebhookResponse {} export interface DeleteTransitionRequest { /** Name of the model. */ - name?: string | undefined; + name: string; /** Version of the model. */ - version?: string | undefined; + version: string; /** * Target stage of the transition request. Valid values are: * @@ -508,9 +508,9 @@ export interface DeleteTransitionRequest { * * * `Archived`: Archived stage. */ - stage?: string | undefined; + stage: string; /** Username of the user who created this request. Of the transition requests matching the specified details, only the one transition created by this user will be deleted. */ - creator?: string | undefined; + creator: string; /** User-provided comment on the action. */ comment?: string | undefined; } @@ -535,9 +535,9 @@ export interface GetLatestVersionsResponse { export interface GetModelVersionDownloadUriRequest { /** Name of the registered model */ - name?: string | undefined; + name: string; /** Model version number */ - version?: string | undefined; + version: string; } export interface GetModelVersionDownloadUriResponse { @@ -547,9 +547,9 @@ export interface GetModelVersionDownloadUriResponse { export interface GetModelVersionRequest { /** Name of the registered model */ - name?: string | undefined; + name: string; /** Model version number */ - version?: string | undefined; + version: string; } export interface GetModelVersionResponse { @@ -558,7 +558,7 @@ export interface GetModelVersionResponse { export interface GetRegisteredModelDatabricksRequest { /** Registered model unique name identifier. */ - name?: string | undefined; + name: string; } export interface GetRegisteredModelDatabricksResponse { @@ -597,7 +597,7 @@ export interface LinkedFeature { export interface ListLatestVersionsRequest { /** Registered model unique name identifier. */ - name?: string | undefined; + name: string; /** List of stages. */ stages?: string[] | undefined; } @@ -665,9 +665,9 @@ export interface ListRegistryWebhooksResponse { export interface ListTransitionRequest { /** Name of the registered model. */ - name?: string | undefined; + name: string; /** Version of the model. */ - version?: string | undefined; + version: string; } export interface ListTransitionResponse { @@ -850,9 +850,9 @@ export interface RegistryWebhook { /** Details required to identify and reject a model version stage transition request. */ export interface RejectTransitionRequest { /** Name of the model. */ - name?: string | undefined; + name: string; /** Version of the model. */ - version?: string | undefined; + version: string; /** * Target stage of the transition. Valid values are: * @@ -864,7 +864,7 @@ export interface RejectTransitionRequest { * * * `Archived`: Archived stage. */ - stage?: string | undefined; + stage: string; /** User-provided comment on the action. */ comment?: string | undefined; } @@ -876,7 +876,7 @@ export interface RejectTransitionResponse { export interface RenameRegisteredModelRequest { /** Registered model unique name identifier. */ - name?: string | undefined; + name: string; /** If provided, updates the name for this `registered_model`. */ newName?: string | undefined; } @@ -939,20 +939,20 @@ export interface SearchRegisteredModelsResponse { export interface SetModelVersionTagRequest { /** Unique name of the model. */ - name?: string | undefined; + name: string; /** Model version number. */ - version?: string | undefined; + version: string; /** * Name of the tag. Maximum size depends on storage backend. * If a tag with this name already exists, its preexisting value will be replaced by the specified `value`. * All storage backends are guaranteed to support key values up to 250 bytes in size. */ - key?: string | undefined; + key: string; /** * String value of the tag being logged. Maximum size depends on storage backend. * All storage backends are guaranteed to support key values up to 5000 bytes in size. */ - value?: string | undefined; + value: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -960,18 +960,18 @@ export interface SetModelVersionTagResponse {} export interface SetRegisteredModelTagRequest { /** Unique name of the model. */ - name?: string | undefined; + name: string; /** * Name of the tag. Maximum size depends on storage backend. * If a tag with this name already exists, its preexisting value will be replaced by the specified `value`. * All storage backends are guaranteed to support key values up to 250 bytes in size. */ - key?: string | undefined; + key: string; /** * String value of the tag being logged. Maximum size depends on storage backend. * All storage backends are guaranteed to support key values up to 5000 bytes in size. */ - value?: string | undefined; + value: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -980,7 +980,7 @@ export interface SetRegisteredModelTagResponse {} /** Details required to test a registry webhook. */ export interface TestRegistryWebhookRequest { /** Webhook ID */ - id?: string | undefined; + id: string; /** If `event` is specified, the test trigger uses the specified event. If `event` is not specified, the test trigger uses a randomly chosen event associated with the webhook. */ event?: RegistryWebhookEvent | undefined; } @@ -995,9 +995,9 @@ export interface TestRegistryWebhookResponse { /** Details required to transition a model version's stage. */ export interface TransitionModelVersionStageDatabricksRequest { /** Name of the model. */ - name?: string | undefined; + name: string; /** Version of the model. */ - version?: string | undefined; + version: string; /** * Target stage of the transition. Valid values are: * @@ -1009,9 +1009,9 @@ export interface TransitionModelVersionStageDatabricksRequest { * * * `Archived`: Archived stage. */ - stage?: string | undefined; + stage: string; /** Specifies whether to archive all current model versions in the target stage. */ - archiveExistingVersions?: boolean | undefined; + archiveExistingVersions: boolean; /** User-provided comment on the action. */ comment?: string | undefined; } @@ -1071,9 +1071,9 @@ export interface TransitionRequest { /** Details required to edit a comment on a model version. */ export interface UpdateCommentRequest { /** Unique identifier of an activity */ - id?: string | undefined; + id: string; /** User-provided comment on the action. */ - comment?: string | undefined; + comment: string; } export interface UpdateCommentResponse { @@ -1083,9 +1083,9 @@ export interface UpdateCommentResponse { export interface UpdateModelVersionRequest { /** Name of the registered model */ - name?: string | undefined; + name: string; /** Model version number */ - version?: string | undefined; + version: string; /** If provided, updates the description for this `registered_model`. */ description?: string | undefined; } @@ -1097,7 +1097,7 @@ export interface UpdateModelVersionResponse { export interface UpdateRegisteredModelRequest { /** Registered model unique name identifier. */ - name?: string | undefined; + name: string; /** If provided, updates the description for this `registered_model`. */ description?: string | undefined; } @@ -1109,7 +1109,7 @@ export interface UpdateRegisteredModelResponse { /** Details required to update a registry webhook. Only the fields that need to be updated should be specified, and both `http_url_spec` and `job_spec` should not be specified in the same request. */ export interface UpdateRegistryWebhookRequest { /** Webhook ID */ - id?: string | undefined; + id: string; /** * Events that can trigger a registry webhook: * * `MODEL_VERSION_CREATED`: A new model version was created for the associated model. @@ -1753,10 +1753,10 @@ export const unmarshalUpdateRegistryWebhookResponseSchema: z.ZodType ({ @@ -1769,9 +1769,9 @@ export const marshalApproveTransitionRequestSchema: z.ZodType = z export const marshalCreateCommentRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - version: z.string().optional(), - comment: z.string().optional(), + name: z.string(), + version: z.string(), + comment: z.string(), }) .transform(d => ({ name: d.name, @@ -1781,8 +1781,8 @@ export const marshalCreateCommentRequestSchema: z.ZodType = z export const marshalCreateModelVersionRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - source: z.string().optional(), + name: z.string(), + source: z.string(), runId: z.string().optional(), tags: z.array(z.lazy(() => marshalModelVersionTagSchema)).optional(), runLink: z.string().optional(), @@ -1799,7 +1799,7 @@ export const marshalCreateModelVersionRequestSchema: z.ZodType = z export const marshalCreateRegisteredModelRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), tags: z.array(z.lazy(() => marshalRegisteredModelTagSchema)).optional(), description: z.string().optional(), }) @@ -1812,7 +1812,7 @@ export const marshalCreateRegisteredModelRequestSchema: z.ZodType = z export const marshalCreateRegistryWebhookRequestSchema: z.ZodType = z .object({ modelName: z.string().optional(), - events: z.array(z.string()).optional(), + events: z.array(z.string()), description: z.string().optional(), status: z.string().optional(), httpUrlSpec: z.lazy(() => marshalHttpUrlSpecSchema).optional(), @@ -1829,9 +1829,9 @@ export const marshalCreateRegistryWebhookRequestSchema: z.ZodType = z export const marshalCreateTransitionRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - version: z.string().optional(), - stage: z.string().optional(), + name: z.string(), + version: z.string(), + stage: z.string(), comment: z.string().optional(), }) .transform(d => ({ @@ -1869,7 +1869,7 @@ export const marshalJobSpecSchema: z.ZodType = z export const marshalListLatestVersionsRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), stages: z.array(z.string()).optional(), }) .transform(d => ({ @@ -1899,9 +1899,9 @@ export const marshalRegisteredModelTagSchema: z.ZodType = z export const marshalRejectTransitionRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - version: z.string().optional(), - stage: z.string().optional(), + name: z.string(), + version: z.string(), + stage: z.string(), comment: z.string().optional(), }) .transform(d => ({ @@ -1913,7 +1913,7 @@ export const marshalRejectTransitionRequestSchema: z.ZodType = z export const marshalRenameRegisteredModelRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), newName: z.string().optional(), }) .transform(d => ({ @@ -1923,10 +1923,10 @@ export const marshalRenameRegisteredModelRequestSchema: z.ZodType = z export const marshalSetModelVersionTagRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - version: z.string().optional(), - key: z.string().optional(), - value: z.string().optional(), + name: z.string(), + version: z.string(), + key: z.string(), + value: z.string(), }) .transform(d => ({ name: d.name, @@ -1937,9 +1937,9 @@ export const marshalSetModelVersionTagRequestSchema: z.ZodType = z export const marshalSetRegisteredModelTagRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - key: z.string().optional(), - value: z.string().optional(), + name: z.string(), + key: z.string(), + value: z.string(), }) .transform(d => ({ name: d.name, @@ -1949,7 +1949,7 @@ export const marshalSetRegisteredModelTagRequestSchema: z.ZodType = z export const marshalTestRegistryWebhookRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), event: z.string().optional(), }) .transform(d => ({ @@ -1960,10 +1960,10 @@ export const marshalTestRegistryWebhookRequestSchema: z.ZodType = z export const marshalTransitionModelVersionStageDatabricksRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - version: z.string().optional(), - stage: z.string().optional(), - archiveExistingVersions: z.boolean().optional(), + name: z.string(), + version: z.string(), + stage: z.string(), + archiveExistingVersions: z.boolean(), comment: z.string().optional(), }) .transform(d => ({ @@ -1976,8 +1976,8 @@ export const marshalTransitionModelVersionStageDatabricksRequestSchema: z.ZodTyp export const marshalUpdateCommentRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), - comment: z.string().optional(), + id: z.string(), + comment: z.string(), }) .transform(d => ({ id: d.id, @@ -1986,8 +1986,8 @@ export const marshalUpdateCommentRequestSchema: z.ZodType = z export const marshalUpdateModelVersionRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - version: z.string().optional(), + name: z.string(), + version: z.string(), description: z.string().optional(), }) .transform(d => ({ @@ -1998,7 +1998,7 @@ export const marshalUpdateModelVersionRequestSchema: z.ZodType = z export const marshalUpdateRegisteredModelRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), description: z.string().optional(), }) .transform(d => ({ @@ -2008,7 +2008,7 @@ export const marshalUpdateRegisteredModelRequestSchema: z.ZodType = z export const marshalUpdateRegistryWebhookRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), events: z.array(z.string()).optional(), description: z.string().optional(), status: z.string().optional(), diff --git a/packages/modelserving/src/v1/model.ts b/packages/modelserving/src/v1/model.ts index 93d181f73..7117391f4 100644 --- a/packages/modelserving/src/v1/model.ts +++ b/packages/modelserving/src/v1/model.ts @@ -140,7 +140,7 @@ export interface AiGatewayRateLimit { */ key?: string | undefined; /** Renewal period field for a rate limit. Currently, only 'minute' is supported. */ - renewalPeriod?: string | undefined; + renewalPeriod: string; /** Principal field for a user, user group, or service principal to apply rate limiting to. Accepts a user email, group name, or service principal application ID. */ principal?: string | undefined; /** Used to specify how many tokens are allowed for a key within the renewal_period. */ @@ -173,7 +173,7 @@ export interface AiGuardrails { export interface AmazonBedrockConfig { /** The AWS region to use. Bedrock has to be enabled there. */ - awsRegion?: string | undefined; + awsRegion: string; /** * The secret key reference for an AWS access key ID with * permissions to interact with Bedrock services. If you prefer to paste @@ -195,7 +195,7 @@ export interface AmazonBedrockConfig { * The underlying provider in Amazon Bedrock. Supported values (case * insensitive) include: Anthropic, Cohere, AI21Labs, Amazon. */ - bedrockProvider?: string | undefined; + bedrockProvider: string; /** * An AWS access key ID with permissions to interact with Bedrock services * provided as a plaintext string. If you prefer to reference your key using @@ -241,7 +241,7 @@ export interface AnthropicConfig { export interface ApiKeyAuth { /** The name of the API key parameter used for authentication. */ - key?: string | undefined; + key: string; /** * The secret key reference for an API Key. * If you prefer to paste your token directly, see `value_plaintext`. @@ -314,7 +314,7 @@ export interface CreateInferenceEndpointRequest { * The name of the serving endpoint. This field is required and must be unique across a . * An endpoint name can consist of alphanumeric characters, dashes, and underscores. */ - name?: string | undefined; + name: string; /** The core config of the serving endpoint. */ config?: EndpointCoreConfig | undefined; /** Tags to be attached to the serving endpoint and automatically propagated to billing logs. */ @@ -339,9 +339,9 @@ export interface CreatePtEndpointRequest { * The name of the serving endpoint. This field is required and must be unique across a . * An endpoint name can consist of alphanumeric characters, dashes, and underscores. */ - name?: string | undefined; + name: string; /** The core config of the serving endpoint. */ - config?: PtEndpointCoreConfig | undefined; + config: PtEndpointCoreConfig; /** Tags to be attached to the serving endpoint and automatically propagated to billing logs. */ tags?: EndpointTag[] | undefined; /** The AI Gateway configuration for the serving endpoint. */ @@ -355,7 +355,7 @@ export interface CreatePtEndpointRequest { /** Configs needed to create a custom provider model route. */ export interface CustomProviderConfig { /** This is a field to provide the URL of the custom provider API. */ - customProviderUrl?: string | undefined; + customProviderUrl: string; /** * This is a field to provide bearer token authentication for the custom provider API. * You can only specify one authentication method. @@ -390,7 +390,7 @@ export interface DatabricksModelServingConfig { * The URL of the workspace containing the model serving endpoint * pointed to by this external model. */ - databricksWorkspaceUrl?: string | undefined; + databricksWorkspaceUrl: string; /** * The Databricks API token that corresponds to a user or service principal * with Can Query access to the model serving endpoint pointed to by this @@ -403,7 +403,7 @@ export interface DatabricksModelServingConfig { } export interface DeleteInferenceEndpointRequest { - name?: string | undefined; + name: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -459,7 +459,7 @@ export interface EndpointCoreConfigSummary { export interface EndpointTag { /** Key field for a serving endpoint tag. */ - key?: string | undefined; + key: string; /** Optional value field for a serving endpoint tag. */ value?: string | undefined; } @@ -481,11 +481,11 @@ export interface ExportMetricsResponse { /** Simple Proto message for testing */ export interface ExternalFunctionRequest { /** The connection name to use. This is required to identify the external connection. */ - connectionName?: string | undefined; + connectionName: string; /** The HTTP method to use (e.g., 'GET', 'POST'). */ - method?: ExternalFunctionRequest_HttpMethod | undefined; + method: ExternalFunctionRequest_HttpMethod; /** The relative path for the API endpoint. This is required. */ - path?: string | undefined; + path: string; /** The JSON payload to send in the request body. */ json?: string | undefined; /** Additional headers for the request. If not provided, only auth headers from connections would be passed. */ @@ -507,11 +507,11 @@ export interface ExternalFunctionResponse { export interface ExternalModel { /** The name of the provider for the external model. Currently, the supported providers are 'ai21labs', 'anthropic', 'amazon-bedrock', 'cohere', 'databricks-model-serving', 'google-cloud-vertex-ai', 'openai', 'palm', and 'custom'. */ - provider?: string | undefined; + provider: string; /** The name of the external model. */ - name?: string | undefined; + name: string; /** The task type of the external model. */ - task?: string | undefined; + task: string; /** external model config. The config corresponding to the provider will be used. */ config?: | { @@ -569,7 +569,7 @@ export interface FallbackConfig { * endpoint, following the order of served entity list, until a successful response is returned. * If all attempts fail, return the last response with the error code. */ - enabled?: boolean | undefined; + enabled: boolean; } /** All fields are not sensitive as they are hard-coded in the system and made available to customers. */ @@ -582,17 +582,17 @@ export interface FoundationModel { export interface GetExportEndpointMetricsRequest { /** The name of the serving endpoint to retrieve metrics for. This field is required. */ - name?: string | undefined; + name: string; } export interface GetInferenceEndpointRequest { /** The name of the serving endpoint. This field is required. */ - name?: string | undefined; + name: string; } export interface GetInferenceEndpointSchemaRequest { /** The name of the serving endpoint that the served model belongs to. This field is required. */ - name?: string | undefined; + name: string; } /** The top level proto message that represents an OpenAPI 3.0 document. */ @@ -602,26 +602,26 @@ export interface GetOpenApiResponse { export interface GetServedModelBuildLogsRequest { /** The name of the serving endpoint that the served model belongs to. This field is required. */ - name?: string | undefined; + name: string; /** The name of the served model that build logs will be retrieved for. This field is required. */ servedModelName?: string | undefined; } export interface GetServedModelBuildLogsResponse { /** The logs associated with building the served entity's environment. */ - logs?: string | undefined; + logs: string; } export interface GetServedModelLogsRequest { /** The name of the serving endpoint that the served model belongs to. This field is required. */ - name?: string | undefined; + name: string; /** The name of the served model that logs will be retrieved for. This field is required. */ servedModelName?: string | undefined; } export interface GetServedModelLogsResponse { /** The most recent log lines of the model server processing invocation requests. */ - logs?: string | undefined; + logs: string; } export interface GoogleCloudVertexAiConfig { @@ -640,7 +640,7 @@ export interface GoogleCloudVertexAiConfig { * This is the Google Cloud project id that the service account is * associated with. */ - projectId?: string | undefined; + projectId: string; /** * This is the region for the Google Cloud Vertex AI Service. See [supported * regions] for more details. Some models are only available in specific @@ -648,7 +648,7 @@ export interface GoogleCloudVertexAiConfig { * * [supported regions]: https://cloud.google.com/vertex-ai/docs/general/locations */ - region?: string | undefined; + region: string; /** * The private key for the service account which has access to the Google * Cloud Vertex AI Service provided as a plaintext secret. See [Best @@ -879,7 +879,7 @@ export interface PaLmConfig { export interface PatchInferenceEndpointTagsRequest { /** The name of the serving endpoint who's tags to patch. This field is required. */ - name?: string | undefined; + name: string; /** List of endpoint tags to add */ addTags?: EndpointTag[] | undefined; /** List of tag keys to delete */ @@ -893,7 +893,7 @@ export interface PatchInferenceEndpointTagsResponse { /** Updates the telemetry configuration of a serving endpoint. */ export interface PatchInferenceEndpointTelemetryConfigRequest { /** The name of the serving endpoint whose telemetry configuration is being updated. This field is required. */ - name?: string | undefined; + name: string; /** * The telemetry configuration to be applied to the serving endpoint. * Can specify either a telemetry_profile_id to use an existing profile, @@ -944,10 +944,10 @@ export interface PtServedModel { /** The name of a served entity. It must be unique across an endpoint. A served entity name can consist of alphanumeric characters, dashes, and underscores. If not specified for an external model, this field defaults to external_model.name, with '.' and ':' replaced with '-', and if not specified for other entities, it defaults to entity_name-entity_version. */ name?: string | undefined; /** The name of the entity to be served. The entity may be a model in the Databricks Model Registry, a model in the Unity Catalog (UC), or a function of type FEATURE_SPEC in the UC. If it is a UC object, the full name of the object should be given in the form of **catalog_name.schema_name.model_name**. */ - entityName?: string | undefined; + entityName: string; entityVersion?: string | undefined; /** The number of model units to be provisioned. */ - provisionedModelUnits?: bigint | undefined; + provisionedModelUnits: bigint; /** * Whether burst scaling is enabled. When enabled (default), the endpoint can automatically * scale up beyond provisioned capacity to handle traffic spikes. When disabled, the endpoint @@ -958,7 +958,7 @@ export interface PtServedModel { export interface PutInferenceEndpointAiGatewayRequest { /** The name of the serving endpoint whose AI Gateway is being updated. This field is required. */ - name?: string | undefined; + name: string; /** * Configuration to enable usage tracking using system tables. * These tables allow you to monitor operational usage on endpoints and their associated costs. @@ -1004,7 +1004,7 @@ export interface PutInferenceEndpointAiGatewayResponse { export interface PutInferenceEndpointConfigRequest { /** The name of the serving endpoint to update. This field is required. */ - name?: string | undefined; + name: string; /** The list of served entities under the serving endpoint config. */ servedEntities?: ServedModel[] | undefined; /** (Deprecated, use served_entities instead) The list of served models under the serving endpoint config. */ @@ -1022,7 +1022,7 @@ export interface PutInferenceEndpointConfigRequest { export interface PutInferenceEndpointRateLimitsRequest { /** The name of the serving endpoint whose rate limits are being updated. This field is required. */ - name?: string | undefined; + name: string; /** The list of endpoint rate limits. */ rateLimits?: RateLimit[] | undefined; } @@ -1034,24 +1034,24 @@ export interface PutInferenceEndpointRateLimitsResponse { export interface PutPtEndpointConfigRequest { /** The name of the pt endpoint to update. This field is required. */ - name?: string | undefined; - config?: PtEndpointCoreConfig | undefined; + name: string; + config: PtEndpointCoreConfig; } export interface RateLimit { /** Used to specify how many calls are allowed for a key within the renewal_period. */ - calls?: bigint | undefined; + calls: bigint; /** Key field for a serving endpoint rate limit. Currently, only 'user' and 'endpoint' are supported, with 'endpoint' being the default if not specified. */ key?: string | undefined; /** Renewal period field for a serving endpoint rate limit. Currently, only 'minute' is supported. */ - renewalPeriod?: string | undefined; + renewalPeriod: string; } export interface Route { /** The name of the served model this route configures traffic for. */ servedModelName?: string | undefined; /** The percentage of endpoint traffic to send to this route. It must be an integer between 0 and 100 inclusive. */ - trafficPercentage?: number | undefined; + trafficPercentage: number; servedEntityName?: string | undefined; } @@ -1083,8 +1083,8 @@ export interface ServedModel { burstScalingEnabled?: boolean | undefined; /** Whether the compute resources for the served entity should scale down to zero. */ scaleToZeroEnabled?: boolean | undefined; - modelName?: string | undefined; - modelVersion?: string | undefined; + modelName: string; + modelVersion: string; /** An object containing a set of optional, user-specified environment variable key-value pairs used for serving this entity. Note: this is an experimental feature and subject to change. Example entity environment variables that refer to secrets: `{"OPENAI_API_KEY": "{{secrets/my_scope/my_key}}", "DATABRICKS_TOKEN": "{{secrets/my_scope2/my_key2}}"}` */ environmentVars?: Record | undefined; /** ARN of the instance profile that the served entity uses to access AWS resources. */ @@ -1178,7 +1178,7 @@ export interface UnityCatalogTableNames { export interface UpdateInferenceEndpointNotificationsRequest { /** The name of the serving endpoint whose notifications are being updated. This field is required. */ - name?: string | undefined; + name: string; /** The email notification settings to update. Specify email addresses to notify when endpoint state changes occur. */ emailNotifications?: EmailNotifications | undefined; } @@ -1233,7 +1233,7 @@ export const unmarshalAiGatewayRateLimitSchema: z.ZodType = .transform(v => BigInt(v)) .optional(), key: z.string().optional(), - renewal_period: z.string().optional(), + renewal_period: z.string(), principal: z.string().optional(), tokens: z .union([z.number(), z.bigint(), z.string()]) @@ -1276,10 +1276,10 @@ export const unmarshalAiGuardrailsSchema: z.ZodType = z export const unmarshalAmazonBedrockConfigSchema: z.ZodType = z .object({ - aws_region: z.string().optional(), + aws_region: z.string(), aws_access_key_id: z.string().optional(), aws_secret_access_key: z.string().optional(), - bedrock_provider: z.string().optional(), + bedrock_provider: z.string(), aws_access_key_id_plaintext: z.string().optional(), aws_secret_access_key_plaintext: z.string().optional(), instance_profile_arn: z.string().optional(), @@ -1306,7 +1306,7 @@ export const unmarshalAnthropicConfigSchema: z.ZodType = z export const unmarshalApiKeyAuthSchema: z.ZodType = z .object({ - key: z.string().optional(), + key: z.string(), value: z.string().optional(), value_plaintext: z.string().optional(), }) @@ -1365,7 +1365,7 @@ export const unmarshalCohereConfigSchema: z.ZodType = z export const unmarshalCustomProviderConfigSchema: z.ZodType = z .object({ - custom_provider_url: z.string().optional(), + custom_provider_url: z.string(), bearer_token_auth: z .lazy(() => unmarshalBearerTokenAuthSchema) .optional(), @@ -1391,7 +1391,7 @@ export const unmarshalDatabricksModelServingConfigSchema: z.ZodType ({ @@ -1457,7 +1457,7 @@ export const unmarshalEndpointCoreConfigSummarySchema: z.ZodType = z .object({ - key: z.string().optional(), + key: z.string(), value: z.string().optional(), }) .transform(d => ({ @@ -1467,9 +1467,9 @@ export const unmarshalEndpointTagSchema: z.ZodType = z export const unmarshalExternalModelSchema: z.ZodType = z .object({ - provider: z.string().optional(), - name: z.string().optional(), - task: z.string().optional(), + provider: z.string(), + name: z.string(), + task: z.string(), ai21labs_config: z.lazy(() => unmarshalAi21LabsConfigSchema).optional(), anthropic_config: z.lazy(() => unmarshalAnthropicConfigSchema).optional(), amazon_bedrock_config: z @@ -1538,7 +1538,7 @@ export const unmarshalExternalModelSchema: z.ZodType = z export const unmarshalFallbackConfigSchema: z.ZodType = z .object({ - enabled: z.boolean().optional(), + enabled: z.boolean(), }) .transform(d => ({ enabled: d.enabled, @@ -1561,7 +1561,7 @@ export const unmarshalFoundationModelSchema: z.ZodType = z export const unmarshalGetServedModelBuildLogsResponseSchema: z.ZodType = z .object({ - logs: z.string().optional(), + logs: z.string(), }) .transform(d => ({ logs: d.logs, @@ -1570,7 +1570,7 @@ export const unmarshalGetServedModelBuildLogsResponseSchema: z.ZodType = z .object({ - logs: z.string().optional(), + logs: z.string(), }) .transform(d => ({ logs: d.logs, @@ -1580,8 +1580,8 @@ export const unmarshalGoogleCloudVertexAiConfigSchema: z.ZodType ({ @@ -1861,10 +1861,9 @@ export const unmarshalRateLimitSchema: z.ZodType = z .object({ calls: z .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), + .transform(v => BigInt(v)), key: z.string().optional(), - renewal_period: z.string().optional(), + renewal_period: z.string(), }) .transform(d => ({ calls: d.calls, @@ -1875,7 +1874,7 @@ export const unmarshalRateLimitSchema: z.ZodType = z export const unmarshalRouteSchema: z.ZodType = z .object({ served_model_name: z.string().optional(), - traffic_percentage: z.number().optional(), + traffic_percentage: z.number(), served_entity_name: z.string().optional(), }) .transform(d => ({ @@ -1901,8 +1900,8 @@ export const unmarshalServedModelSchema: z.ZodType = z .optional(), burst_scaling_enabled: z.boolean().optional(), scale_to_zero_enabled: z.boolean().optional(), - model_name: z.string().optional(), - model_version: z.string().optional(), + model_name: z.string(), + model_version: z.string(), environment_vars: z.record(z.string(), z.string()).optional(), instance_profile_arn: z.string().optional(), foundation_model: z.lazy(() => unmarshalFoundationModelSchema).optional(), @@ -2081,7 +2080,7 @@ export const marshalAiGatewayRateLimitSchema: z.ZodType = z .object({ calls: z.bigint().optional(), key: z.string().optional(), - renewalPeriod: z.string().optional(), + renewalPeriod: z.string(), principal: z.string().optional(), tokens: z.bigint().optional(), }) @@ -2119,10 +2118,10 @@ export const marshalAiGuardrailsSchema: z.ZodType = z export const marshalAmazonBedrockConfigSchema: z.ZodType = z .object({ - awsRegion: z.string().optional(), + awsRegion: z.string(), awsAccessKeyId: z.string().optional(), awsSecretAccessKey: z.string().optional(), - bedrockProvider: z.string().optional(), + bedrockProvider: z.string(), awsAccessKeyIdPlaintext: z.string().optional(), awsSecretAccessKeyPlaintext: z.string().optional(), instanceProfileArn: z.string().optional(), @@ -2149,7 +2148,7 @@ export const marshalAnthropicConfigSchema: z.ZodType = z export const marshalApiKeyAuthSchema: z.ZodType = z .object({ - key: z.string().optional(), + key: z.string(), value: z.string().optional(), valuePlaintext: z.string().optional(), }) @@ -2207,7 +2206,7 @@ export const marshalCohereConfigSchema: z.ZodType = z export const marshalCreateInferenceEndpointRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), config: z.lazy(() => marshalEndpointCoreConfigSchema).optional(), tags: z.array(z.lazy(() => marshalEndpointTagSchema)).optional(), routeOptimized: z.boolean().optional(), @@ -2235,8 +2234,8 @@ export const marshalCreateInferenceEndpointRequestSchema: z.ZodType = z export const marshalCreatePtEndpointRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - config: z.lazy(() => marshalPtEndpointCoreConfigSchema).optional(), + name: z.string(), + config: z.lazy(() => marshalPtEndpointCoreConfigSchema), tags: z.array(z.lazy(() => marshalEndpointTagSchema)).optional(), aiGateway: z.lazy(() => marshalAiGatewayConfigSchema).optional(), budgetPolicyId: z.string().optional(), @@ -2255,7 +2254,7 @@ export const marshalCreatePtEndpointRequestSchema: z.ZodType = z export const marshalCustomProviderConfigSchema: z.ZodType = z .object({ - customProviderUrl: z.string().optional(), + customProviderUrl: z.string(), bearerTokenAuth: z.lazy(() => marshalBearerTokenAuthSchema).optional(), apiKeyAuth: z.lazy(() => marshalApiKeyAuthSchema).optional(), }) @@ -2268,7 +2267,7 @@ export const marshalCustomProviderConfigSchema: z.ZodType = z export const marshalDatabricksModelServingConfigSchema: z.ZodType = z .object({ databricksApiToken: z.string().optional(), - databricksWorkspaceUrl: z.string().optional(), + databricksWorkspaceUrl: z.string(), databricksApiTokenPlaintext: z.string().optional(), }) .transform(d => ({ @@ -2303,7 +2302,7 @@ export const marshalEndpointCoreConfigSchema: z.ZodType = z export const marshalEndpointTagSchema: z.ZodType = z .object({ - key: z.string().optional(), + key: z.string(), value: z.string().optional(), }) .transform(d => ({ @@ -2313,9 +2312,9 @@ export const marshalEndpointTagSchema: z.ZodType = z export const marshalExternalFunctionRequestSchema: z.ZodType = z .object({ - connectionName: z.string().optional(), - method: z.string().optional(), - path: z.string().optional(), + connectionName: z.string(), + method: z.string(), + path: z.string(), json: z.string().optional(), headers: z.string().optional(), params: z.string().optional(), @@ -2333,9 +2332,9 @@ export const marshalExternalFunctionRequestSchema: z.ZodType = z export const marshalExternalModelSchema: z.ZodType = z .object({ - provider: z.string().optional(), - name: z.string().optional(), - task: z.string().optional(), + provider: z.string(), + name: z.string(), + task: z.string(), config: z .discriminatedUnion('$case', [ z.object({ @@ -2414,7 +2413,7 @@ export const marshalExternalModelSchema: z.ZodType = z export const marshalFallbackConfigSchema: z.ZodType = z .object({ - enabled: z.boolean().optional(), + enabled: z.boolean(), }) .transform(d => ({ enabled: d.enabled, @@ -2437,8 +2436,8 @@ export const marshalFoundationModelSchema: z.ZodType = z export const marshalGoogleCloudVertexAiConfigSchema: z.ZodType = z .object({ privateKey: z.string().optional(), - projectId: z.string().optional(), - region: z.string().optional(), + projectId: z.string(), + region: z.string(), privateKeyPlaintext: z.string().optional(), }) .transform(d => ({ @@ -2503,7 +2502,7 @@ export const marshalPaLmConfigSchema: z.ZodType = z export const marshalPatchInferenceEndpointTagsRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), addTags: z.array(z.lazy(() => marshalEndpointTagSchema)).optional(), deleteTags: z.array(z.string()).optional(), }) @@ -2516,7 +2515,7 @@ export const marshalPatchInferenceEndpointTagsRequestSchema: z.ZodType = z export const marshalPatchInferenceEndpointTelemetryConfigRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), telemetryConfig: z.lazy(() => marshalTelemetryConfigSchema).optional(), }) .transform(d => ({ @@ -2559,9 +2558,9 @@ export const marshalPtEndpointCoreConfigSchema: z.ZodType = z export const marshalPtServedModelSchema: z.ZodType = z .object({ name: z.string().optional(), - entityName: z.string().optional(), + entityName: z.string(), entityVersion: z.string().optional(), - provisionedModelUnits: z.bigint().optional(), + provisionedModelUnits: z.bigint(), burstScalingEnabled: z.boolean().optional(), }) .transform(d => ({ @@ -2574,7 +2573,7 @@ export const marshalPtServedModelSchema: z.ZodType = z export const marshalPutInferenceEndpointAiGatewayRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), usageTrackingConfig: z .lazy(() => marshalUsageTrackingConfigSchema) .optional(), @@ -2598,7 +2597,7 @@ export const marshalPutInferenceEndpointAiGatewayRequestSchema: z.ZodType = z export const marshalPutInferenceEndpointConfigRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), servedEntities: z.array(z.lazy(() => marshalServedModelSchema)).optional(), servedModels: z.array(z.lazy(() => marshalServedModelSchema)).optional(), trafficConfig: z.lazy(() => marshalTrafficConfigSchema).optional(), @@ -2614,7 +2613,7 @@ export const marshalPutInferenceEndpointConfigRequestSchema: z.ZodType = z export const marshalPutInferenceEndpointRateLimitsRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), rateLimits: z.array(z.lazy(() => marshalRateLimitSchema)).optional(), }) .transform(d => ({ @@ -2624,8 +2623,8 @@ export const marshalPutInferenceEndpointRateLimitsRequestSchema: z.ZodType = z export const marshalPutPtEndpointConfigRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - config: z.lazy(() => marshalPtEndpointCoreConfigSchema).optional(), + name: z.string(), + config: z.lazy(() => marshalPtEndpointCoreConfigSchema), }) .transform(d => ({ name: d.name, @@ -2634,9 +2633,9 @@ export const marshalPutPtEndpointConfigRequestSchema: z.ZodType = z export const marshalRateLimitSchema: z.ZodType = z .object({ - calls: z.bigint().optional(), + calls: z.bigint(), key: z.string().optional(), - renewalPeriod: z.string().optional(), + renewalPeriod: z.string(), }) .transform(d => ({ calls: d.calls, @@ -2647,7 +2646,7 @@ export const marshalRateLimitSchema: z.ZodType = z export const marshalRouteSchema: z.ZodType = z .object({ servedModelName: z.string().optional(), - trafficPercentage: z.number().optional(), + trafficPercentage: z.number(), servedEntityName: z.string().optional(), }) .transform(d => ({ @@ -2670,8 +2669,8 @@ export const marshalServedModelSchema: z.ZodType = z provisionedModelUnits: z.bigint().optional(), burstScalingEnabled: z.boolean().optional(), scaleToZeroEnabled: z.boolean().optional(), - modelName: z.string().optional(), - modelVersion: z.string().optional(), + modelName: z.string(), + modelVersion: z.string(), environmentVars: z.record(z.string(), z.string()).optional(), instanceProfileArn: z.string().optional(), foundationModel: z.lazy(() => marshalFoundationModelSchema).optional(), @@ -2777,7 +2776,7 @@ export const marshalUnityCatalogTableNamesSchema: z.ZodType = z export const marshalUpdateInferenceEndpointNotificationsRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), emailNotifications: z .lazy(() => marshalEmailNotificationsSchema) .optional(), diff --git a/packages/modelservingquery/src/v1/model.ts b/packages/modelservingquery/src/v1/model.ts index 0ccb4e8df..fecaf9ce4 100644 --- a/packages/modelservingquery/src/v1/model.ts +++ b/packages/modelservingquery/src/v1/model.ts @@ -89,7 +89,7 @@ export interface ExternalModelUsageElement { export interface QueryEndpointRequest { /** The name of the serving endpoint. This field is required and is provided via the path parameter. */ - name?: string | undefined; + name: string; /** * The prompt string (or array of strings) field used ONLY for __completions external & foundation model__ * serving endpoints and should only be used with other completions query fields. @@ -310,7 +310,7 @@ export const marshalDataframeSplitInputSchema: z.ZodType = z export const marshalQueryEndpointRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), prompt: jsonValueSchema.optional(), input: jsonValueSchema.optional(), messages: z.array(z.lazy(() => marshalChatMessageSchema)).optional(), diff --git a/packages/networking/src/v1/model.ts b/packages/networking/src/v1/model.ts index 7cae8cce9..2c01b121e 100644 --- a/packages/networking/src/v1/model.ts +++ b/packages/networking/src/v1/model.ts @@ -419,7 +419,7 @@ export interface AwsVpcEndpointInfo { * The ID of the underlying VPC endpoint in AWS. Provided by the customer when * registering an existing AWS VPC endpoint. */ - awsVpcEndpointId?: string | undefined; + awsVpcEndpointId: string; /** The ID of the Databricks VPC endpoint service that this endpoint connects to. */ awsEndpointServiceId?: string | undefined; /** The AWS account ID in which this VPC endpoint lives. */ @@ -428,12 +428,12 @@ export interface AwsVpcEndpointInfo { export interface AzurePrivateEndpointInfo { /** The name of the Private Endpoint in the Azure subscription. */ - privateEndpointName?: string | undefined; + privateEndpointName: string; /** * The GUID of the Private Endpoint resource in the Azure subscription. * This is assigned by Azure when the user sets up the Private Endpoint. */ - privateEndpointResourceGuid?: string | undefined; + privateEndpointResourceGuid: string; /** The full resource ID of the Private Endpoint. */ privateEndpointResourceId?: string | undefined; /** The resource ID of the Databricks Private Link Service that this Private Endpoint connects to. */ @@ -443,8 +443,8 @@ export interface AzurePrivateEndpointInfo { /** Details required to configure a block list or allow list. */ export interface CreateAccountIpAccessListRequest { accountId?: string | undefined; - label?: string | undefined; - listType?: AccountIpAccessListType_IpAccessListType | undefined; + label: string; + listType: AccountIpAccessListType_IpAccessListType; ipAddresses?: string[] | undefined; } @@ -458,15 +458,15 @@ export interface CreateEndpointRequest { * The parent resource name of the account under which the endpoint is created. * Format: `accounts/{account_id}`. */ - parent?: string | undefined; - endpoint?: Endpoint | undefined; + parent: string; + endpoint: Endpoint; } /** Details required to configure a block list or allow list. */ export interface CreateIpAccessListRequest { /** Label for the IP access list. This **cannot** be empty. */ - label?: string | undefined; - listType?: IpAccessListType | undefined; + label: string; + listType: IpAccessListType; ipAddresses?: string[] | undefined; } @@ -522,13 +522,13 @@ export interface CreateNetworkConnectivityConfiguration { export interface CreateNetworkPolicyRequest { /** Your account ID. You can find your account ID in your accounts console. */ - accountId?: string | undefined; + accountId: string; /** Network policy configuration details. */ - networkPolicy?: AccountNetworkPolicy | undefined; + networkPolicy: AccountNetworkPolicy; } export interface CreateNetworkRequest { - accountId?: string | undefined; + accountId: string; /** The human-readable name of the network configuration. */ networkName?: string | undefined; /** The ID of the VPC associated with this network configuration. VPC IDs can be used in multiple networks. */ @@ -542,7 +542,7 @@ export interface CreateNetworkRequest { } export interface CreatePrivateAccessSettingsRequest { - accountId?: string | undefined; + accountId: string; /** The human-readable name of the private access settings object. */ privateAccessSettingsName?: string | undefined; /** The AWS region for workspaces attached to this private access settings object. */ @@ -639,7 +639,7 @@ export interface CreatePrivateEndpointRule { } export interface CreateVpcEndpointRequest { - accountId?: string | undefined; + accountId: string; /** The human-readable name of the storage configuration. */ vpcEndpointName?: string | undefined; /** The region in which this VPC endpoint object exists. */ @@ -690,7 +690,7 @@ export interface DeleteAccountIpAccessListRequest { export interface DeleteAccountIpAccessListResponse {} export interface DeleteEndpointRequest { - name?: string | undefined; + name: string; } export interface DeleteIpAccessListRequest { @@ -726,25 +726,25 @@ export interface DeleteNetworkConnectivityConfigRequest { export interface DeleteNetworkPolicyRequest { /** The unique identifier of the network policy to delete. */ - networkPolicyId?: string | undefined; + networkPolicyId: string; /** Your account ID. You can find your account ID in your accounts console. */ - accountId?: string | undefined; + accountId: string; } export interface DeleteNetworkRequest { /** Databricks Account API network configuration ID. */ - networkId?: string | undefined; - accountId?: string | undefined; + networkId: string; + accountId: string; } export interface DeletePrivateAccessSettingsRequest { - privateAccessSettingsId?: string | undefined; - accountId?: string | undefined; + privateAccessSettingsId: string; + accountId: string; } export interface DeleteVpcEndpointRequest { - vpcEndpointId?: string | undefined; - accountId?: string | undefined; + vpcEndpointId: string; + accountId: string; } /** The network policies applying for egress traffic. */ @@ -856,14 +856,14 @@ export interface Endpoint { * The input should conform to RFC-1034, which restricts to letters, numbers, and hyphens, * with the first character a letter, the last a letter or a number, and a 63 character maximum. */ - displayName?: string | undefined; + displayName: string; /** * The use case that determines the type of network connectivity this endpoint provides. * This field is automatically determined based on the endpoint configuration and cloud-specific settings. */ useCase?: EndpointUseCase_EndpointUseCase | undefined; /** The cloud provider region where this endpoint is located. */ - region?: string | undefined; + region: string; /** The state of the endpoint. The endpoint can only be used if the state is `APPROVED`. */ state?: EndpointState | undefined; /** @@ -923,22 +923,22 @@ export interface GcpEndpoint { export interface GcpNetworkInfo { /** The GCP project ID for network resources. This project is where the VPC and subnet resides. */ - networkProjectId?: string | undefined; + networkProjectId: string; /** The customer-provided VPC ID. */ - vpcId?: string | undefined; + vpcId: string; /** * The customer-provided Subnet ID that will be available to Clusters in Workspaces using this * Network. */ - subnetId?: string | undefined; - subnetRegion?: string | undefined; + subnetId: string; + subnetRegion: string; /** * Name of the secondary range within the subnet that will be used by GKE as Pod IP range. * This is BYO VPC specific. DB VPC uses network.getGcpManagedNetworkConfig.getGkeClusterPodIpRange */ - podIpRangeName?: string | undefined; + podIpRangeName: string; /** Name of the secondary range within the subnet that will be used by GKE as Service IP range. */ - serviceIpRangeName?: string | undefined; + serviceIpRangeName: string; } export interface GcpPscEndpointInfo { @@ -951,27 +951,27 @@ export interface GcpPscEndpointInfo { * The GCP consumer project ID in which this PSC endpoint is created. Provided by the customer * when registering an existing PSC endpoint. */ - projectId?: string | undefined; + projectId: string; /** * The name of this PSC connection in the GCP consumer project. Provided by the customer when * registering an existing PSC endpoint. */ - pscEndpoint?: string | undefined; + pscEndpoint: string; /** * The GCP region of the PSC connection endpoint. Provided by the customer when registering an * existing PSC endpoint. GCP supports only same-region PSC, so this must match the workspace * region. */ - endpointRegion?: string | undefined; + endpointRegion: string; /** The ID of the service attachment this PSC endpoint connects to. */ serviceAttachmentId?: string | undefined; } export interface GcpVpcEndpointInfo { pscConnectionId?: string | undefined; - projectId?: string | undefined; - pscEndpointName?: string | undefined; - endpointRegion?: string | undefined; + projectId: string; + pscEndpointName: string; + endpointRegion: string; serviceAttachmentId?: string | undefined; } @@ -986,7 +986,7 @@ export interface GetAccountIpAccessListResponse { } export interface GetEndpointRequest { - name?: string | undefined; + name: string; } export interface GetIpAccessListRequest { @@ -1018,26 +1018,26 @@ export interface GetNetworkConnectivityConfigRequest { export interface GetNetworkPolicyRequest { /** The unique identifier of the network policy to retrieve. */ - networkPolicyId?: string | undefined; + networkPolicyId: string; /** Your account ID. You can find your account ID in your accounts console. */ - accountId?: string | undefined; + accountId: string; } export interface GetNetworkRequest { /** Databricks Account API network configuration ID. */ - networkId?: string | undefined; - accountId?: string | undefined; + networkId: string; + accountId: string; } export interface GetPrivateAccessSettingsRequest { - privateAccessSettingsId?: string | undefined; - accountId?: string | undefined; + privateAccessSettingsId: string; + accountId: string; } export interface GetVpcEndpointRequest { /** Databricks VPC endpoint ID. */ - vpcEndpointId?: string | undefined; - accountId?: string | undefined; + vpcEndpointId: string; + accountId: string; } export interface GetWorkspaceNetworkOptionRequest { @@ -1389,7 +1389,7 @@ export interface ListEndpointsRequest { * The parent resource name of the account to list endpoints for. * Format: `accounts/{account_id}`. */ - parent?: string | undefined; + parent: string; pageToken?: string | undefined; pageSize?: number | undefined; } @@ -1440,7 +1440,7 @@ export interface ListNetworkConnectivityConfigsResponse { export interface ListNetworkPoliciesRequest { /** Your account ID. You can find your account ID in your accounts console. */ - accountId?: string | undefined; + accountId: string; /** Pagination token to go to next page based on previous query. */ pageToken?: string | undefined; } @@ -1453,7 +1453,7 @@ export interface ListNetworkPoliciesResponse { } export interface ListNetworkRequest { - accountId?: string | undefined; + accountId: string; } export interface ListNetworkResponse { @@ -1461,7 +1461,7 @@ export interface ListNetworkResponse { } export interface ListPrivateAccessSettingsRequest { - accountId?: string | undefined; + accountId: string; } export interface ListPrivateAccessSettingsResponse { @@ -1469,7 +1469,7 @@ export interface ListPrivateAccessSettingsResponse { } export interface ListVpcEndpointRequest { - accountId?: string | undefined; + accountId: string; } export interface ListVpcEndpointResponse { @@ -1812,11 +1812,11 @@ export interface ReplaceAccountIpAccessListRequest { /** The ID for the corresponding IP access list */ listId?: string | undefined; /** Label for the IP access list. This **cannot** be empty. */ - label?: string | undefined; - listType?: AccountIpAccessListType_IpAccessListType | undefined; + label: string; + listType: AccountIpAccessListType_IpAccessListType; ipAddresses?: string[] | undefined; /** Specifies whether this IP access list is enabled. */ - enabled?: boolean | undefined; + enabled: boolean; } /** The IP access list was successfully replaced. */ @@ -1829,11 +1829,11 @@ export interface ReplaceIpAccessListRequest { /** The ID for the corresponding IP access list */ listId?: string | undefined; /** Label for the IP access list. This **cannot** be empty. */ - label?: string | undefined; - listType?: IpAccessListType | undefined; + label: string; + listType: IpAccessListType; ipAddresses?: string[] | undefined; /** Specifies whether this IP access list is enabled. */ - enabled?: boolean | undefined; + enabled: boolean; } /** The IP access list was successfully replaced. */ @@ -1845,7 +1845,7 @@ export interface ReplaceIpAccessListResponse { export interface UpdateAccountIpAccessListRequest { accountId?: string | undefined; /** The ID for the corresponding IP access list */ - listId?: string | undefined; + listId: string; /** Label for the IP access list. This **cannot** be empty. */ label?: string | undefined; listType?: AccountIpAccessListType_IpAccessListType | undefined; @@ -1862,7 +1862,7 @@ export interface UpdateAccountIpAccessListResponse { /** Details required to update an IP access list. */ export interface UpdateIpAccessListRequest { /** The ID for the corresponding IP access list */ - listId?: string | undefined; + listId: string; /** Label for the IP access list. This **cannot** be empty. */ label?: string | undefined; listType?: IpAccessListType | undefined; @@ -1885,21 +1885,21 @@ export interface UpdateNccPrivateEndpointRuleRequest { /** Your private endpoint rule ID. */ privateEndpointRuleId?: string | undefined; privateEndpointRule?: UpdatePrivateEndpointRule | undefined; - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateNetworkPolicyRequest { /** The unique identifier for the network policy. */ - networkPolicyId?: string | undefined; + networkPolicyId: string; /** Your account ID. You can find your account ID in your accounts console. */ - accountId?: string | undefined; + accountId: string; /** Updated network policy configuration details. */ networkPolicy?: AccountNetworkPolicy | undefined; } export interface UpdatePrivateAccessSettingsRequest { /** Properties of the new private access settings object. */ - customerFacingPrivateAccessSettings?: PrivateAccessSettings | undefined; + customerFacingPrivateAccessSettings: PrivateAccessSettings; } /** @@ -2095,7 +2095,7 @@ export const unmarshalAccountNetworkPolicySchema: z.ZodType = z .object({ - aws_vpc_endpoint_id: z.string().optional(), + aws_vpc_endpoint_id: z.string(), aws_endpoint_service_id: z.string().optional(), aws_account_id: z.string().optional(), }) @@ -2108,8 +2108,8 @@ export const unmarshalAwsVpcEndpointInfoSchema: z.ZodType = export const unmarshalAzurePrivateEndpointInfoSchema: z.ZodType = z .object({ - private_endpoint_name: z.string().optional(), - private_endpoint_resource_guid: z.string().optional(), + private_endpoint_name: z.string(), + private_endpoint_resource_guid: z.string(), private_endpoint_resource_id: z.string().optional(), private_link_service_id: z.string().optional(), }) @@ -2318,9 +2318,9 @@ export const unmarshalEndpointSchema: z.ZodType = z name: z.string().optional(), endpoint_id: z.string().optional(), account_id: z.string().optional(), - display_name: z.string().optional(), + display_name: z.string(), use_case: z.string().optional(), - region: z.string().optional(), + region: z.string(), state: z.string().optional(), azure_private_endpoint_info: z .lazy(() => unmarshalAzurePrivateEndpointInfoSchema) @@ -2396,12 +2396,12 @@ export const unmarshalGcpEndpointSchema: z.ZodType = z export const unmarshalGcpNetworkInfoSchema: z.ZodType = z .object({ - network_project_id: z.string().optional(), - vpc_id: z.string().optional(), - subnet_id: z.string().optional(), - subnet_region: z.string().optional(), - pod_ip_range_name: z.string().optional(), - service_ip_range_name: z.string().optional(), + network_project_id: z.string(), + vpc_id: z.string(), + subnet_id: z.string(), + subnet_region: z.string(), + pod_ip_range_name: z.string(), + service_ip_range_name: z.string(), }) .transform(d => ({ networkProjectId: d.network_project_id, @@ -2416,9 +2416,9 @@ export const unmarshalGcpPscEndpointInfoSchema: z.ZodType = z .object({ psc_connection_id: z.string().optional(), - project_id: z.string().optional(), - psc_endpoint: z.string().optional(), - endpoint_region: z.string().optional(), + project_id: z.string(), + psc_endpoint: z.string(), + endpoint_region: z.string(), service_attachment_id: z.string().optional(), }) .transform(d => ({ @@ -2433,9 +2433,9 @@ export const unmarshalGcpVpcEndpointInfoSchema: z.ZodType = z .object({ psc_connection_id: z.string().optional(), - project_id: z.string().optional(), - psc_endpoint_name: z.string().optional(), - endpoint_region: z.string().optional(), + project_id: z.string(), + psc_endpoint_name: z.string(), + endpoint_region: z.string(), service_attachment_id: z.string().optional(), }) .transform(d => ({ @@ -3434,7 +3434,7 @@ export const marshalAccountNetworkPolicySchema: z.ZodType = z export const marshalAwsVpcEndpointInfoSchema: z.ZodType = z .object({ - awsVpcEndpointId: z.string().optional(), + awsVpcEndpointId: z.string(), awsEndpointServiceId: z.string().optional(), awsAccountId: z.string().optional(), }) @@ -3446,8 +3446,8 @@ export const marshalAwsVpcEndpointInfoSchema: z.ZodType = z export const marshalAzurePrivateEndpointInfoSchema: z.ZodType = z .object({ - privateEndpointName: z.string().optional(), - privateEndpointResourceGuid: z.string().optional(), + privateEndpointName: z.string(), + privateEndpointResourceGuid: z.string(), privateEndpointResourceId: z.string().optional(), privateLinkServiceId: z.string().optional(), }) @@ -3461,8 +3461,8 @@ export const marshalAzurePrivateEndpointInfoSchema: z.ZodType = z export const marshalCreateAccountIpAccessListRequestSchema: z.ZodType = z .object({ accountId: z.string().optional(), - label: z.string().optional(), - listType: z.string().optional(), + label: z.string(), + listType: z.string(), ipAddresses: z.array(z.string()).optional(), }) .transform(d => ({ @@ -3474,8 +3474,8 @@ export const marshalCreateAccountIpAccessListRequestSchema: z.ZodType = z export const marshalCreateIpAccessListRequestSchema: z.ZodType = z .object({ - label: z.string().optional(), - listType: z.string().optional(), + label: z.string(), + listType: z.string(), ipAddresses: z.array(z.string()).optional(), }) .transform(d => ({ @@ -3510,7 +3510,7 @@ export const marshalCreateNetworkConnectivityConfigurationSchema: z.ZodType = z export const marshalCreateNetworkRequestSchema: z.ZodType = z .object({ - accountId: z.string().optional(), + accountId: z.string(), networkName: z.string().optional(), vpcId: z.string().optional(), subnetIds: z.array(z.string()).optional(), @@ -3530,7 +3530,7 @@ export const marshalCreateNetworkRequestSchema: z.ZodType = z export const marshalCreatePrivateAccessSettingsRequestSchema: z.ZodType = z .object({ - accountId: z.string().optional(), + accountId: z.string(), privateAccessSettingsName: z.string().optional(), region: z.string().optional(), publicAccessEnabled: z.boolean().optional(), @@ -3599,7 +3599,7 @@ export const marshalCreatePrivateEndpointRuleSchema: z.ZodType = z export const marshalCreateVpcEndpointRequestSchema: z.ZodType = z .object({ - accountId: z.string().optional(), + accountId: z.string(), vpcEndpointName: z.string().optional(), region: z.string().optional(), awsVpcEndpointId: z.string().optional(), @@ -3785,9 +3785,9 @@ export const marshalEndpointSchema: z.ZodType = z name: z.string().optional(), endpointId: z.string().optional(), accountId: z.string().optional(), - displayName: z.string().optional(), + displayName: z.string(), useCase: z.string().optional(), - region: z.string().optional(), + region: z.string(), state: z.string().optional(), endpointInfo: z .discriminatedUnion('$case', [ @@ -3867,12 +3867,12 @@ export const marshalGcpEndpointSchema: z.ZodType = z export const marshalGcpNetworkInfoSchema: z.ZodType = z .object({ - networkProjectId: z.string().optional(), - vpcId: z.string().optional(), - subnetId: z.string().optional(), - subnetRegion: z.string().optional(), - podIpRangeName: z.string().optional(), - serviceIpRangeName: z.string().optional(), + networkProjectId: z.string(), + vpcId: z.string(), + subnetId: z.string(), + subnetRegion: z.string(), + podIpRangeName: z.string(), + serviceIpRangeName: z.string(), }) .transform(d => ({ network_project_id: d.networkProjectId, @@ -3886,9 +3886,9 @@ export const marshalGcpNetworkInfoSchema: z.ZodType = z export const marshalGcpPscEndpointInfoSchema: z.ZodType = z .object({ pscConnectionId: z.string().optional(), - projectId: z.string().optional(), - pscEndpoint: z.string().optional(), - endpointRegion: z.string().optional(), + projectId: z.string(), + pscEndpoint: z.string(), + endpointRegion: z.string(), serviceAttachmentId: z.string().optional(), }) .transform(d => ({ @@ -3902,9 +3902,9 @@ export const marshalGcpPscEndpointInfoSchema: z.ZodType = z export const marshalGcpVpcEndpointInfoSchema: z.ZodType = z .object({ pscConnectionId: z.string().optional(), - projectId: z.string().optional(), - pscEndpointName: z.string().optional(), - endpointRegion: z.string().optional(), + projectId: z.string(), + pscEndpointName: z.string(), + endpointRegion: z.string(), serviceAttachmentId: z.string().optional(), }) .transform(d => ({ @@ -4482,10 +4482,10 @@ export const marshalReplaceAccountIpAccessListRequestSchema: z.ZodType = z .object({ accountId: z.string().optional(), listId: z.string().optional(), - label: z.string().optional(), - listType: z.string().optional(), + label: z.string(), + listType: z.string(), ipAddresses: z.array(z.string()).optional(), - enabled: z.boolean().optional(), + enabled: z.boolean(), }) .transform(d => ({ account_id: d.accountId, @@ -4499,10 +4499,10 @@ export const marshalReplaceAccountIpAccessListRequestSchema: z.ZodType = z export const marshalReplaceIpAccessListRequestSchema: z.ZodType = z .object({ listId: z.string().optional(), - label: z.string().optional(), - listType: z.string().optional(), + label: z.string(), + listType: z.string(), ipAddresses: z.array(z.string()).optional(), - enabled: z.boolean().optional(), + enabled: z.boolean(), }) .transform(d => ({ list_id: d.listId, @@ -4515,7 +4515,7 @@ export const marshalReplaceIpAccessListRequestSchema: z.ZodType = z export const marshalUpdateAccountIpAccessListRequestSchema: z.ZodType = z .object({ accountId: z.string().optional(), - listId: z.string().optional(), + listId: z.string(), label: z.string().optional(), listType: z.string().optional(), ipAddresses: z.array(z.string()).optional(), @@ -4532,7 +4532,7 @@ export const marshalUpdateAccountIpAccessListRequestSchema: z.ZodType = z export const marshalUpdateIpAccessListRequestSchema: z.ZodType = z .object({ - listId: z.string().optional(), + listId: z.string(), label: z.string().optional(), listType: z.string().optional(), ipAddresses: z.array(z.string()).optional(), diff --git a/packages/pipelines/src/v2/model.ts b/packages/pipelines/src/v2/model.ts index cce0d8263..ebc891d0d 100644 --- a/packages/pipelines/src/v2/model.ts +++ b/packages/pipelines/src/v2/model.ts @@ -515,7 +515,7 @@ export interface ApplyEnvironmentResponse {} /** Policy for auto full refresh. */ export interface AutoFullRefreshPolicy { /** (Required, Mutable) Whether to enable auto full refresh or not. */ - enabled?: boolean | undefined; + enabled: boolean; /** * (Optional, Mutable) Specify the minimum interval in hours between the timestamp * at which a table was last full refreshed and the current timestamp for triggering auto full @@ -770,9 +770,9 @@ export interface DataPlaneId { /** Location of staged data storage */ export interface DataStagingOptions { /** (Required, Immutable) The name of the catalog for the connector's staging storage location. */ - catalogName?: string | undefined; + catalogName: string; /** (Required, Immutable) The name of the schema for the connector's staging storage location. */ - schemaName?: string | undefined; + schemaName: string; /** * (Optional) The Unity Catalog-compatible name for the storage location. * This is the volume to use for the data that is extracted by the connector. @@ -784,7 +784,7 @@ export interface DataStagingOptions { } export interface DeletePipelineRequest { - pipelineId?: string | undefined; + pipelineId: string; /** * If true, deletion will proceed even if resource cleanup fails. * By default, deletion will fail if resources cleanup is required but fails. @@ -802,7 +802,7 @@ export interface DeletePipelineResponse {} export interface EditPipelineRequest { /** Unique identifier for this pipeline. */ - pipelineId?: string | undefined; + pipelineId: string; /** If false, deployment will fail if name has changed and conflicts the name of another pipeline. */ allowDuplicateNames?: boolean | undefined; /** @@ -978,7 +978,7 @@ export interface Filters { } export interface GetPipelineRequest { - pipelineId?: string | undefined; + pipelineId: string; } export interface GetPipelineResponse { @@ -1025,9 +1025,9 @@ export interface GetPipelineResponse { export interface GetUpdateRequest { /** The ID of the pipeline. */ - pipelineId?: string | undefined; + pipelineId: string; /** The ID of the update. */ - updateId?: string | undefined; + updateId: string; } export interface GetUpdateResponse { @@ -1063,7 +1063,7 @@ export interface GoogleAdsCustomReportOptions { * metrics. Values are validated against Google Ads' field-service * catalog at pipeline plan time. */ - resource?: string | undefined; + resource: string; /** * (Optional) Resource fields to select, in fully-qualified GAQL form * (e.g. "ad_group_ad.ad.id", "ad_group_ad.status"). Multiple values are @@ -1096,7 +1096,7 @@ export interface GoogleAdsOptions { * and access customer accounts under this manager account. * Overrides GoogleAdsConfig.manager_account_id from source_configurations when set. */ - managerAccountId?: string | undefined; + managerAccountId: string; /** * (Optional) Number of days to look back for report tables to capture late-arriving data. * If not specified, defaults to 30 days. @@ -1126,13 +1126,13 @@ export interface GoogleDriveOptions { export interface IngestionGatewayPipelineDefinition { /** Immutable. The Unity Catalog connection that this gateway pipeline uses to communicate with the source. */ - connectionName?: string | undefined; + connectionName: string; /** [Deprecated, use connection_name instead] Immutable. The Unity Catalog connection that this gateway pipeline uses to communicate with the source. */ connectionId?: string | undefined; /** Required, Immutable. The name of the catalog for the gateway pipeline's storage location. */ - gatewayStorageCatalog?: string | undefined; + gatewayStorageCatalog: string; /** Required, Immutable. The name of the schema for the gateway pipelines's storage location. */ - gatewayStorageSchema?: string | undefined; + gatewayStorageSchema: string; /** * Optional. The Unity Catalog-compatible name for the gateway storage location. * This is the destination to use for the data that is extracted by the gateway. @@ -1262,11 +1262,11 @@ export interface IngestionPipelineDefinition_IngestionConfig { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface IngestionPipelineDefinition_ReportSpec { /** Required. Report URL in the source system. */ - sourceUrl?: string | undefined; + sourceUrl: string; /** Required. Destination catalog to store table. */ - destinationCatalog?: string | undefined; + destinationCatalog: string; /** Required. Destination schema to store table. */ - destinationSchema?: string | undefined; + destinationSchema: string; /** Required. Destination table name. The pipeline fails if a table with that name already exists. */ destinationTable?: string | undefined; /** Configuration settings to control the ingestion of tables. These settings override the table_configuration defined in the IngestionPipelineDefinition object. */ @@ -1280,17 +1280,15 @@ export interface IngestionPipelineDefinition_SchemaSpec { /** The source catalog name. Might be optional depending on the type of source. */ sourceCatalog?: string | undefined; /** - * Schema name in the source database. Currently required; this field will become optional in - * an upcoming release, since some source types (for example streaming / message-bus connectors) - * do not use it. When that change ships, this field's type in the generated SDKs and CLI will - * change from required to optional (nullable); clients that assume it is always present should - * handle its absence. + * Schema name in the source database. Optional: some source types (for example streaming or + * message-bus connectors) do not use it, so it may be absent from a pipeline's definition. + * Clients that assume it is always present should handle its absence. */ sourceSchema?: string | undefined; /** Required. Destination catalog to store tables. */ - destinationCatalog?: string | undefined; + destinationCatalog: string; /** Required. Destination schema to store tables in. Tables with the same name as the source tables are created in this destination schema. The pipeline fails If a table with the same name already exists. */ - destinationSchema?: string | undefined; + destinationSchema: string; /** Configuration settings to control the ingestion of tables. These settings are applied to all tables in this schema and override the table_configuration defined in the IngestionPipelineDefinition object. */ tableConfiguration?: | IngestionPipelineDefinition_TableSpecificConfig @@ -1313,17 +1311,15 @@ export interface IngestionPipelineDefinition_TableSpec { /** Schema name in the source database. Might be optional depending on the type of source. */ sourceSchema?: string | undefined; /** - * Table name in the source database. Currently required; this field will become optional in - * an upcoming release, since some source types (for example streaming / message-bus connectors) - * do not use it. When that change ships, this field's type in the generated SDKs and CLI will - * change from required to optional (nullable); clients that assume it is always present should - * handle its absence. + * Table name in the source database. Optional: some source types (for example streaming or + * message-bus connectors) do not use it, so it may be absent from a pipeline's definition. + * Clients that assume it is always present should handle its absence. */ sourceTable?: string | undefined; /** Required. Destination catalog to store table. */ - destinationCatalog?: string | undefined; + destinationCatalog: string; /** Required. Destination schema to store table. */ - destinationSchema?: string | undefined; + destinationSchema: string; /** Optional. Destination table name. The pipeline fails if a table with that name already exists. If not set, the source table name is used. */ destinationTable?: string | undefined; /** Configuration settings to control the ingestion of tables. These settings override the table_configuration defined in the IngestionPipelineDefinition object and the SchemaSpec. */ @@ -1588,9 +1584,7 @@ export interface LinkedInAdsOptions { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface LinkedInAdsOptions_LinkedInAdsCustomReportOptions { /** (Required) adAnalytics finder. See LinkedInAdsFinder. */ - finder?: - | LinkedInAdsOptions_LinkedInAdsCustomReportOptions_LinkedInAdsFinder - | undefined; + finder: LinkedInAdsOptions_LinkedInAdsCustomReportOptions_LinkedInAdsFinder; /** (Required) Entity pivots to group by; count/constraints depend on finder. */ entityGranularity?: | LinkedInAdsOptions_LinkedInAdsCustomReportOptions_LinkedInAdsEntityGranularity[] @@ -1710,7 +1704,7 @@ export interface ListPipelinesResponse { */ export interface ListUpdatesRequest { /** The pipeline to return updates for. */ - pipelineId?: string | undefined; + pipelineId: string; /** Page token returned by previous call */ pageToken?: string | undefined; /** Max number of entries to return in a single page. */ @@ -1833,7 +1827,7 @@ export interface Notifications { /** Proto representing a window */ export interface OperationTimeWindow { /** An integer between 0 and 23 denoting the start hour for the window in the 24-hour day. */ - startHour?: number | undefined; + startHour: number; /** * Days of week in which the window is allowed to happen * If not specified all days of the week will be used. @@ -1958,7 +1952,7 @@ export interface PathPattern { } export interface PipelineCluster { - /** A label for the cluster specification, either `default` to configure the default cluster, or `maintenance` to configure the maintenance cluster. This field is optional. The default value is `default`. */ + /** A label for the cluster specification, either `default` to configure the default cluster settings applied to both the update and maintenance clusters, `updates` to configure the update cluster, or `maintenance` to configure the maintenance cluster. This field is optional. The default value is `default`. */ label?: string | undefined; /** Note: This field won't be persisted. Only API users will check this field. */ applyPolicyDefaultValues?: boolean | undefined; @@ -2074,7 +2068,7 @@ export interface PipelineCluster { export interface PipelineDeployment { /** The deployment method that manages the pipeline. */ - kind?: DeploymentKind | undefined; + kind: DeploymentKind; /** The path to the file containing metadata about the deployment. */ metadataFilePath?: string | undefined; /** @@ -2266,9 +2260,9 @@ export interface PipelinesAutoScale { * The minimum number of workers the cluster can scale down to when underutilized. * It is also the initial number of workers the cluster will have after creation. */ - minWorkers?: number | undefined; + minWorkers: number; /** The maximum number of workers to which the cluster can scale up when overloaded. `max_workers` must be strictly greater than `min_workers`. */ - maxWorkers?: number | undefined; + maxWorkers: number; /** * Databricks Enhanced Autoscaling optimizes cluster utilization by automatically * allocating cluster resources based on workload volume, with minimal impact to @@ -2528,7 +2522,7 @@ export interface PipelinesJobRunAs { export interface PipelinesMavenLibrary { /** Gradle-style maven coordinates. For example: "org.jsoup:jsoup:1.7.2". */ - coordinates?: string | undefined; + coordinates: string; /** * Maven repo to install the Maven package from. If omitted, both Maven Central Repository * and Spark Packages are searched. @@ -2604,7 +2598,7 @@ export interface PostgresSlotConfig { */ export interface RabbitmqOptions { /** (Required) RabbitMQ queue name to consume from. */ - queue?: string | undefined; + queue: string; } /** Reddit Ads specific options for ingestion */ @@ -2666,7 +2660,7 @@ export interface RestartWindow { * An integer between 0 and 23 denoting the start hour for the restart window in the 24-hour day. * Continuous pipeline restart is triggered only within a five-hour window starting at this hour. */ - startHour?: number | undefined; + startHour: number; /** * Days of week in which the restart is allowed to happen (within a five-hour window starting at start_hour). * If not specified all days of the week will be used. @@ -2791,7 +2785,7 @@ export interface StackFrame { } export interface StartUpdateRequest { - pipelineId?: string | undefined; + pipelineId: string; /** If true, this update will reset all tables before running. */ fullRefresh?: boolean | undefined; cause?: UpdateCause | undefined; @@ -2833,7 +2827,7 @@ export interface StartUpdateResponse { } export interface StopPipelineRequest { - pipelineId?: string | undefined; + pipelineId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -3032,7 +3026,7 @@ export const unmarshalApplyEnvironmentResponseSchema: z.ZodType = z .object({ - enabled: z.boolean().optional(), + enabled: z.boolean(), min_interval_hours: z.number().optional(), }) .transform(d => ({ @@ -3232,8 +3226,8 @@ export const unmarshalDataPlaneIdSchema: z.ZodType = z export const unmarshalDataStagingOptionsSchema: z.ZodType = z .object({ - catalog_name: z.string().optional(), - schema_name: z.string().optional(), + catalog_name: z.string(), + schema_name: z.string(), volume_name: z.string().optional(), }) .transform(d => ({ @@ -3394,7 +3388,7 @@ export const unmarshalGoogleAdsConfigSchema: z.ZodType = z export const unmarshalGoogleAdsCustomReportOptionsSchema: z.ZodType = z .object({ - resource: z.string().optional(), + resource: z.string(), resource_fields: z.array(z.string()).optional(), segments: z.array(z.string()).optional(), metrics: z.array(z.string()).optional(), @@ -3408,7 +3402,7 @@ export const unmarshalGoogleAdsCustomReportOptionsSchema: z.ZodType = z .object({ - manager_account_id: z.string().optional(), + manager_account_id: z.string(), lookback_window_days: z.number().optional(), sync_start_date: z.string().optional(), custom_report_options: z @@ -3440,10 +3434,10 @@ export const unmarshalGoogleDriveOptionsSchema: z.ZodType = export const unmarshalIngestionGatewayPipelineDefinitionSchema: z.ZodType = z .object({ - connection_name: z.string().optional(), + connection_name: z.string(), connection_id: z.string().optional(), - gateway_storage_catalog: z.string().optional(), - gateway_storage_schema: z.string().optional(), + gateway_storage_catalog: z.string(), + gateway_storage_schema: z.string(), gateway_storage_name: z.string().optional(), connection_parameters: z .lazy(() => unmarshalConnectionParametersSchema) @@ -3558,9 +3552,9 @@ export const unmarshalIngestionPipelineDefinition_IngestionConfigSchema: z.ZodTy export const unmarshalIngestionPipelineDefinition_ReportSpecSchema: z.ZodType = z .object({ - source_url: z.string().optional(), - destination_catalog: z.string().optional(), - destination_schema: z.string().optional(), + source_url: z.string(), + destination_catalog: z.string(), + destination_schema: z.string(), destination_table: z.string().optional(), table_configuration: z .lazy( @@ -3582,8 +3576,8 @@ export const unmarshalIngestionPipelineDefinition_SchemaSpecSchema: z.ZodType unmarshalIngestionPipelineDefinition_TableSpecificConfigSchema @@ -3613,8 +3607,8 @@ export const unmarshalIngestionPipelineDefinition_TableSpecSchema: z.ZodType = export const unmarshalLinkedInAdsOptions_LinkedInAdsCustomReportOptionsSchema: z.ZodType = z .object({ - finder: z.string().optional(), + finder: z.string(), entity_granularity: z.array(z.string()).optional(), time_granularity: z.string().optional(), metrics: z.array(z.string()).optional(), @@ -3939,7 +3933,7 @@ export const unmarshalNotificationsSchema: z.ZodType = z export const unmarshalOperationTimeWindowSchema: z.ZodType = z .object({ - start_hour: z.number().optional(), + start_hour: z.number(), days_of_week: z.array(z.string()).optional(), time_zone_id: z.string().optional(), }) @@ -4100,7 +4094,7 @@ export const unmarshalPipelineClusterSchema: z.ZodType = z export const unmarshalPipelineDeploymentSchema: z.ZodType = z .object({ - kind: z.string().optional(), + kind: z.string(), metadata_file_path: z.string().optional(), deployment_id: z.string().optional(), version_id: z.string().optional(), @@ -4275,8 +4269,8 @@ export const unmarshalPipelineTriggerSchema: z.ZodType = z export const unmarshalPipelinesAutoScaleSchema: z.ZodType = z .object({ - min_workers: z.number().optional(), - max_workers: z.number().optional(), + min_workers: z.number(), + max_workers: z.number(), mode: z.string().optional(), }) .transform(d => ({ @@ -4409,7 +4403,7 @@ export const unmarshalPipelinesJobRunAsSchema: z.ZodType = z export const unmarshalPipelinesMavenLibrarySchema: z.ZodType = z .object({ - coordinates: z.string().optional(), + coordinates: z.string(), repo: z.string().optional(), exclusions: z.array(z.string()).optional(), }) @@ -4462,7 +4456,7 @@ export const unmarshalPostgresSlotConfigSchema: z.ZodType = export const unmarshalRabbitmqOptionsSchema: z.ZodType = z .object({ - queue: z.string().optional(), + queue: z.string(), }) .transform(d => ({ queue: d.queue, @@ -4496,7 +4490,7 @@ export const unmarshalRedditAdsOptions_RedditAdsCustomReportOptionsSchema: z.Zod export const unmarshalRestartWindowSchema: z.ZodType = z .object({ - start_hour: z.number().optional(), + start_hour: z.number(), days_of_week: z.array(z.string()).optional(), time_zone_id: z.string().optional(), }) @@ -4781,7 +4775,7 @@ export const marshalApplyEnvironmentRequestSchema: z.ZodType = z export const marshalAutoFullRefreshPolicySchema: z.ZodType = z .object({ - enabled: z.boolean().optional(), + enabled: z.boolean(), minIntervalHours: z.number().optional(), }) .transform(d => ({ @@ -5098,8 +5092,8 @@ export const marshalCronTriggerSchema: z.ZodType = z export const marshalDataStagingOptionsSchema: z.ZodType = z .object({ - catalogName: z.string().optional(), - schemaName: z.string().optional(), + catalogName: z.string(), + schemaName: z.string(), volumeName: z.string().optional(), }) .transform(d => ({ @@ -5110,7 +5104,7 @@ export const marshalDataStagingOptionsSchema: z.ZodType = z export const marshalEditPipelineRequestSchema: z.ZodType = z .object({ - pipelineId: z.string().optional(), + pipelineId: z.string(), allowDuplicateNames: z.boolean().optional(), expectedLastModified: z.bigint().optional(), runAs: z.lazy(() => marshalPipelinesJobRunAsSchema).optional(), @@ -5272,7 +5266,7 @@ export const marshalGoogleAdsConfigSchema: z.ZodType = z export const marshalGoogleAdsCustomReportOptionsSchema: z.ZodType = z .object({ - resource: z.string().optional(), + resource: z.string(), resourceFields: z.array(z.string()).optional(), segments: z.array(z.string()).optional(), metrics: z.array(z.string()).optional(), @@ -5286,7 +5280,7 @@ export const marshalGoogleAdsCustomReportOptionsSchema: z.ZodType = z export const marshalGoogleAdsOptionsSchema: z.ZodType = z .object({ - managerAccountId: z.string().optional(), + managerAccountId: z.string(), lookbackWindowDays: z.number().optional(), syncStartDate: z.string().optional(), customReportOptions: z @@ -5316,10 +5310,10 @@ export const marshalGoogleDriveOptionsSchema: z.ZodType = z export const marshalIngestionGatewayPipelineDefinitionSchema: z.ZodType = z .object({ - connectionName: z.string().optional(), + connectionName: z.string(), connectionId: z.string().optional(), - gatewayStorageCatalog: z.string().optional(), - gatewayStorageSchema: z.string().optional(), + gatewayStorageCatalog: z.string(), + gatewayStorageSchema: z.string(), gatewayStorageName: z.string().optional(), connectionParameters: z .lazy(() => marshalConnectionParametersSchema) @@ -5445,9 +5439,9 @@ export const marshalIngestionPipelineDefinition_IngestionConfigSchema: z.ZodType // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalIngestionPipelineDefinition_ReportSpecSchema: z.ZodType = z .object({ - sourceUrl: z.string().optional(), - destinationCatalog: z.string().optional(), - destinationSchema: z.string().optional(), + sourceUrl: z.string(), + destinationCatalog: z.string(), + destinationSchema: z.string(), destinationTable: z.string().optional(), tableConfiguration: z .lazy(() => marshalIngestionPipelineDefinition_TableSpecificConfigSchema) @@ -5466,8 +5460,8 @@ export const marshalIngestionPipelineDefinition_SchemaSpecSchema: z.ZodType = z .object({ sourceCatalog: z.string().optional(), sourceSchema: z.string().optional(), - destinationCatalog: z.string().optional(), - destinationSchema: z.string().optional(), + destinationCatalog: z.string(), + destinationSchema: z.string(), tableConfiguration: z .lazy(() => marshalIngestionPipelineDefinition_TableSpecificConfigSchema) .optional(), @@ -5492,8 +5486,8 @@ export const marshalIngestionPipelineDefinition_TableSpecSchema: z.ZodType = z sourceCatalog: z.string().optional(), sourceSchema: z.string().optional(), sourceTable: z.string().optional(), - destinationCatalog: z.string().optional(), - destinationSchema: z.string().optional(), + destinationCatalog: z.string(), + destinationSchema: z.string(), destinationTable: z.string().optional(), tableConfiguration: z .lazy(() => marshalIngestionPipelineDefinition_TableSpecificConfigSchema) @@ -5670,7 +5664,7 @@ export const marshalLinkedInAdsOptionsSchema: z.ZodType = z export const marshalLinkedInAdsOptions_LinkedInAdsCustomReportOptionsSchema: z.ZodType = z .object({ - finder: z.string().optional(), + finder: z.string(), entityGranularity: z.array(z.string()).optional(), timeGranularity: z.string().optional(), metrics: z.array(z.string()).optional(), @@ -5760,7 +5754,7 @@ export const marshalNotificationsSchema: z.ZodType = z export const marshalOperationTimeWindowSchema: z.ZodType = z .object({ - startHour: z.number().optional(), + startHour: z.number(), daysOfWeek: z.array(z.string()).optional(), timeZoneId: z.string().optional(), }) @@ -5863,7 +5857,7 @@ export const marshalPipelineClusterSchema: z.ZodType = z export const marshalPipelineDeploymentSchema: z.ZodType = z .object({ - kind: z.string().optional(), + kind: z.string(), metadataFilePath: z.string().optional(), deploymentId: z.string().optional(), versionId: z.string().optional(), @@ -5931,8 +5925,8 @@ export const marshalPipelineTriggerSchema: z.ZodType = z export const marshalPipelinesAutoScaleSchema: z.ZodType = z .object({ - minWorkers: z.number().optional(), - maxWorkers: z.number().optional(), + minWorkers: z.number(), + maxWorkers: z.number(), mode: z.string().optional(), }) .transform(d => ({ @@ -6069,7 +6063,7 @@ export const marshalPipelinesJobRunAsSchema: z.ZodType = z export const marshalPipelinesMavenLibrarySchema: z.ZodType = z .object({ - coordinates: z.string().optional(), + coordinates: z.string(), repo: z.string().optional(), exclusions: z.array(z.string()).optional(), }) @@ -6119,7 +6113,7 @@ export const marshalPostgresSlotConfigSchema: z.ZodType = z export const marshalRabbitmqOptionsSchema: z.ZodType = z .object({ - queue: z.string().optional(), + queue: z.string(), }) .transform(d => ({ queue: d.queue, @@ -6163,7 +6157,7 @@ export const marshalReplaceWhereOverrideSchema: z.ZodType = z export const marshalRestartWindowSchema: z.ZodType = z .object({ - startHour: z.number().optional(), + startHour: z.number(), daysOfWeek: z.array(z.string()).optional(), timeZoneId: z.string().optional(), }) @@ -6266,7 +6260,7 @@ export const marshalSourceConfigSchema: z.ZodType = z export const marshalStartUpdateRequestSchema: z.ZodType = z .object({ - pipelineId: z.string().optional(), + pipelineId: z.string(), fullRefresh: z.boolean().optional(), cause: z.string().optional(), refreshSelection: z.array(z.string()).optional(), @@ -6294,7 +6288,7 @@ export const marshalStartUpdateRequestSchema: z.ZodType = z export const marshalStopPipelineRequestSchema: z.ZodType = z .object({ - pipelineId: z.string().optional(), + pipelineId: z.string(), }) .transform(d => ({ pipeline_id: d.pipelineId, diff --git a/packages/policyfamilies/src/v2/model.ts b/packages/policyfamilies/src/v2/model.ts index 7e2d5b7f8..80d73f7d9 100644 --- a/packages/policyfamilies/src/v2/model.ts +++ b/packages/policyfamilies/src/v2/model.ts @@ -5,7 +5,7 @@ import {z} from 'zod'; /** Returns the details of a policy family at a specific version */ export interface GetPolicyFamilyRequest { /** The family ID about which to retrieve information. */ - policyFamilyId?: string | undefined; + policyFamilyId: string; /** The version number for the family to fetch. Defaults to the latest version. */ version?: bigint | undefined; } diff --git a/packages/postgres/src/v1/client.ts b/packages/postgres/src/v1/client.ts index a68124e72..676e63ea0 100644 --- a/packages/postgres/src/v1/client.ts +++ b/packages/postgres/src/v1/client.ts @@ -67,6 +67,7 @@ import type { GetProjectRequest, GetRoleRequest, GetSnapshotRequest, + GetSnapshotScheduleRequest, GetSyncedTableRequest, ListBranchesRequest, ListBranchesResponse, @@ -91,6 +92,8 @@ import type { RoleOperationMetadata, Snapshot, SnapshotOperationMetadata, + SnapshotSchedule, + SnapshotScheduleOperationMetadata, SyncedTable, SyncedTableOperationMetadata, UndeleteBranchRequest, @@ -101,6 +104,7 @@ import type { UpdateEndpointRequest, UpdateProjectRequest, UpdateRoleRequest, + UpdateSnapshotScheduleRequest, } from './model'; import { marshalBranchSchema, @@ -112,6 +116,7 @@ import { marshalGenerateDatabaseCredentialRequestSchema, marshalProjectSchema, marshalRoleSchema, + marshalSnapshotScheduleSchema, marshalSnapshotSchema, marshalSyncedTableSchema, marshalUndeleteBranchRequestSchema, @@ -144,6 +149,8 @@ import { unmarshalRoleOperationMetadataSchema, unmarshalRoleSchema, unmarshalSnapshotOperationMetadataSchema, + unmarshalSnapshotScheduleOperationMetadataSchema, + unmarshalSnapshotScheduleSchema, unmarshalSnapshotSchema, unmarshalSyncedTableOperationMetadataSchema, unmarshalSyncedTableSchema, @@ -1518,6 +1525,38 @@ export class PostgresClient { return resp; } + /** + * Retrieves the snapshot schedule for a branch. A branch with no configured + * schedule returns an empty schedule (not NOT_FOUND). + */ + async getSnapshotSchedule( + req: GetSnapshotScheduleRequest, + options?: CallOptions + ): Promise { + const {host, workspaceId, httpClient} = await this.resolveConfig(); + const url = `${host}/api/2.0/postgres/${req.name ?? ''}`; + let resp: SnapshotSchedule | undefined; + const call = async (callSignal?: AbortSignal): Promise => { + const headers = new Headers(); + if (workspaceId !== undefined) { + headers.set('X-Databricks-Workspace-Id', workspaceId); + } + headers.set('User-Agent', this.userAgent); + const httpReq = buildHttpRequest('GET', url, headers, callSignal); + const respBody = await executeHttpCall({ + request: httpReq, + httpClient, + logger: this.logger, + }); + resp = parseResponse(respBody, unmarshalSnapshotScheduleSchema); + }; + await executeCall(call, options); + if (resp === undefined) { + throw new Error('operation completed without a result.'); + } + return resp; + } + /** Get a Synced Table. */ async getSyncedTable( req: GetSyncedTableRequest, @@ -2400,6 +2439,68 @@ export class PostgresClient { this.getOperation(req, options) ); } + + /** + * Sets the snapshot schedule for a branch. The `schedule` field is replaced + * wholesale; an empty schedule disables automatic snapshots. + */ + private async updateSnapshotScheduleBase( + req: UpdateSnapshotScheduleRequest, + options?: CallOptions + ): Promise { + const {host, workspaceId, httpClient} = await this.resolveConfig(); + const url = `${host}/api/2.0/postgres/${req.snapshotSchedule?.name ?? ''}`; + const params = new URLSearchParams(); + if (req.updateMask !== undefined) { + params.append('update_mask', req.updateMask.toString()); + } + const query = params.toString(); + const fullUrl = query !== '' ? `${url}?${query}` : url; + const body = marshalRequest( + req.snapshotSchedule, + marshalSnapshotScheduleSchema + ); + let resp: Operation | undefined; + const call = async (callSignal?: AbortSignal): Promise => { + const headers = new Headers({'Content-Type': 'application/json'}); + if (workspaceId !== undefined) { + headers.set('X-Databricks-Workspace-Id', workspaceId); + } + headers.set('User-Agent', this.userAgent); + const httpReq = buildHttpRequest( + 'PATCH', + fullUrl, + headers, + callSignal, + body + ); + const respBody = await executeHttpCall({ + request: httpReq, + httpClient, + logger: this.logger, + }); + resp = parseResponse(respBody, unmarshalOperationSchema); + }; + await executeCall(call, options); + if (resp === undefined) { + throw new Error('operation completed without a result.'); + } + return resp; + } + + /** + * Sets the snapshot schedule for a branch. The `schedule` field is replaced + * wholesale; an empty schedule disables automatic snapshots. + */ + async updateSnapshotSchedule( + req: UpdateSnapshotScheduleRequest, + options?: CallOptions + ): Promise { + const op = await this.updateSnapshotScheduleBase(req, options); + return new UpdateSnapshotScheduleOperation(op, (req, options) => + this.getOperation(req, options) + ); + } } export class CreateBranchOperation { @@ -4611,3 +4712,89 @@ export class UpdateRoleOperation { return op.done; } } + +export class UpdateSnapshotScheduleOperation { + constructor( + private operation: Operation, + private readonly getOperation: ( + req: GetOperationRequest, + options?: CallOptions + ) => Promise + ) {} + + /** Returns the server-assigned name of the long-running operation. */ + name(): Promise { + return Promise.resolve(this.operation.name); + } + + /** Returns metadata associated with the long-running operation. */ + metadata(): Promise { + if (this.operation.metadata === undefined) { + return Promise.resolve(undefined); + } + return Promise.resolve( + z + .lazy(() => unmarshalSnapshotScheduleOperationMetadataSchema) + .parse(this.operation.metadata) + ); + } + + /** + * Polls the operation until it completes. + * + * Throws if the operation failed. + */ + async wait(options?: LroOptions): Promise { + let result: SnapshotSchedule | undefined; + + const call = async (callSignal?: AbortSignal): Promise => { + const op = await this.getOperation( + { + name: this.operation.name, + }, + callSignal !== undefined ? {signal: callSignal} : undefined + ); + this.operation = op; + if (op.done === undefined) { + throw new Error('operation is missing the done field'); + } + if (!op.done) { + throw new StillRunningError(); + } + + if (op.result?.$case === 'error') { + const err = op.result.error; + const msg = + err.message !== undefined && err.message !== '' + ? err.message + : 'unknown error'; + const errorMsg = + err.errorCode !== undefined ? `[${err.errorCode}] ${msg}` : msg; + throw new Error(`operation failed: ${errorMsg}`, { + cause: err, + }); + } + + if (op.result?.$case !== 'response') { + throw new Error('operation completed without a response'); + } + + result = z + .lazy(() => unmarshalSnapshotScheduleSchema) + .parse(op.result.response); + }; + + await executeWait(call, options); + if (result === undefined) { + throw new Error('operation completed without a result.'); + } + return result; + } + + /** Checks whether the operation has completed */ + async done(options?: CallOptions): Promise { + const op = await this.getOperation({name: this.operation.name}, options); + this.operation = op; + return op.done; + } +} diff --git a/packages/postgres/src/v1/index.ts b/packages/postgres/src/v1/index.ts index 543755c5f..40240023a 100644 --- a/packages/postgres/src/v1/index.ts +++ b/packages/postgres/src/v1/index.ts @@ -34,10 +34,12 @@ export { UpdateEndpointOperation, UpdateProjectOperation, UpdateRoleOperation, + UpdateSnapshotScheduleOperation, } from './client'; export { CdfState, + DayOfWeek, EndpointType, ErrorCode, OpenApiMode, @@ -79,6 +81,7 @@ export type { CreateRoleRequest, CreateSnapshotRequest, CreateSyncedTableRequest, + DailySchedule, DataApi, DataApi_DataApiSpec, DataApi_DataApiStatus, @@ -119,6 +122,7 @@ export type { GetProjectRequest, GetRoleRequest, GetSnapshotRequest, + GetSnapshotScheduleRequest, GetSyncedTableRequest, InitialBranchSpec, InitialEndpointSpec, @@ -138,6 +142,7 @@ export type { ListRolesResponse, ListSnapshotsRequest, ListSnapshotsResponse, + MonthlySchedule, NewPipelineSpec, Operation, Project, @@ -154,8 +159,11 @@ export type { Role_RoleSpec, Role_RoleStatus, RoleOperationMetadata, + ScheduleCadence, Snapshot, SnapshotOperationMetadata, + SnapshotSchedule, + SnapshotScheduleOperationMetadata, SnapshotSpec, SnapshotStatus, SyncedTable, @@ -174,6 +182,8 @@ export type { UpdateEndpointRequest, UpdateProjectRequest, UpdateRoleRequest, + UpdateSnapshotScheduleRequest, + WeeklySchedule, } from './model'; export { @@ -183,4 +193,5 @@ export { endpointFieldMask, projectFieldMask, roleFieldMask, + snapshotScheduleFieldMask, } from './model'; diff --git a/packages/postgres/src/v1/model.ts b/packages/postgres/src/v1/model.ts index 0fefea569..c66146d71 100644 --- a/packages/postgres/src/v1/model.ts +++ b/packages/postgres/src/v1/model.ts @@ -31,6 +31,33 @@ export const CdfState = { } as const; export type CdfState = (typeof CdfState)[keyof typeof CdfState] | (string & {}); +/** The day of the week on which a weekly snapshot is taken. */ +// eslint-disable-next-line @typescript-eslint/naming-convention -- Enum-style const object. +export const DayOfWeek = { + /** + * Default value; a WeeklySchedule with this value is rejected with + * INVALID_PARAMETER_VALUE. + */ + DAY_OF_WEEK_UNSPECIFIED: 'DAY_OF_WEEK_UNSPECIFIED', + /** Monday. */ + MONDAY: 'MONDAY', + /** Tuesday. */ + TUESDAY: 'TUESDAY', + /** Wednesday. */ + WEDNESDAY: 'WEDNESDAY', + /** Thursday. */ + THURSDAY: 'THURSDAY', + /** Friday. */ + FRIDAY: 'FRIDAY', + /** Saturday. */ + SATURDAY: 'SATURDAY', + /** Sunday. */ + SUNDAY: 'SUNDAY', +} as const; +export type DayOfWeek = + | (typeof DayOfWeek)[keyof typeof DayOfWeek] + | (string & {}); + /** The compute endpoint type. Either `read_write` or `read_only`. */ // eslint-disable-next-line @typescript-eslint/naming-convention -- Enum-style const object. export const EndpointType = { @@ -920,6 +947,14 @@ export interface BranchSpec { noExpiry: boolean; } | undefined; + /** + * The snapshot this branch was created from. When set, the branch's data + * comes from the snapshot rather than a source branch, so source_branch, + * source_branch_lsn, and source_branch_time must be empty. The snapshot must + * be AVAILABLE and belong to this branch's project. + * Format: projects/{project_id}/snapshots/{snapshot_id} + */ + sourceSnapshot?: string | undefined; } export interface BranchStatus { @@ -958,6 +993,12 @@ export interface BranchStatus { * Empty if the branch is not deleted, otherwise set to a timestamp in the future. */ purgeTime?: Temporal.Instant | undefined; + /** + * The snapshot this branch was restored from. Set only for branches created by + * restoring a snapshot; unset for all other branches. + * Format: projects/{project_id}/snapshots/{snapshot_id} + */ + sourceSnapshot?: string | undefined; } export interface Catalog { @@ -1000,7 +1041,7 @@ export interface Catalog_CatalogSpec { * Doing Point In Time Restore (PITR) prior to the moment before the Postgres DB was registered * in the Catalog drops the fact of registration of the database. So the user should avoid doing so. */ - postgresDatabase?: string | undefined; + postgresDatabase: string; /** * If set to true, the specified postgres_database is created on behalf of the calling user * if it does not already exist. In this case, the calling user has a role created for @@ -1054,12 +1095,12 @@ export interface CdfConfig { * The Unity Catalog catalog that replicated tables are written into. * Set at creation; the CdfConfig is immutable. */ - catalog?: string | undefined; + catalog: string; /** * The Unity Catalog schema that replicated tables are written into. * Set at creation; the CdfConfig is immutable. */ - schema?: string | undefined; + schema: string; /** When the CdfConfig was created. */ createTime?: Temporal.Instant | undefined; /** @@ -1071,7 +1112,7 @@ export interface CdfConfig { * The Postgres schema this CdfConfig replicates from. Unique within the * parent database. Set at creation; the CdfConfig is immutable. */ - postgresSchema?: string | undefined; + postgresSchema: string; } /** @@ -1117,13 +1158,13 @@ export interface CreateBranchRequest { * The Project where this Branch will be created. * Format: projects/{project_id} */ - parent?: string | undefined; + parent: string; /** * The ID to use for the Branch. This becomes the final component of the branch's resource name. * The ID is required and must be 1-63 characters long, start with a lowercase letter, and contain only lowercase letters, numbers, and hyphens. * For example, `development` becomes `projects/my-app/branches/development`. */ - branchId?: string | undefined; + branchId: string; /** The Branch to create. */ branch?: Branch | undefined; /** If true, update the branch if it already exists instead of returning an error. */ @@ -1135,8 +1176,8 @@ export interface CreateCatalogRequest { * The ID in the Unity Catalog. * It becomes the full resource name, for example "my_catalog" becomes "catalogs/my_catalog". */ - catalogId?: string | undefined; - catalog?: Catalog | undefined; + catalogId: string; + catalog: Catalog; } /** Request to create a Lakebase CDF configuration (CdfConfig). */ @@ -1145,12 +1186,12 @@ export interface CreateCdfConfigRequest { * The parent database under which to create the CdfConfig. * Format: projects/{project}/branches/{branch}/databases/{database} */ - parent?: string | undefined; + parent: string; /** * The CdfConfig to create. The catalog, schema, and postgres_schema fields are * required; all other fields are output only and ignored on input. */ - cdfConfig?: CdfConfig | undefined; + cdfConfig: CdfConfig; /** * The user-specified id for the CdfConfig, forming the final segment of its * resource name. Must match the pattern `[a-z][a-z0-9_]{0,62}`. Defaults to @@ -1162,9 +1203,9 @@ export interface CreateCdfConfigRequest { /** Enable Data API for a database. */ export interface CreateDataApiRequest { /** Parent database: projects/{project_id}/branches/{branch_id}/databases/{database_id} */ - parent?: string | undefined; + parent: string; /** The Data API configuration to create. */ - dataApi?: DataApi | undefined; + dataApi: DataApi; } export interface CreateDatabaseRequest { @@ -1172,7 +1213,7 @@ export interface CreateDatabaseRequest { * The Branch where this Database will be created. * Format: projects/{project_id}/branches/{branch_id} */ - parent?: string | undefined; + parent: string; /** * The ID to use for the Database, which will become the final component of * the database's resource name. @@ -1185,7 +1226,7 @@ export interface CreateDatabaseRequest { */ databaseId?: string | undefined; /** The desired specification of a Database. */ - database?: Database | undefined; + database: Database; /** * If true, update the database if it already exists instead of returning an * error. @@ -1198,15 +1239,15 @@ export interface CreateEndpointRequest { * The Branch where this Endpoint will be created. * Format: projects/{project_id}/branches/{branch_id} */ - parent?: string | undefined; + parent: string; /** * The ID to use for the Endpoint. This becomes the final component of the endpoint's resource name. * The ID is required and must be 1-63 characters long, start with a lowercase letter, and contain only lowercase letters, numbers, and hyphens. * For example, `primary` becomes `projects/my-app/branches/development/endpoints/primary`. */ - endpointId?: string | undefined; + endpointId: string; /** The Endpoint to create. */ - endpoint?: Endpoint | undefined; + endpoint: Endpoint; /** If true, update the endpoint if it already exists instead of returning an error. */ replaceExisting?: boolean | undefined; } @@ -1217,7 +1258,7 @@ export interface CreateProjectRequest { * The ID is required and must be 1-63 characters long, start with a lowercase letter, and contain only lowercase letters, numbers, and hyphens. * For example, `my-app` becomes `projects/my-app`. */ - projectId?: string | undefined; + projectId: string; /** The Project to create. */ project?: Project | undefined; } @@ -1227,7 +1268,7 @@ export interface CreateRoleRequest { * The Branch where this Role is created. * Format: projects/{project_id}/branches/{branch_id} */ - parent?: string | undefined; + parent: string; /** * The ID to use for the Role, which will become the final component of * the role's resource name. @@ -1240,7 +1281,7 @@ export interface CreateRoleRequest { */ roleId?: string | undefined; /** The desired specification of a Role. */ - role?: Role | undefined; + role: Role; /** * If true, update the role if it already exists instead of returning an * error. @@ -1259,14 +1300,14 @@ export interface CreateSnapshotRequest { * The project in which to create the snapshot. * Format: projects/{project_id} */ - parent?: string | undefined; + parent: string; /** The snapshot to create. */ - snapshot?: Snapshot | undefined; + snapshot: Snapshot; /** * Client-chosen ID for the snapshot. It becomes the final segment of the * snapshot resource name and cannot be changed after creation. */ - snapshotId?: string | undefined; + snapshotId: string; } /** Establish a synchronisation to the Postgres database for Reverse ETL for the source table selected from the Unity Catalog. */ @@ -1283,8 +1324,14 @@ export interface CreateSyncedTableRequest { * 1. An online VIEW virtual table in the Unity Catalog accessible via the Lakehouse Federation. * 2. Postgres table named "{table}" in schema "{schema}" in the connected Postgres database */ - syncedTableId?: string | undefined; - syncedTable?: SyncedTable | undefined; + syncedTableId: string; + syncedTable: SyncedTable; +} + +/** Take a snapshot once per day, at the configured hour. */ +export interface DailySchedule { + /** The hour of the day, in UTC, at which to take the snapshot, in [0, 23]. */ + hour?: number | undefined; } /** @@ -1415,7 +1462,7 @@ export interface Database_DatabaseSpec { * * A database always has an owner. */ - role?: string | undefined; + role: string; /** * The name of the Postgres database. * @@ -1456,7 +1503,7 @@ export interface DeleteBranchRequest { * The full resource path of the branch to delete. * Format: projects/{project_id}/branches/{branch_id} */ - name?: string | undefined; + name: string; /** If true, permanently delete the branch; if false, soft delete. */ purge?: boolean | undefined; } @@ -1467,7 +1514,7 @@ export interface DeleteCatalogRequest { * * Format: "catalogs/{catalog_id}". */ - name?: string | undefined; + name: string; } /** Request to delete a Lakebase CDF configuration (CdfConfig). */ @@ -1476,7 +1523,7 @@ export interface DeleteCdfConfigRequest { * The resource name of the CdfConfig to delete. * Format: projects/{project}/branches/{branch}/databases/{database}/cdf-configs/{cdf_config} */ - name?: string | undefined; + name: string; /** * When true, also drops the replicated Delta tables in Unity Catalog. When * false (the default), the replicated tables are preserved at their last @@ -1488,7 +1535,7 @@ export interface DeleteCdfConfigRequest { /** Disable Data API for a database. */ export interface DeleteDataApiRequest { /** Resource name: projects/{project_id}/branches/{branch_id}/databases/{database_id}/data-api */ - name?: string | undefined; + name: string; } export interface DeleteDatabaseRequest { @@ -1496,7 +1543,7 @@ export interface DeleteDatabaseRequest { * The resource name of the postgres database. * Format: projects/{project_id}/branches/{branch_id}/databases/{database_id} */ - name?: string | undefined; + name: string; } export interface DeleteEndpointRequest { @@ -1504,7 +1551,7 @@ export interface DeleteEndpointRequest { * The full resource path of the endpoint to delete. * Format: projects/{project_id}/branches/{branch_id}/endpoints/{endpoint_id} */ - name?: string | undefined; + name: string; } export interface DeleteProjectRequest { @@ -1525,7 +1572,7 @@ export interface DeleteRoleRequest { * The full resource path of the role to delete. * Format: projects/{project_id}/branches/{branch_id}/roles/{role_id} */ - name?: string | undefined; + name: string; /** * Reassign objects. If this is set, all objects owned by the role are * reassigned to the role specified in this parameter. @@ -1541,7 +1588,7 @@ export interface DeleteSnapshotRequest { * The resource name of the snapshot to delete. * Format: projects/{project_id}/snapshots/{snapshot_id} */ - name?: string | undefined; + name: string; } export interface DeleteSyncedTableRequest { @@ -1549,7 +1596,7 @@ export interface DeleteSyncedTableRequest { * The Full resource name of the synced table, of the format "synced_tables/{catalog}.{schema}.{table}", * where (catalog, schema, table) are the UC entity names. */ - name?: string | undefined; + name: string; } export interface DeltaTableSyncInfo { @@ -1592,13 +1639,13 @@ export interface EndpointGroupSpec { * The minimum number of computes in the endpoint group. Currently, this must be equal to max. This must be greater * than or equal to 1. */ - min?: number | undefined; + min: number; /** * The maximum number of computes in the endpoint group. Currently, this must be equal to min. Set to 1 for single * compute endpoints, to disable HA. To manually suspend all computes in an endpoint group, set disabled to * true on the EndpointSpec. */ - max?: number | undefined; + max: number; /** * Whether to allow read-only connections to read-write endpoints. Only relevant for read-write endpoints where * size.max > 1. @@ -1611,13 +1658,13 @@ export interface EndpointGroupStatus { * The minimum number of computes in the endpoint group. Currently, this must be equal to max. This must be greater * than or equal to 1. */ - min?: number | undefined; + min: number; /** * The maximum number of computes in the endpoint group. Currently, this must be equal to min. Set to 1 for single * compute endpoints, to disable HA. To manually suspend all computes in an endpoint group, set disabled to * true on the EndpointSpec. */ - max?: number | undefined; + max: number; /** * Whether read-only connections to read-write endpoints are allowed. Only relevant if read replicas are configured * by specifying size.max > 1. @@ -1658,7 +1705,7 @@ export interface EndpointSettings { export interface EndpointSpec { /** The endpoint type. A branch can only have one READ_WRITE endpoint. */ - endpointType?: EndpointType | undefined; + endpointType: EndpointType; /** The minimum number of Compute Units. Minimum value is 0.5. */ autoscalingLimitMinCu?: number | undefined; /** @@ -1747,7 +1794,7 @@ export interface GenerateDatabaseCredentialRequest { * The endpoint resource name for which this credential will be generated. * Format: projects/{project_id}/branches/{branch_id}/endpoints/{endpoint_id} */ - endpoint?: string | undefined; + endpoint: string; /** * Expiration information for the credential. * Users can specify either expire_time or ttl. @@ -1778,7 +1825,7 @@ export interface GetBranchRequest { * The full resource path of the branch to retrieve. * Format: projects/{project_id}/branches/{branch_id} */ - name?: string | undefined; + name: string; } export interface GetCatalogRequest { @@ -1787,7 +1834,7 @@ export interface GetCatalogRequest { * * Format: "catalogs/{catalog_id}". */ - name?: string | undefined; + name: string; } /** Request to retrieve a single CdfConfig. */ @@ -1796,7 +1843,7 @@ export interface GetCdfConfigRequest { * The resource name of the CdfConfig to retrieve. * Format: projects/{project}/branches/{branch}/databases/{database}/cdf-configs/{cdf_config} */ - name?: string | undefined; + name: string; } /** Request to retrieve the status of a single replicated table (CdfStatus). */ @@ -1805,13 +1852,13 @@ export interface GetCdfStatusRequest { * The resource name of the CdfStatus to retrieve. * Format: projects/{project}/branches/{branch}/databases/{database}/cdf-configs/{cdf_config}/cdf-statuses/{cdf_status} */ - name?: string | undefined; + name: string; } /** Get Data API configuration for a database. */ export interface GetDataApiRequest { /** Resource name: projects/{project_id}/branches/{branch_id}/databases/{database_id}/data-api */ - name?: string | undefined; + name: string; } export interface GetDatabaseRequest { @@ -1819,7 +1866,7 @@ export interface GetDatabaseRequest { * The name of the Database to retrieve. * Format: projects/{project_id}/branches/{branch_id}/databases/{database_id} */ - name?: string | undefined; + name: string; } export interface GetEndpointRequest { @@ -1827,7 +1874,7 @@ export interface GetEndpointRequest { * The full resource path of the endpoint to retrieve. * Format: projects/{project_id}/branches/{branch_id}/endpoints/{endpoint_id} */ - name?: string | undefined; + name: string; } /** The request message for `GetOperation` method. */ @@ -1849,7 +1896,7 @@ export interface GetRoleRequest { * The full resource path of the role to retrieve. * Format: projects/{project_id}/branches/{branch_id}/roles/{role_id} */ - name?: string | undefined; + name: string; } export interface GetSnapshotRequest { @@ -1857,7 +1904,16 @@ export interface GetSnapshotRequest { * The resource name of the snapshot to retrieve. * Format: projects/{project_id}/snapshots/{snapshot_id} */ - name?: string | undefined; + name: string; +} + +/** Request to retrieve the snapshot schedule for a branch. */ +export interface GetSnapshotScheduleRequest { + /** + * The resource name of the branch's snapshot schedule. + * Format: projects/{project_id}/branches/{branch_id}/snapshot-schedule + */ + name: string; } export interface GetSyncedTableRequest { @@ -1866,7 +1922,7 @@ export interface GetSyncedTableRequest { * Format: "synced_tables/{catalog}.{schema}.{table}", * where (catalog, schema, table) are the entity names in the Unity Catalog. */ - name?: string | undefined; + name: string; } /** Configuration for the initial default branch created during project creation. */ @@ -1910,7 +1966,7 @@ export interface ListBranchesRequest { * The Project that owns this collection of branches. * Format: projects/{project_id} */ - parent?: string | undefined; + parent: string; /** Page token from a previous response. If not provided, returns the first page. */ pageToken?: string | undefined; /** Upper bound for items returned. Cannot be negative. */ @@ -1936,7 +1992,7 @@ export interface ListCdfConfigsRequest { * The parent database to list CdfConfigs for. * Format: projects/{project}/branches/{branch}/databases/{database} */ - parent?: string | undefined; + parent: string; /** Maximum number of CdfConfigs to return. */ pageSize?: number | undefined; /** @@ -1966,7 +2022,7 @@ export interface ListCdfStatusesRequest { * The parent CdfConfig to list CdfStatuses for. * Format: projects/{project}/branches/{branch}/databases/{database}/cdf-configs/{cdf_config} */ - parent?: string | undefined; + parent: string; /** Maximum number of CdfStatuses to return. */ pageSize?: number | undefined; /** @@ -1993,7 +2049,7 @@ export interface ListDatabasesRequest { * The Branch that owns this collection of databases. * Format: projects/{project_id}/branches/{branch_id} */ - parent?: string | undefined; + parent: string; /** Pagination token to go to the next page of Databases. Requests first page if absent. */ pageToken?: string | undefined; /** Upper bound for items returned. */ @@ -2012,7 +2068,7 @@ export interface ListEndpointsRequest { * The Branch that owns this collection of endpoints. * Format: projects/{project_id}/branches/{branch_id} */ - parent?: string | undefined; + parent: string; /** Page token from a previous response. If not provided, returns the first page. */ pageToken?: string | undefined; /** Upper bound for items returned. Cannot be negative. */ @@ -2051,7 +2107,7 @@ export interface ListRolesRequest { * The Branch that owns this collection of roles. * Format: projects/{project_id}/branches/{branch_id} */ - parent?: string | undefined; + parent: string; /** Page token from a previous response. If not provided, returns the first page. */ pageToken?: string | undefined; /** Upper bound for items returned. Cannot be negative. */ @@ -2070,7 +2126,7 @@ export interface ListSnapshotsRequest { * The project that owns the snapshots. * Format: projects/{project_id} */ - parent?: string | undefined; + parent: string; /** Page token from a previous response; omit for the first page. */ pageToken?: string | undefined; /** Maximum number of snapshots to return per page. */ @@ -2084,6 +2140,18 @@ export interface ListSnapshotsResponse { nextPageToken?: string | undefined; } +/** Take a snapshot once per month, on the configured day at the configured hour. */ +export interface MonthlySchedule { + /** + * The day of the month on which to take the snapshot, in [1, 31]. In shorter + * months the snapshot is taken on the last day instead (day 31 runs on Feb 28 + * or 29, and on Apr 30), so every month gets exactly one snapshot. + */ + day: number; + /** The hour of the day, in UTC, at which to take the snapshot, in [0, 23]. */ + hour?: number | undefined; +} + export interface NewPipelineSpec { /** * UC catalog for the pipeline to store intermediate files (checkpoints, event logs etc). @@ -2417,6 +2485,37 @@ export interface Role_RoleStatus { // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface RoleOperationMetadata {} +/** One cadence at which automatic snapshots are taken. */ +export interface ScheduleCadence { + /** + * The recurrence pattern. Exactly one arm must be set; an unset cadence is + * rejected with INVALID_PARAMETER_VALUE. + */ + schedule?: + | { + $case: 'dailySchedule'; + /** Take a snapshot once per day. */ + dailySchedule: DailySchedule; + } + | { + $case: 'weeklySchedule'; + /** Take a snapshot once per week. */ + weeklySchedule: WeeklySchedule; + } + | { + $case: 'monthlySchedule'; + /** Take a snapshot once per month. */ + monthlySchedule: MonthlySchedule; + } + | undefined; + /** + * How long snapshots from this cadence are kept before automatic deletion. + * Must be at least 1 hour. Applied when a snapshot is taken; not retroactive, + * so changing it affects only later snapshots. + */ + retention: Temporal.Duration; +} + /** * An immutable, point-in-time copy of a branch's data within a project. It * remains available after the source branch is deleted. @@ -2443,13 +2542,38 @@ export interface Snapshot { // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface SnapshotOperationMetadata {} +/** + * The automatic snapshot cadences for a branch. There is exactly one schedule + * per branch (singleton); it is configured in place, not created or deleted. + * + * Name: projects/{project_id}/branches/{branch_id}/snapshot-schedule + */ +export interface SnapshotSchedule { + /** + * The resource name of the branch's snapshot schedule. + * Format: projects/{project_id}/branches/{branch_id}/snapshot-schedule + */ + name?: string | undefined; + /** + * The cadences at which automatic snapshots are taken. Update replaces the + * whole set; an empty set disables automatic snapshots. Order is not + * significant. When several cadences fire together, one snapshot is taken, + * retained for the longest of their retentions. + */ + schedule?: ScheduleCadence[] | undefined; +} + +/** Metadata for the long-running snapshot schedule Update operation. */ +// eslint-disable-next-line @typescript-eslint/no-empty-object-type +export interface SnapshotScheduleOperationMetadata {} + /** Client-provided configuration of the snapshot. */ export interface SnapshotSpec { /** * The source branch to snapshot. * Format: projects/{project_id}/branches/{branch_id} */ - sourceBranch?: string | undefined; + sourceBranch: string; /** * The point in time to snapshot from. If unset, the current head of the * source branch is used. The chosen LSN or timestamp must fall within the @@ -2632,9 +2756,9 @@ export interface SyncedTable_SyncedTableSpec { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface SyncedTable_SyncedTableSpec_ExtraColumn { /** Name of the column. */ - columnName?: string | undefined; + columnName: string; /** PostgreSQL type of the column, for example "tsvector" or "vector(1024)". */ - columnType?: string | undefined; + columnType: string; maintenance?: SyncedTable_SyncedTableSpec_ExtraColumn_Maintenance | undefined; /** * SQL expression used to compute the column's value, for example @@ -2647,9 +2771,9 @@ export interface SyncedTable_SyncedTableSpec_ExtraColumn { // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export interface SyncedTable_SyncedTableSpec_TypeOverride { /** Name of the source column whose target PostgreSQL type should be overridden. */ - columnName?: string | undefined; + columnName: string; /** PostgreSQL-specific target type to use for the column. */ - pgType?: SyncedTable_SyncedTableSpec_PgSpecificType | undefined; + pgType: SyncedTable_SyncedTableSpec_PgSpecificType; /** * Size parameter for the target type, for types that take one (e.g. vector * dimension, varchar length). Required when the chosen pg_type needs a size. @@ -2732,7 +2856,7 @@ export interface UndeleteBranchRequest { * The full resource path of the branch to undelete. * Format: projects/{project_id}/branches/{branch_id} */ - name?: string | undefined; + name: string; } /** Request to restore a soft-deleted project within its retention period. */ @@ -2741,7 +2865,7 @@ export interface UndeleteProjectRequest { * The full resource path of the project to undelete. * Format: projects/{project_id} */ - name?: string | undefined; + name: string; } export interface UpdateBranchRequest { @@ -2751,9 +2875,9 @@ export interface UpdateBranchRequest { * The branch's `name` field is used to identify the branch to update. * Format: projects/{project_id}/branches/{branch_id} */ - branch?: Branch | undefined; + branch: Branch; /** The list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } /** Update Data API configuration for a database. */ @@ -2762,9 +2886,9 @@ export interface UpdateDataApiRequest { * The Data API configuration to update. * The data_api's `name` field identifies the resource. */ - dataApi?: DataApi | undefined; + dataApi: DataApi; /** The list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateDatabaseRequest { @@ -2774,9 +2898,9 @@ export interface UpdateDatabaseRequest { * The database's `name` field is used to identify the database to update. * Format: projects/{project_id}/branches/{branch_id}/databases/{database_id} */ - database?: Database | undefined; + database: Database; /** The list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateEndpointRequest { @@ -2786,9 +2910,9 @@ export interface UpdateEndpointRequest { * The endpoint's `name` field is used to identify the endpoint to update. * Format: projects/{project_id}/branches/{branch_id}/endpoints/{endpoint_id} */ - endpoint?: Endpoint | undefined; + endpoint: Endpoint; /** The list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateProjectRequest { @@ -2798,9 +2922,9 @@ export interface UpdateProjectRequest { * The project's `name` field is used to identify the project to update. * Format: projects/{project_id} */ - project?: Project | undefined; + project: Project; /** The list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateRoleRequest { @@ -2810,9 +2934,34 @@ export interface UpdateRoleRequest { * The role's `name` field is used to identify the role to update. * Format: projects/{project_id}/branches/{branch_id}/roles/{role_id} */ - role?: Role | undefined; + role: Role; /** The list of fields to update. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; +} + +/** + * Request to set the snapshot schedule for a branch. Returns a completed + * long-running operation whose response is the persisted snapshot schedule. + */ +export interface UpdateSnapshotScheduleRequest { + /** + * The snapshot schedule to set. Its `name` identifies the branch. + * Format: projects/{project_id}/branches/{branch_id}/snapshot-schedule + */ + snapshotSchedule: SnapshotSchedule; + /** + * Fields to update. The only updatable path is `schedule`, which replaces the + * entire set of cadences. + */ + updateMask: FieldMask; +} + +/** Take a snapshot once per week, on the configured day at the configured hour. */ +export interface WeeklySchedule { + /** The day of the week on which to take the snapshot. */ + dayOfWeek: DayOfWeek; + /** The hour of the day, in UTC, at which to take the snapshot, in [0, 23]. */ + hour?: number | undefined; } export const unmarshalApiErrorSchema: z.ZodType = z @@ -2878,6 +3027,7 @@ export const unmarshalBranchSpecSchema: z.ZodType = z .transform(s => Temporal.Duration.from('PT' + s.toUpperCase())) .optional(), no_expiry: z.boolean().optional(), + source_snapshot: z.string().optional(), }) .transform(d => ({ sourceBranch: d.source_branch, @@ -2892,6 +3042,7 @@ export const unmarshalBranchSpecSchema: z.ZodType = z : d.no_expiry !== undefined ? {$case: 'noExpiry' as const, noExpiry: d.no_expiry} : undefined, + sourceSnapshot: d.source_snapshot, })); export const unmarshalBranchStatusSchema: z.ZodType = z @@ -2927,6 +3078,7 @@ export const unmarshalBranchStatusSchema: z.ZodType = z .string() .transform(s => Temporal.Instant.from(s)) .optional(), + source_snapshot: z.string().optional(), }) .transform(d => ({ sourceBranch: d.source_branch, @@ -2942,6 +3094,7 @@ export const unmarshalBranchStatusSchema: z.ZodType = z branchId: d.branch_id, deleteTime: d.delete_time, purgeTime: d.purge_time, + sourceSnapshot: d.source_snapshot, })); export const unmarshalCatalogSchema: z.ZodType = z @@ -2974,7 +3127,7 @@ export const unmarshalCatalogSchema: z.ZodType = z export const unmarshalCatalog_CatalogSpecSchema: z.ZodType = z .object({ - postgres_database: z.string().optional(), + postgres_database: z.string(), create_database_if_missing: z.boolean().optional(), branch: z.string().optional(), }) @@ -3004,14 +3157,14 @@ export const unmarshalCatalogOperationMetadataSchema: z.ZodType = z .object({ name: z.string().optional(), - catalog: z.string().optional(), - schema: z.string().optional(), + catalog: z.string(), + schema: z.string(), create_time: z .string() .transform(s => Temporal.Instant.from(s)) .optional(), cdf_config_id: z.string().optional(), - postgres_schema: z.string().optional(), + postgres_schema: z.string(), }) .transform(d => ({ name: d.name, @@ -3053,6 +3206,14 @@ export const unmarshalCdfStatusSchema: z.ZodType = z statusDetail: d.status_detail, })); +export const unmarshalDailyScheduleSchema: z.ZodType = z + .object({ + hour: z.number().optional(), + }) + .transform(d => ({ + hour: d.hour, + })); + export const unmarshalDataApiSchema: z.ZodType = z .object({ name: z.string().optional(), @@ -3172,7 +3333,7 @@ export const unmarshalDatabaseSchema: z.ZodType = z export const unmarshalDatabase_DatabaseSpecSchema: z.ZodType = z .object({ - role: z.string().optional(), + role: z.string(), postgres_database: z.string().optional(), }) .transform(d => ({ @@ -3258,8 +3419,8 @@ export const unmarshalEndpointSchema: z.ZodType = z export const unmarshalEndpointGroupSpecSchema: z.ZodType = z .object({ - min: z.number().optional(), - max: z.number().optional(), + min: z.number(), + max: z.number(), enable_readable_secondaries: z.boolean().optional(), }) .transform(d => ({ @@ -3271,8 +3432,8 @@ export const unmarshalEndpointGroupSpecSchema: z.ZodType = z export const unmarshalEndpointGroupStatusSchema: z.ZodType = z .object({ - min: z.number().optional(), - max: z.number().optional(), + min: z.number(), + max: z.number(), enable_readable_secondaries: z.boolean().optional(), }) .transform(d => ({ @@ -3308,7 +3469,7 @@ export const unmarshalEndpointSettingsSchema: z.ZodType = z export const unmarshalEndpointSpecSchema: z.ZodType = z .object({ - endpoint_type: z.string().optional(), + endpoint_type: z.string(), autoscaling_limit_min_cu: z.number().optional(), autoscaling_limit_max_cu: z.number().optional(), disabled: z.boolean().optional(), @@ -3496,6 +3657,16 @@ export const unmarshalListSnapshotsResponseSchema: z.ZodType = z + .object({ + day: z.number(), + hour: z.number().optional(), + }) + .transform(d => ({ + day: d.day, + hour: d.hour, + })); + export const unmarshalNewPipelineSpecSchema: z.ZodType = z .object({ storage_catalog: z.string().optional(), @@ -3769,6 +3940,33 @@ export const unmarshalRole_RoleStatusSchema: z.ZodType = z export const unmarshalRoleOperationMetadataSchema: z.ZodType = z.object({}); +export const unmarshalScheduleCadenceSchema: z.ZodType = z + .object({ + daily_schedule: z.lazy(() => unmarshalDailyScheduleSchema).optional(), + weekly_schedule: z.lazy(() => unmarshalWeeklyScheduleSchema).optional(), + monthly_schedule: z.lazy(() => unmarshalMonthlyScheduleSchema).optional(), + retention: z + .string() + .transform(s => Temporal.Duration.from('PT' + s.toUpperCase())), + }) + .transform(d => ({ + schedule: + d.daily_schedule !== undefined + ? {$case: 'dailySchedule' as const, dailySchedule: d.daily_schedule} + : d.weekly_schedule !== undefined + ? { + $case: 'weeklySchedule' as const, + weeklySchedule: d.weekly_schedule, + } + : d.monthly_schedule !== undefined + ? { + $case: 'monthlySchedule' as const, + monthlySchedule: d.monthly_schedule, + } + : undefined, + retention: d.retention, + })); + export const unmarshalSnapshotSchema: z.ZodType = z .object({ name: z.string().optional(), @@ -3793,9 +3991,22 @@ export const unmarshalSnapshotSchema: z.ZodType = z export const unmarshalSnapshotOperationMetadataSchema: z.ZodType = z.object({}); +export const unmarshalSnapshotScheduleSchema: z.ZodType = z + .object({ + name: z.string().optional(), + schedule: z.array(z.lazy(() => unmarshalScheduleCadenceSchema)).optional(), + }) + .transform(d => ({ + name: d.name, + schedule: d.schedule, + })); + +export const unmarshalSnapshotScheduleOperationMetadataSchema: z.ZodType = + z.object({}); + export const unmarshalSnapshotSpecSchema: z.ZodType = z .object({ - source_branch: z.string().optional(), + source_branch: z.string(), source_branch_lsn: z.string().optional(), source_branch_time: z .string() @@ -3933,8 +4144,8 @@ export const unmarshalSyncedTable_SyncedTableSpecSchema: z.ZodType = z .object({ - column_name: z.string().optional(), - column_type: z.string().optional(), + column_name: z.string(), + column_type: z.string(), maintenance: z.string().optional(), compute: z.string().optional(), }) @@ -3949,8 +4160,8 @@ export const unmarshalSyncedTable_SyncedTableSpec_ExtraColumnSchema: z.ZodType = z .object({ - column_name: z.string().optional(), - pg_type: z.string().optional(), + column_name: z.string(), + pg_type: z.string(), size: z.number().optional(), }) .transform(d => ({ @@ -4051,6 +4262,16 @@ export const unmarshalSyncedTablePositionSchema: z.ZodType : undefined, })); +export const unmarshalWeeklyScheduleSchema: z.ZodType = z + .object({ + day_of_week: z.string(), + hour: z.number().optional(), + }) + .transform(d => ({ + dayOfWeek: d.day_of_week, + hour: d.hour, + })); + export const marshalBranchSchema: z.ZodType = z .object({ name: z.string().optional(), @@ -4105,6 +4326,7 @@ export const marshalBranchSpecSchema: z.ZodType = z z.object({$case: z.literal('noExpiry'), noExpiry: z.boolean()}), ]) .optional(), + sourceSnapshot: z.string().optional(), }) .transform(d => ({ source_branch: d.sourceBranch, @@ -4118,6 +4340,7 @@ export const marshalBranchSpecSchema: z.ZodType = z ...(d.expiration?.$case === 'noExpiry' && { no_expiry: d.expiration.noExpiry, }), + source_snapshot: d.sourceSnapshot, })); export const marshalBranchStatusSchema: z.ZodType = z @@ -4150,6 +4373,7 @@ export const marshalBranchStatusSchema: z.ZodType = z .any() .transform((d: Temporal.Instant) => d.toString()) .optional(), + sourceSnapshot: z.string().optional(), }) .transform(d => ({ source_branch: d.sourceBranch, @@ -4165,6 +4389,7 @@ export const marshalBranchStatusSchema: z.ZodType = z branch_id: d.branchId, delete_time: d.deleteTime, purge_time: d.purgeTime, + source_snapshot: d.sourceSnapshot, })); export const marshalCatalogSchema: z.ZodType = z @@ -4196,7 +4421,7 @@ export const marshalCatalogSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalCatalog_CatalogSpecSchema: z.ZodType = z .object({ - postgresDatabase: z.string().optional(), + postgresDatabase: z.string(), createDatabaseIfMissing: z.boolean().optional(), branch: z.string().optional(), }) @@ -4222,14 +4447,14 @@ export const marshalCatalog_CatalogStatusSchema: z.ZodType = z export const marshalCdfConfigSchema: z.ZodType = z .object({ name: z.string().optional(), - catalog: z.string().optional(), - schema: z.string().optional(), + catalog: z.string(), + schema: z.string(), createTime: z .any() .transform((d: Temporal.Instant) => d.toString()) .optional(), cdfConfigId: z.string().optional(), - postgresSchema: z.string().optional(), + postgresSchema: z.string(), }) .transform(d => ({ name: d.name, @@ -4240,6 +4465,14 @@ export const marshalCdfConfigSchema: z.ZodType = z postgres_schema: d.postgresSchema, })); +export const marshalDailyScheduleSchema: z.ZodType = z + .object({ + hour: z.number().optional(), + }) + .transform(d => ({ + hour: d.hour, + })); + export const marshalDataApiSchema: z.ZodType = z .object({ name: z.string().optional(), @@ -4353,7 +4586,7 @@ export const marshalDatabaseSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalDatabase_DatabaseSpecSchema: z.ZodType = z .object({ - role: z.string().optional(), + role: z.string(), postgresDatabase: z.string().optional(), }) .transform(d => ({ @@ -4417,8 +4650,8 @@ export const marshalEndpointSchema: z.ZodType = z export const marshalEndpointGroupSpecSchema: z.ZodType = z .object({ - min: z.number().optional(), - max: z.number().optional(), + min: z.number(), + max: z.number(), enableReadableSecondaries: z.boolean().optional(), }) .transform(d => ({ @@ -4429,8 +4662,8 @@ export const marshalEndpointGroupSpecSchema: z.ZodType = z export const marshalEndpointGroupStatusSchema: z.ZodType = z .object({ - min: z.number().optional(), - max: z.number().optional(), + min: z.number(), + max: z.number(), enableReadableSecondaries: z.boolean().optional(), }) .transform(d => ({ @@ -4463,7 +4696,7 @@ export const marshalEndpointSettingsSchema: z.ZodType = z export const marshalEndpointSpecSchema: z.ZodType = z .object({ - endpointType: z.string().optional(), + endpointType: z.string(), autoscalingLimitMinCu: z.number().optional(), autoscalingLimitMaxCu: z.number().optional(), disabled: z.boolean().optional(), @@ -4537,7 +4770,7 @@ export const marshalEndpointStatusSchema: z.ZodType = z export const marshalGenerateDatabaseCredentialRequestSchema: z.ZodType = z .object({ claims: z.array(z.lazy(() => marshalRequestedClaimsSchema)).optional(), - endpoint: z.string().optional(), + endpoint: z.string(), expiration: z .discriminatedUnion('$case', [ z.object({ @@ -4603,6 +4836,16 @@ export const marshalInitialEndpointSpecSchema: z.ZodType = z }), })); +export const marshalMonthlyScheduleSchema: z.ZodType = z + .object({ + day: z.number(), + hour: z.number().optional(), + }) + .transform(d => ({ + day: d.day, + hour: d.hour, + })); + export const marshalNewPipelineSpecSchema: z.ZodType = z .object({ storageCatalog: z.string().optional(), @@ -4866,6 +5109,41 @@ export const marshalRole_RoleStatusSchema: z.ZodType = z role_id: d.roleId, })); +export const marshalScheduleCadenceSchema: z.ZodType = z + .object({ + schedule: z + .discriminatedUnion('$case', [ + z.object({ + $case: z.literal('dailySchedule'), + dailySchedule: z.lazy(() => marshalDailyScheduleSchema), + }), + z.object({ + $case: z.literal('weeklySchedule'), + weeklySchedule: z.lazy(() => marshalWeeklyScheduleSchema), + }), + z.object({ + $case: z.literal('monthlySchedule'), + monthlySchedule: z.lazy(() => marshalMonthlyScheduleSchema), + }), + ]) + .optional(), + retention: z + .any() + .transform((d: Temporal.Duration) => d.toString().slice(2).toLowerCase()), + }) + .transform(d => ({ + ...(d.schedule?.$case === 'dailySchedule' && { + daily_schedule: d.schedule.dailySchedule, + }), + ...(d.schedule?.$case === 'weeklySchedule' && { + weekly_schedule: d.schedule.weeklySchedule, + }), + ...(d.schedule?.$case === 'monthlySchedule' && { + monthly_schedule: d.schedule.monthlySchedule, + }), + retention: d.retention, + })); + export const marshalSnapshotSchema: z.ZodType = z .object({ name: z.string().optional(), @@ -4887,9 +5165,19 @@ export const marshalSnapshotSchema: z.ZodType = z snapshot_id: d.snapshotId, })); +export const marshalSnapshotScheduleSchema: z.ZodType = z + .object({ + name: z.string().optional(), + schedule: z.array(z.lazy(() => marshalScheduleCadenceSchema)).optional(), + }) + .transform(d => ({ + name: d.name, + schedule: d.schedule, + })); + export const marshalSnapshotSpecSchema: z.ZodType = z .object({ - sourceBranch: z.string().optional(), + sourceBranch: z.string(), pointInTime: z .discriminatedUnion('$case', [ z.object({ @@ -5027,8 +5315,8 @@ export const marshalSyncedTable_SyncedTableSpecSchema: z.ZodType = z // eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name. export const marshalSyncedTable_SyncedTableSpec_ExtraColumnSchema: z.ZodType = z .object({ - columnName: z.string().optional(), - columnType: z.string().optional(), + columnName: z.string(), + columnType: z.string(), maintenance: z.string().optional(), compute: z.string().optional(), }) @@ -5043,8 +5331,8 @@ export const marshalSyncedTable_SyncedTableSpec_ExtraColumnSchema: z.ZodType = z export const marshalSyncedTable_SyncedTableSpec_TypeOverrideSchema: z.ZodType = z .object({ - columnName: z.string().optional(), - pgType: z.string().optional(), + columnName: z.string(), + pgType: z.string(), size: z.number().optional(), }) .transform(d => ({ @@ -5130,7 +5418,7 @@ export const marshalSyncedTablePositionSchema: z.ZodType = z export const marshalUndeleteBranchRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -5138,12 +5426,22 @@ export const marshalUndeleteBranchRequestSchema: z.ZodType = z export const marshalUndeleteProjectRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, })); +export const marshalWeeklyScheduleSchema: z.ZodType = z + .object({ + dayOfWeek: z.string(), + hour: z.number().optional(), + }) + .transform(d => ({ + day_of_week: d.dayOfWeek, + hour: d.hour, + })); + const branchFieldMaskSchema: FieldMaskSchema = { branchId: {wire: 'branch_id'}, createTime: {wire: 'create_time'}, @@ -5166,6 +5464,7 @@ const branchSpecFieldMaskSchema: FieldMaskSchema = { sourceBranch: {wire: 'source_branch'}, sourceBranchLsn: {wire: 'source_branch_lsn'}, sourceBranchTime: {wire: 'source_branch_time'}, + sourceSnapshot: {wire: 'source_snapshot'}, ttl: {wire: 'ttl'}, }; @@ -5182,6 +5481,7 @@ const branchStatusFieldMaskSchema: FieldMaskSchema = { sourceBranch: {wire: 'source_branch'}, sourceBranchLsn: {wire: 'source_branch_lsn'}, sourceBranchTime: {wire: 'source_branch_time'}, + sourceSnapshot: {wire: 'source_snapshot'}, stateChangeTime: {wire: 'state_change_time'}, }; @@ -5445,3 +5745,17 @@ const role_RoleStatusFieldMaskSchema: FieldMaskSchema = { postgresRole: {wire: 'postgres_role'}, roleId: {wire: 'role_id'}, }; + +const snapshotScheduleFieldMaskSchema: FieldMaskSchema = { + name: {wire: 'name'}, + schedule: {wire: 'schedule'}, +}; + +export function snapshotScheduleFieldMask( + ...paths: string[] +): FieldMask { + return FieldMask.build( + paths, + snapshotScheduleFieldMaskSchema + ); +} diff --git a/packages/queries/src/v1/model.ts b/packages/queries/src/v1/model.ts index 30b575204..2d1291a9b 100644 --- a/packages/queries/src/v1/model.ts +++ b/packages/queries/src/v1/model.ts @@ -111,8 +111,8 @@ export interface CreateQueryRequestQuery { } export interface DateRange { - start?: string | undefined; - end?: string | undefined; + start: string; + end: string; } export interface DateRangeValue { @@ -335,7 +335,7 @@ export interface TrashQueryRequest { export interface UpdateQueryRequest { query?: UpdateQueryRequestQuery | undefined; - updateMask?: FieldMask | undefined; + updateMask: FieldMask; id?: string | undefined; /** If true, automatically resolve alert display name conflicts. Otherwise, fail the request if the alert's display name conflicts with an existing alert's display name. */ autoResolveDisplayName?: boolean | undefined; @@ -398,8 +398,8 @@ export interface Visualization { export const unmarshalDateRangeSchema: z.ZodType = z .object({ - start: z.string().optional(), - end: z.string().optional(), + start: z.string(), + end: z.string(), }) .transform(d => ({ start: d.start, @@ -751,8 +751,8 @@ export const marshalCreateQueryRequestQuerySchema: z.ZodType = z export const marshalDateRangeSchema: z.ZodType = z .object({ - start: z.string().optional(), - end: z.string().optional(), + start: z.string(), + end: z.string(), }) .transform(d => ({ start: d.start, @@ -923,10 +923,7 @@ export const marshalTextValueSchema: z.ZodType = z export const marshalUpdateQueryRequestSchema: z.ZodType = z .object({ query: z.lazy(() => marshalUpdateQueryRequestQuerySchema).optional(), - updateMask: z - .any() - .transform((m: FieldMask) => m.toString()) - .optional(), + updateMask: z.any().transform((m: FieldMask) => m.toString()), id: z.string().optional(), autoResolveDisplayName: z.boolean().optional(), }) diff --git a/packages/queryhistory/src/v1/model.ts b/packages/queryhistory/src/v1/model.ts index 1e180021d..cda01c9bb 100644 --- a/packages/queryhistory/src/v1/model.ts +++ b/packages/queryhistory/src/v1/model.ts @@ -356,7 +356,7 @@ export interface QueryMetrics { * QueryTag is the user-facing representation. */ export interface QueryTag { - key?: string | undefined; + key: string; value?: string | undefined; } @@ -672,7 +672,7 @@ export const unmarshalQueryMetricsSchema: z.ZodType = z export const unmarshalQueryTagSchema: z.ZodType = z .object({ - key: z.string().optional(), + key: z.string(), value: z.string().optional(), }) .transform(d => ({ diff --git a/packages/repos/src/v1/model.ts b/packages/repos/src/v1/model.ts index 5da852201..035188f7d 100644 --- a/packages/repos/src/v1/model.ts +++ b/packages/repos/src/v1/model.ts @@ -4,14 +4,14 @@ import {z} from 'zod'; export interface CreateRepoRequest { /** URL of the Git repository to be linked. */ - url?: string | undefined; + url: string; /** * Git provider. This field is case-insensitive. The available Git providers are `gitHub`, * `bitbucketCloud`, `gitLab`, `azureDevOpsServices` (Azure DevOps Services, including * Microsoft Entra ID authentication), `gitHubEnterprise`, `bitbucketServer` (Bitbucket * Data Center), `gitLabEnterpriseEdition` (GitLab Self-Managed), and `awsCodeCommit`. */ - provider?: string | undefined; + provider: string; /** * Desired path for the repo in the workspace. Almost any path in the workspace can be chosen. * If repo is created in `/Repos`, path must be in the format `/Repos/{folder}/{repo-name}`. @@ -52,7 +52,7 @@ export interface CreateRepoResponse { export interface DeleteRepoRequest { /** The ID for the corresponding repo to delete. */ - id?: bigint | undefined; + id: bigint; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -60,7 +60,7 @@ export interface DeleteRepoResponse {} export interface GetRepoRequest { /** ID of the Git folder (repo) object in the workspace. */ - id?: bigint | undefined; + id: bigint; } export interface GetRepoResponse { @@ -157,7 +157,7 @@ export interface SparseCheckoutUpdate { export interface UpdateRepoRequest { /** ID of the Git folder (repo) object in the workspace. */ - id?: bigint | undefined; + id: bigint; /** Branch that the local version of the repo is checked out to. */ branch?: string | undefined; /** @@ -292,8 +292,8 @@ export const unmarshalUpdateRepoResponseSchema: z.ZodType = export const marshalCreateRepoRequestSchema: z.ZodType = z .object({ - url: z.string().optional(), - provider: z.string().optional(), + url: z.string(), + provider: z.string(), path: z.string().optional(), sparseCheckout: z.lazy(() => marshalSparseCheckoutSchema).optional(), gitCredentialId: z.bigint().optional(), @@ -324,7 +324,7 @@ export const marshalSparseCheckoutUpdateSchema: z.ZodType = z export const marshalUpdateRepoRequestSchema: z.ZodType = z .object({ - id: z.bigint().optional(), + id: z.bigint(), branch: z.string().optional(), tag: z.string().optional(), sparseCheckout: z.lazy(() => marshalSparseCheckoutUpdateSchema).optional(), diff --git a/packages/scim/src/v1/model.ts b/packages/scim/src/v1/model.ts index d80f1067b..d365b982f 100644 --- a/packages/scim/src/v1/model.ts +++ b/packages/scim/src/v1/model.ts @@ -373,7 +373,7 @@ export interface CreateUserRequest { /** Delete a group */ export interface DeleteAccountGroupRequest { /** Unique ID for a group in the account. */ - id?: string | undefined; + id: string; /** account ID */ accountId?: string | undefined; } @@ -381,7 +381,7 @@ export interface DeleteAccountGroupRequest { /** Delete a service principal */ export interface DeleteAccountServicePrincipalRequest { /** Unique ID for a service principal in the account. */ - id?: string | undefined; + id: string; /** account ID */ accountId?: string | undefined; } @@ -389,7 +389,7 @@ export interface DeleteAccountServicePrincipalRequest { /** Delete a user */ export interface DeleteAccountUserRequest { /** Unique ID for a user in the account. */ - id?: string | undefined; + id: string; /** account ID */ accountId?: string | undefined; } @@ -397,25 +397,25 @@ export interface DeleteAccountUserRequest { /** Delete a group */ export interface DeleteGroupRequest { /** Unique ID for a group in the workspace. */ - id?: string | undefined; + id: string; } /** Delete a service principal */ export interface DeleteServicePrincipalRequest { /** Unique ID for a service principal in the workspace. */ - id?: string | undefined; + id: string; } /** Delete a user */ export interface DeleteUserRequest { /** Unique ID for a user in the workspace. */ - id?: string | undefined; + id: string; } /** Get group details */ export interface GetAccountGroupRequest { /** Unique ID for a group in the account. */ - id?: string | undefined; + id: string; /** account ID */ accountId?: string | undefined; } @@ -423,7 +423,7 @@ export interface GetAccountGroupRequest { /** Get service principal details */ export interface GetAccountServicePrincipalRequest { /** Unique ID for a service principal in the account. */ - id?: string | undefined; + id: string; /** account ID */ accountId?: string | undefined; } @@ -439,7 +439,7 @@ export interface GetAccountUserRequest { /** Query by which the results have to be filtered. Supported operators are equals(`eq`), contains(`co`), starts with(`sw`) and not equals(`ne`). Additionally, simple expressions can be formed using logical operators - `and` and `or`. The [SCIM RFC](https://tools.ietf.org/html/rfc7644#section-3.4.2.2) has more details but we currently only support simple expressions. */ filter?: string | undefined; /** Unique ID for a user in the account. */ - id?: string | undefined; + id: string; /** Attribute to sort the results. Multi-part paths are supported. For example, `userName`, `name.givenName`, and `emails`. */ sortBy?: string | undefined; /** The order to sort the results. */ @@ -453,7 +453,7 @@ export interface GetAccountUserRequest { /** Get group details */ export interface GetGroupRequest { /** Unique ID for a group in the workspace. */ - id?: string | undefined; + id: string; } /** Get object permission levels */ @@ -471,7 +471,7 @@ export interface GetPasswordPermissionsRequest {} /** Get service principal details */ export interface GetServicePrincipalRequest { /** Unique ID for a service principal in the workspace. */ - id?: string | undefined; + id: string; } /** Get user details */ @@ -485,7 +485,7 @@ export interface GetUserRequest { /** Query by which the results have to be filtered. Supported operators are equals(`eq`), contains(`co`), starts with(`sw`) and not equals(`ne`). Additionally, simple expressions can be formed using logical operators - `and` and `or`. The [SCIM RFC](https://tools.ietf.org/html/rfc7644#section-3.4.2.2) has more details but we currently only support simple expressions. */ filter?: string | undefined; /** Unique ID for a user in the workspace. */ - id?: string | undefined; + id: string; /** Attribute to sort the results. Multi-part paths are supported. For example, `userName`, `name.givenName`, and `emails`. */ sortBy?: string | undefined; /** The order to sort the results. */ @@ -778,7 +778,7 @@ export interface Patch { export interface PatchAccountGroupRequest { /** Unique ID in the workspace. */ - id?: string | undefined; + id: string; operations?: AccountPatch[] | undefined; /** The schema of the patch request. Must be ["urn:ietf:params:scim:api:messages:2.0:PatchOp"]. */ schemas?: AccountPatchSchema_PatchSchema[] | undefined; @@ -788,7 +788,7 @@ export interface PatchAccountGroupRequest { export interface PatchAccountServicePrincipalRequest { /** Unique ID in the workspace. */ - id?: string | undefined; + id: string; operations?: AccountPatch[] | undefined; /** The schema of the patch request. Must be ["urn:ietf:params:scim:api:messages:2.0:PatchOp"]. */ schemas?: AccountPatchSchema_PatchSchema[] | undefined; @@ -798,7 +798,7 @@ export interface PatchAccountServicePrincipalRequest { export interface PatchAccountUserRequest { /** Unique ID in the workspace. */ - id?: string | undefined; + id: string; operations?: AccountPatch[] | undefined; /** The schema of the patch request. Must be ["urn:ietf:params:scim:api:messages:2.0:PatchOp"]. */ schemas?: AccountPatchSchema_PatchSchema[] | undefined; @@ -808,7 +808,7 @@ export interface PatchAccountUserRequest { export interface PatchGroupRequest { /** Unique ID in the workspace. */ - id?: string | undefined; + id: string; operations?: Patch[] | undefined; /** The schema of the patch request. Must be ["urn:ietf:params:scim:api:messages:2.0:PatchOp"]. */ schemas?: PatchSchema[] | undefined; @@ -816,7 +816,7 @@ export interface PatchGroupRequest { export interface PatchServicePrincipalRequest { /** Unique ID in the workspace. */ - id?: string | undefined; + id: string; operations?: Patch[] | undefined; /** The schema of the patch request. Must be ["urn:ietf:params:scim:api:messages:2.0:PatchOp"]. */ schemas?: PatchSchema[] | undefined; @@ -824,7 +824,7 @@ export interface PatchServicePrincipalRequest { export interface PatchUserRequest { /** Unique ID in the workspace. */ - id?: string | undefined; + id: string; operations?: Patch[] | undefined; /** The schema of the patch request. Must be ["urn:ietf:params:scim:api:messages:2.0:PatchOp"]. */ schemas?: PatchSchema[] | undefined; @@ -1641,7 +1641,7 @@ export const marshalPatchSchema: z.ZodType = z export const marshalPatchAccountGroupRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), operations: z.array(z.lazy(() => marshalAccountPatchSchema)).optional(), schemas: z.array(z.string()).optional(), accountId: z.string().optional(), @@ -1655,7 +1655,7 @@ export const marshalPatchAccountGroupRequestSchema: z.ZodType = z export const marshalPatchAccountServicePrincipalRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), operations: z.array(z.lazy(() => marshalAccountPatchSchema)).optional(), schemas: z.array(z.string()).optional(), accountId: z.string().optional(), @@ -1669,7 +1669,7 @@ export const marshalPatchAccountServicePrincipalRequestSchema: z.ZodType = z export const marshalPatchAccountUserRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), operations: z.array(z.lazy(() => marshalAccountPatchSchema)).optional(), schemas: z.array(z.string()).optional(), accountId: z.string().optional(), @@ -1683,7 +1683,7 @@ export const marshalPatchAccountUserRequestSchema: z.ZodType = z export const marshalPatchGroupRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), operations: z.array(z.lazy(() => marshalPatchSchema)).optional(), schemas: z.array(z.string()).optional(), }) @@ -1695,7 +1695,7 @@ export const marshalPatchGroupRequestSchema: z.ZodType = z export const marshalPatchServicePrincipalRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), operations: z.array(z.lazy(() => marshalPatchSchema)).optional(), schemas: z.array(z.string()).optional(), }) @@ -1707,7 +1707,7 @@ export const marshalPatchServicePrincipalRequestSchema: z.ZodType = z export const marshalPatchUserRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), operations: z.array(z.lazy(() => marshalPatchSchema)).optional(), schemas: z.array(z.string()).optional(), }) diff --git a/packages/secrets/src/v1/model.ts b/packages/secrets/src/v1/model.ts index 337a38b52..fa52ee31b 100644 --- a/packages/secrets/src/v1/model.ts +++ b/packages/secrets/src/v1/model.ts @@ -43,22 +43,22 @@ export type ScopeBackendType = */ export interface AclItem { /** The principal in which the permission is applied. */ - principal?: string | undefined; + principal: string; /** The permission level applied to the principal. */ - permission?: AclPermission | undefined; + permission: AclPermission; } /** The metadata of the Azure KeyVault for a secret scope of type `AZURE_KEYVAULT` */ export interface AzureKeyVaultSecretScopeMetadata { /** The resource id of the azure KeyVault that user wants to associate the scope with. */ - resourceId?: string | undefined; + resourceId: string; /** The DNS of the KeyVault */ - dnsName?: string | undefined; + dnsName: string; } export interface CreateScopeRequest { /** Scope name requested by the user. Scope names are unique. */ - scope?: string | undefined; + scope: string; /** The principal that is initially granted ``MANAGE`` permission to the created scope. */ initialManagePrincipal?: string | undefined; /** The backend type the scope will be created with. If not specified, will default to ``DATABRICKS`` */ @@ -72,9 +72,9 @@ export interface CreateScopeResponse {} export interface DeleteAclRequest { /** The name of the scope to remove permissions from. */ - scope?: string | undefined; + scope: string; /** The principal to remove an existing ACL from. */ - principal?: string | undefined; + principal: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -82,7 +82,7 @@ export interface DeleteAclResponse {} export interface DeleteScopeRequest { /** Name of the scope to delete. */ - scope?: string | undefined; + scope: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -90,9 +90,9 @@ export interface DeleteScopeResponse {} export interface DeleteSecretRequest { /** The name of the scope that contains the secret to delete. */ - scope?: string | undefined; + scope: string; /** Name of the secret to delete. */ - key?: string | undefined; + key: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -100,16 +100,16 @@ export interface DeleteSecretResponse {} export interface GetAclRequest { /** The name of the scope to fetch ACL information from. */ - scope?: string | undefined; + scope: string; /** The principal to fetch ACL information for. */ - principal?: string | undefined; + principal: string; } export interface GetSecretRequest { /** The name of the scope that contains the secret. */ - scope?: string | undefined; + scope: string; /** Name of the secret to fetch value information. */ - key?: string | undefined; + key: string; } export interface GetSecretResponse { @@ -121,7 +121,7 @@ export interface GetSecretResponse { export interface ListAclsRequest { /** The name of the scope to fetch ACL information from. */ - scope?: string | undefined; + scope: string; } export interface ListAclsResponse { @@ -139,7 +139,7 @@ export interface ListScopesResponse { export interface ListSecretsRequest { /** The name of the scope to list secrets within. */ - scope?: string | undefined; + scope: string; } export interface ListSecretsResponse { @@ -149,11 +149,11 @@ export interface ListSecretsResponse { export interface PutAclRequest { /** The name of the scope to apply permissions to. */ - scope?: string | undefined; + scope: string; /** The principal in which the permission is applied. */ - principal?: string | undefined; + principal: string; /** The permission level applied to the principal. */ - permission?: AclPermission | undefined; + permission: AclPermission; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -161,9 +161,9 @@ export interface PutAclResponse {} export interface PutSecretRequest { /** The name of the scope to which the secret will be associated with. */ - scope?: string | undefined; + scope: string; /** A unique name to identify the secret. */ - key?: string | undefined; + key: string; value?: | { $case: 'stringValue'; @@ -208,8 +208,8 @@ export interface SecretScope { export const unmarshalAclItemSchema: z.ZodType = z .object({ - principal: z.string().optional(), - permission: z.string().optional(), + principal: z.string(), + permission: z.string(), }) .transform(d => ({ principal: d.principal, @@ -219,8 +219,8 @@ export const unmarshalAclItemSchema: z.ZodType = z export const unmarshalAzureKeyVaultSecretScopeMetadataSchema: z.ZodType = z .object({ - resource_id: z.string().optional(), - dns_name: z.string().optional(), + resource_id: z.string(), + dns_name: z.string(), }) .transform(d => ({ resourceId: d.resource_id, @@ -313,8 +313,8 @@ export const unmarshalSecretScopeSchema: z.ZodType = z export const marshalAzureKeyVaultSecretScopeMetadataSchema: z.ZodType = z .object({ - resourceId: z.string().optional(), - dnsName: z.string().optional(), + resourceId: z.string(), + dnsName: z.string(), }) .transform(d => ({ resource_id: d.resourceId, @@ -323,7 +323,7 @@ export const marshalAzureKeyVaultSecretScopeMetadataSchema: z.ZodType = z export const marshalCreateScopeRequestSchema: z.ZodType = z .object({ - scope: z.string().optional(), + scope: z.string(), initialManagePrincipal: z.string().optional(), scopeBackendType: z.string().optional(), backendAzureKeyvault: z @@ -339,8 +339,8 @@ export const marshalCreateScopeRequestSchema: z.ZodType = z export const marshalDeleteAclRequestSchema: z.ZodType = z .object({ - scope: z.string().optional(), - principal: z.string().optional(), + scope: z.string(), + principal: z.string(), }) .transform(d => ({ scope: d.scope, @@ -349,7 +349,7 @@ export const marshalDeleteAclRequestSchema: z.ZodType = z export const marshalDeleteScopeRequestSchema: z.ZodType = z .object({ - scope: z.string().optional(), + scope: z.string(), }) .transform(d => ({ scope: d.scope, @@ -357,8 +357,8 @@ export const marshalDeleteScopeRequestSchema: z.ZodType = z export const marshalDeleteSecretRequestSchema: z.ZodType = z .object({ - scope: z.string().optional(), - key: z.string().optional(), + scope: z.string(), + key: z.string(), }) .transform(d => ({ scope: d.scope, @@ -367,9 +367,9 @@ export const marshalDeleteSecretRequestSchema: z.ZodType = z export const marshalPutAclRequestSchema: z.ZodType = z .object({ - scope: z.string().optional(), - principal: z.string().optional(), - permission: z.string().optional(), + scope: z.string(), + principal: z.string(), + permission: z.string(), }) .transform(d => ({ scope: d.scope, @@ -379,8 +379,8 @@ export const marshalPutAclRequestSchema: z.ZodType = z export const marshalPutSecretRequestSchema: z.ZodType = z .object({ - scope: z.string().optional(), - key: z.string().optional(), + scope: z.string(), + key: z.string(), value: z .discriminatedUnion('$case', [ z.object({$case: z.literal('stringValue'), stringValue: z.string()}), diff --git a/packages/settings/src/v2/model.ts b/packages/settings/src/v2/model.ts index 26ca8b2e9..d3ee38b8c 100644 --- a/packages/settings/src/v2/model.ts +++ b/packages/settings/src/v2/model.ts @@ -124,9 +124,7 @@ export type RestrictWorkspaceAdminsMessage_Status = | (string & {}); export interface AibiDashboardEmbeddingAccessPolicy { - accessPolicyType?: - | AibiDashboardEmbeddingAccessPolicy_AccessPolicyType - | undefined; + accessPolicyType: AibiDashboardEmbeddingAccessPolicy_AccessPolicyType; } export interface AibiDashboardEmbeddingApprovedDomains { @@ -196,28 +194,26 @@ export interface ClusterAutoRestartMessage_MaintenanceWindow_WindowStartTime { * to a workspace. Defaults to ALLOW_ALL. */ export interface CollaborationPlatformConnectivityMessage { - connectivity?: - | CollaborationPlatformConnectivityMessage_Connectivity - | undefined; + connectivity: CollaborationPlatformConnectivityMessage_Connectivity; } export interface GetPublicAccountSettingRequest { - accountId?: string | undefined; - name?: string | undefined; + accountId: string; + name: string; } export interface GetPublicAccountUserPreferenceRequest { /** account ID of the account being managed. */ - accountId?: string | undefined; + accountId: string; /** User ID of the user whose setting is being retrieved. */ - userId?: string | undefined; + userId: string; /** User Setting name. */ - name?: string | undefined; + name: string; } export interface GetPublicWorkspaceSettingRequest { /** Name of the setting */ - name?: string | undefined; + name: string; } export interface IntegerMessage { @@ -226,7 +222,7 @@ export interface IntegerMessage { export interface ListAccountSettingsMetadataRequest { /** account ID of the account being managed. */ - accountId?: string | undefined; + accountId: string; /** * The maximum number of settings to return. The service may return fewer than this value. * If unspecified, at most 200 settings will be returned. @@ -255,9 +251,9 @@ export interface ListAccountSettingsMetadataResponse { export interface ListAccountUserPreferencesMetadataRequest { /** account ID of the account being managed. */ - accountId?: string | undefined; + accountId: string; /** User ID of the user whose settings metadata is being retrieved. */ - userId?: string | undefined; + userId: string; /** * The maximum number of settings to return. The service may return fewer than this value. * If unspecified, at most 200 settings will be returned. @@ -317,24 +313,24 @@ export interface OperationalEmailCustomRecipientMessage { export interface PatchPublicAccountSettingRequest { /** account ID of the account being managed. */ - accountId?: string | undefined; - name?: string | undefined; - setting?: Setting | undefined; + accountId: string; + name: string; + setting: Setting; } export interface PatchPublicAccountUserPreferenceRequest { /** account ID of the account being managed. */ - accountId?: string | undefined; + accountId: string; /** User ID of the user whose setting is being updated. */ - userId?: string | undefined; - name?: string | undefined; - setting?: UserPreference | undefined; + userId: string; + name: string; + setting: UserPreference; } export interface PatchPublicWorkspaceSettingRequest { /** Name of the setting */ - name?: string | undefined; - setting?: Setting | undefined; + name: string; + setting: Setting; } export interface PersonalComputeMessage { @@ -342,7 +338,7 @@ export interface PersonalComputeMessage { } export interface RestrictWorkspaceAdminsMessage { - status?: RestrictWorkspaceAdminsMessage_Status | undefined; + status: RestrictWorkspaceAdminsMessage_Status; /** * When true, workspace admins cannot create governance tags. * ALLOW_ALL status does not override this; they are independent. @@ -535,7 +531,7 @@ export interface UserPreference { export const unmarshalAibiDashboardEmbeddingAccessPolicySchema: z.ZodType = z .object({ - access_policy_type: z.string().optional(), + access_policy_type: z.string(), }) .transform(d => ({ accessPolicyType: d.access_policy_type, @@ -651,7 +647,7 @@ export const unmarshalClusterAutoRestartMessage_MaintenanceWindow_WindowStartTim export const unmarshalCollaborationPlatformConnectivityMessageSchema: z.ZodType = z .object({ - connectivity: z.string().optional(), + connectivity: z.string(), }) .transform(d => ({ connectivity: d.connectivity, @@ -725,7 +721,7 @@ export const unmarshalPersonalComputeMessageSchema: z.ZodType = z .object({ - status: z.string().optional(), + status: z.string(), disable_gov_tag_creation: z.boolean().optional(), }) .transform(d => ({ @@ -989,7 +985,7 @@ export const unmarshalUserPreferenceSchema: z.ZodType = z export const marshalAibiDashboardEmbeddingAccessPolicySchema: z.ZodType = z .object({ - accessPolicyType: z.string().optional(), + accessPolicyType: z.string(), }) .transform(d => ({ access_policy_type: d.accessPolicyType, @@ -1102,7 +1098,7 @@ export const marshalClusterAutoRestartMessage_MaintenanceWindow_WindowStartTimeS export const marshalCollaborationPlatformConnectivityMessageSchema: z.ZodType = z .object({ - connectivity: z.string().optional(), + connectivity: z.string(), }) .transform(d => ({ connectivity: d.connectivity, @@ -1134,7 +1130,7 @@ export const marshalPersonalComputeMessageSchema: z.ZodType = z export const marshalRestrictWorkspaceAdminsMessageSchema: z.ZodType = z .object({ - status: z.string().optional(), + status: z.string(), disableGovTagCreation: z.boolean().optional(), }) .transform(d => ({ diff --git a/packages/sharing/src/v1/model.ts b/packages/sharing/src/v1/model.ts index ea171b20d..54857a021 100644 --- a/packages/sharing/src/v1/model.ts +++ b/packages/sharing/src/v1/model.ts @@ -257,14 +257,14 @@ export interface CreateShareRequest { export interface DeleteFederationPolicyRequest { /** Name of the recipient. This is the name of the recipient for which the policy is being deleted. */ - recipientName?: string | undefined; + recipientName: string; /** Name of the policy. This is the name of the policy to be deleted. */ - name?: string | undefined; + name: string; } export interface DeleteProviderRequest { /** Name of the provider. */ - nameArg?: string | undefined; + nameArg: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -272,7 +272,7 @@ export interface DeleteProviderResponse {} export interface DeleteRecipientRequest { /** Name of the recipient. */ - name?: string | undefined; + name: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -280,7 +280,7 @@ export interface DeleteRecipientResponse {} export interface DeleteShareRequest { /** The name of the share. */ - name?: string | undefined; + name: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -399,7 +399,7 @@ export interface FunctionParameterInfos { export interface GetActivationUrlInfoRequest { /** The one time activation url. It also accepts activation token. */ - activationUrl?: string | undefined; + activationUrl: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -407,19 +407,19 @@ export interface GetActivationUrlInfoResponse {} export interface GetFederationPolicyRequest { /** Name of the recipient. This is the name of the recipient for which the policy is being retrieved. */ - recipientName?: string | undefined; + recipientName: string; /** Name of the policy. This is the name of the policy to be retrieved. */ - name?: string | undefined; + name: string; } export interface GetProviderRequest { /** Name of the provider. */ - nameArg?: string | undefined; + nameArg: string; } export interface GetRecipientRequest { /** Name of the recipient. */ - name?: string | undefined; + name: string; } export interface GetRecipientSharePermissionsResponse { @@ -444,7 +444,7 @@ export interface GetSharePermissionsResponse { export interface GetShareRequest { /** The name of the share. */ - name?: string | undefined; + name: string; /** Query for data to include in the share. */ includeSharedData?: boolean | undefined; } @@ -456,7 +456,7 @@ export interface IpAccessList { export interface ListFederationPoliciesRequest { /** Name of the recipient. This is the name of the recipient for which the policies are being listed. */ - recipientName?: string | undefined; + recipientName: string; maxResults?: number | undefined; pageToken?: string | undefined; } @@ -469,9 +469,9 @@ export interface ListFederationPoliciesResponse { /** Request to fetch the list of assets of a share that is shared with the recipient. */ export interface ListProviderShareAssetsRequest { /** The name of the provider who owns the share. */ - providerNameArg?: string | undefined; + providerNameArg: string; /** The name of the share. */ - shareNameArg?: string | undefined; + shareNameArg: string; /** Maximum number of tables to return. */ tableMaxResults?: number | undefined; /** Maximum number of functions to return. */ @@ -498,7 +498,7 @@ export interface ListProviderShareAssetsResponse { export interface ListProviderSharesRequest { /** Name of the provider in which to list shares. */ - providerNameArg?: string | undefined; + providerNameArg: string; /** * Maximum number of shares to return. * - when set to 0, the page length is set to a server configured value (recommended); @@ -555,7 +555,7 @@ export interface ListProvidersResponse { export interface ListRecipientSharePermissionsRequest { /** The name of the Recipient. */ - name?: string | undefined; + name: string; /** * Maximum number of permissions to return. * - when set to 0, the page length is set to a server configured value (recommended); @@ -602,7 +602,7 @@ export interface ListRecipientsResponse { export interface ListSharePermissionsRequest { /** The name of the share. */ - name?: string | undefined; + name: string; /** * Maximum number of permissions to return. * - when set to 0, the page length is set to a server configured value (recommended); @@ -663,7 +663,7 @@ export interface NotebookFile { */ export interface OidcFederationPolicy { /** The required token issuer, as specified in the 'iss' claim of federated tokens. */ - issuer?: string | undefined; + issuer: string; /** * The claim that contains the subject of the token. * Depending on the identity provider and the use case (U2M or M2M), this can vary: @@ -679,7 +679,7 @@ export interface OidcFederationPolicy { * - `groups`: Object ID of the group. * - `sub`: Subject identifier for other use cases. */ - subjectClaim?: string | undefined; + subjectClaim: string; /** * The required token subject, as specified in the subject claim of federated tokens. * The subject claim identifies the identity of the user or machine accessing the resource. @@ -688,7 +688,7 @@ export interface OidcFederationPolicy { * - U2M flow (user access): If the subject claim is `oid`, this must be the Object ID of the user in Entra ID. * - M2M flow (OAuth App access): If the subject claim is `azp`, this must be the client ID of the OAuth app registered in Entra ID. */ - subject?: string | undefined; + subject: string; /** * The allowed token audiences, as specified in the 'aud' claim of federated tokens. * The audience identifier is intended to represent the recipient of the token. @@ -758,7 +758,7 @@ export interface PrivilegeAssignment { /** An object with __properties__ containing map of key-value properties attached to the securable. */ export interface PropertiesKvPairs { /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; } export interface ProviderInfo { @@ -893,7 +893,7 @@ export interface RegisteredModelAlias { export interface RetrieveTokenRequest { /** The one time activation url. It also accepts activation token. */ - activationUrl?: string | undefined; + activationUrl: string; } export interface RetrieveTokenResponse { @@ -909,13 +909,13 @@ export interface RetrieveTokenResponse { export interface RotateRecipientTokenRequest { /** The name of the Recipient. */ - name?: string | undefined; + name: string; /** * The expiration time of the bearer token in ISO 8601 format. This will set the expiration_time * of existing token only to a smaller timestamp, it cannot extend the expiration_time. Use 0 to * expire the existing token immediately, negative number will return an error. */ - existingTokenExpireInSeconds?: bigint | undefined; + existingTokenExpireInSeconds: bigint; } export interface Share { @@ -958,7 +958,7 @@ export interface SharedDataObject { * A fully qualified name that uniquely identifies a data object. * For example, a table's fully qualified name is in the format of `..
    `, */ - name?: string | undefined; + name: string; /** The type of the data object. */ dataObjectType?: string | undefined; /** The time when this data object is added to the share, in epoch milliseconds. */ @@ -1090,7 +1090,7 @@ export interface TagKeyValue { export interface UpdateProviderRequest { /** Name of the provider. */ - nameArg?: string | undefined; + nameArg: string; /** New name for the provider. */ newName?: string | undefined; /** The name of the Provider. */ @@ -1124,7 +1124,7 @@ export interface UpdateProviderRequest { export interface UpdateRecipientRequest { /** Name of the recipient. */ - nameArg?: string | undefined; + nameArg: string; /** * New name for the recipient. * . @@ -1193,7 +1193,7 @@ export interface UpdateRecipientRequest { export interface UpdateSharePermissionsRequest { /** The name of the share. */ - name?: string | undefined; + name: string; /** Optional. Whether to return the latest permissions list of the share in the response. */ omitPermissionsList?: boolean | undefined; /** Array of permissions change objects. */ @@ -1207,7 +1207,7 @@ export interface UpdateSharePermissionsResponse { export interface UpdateShareRequest { /** The name of the share. */ - nameArg?: string | undefined; + nameArg: string; /** New name for the share. */ newName?: string | undefined; /** Array of shared data object updates. */ @@ -1550,9 +1550,9 @@ export const unmarshalNotebookFileSchema: z.ZodType = z export const unmarshalOidcFederationPolicySchema: z.ZodType = z .object({ - issuer: z.string().optional(), - subject_claim: z.string().optional(), - subject: z.string().optional(), + issuer: z.string(), + subject_claim: z.string(), + subject: z.string(), audiences: z.array(z.string()).optional(), }) .transform(d => ({ @@ -1607,7 +1607,7 @@ export const unmarshalPrivilegeAssignmentSchema: z.ZodType export const unmarshalPropertiesKvPairsSchema: z.ZodType = z .object({ - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), }) .transform(d => ({ properties: d.properties, @@ -1846,7 +1846,7 @@ export const unmarshalShareToPrivilegeAssignmentSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), data_object_type: z.string().optional(), added_at: z .union([z.number(), z.bigint(), z.string()]) @@ -2106,9 +2106,9 @@ export const marshalIpAccessListSchema: z.ZodType = z export const marshalOidcFederationPolicySchema: z.ZodType = z .object({ - issuer: z.string().optional(), - subjectClaim: z.string().optional(), - subject: z.string().optional(), + issuer: z.string(), + subjectClaim: z.string(), + subject: z.string(), audiences: z.array(z.string()).optional(), }) .transform(d => ({ @@ -2163,7 +2163,7 @@ export const marshalPermissionsChangeSchema: z.ZodType = z export const marshalPropertiesKvPairsSchema: z.ZodType = z .object({ - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), }) .transform(d => ({ properties: d.properties, @@ -2203,8 +2203,8 @@ export const marshalRecipientTokenInfoSchema: z.ZodType = z export const marshalRotateRecipientTokenRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - existingTokenExpireInSeconds: z.bigint().optional(), + name: z.string(), + existingTokenExpireInSeconds: z.bigint(), }) .transform(d => ({ name: d.name, @@ -2213,7 +2213,7 @@ export const marshalRotateRecipientTokenRequestSchema: z.ZodType = z export const marshalSharedDataObjectSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), dataObjectType: z.string().optional(), addedAt: z.bigint().optional(), addedBy: z.string().optional(), @@ -2247,7 +2247,7 @@ export const marshalSharedDataObjectSchema: z.ZodType = z export const marshalUpdateProviderRequestSchema: z.ZodType = z .object({ - nameArg: z.string().optional(), + nameArg: z.string(), newName: z.string().optional(), name: z.string().optional(), authenticationType: z.string().optional(), @@ -2285,7 +2285,7 @@ export const marshalUpdateProviderRequestSchema: z.ZodType = z export const marshalUpdateRecipientRequestSchema: z.ZodType = z .object({ - nameArg: z.string().optional(), + nameArg: z.string(), newName: z.string().optional(), name: z.string().optional(), authenticationType: z.string().optional(), @@ -2335,7 +2335,7 @@ export const marshalUpdateRecipientRequestSchema: z.ZodType = z export const marshalUpdateSharePermissionsRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), omitPermissionsList: z.boolean().optional(), changes: z.array(z.lazy(() => marshalPermissionsChangeSchema)).optional(), }) @@ -2347,7 +2347,7 @@ export const marshalUpdateSharePermissionsRequestSchema: z.ZodType = z export const marshalUpdateShareRequestSchema: z.ZodType = z .object({ - nameArg: z.string().optional(), + nameArg: z.string(), newName: z.string().optional(), updates: z .array( diff --git a/packages/statementexecution/src/v1/model.ts b/packages/statementexecution/src/v1/model.ts index 149404c9a..3ddcc273a 100644 --- a/packages/statementexecution/src/v1/model.ts +++ b/packages/statementexecution/src/v1/model.ts @@ -118,7 +118,7 @@ export interface CancelStatementRequest { * The statement ID is returned upon successfully submitting a SQL statement, and is a required * reference for all subsequent calls. */ - statementId?: string | undefined; + statementId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -172,12 +172,12 @@ export interface ExecuteStatementRequest { * The SQL statement to execute. The statement can optionally be parameterized, see `parameters`. * The maximum query text size is 16 MiB. */ - statement?: string | undefined; + statement: string; /** * Warehouse upon which to execute a statement. See also * [What are SQL warehouses?](https://docs.databricks.com/sql/admin/warehouse-type.html) */ - warehouseId?: string | undefined; + warehouseId: string; /** * Sets default catalog for statement execution, similar to * [`USE CATALOG`](https://docs.databricks.com/sql/language-manual/sql-ref-syntax-ddl-use-catalog.html) @@ -399,8 +399,8 @@ export interface GetResultDataRequest { * The statement ID is returned upon successfully submitting a SQL statement, and is a required * reference for all subsequent calls. */ - statementId?: string | undefined; - chunkIndex?: number | undefined; + statementId: string; + chunkIndex: number; } export interface GetStatementResultRequest { @@ -408,7 +408,7 @@ export interface GetStatementResultRequest { * The statement ID is returned upon successfully submitting a SQL statement, and is a required * reference for all subsequent calls. */ - statementId?: string | undefined; + statementId: string; } /** @@ -417,7 +417,7 @@ export interface GetStatementResultRequest { * QueryTag is the user-facing representation. */ export interface QueryTag { - key?: string | undefined; + key: string; value?: string | undefined; } @@ -494,7 +494,7 @@ export interface ServiceError { export interface StatementParameter { /** The name of a parameter marker to be substituted in the statement. */ - name?: string | undefined; + name: string; /** The value to substitute, represented as a string. If omitted, the value is interpreted as NULL. */ value?: string | undefined; /** @@ -728,7 +728,7 @@ export const unmarshalStatementStatusSchema: z.ZodType = z export const marshalCancelStatementRequestSchema: z.ZodType = z .object({ - statementId: z.string().optional(), + statementId: z.string(), }) .transform(d => ({ statement_id: d.statementId, @@ -736,8 +736,8 @@ export const marshalCancelStatementRequestSchema: z.ZodType = z export const marshalExecuteStatementRequestSchema: z.ZodType = z .object({ - statement: z.string().optional(), - warehouseId: z.string().optional(), + statement: z.string(), + warehouseId: z.string(), catalog: z.string().optional(), schema: z.string().optional(), rowLimit: z.bigint().optional(), @@ -768,7 +768,7 @@ export const marshalExecuteStatementRequestSchema: z.ZodType = z export const marshalQueryTagSchema: z.ZodType = z .object({ - key: z.string().optional(), + key: z.string(), value: z.string().optional(), }) .transform(d => ({ @@ -778,7 +778,7 @@ export const marshalQueryTagSchema: z.ZodType = z export const marshalStatementParameterSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), value: z.string().optional(), type: z.string().optional(), }) diff --git a/packages/storageconfigurations/src/v1/model.ts b/packages/storageconfigurations/src/v1/model.ts index 2b836f5a0..977095e64 100644 --- a/packages/storageconfigurations/src/v1/model.ts +++ b/packages/storageconfigurations/src/v1/model.ts @@ -3,11 +3,11 @@ import {z} from 'zod'; export interface CreateStorageConfigurationRequest { - accountId?: string | undefined; + accountId: string; /** The human-readable name of the storage configuration. */ - storageConfigurationName?: string | undefined; + storageConfigurationName: string; /** Root S3 bucket information. */ - rootBucketInfo?: RootBucketInfo | undefined; + rootBucketInfo: RootBucketInfo; /** * Optional IAM role that is used to access the workspace catalog which is created during workspace creation * for UC by Default. If a storage configuration with this field populated is used to create a workspace, @@ -18,17 +18,17 @@ export interface CreateStorageConfigurationRequest { } export interface DeleteStorageConfigurationRequest { - storageConfigurationId?: string | undefined; - accountId?: string | undefined; + storageConfigurationId: string; + accountId: string; } export interface GetStorageConfigurationRequest { - storageConfigurationId?: string | undefined; - accountId?: string | undefined; + storageConfigurationId: string; + accountId: string; } export interface ListStorageConfigurationRequest { - accountId?: string | undefined; + accountId: string; } export interface ListStorageConfigurationResponse { @@ -92,9 +92,9 @@ export const unmarshalStorageConfigurationSchema: z.ZodType marshalRootBucketInfoSchema).optional(), + accountId: z.string(), + storageConfigurationName: z.string(), + rootBucketInfo: z.lazy(() => marshalRootBucketInfoSchema), roleArn: z.string().optional(), }) .transform(d => ({ diff --git a/packages/supervisoragents/src/v1/model.ts b/packages/supervisoragents/src/v1/model.ts index bf95fffe5..ff21cb35f 100644 --- a/packages/supervisoragents/src/v1/model.ts +++ b/packages/supervisoragents/src/v1/model.ts @@ -8,7 +8,7 @@ import {z} from 'zod'; /** app. Supported app: custom mcp, custom agent. */ export interface App { /** App name */ - name?: string | undefined; + name: string; } /** Create an example. */ @@ -17,14 +17,14 @@ export interface CreateExampleRequest { * Parent resource where this example will be created. * Format: supervisor-agents/{supervisor_agent_id} */ - parent?: string | undefined; + parent: string; /** The example to create under the parent Supervisor Agent. */ - example?: Example | undefined; + example: Example; } export interface CreateSupervisorAgentRequest { /** The Supervisor Agent to create. */ - supervisorAgent?: SupervisorAgent | undefined; + supervisorAgent: SupervisorAgent; } export interface CreateToolRequest { @@ -32,13 +32,13 @@ export interface CreateToolRequest { * Parent resource where this tool will be created. * Format: supervisor-agents/{supervisor_agent_id} */ - parent?: string | undefined; - tool?: Tool | undefined; + parent: string; + tool: Tool; /** * The ID to use for the tool, which will become the final component of * the tool's resource name. */ - toolId?: string | undefined; + toolId: string; } /** Delete an example. */ @@ -47,7 +47,7 @@ export interface DeleteExampleRequest { * The resource name of the example to delete. * Format: supervisor-agents/{supervisor_agent_id}/examples/{example_id} */ - name?: string | undefined; + name: string; } export interface DeleteSupervisorAgentRequest { @@ -55,7 +55,7 @@ export interface DeleteSupervisorAgentRequest { * The resource name of the Supervisor Agent. * Format: supervisor-agents/{supervisor_agent_id} */ - name?: string | undefined; + name: string; } export interface DeleteToolRequest { @@ -63,7 +63,7 @@ export interface DeleteToolRequest { * The resource name of the Tool. * Format: supervisor-agents/{supervisor_agent_id}/tools/{tool_id} */ - name?: string | undefined; + name: string; } /** @@ -77,9 +77,9 @@ export interface Example { */ name?: string | undefined; /** The example question. */ - question?: string | undefined; + question: string; /** Guidelines for answering the question. */ - guidelines?: string[] | undefined; + guidelines: string[]; /** The universally unique identifier (UUID) of the example. */ exampleId?: string | undefined; } @@ -89,7 +89,7 @@ export interface GenieSpace { * Deprecated: use space_id instead. Still REQUIRED for backward compatibility * until a future API version removes it. */ - id?: string | undefined; + id: string; } /** Get an example. */ @@ -98,7 +98,7 @@ export interface GetExampleRequest { * The resource name of the example. * Format: supervisor-agents/{supervisor_agent_id}/examples/{example_id} */ - name?: string | undefined; + name: string; } export interface GetSupervisorAgentRequest { @@ -106,7 +106,7 @@ export interface GetSupervisorAgentRequest { * The resource name of the Supervisor Agent. * Format: supervisor-agents/{supervisor_agent_id} */ - name?: string | undefined; + name: string; } export interface GetToolRequest { @@ -114,14 +114,14 @@ export interface GetToolRequest { * The resource name of the Tool. * Format: supervisor-agents/{supervisor_agent_id}/tools/{tool_id} */ - name?: string | undefined; + name: string; } export interface KnowledgeAssistant { /** Deprecated: use knowledge_assistant_id instead. */ servingEndpointName?: string | undefined; /** The ID of the knowledge assistant. */ - knowledgeAssistantId?: string | undefined; + knowledgeAssistantId: string; } /** List examples. */ @@ -130,7 +130,7 @@ export interface ListExamplesRequest { * Parent resource to list from. * Format: supervisor-agents/{supervisor_agent_id} */ - parent?: string | undefined; + parent: string; /** * The maximum number of examples to return. * If unspecified, at most 100 examples will be returned. @@ -180,7 +180,7 @@ export interface ListToolsRequest { * Parent resource to list from. * Format: supervisor-agents/{supervisor_agent_id} */ - parent?: string | undefined; + parent: string; pageSize?: number | undefined; pageToken?: string | undefined; } @@ -197,7 +197,7 @@ export interface SupervisorAgent { */ name?: string | undefined; /** The display name of the Supervisor Agent, unique at workspace level. */ - displayName?: string | undefined; + displayName: string; /** Description of what this agent can do (user-facing). */ description?: string | undefined; /** Optional natural-language instructions for the supervisor agent. */ @@ -225,7 +225,7 @@ export interface Tool { /** Deprecated: Use tool_id instead. */ id?: string | undefined; /** Tool type. Must be one of: "genie_space", "knowledge_assistant", "uc_function", "uc_connection", "uc_mcp", "app", "volume", "dashboard", "serving_endpoint", "table", "vector_search_index", "catalog", "schema", "supervisor_agent", "databricks_web_search", "skill". The legacy values "lakeview_dashboard", "uc_table", and "web_search" are also accepted and remain equivalent to "dashboard", "table", and "databricks_web_search" respectively. The "databricks_web_search" tool_type maps to the `web_search` spec field. */ - toolType?: string | undefined; + toolType: string; /** Specification for the tool type. */ spec?: | {$case: 'genieSpace'; genieSpace: GenieSpace} @@ -243,12 +243,12 @@ export interface Tool { /** Databricks UC connection. Supported connection: external mcp server. */ export interface UcConnection { - name?: string | undefined; + name: string; } export interface UcFunction { /** Full uc function name */ - name?: string | undefined; + name: string; } /** Update an example. */ @@ -257,8 +257,8 @@ export interface UpdateExampleRequest { * The resource name of the example to update. * Format: supervisor-agents/{supervisor_agent_id}/examples/{example_id} */ - name?: string | undefined; - example?: Example | undefined; + name: string; + example: Example; /** * Comma-delimited list of fields to update on the example. * Allowed values: `question`, `guidelines`. @@ -266,31 +266,31 @@ export interface UpdateExampleRequest { * - `question` * - `question,guidelines` */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateSupervisorAgentRequest { /** The SupervisorAgent to update. */ - supervisorAgent?: SupervisorAgent | undefined; + supervisorAgent: SupervisorAgent; /** Field mask for fields to be updated. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface UpdateToolRequest { /** The Tool to update. */ - tool?: Tool | undefined; + tool: Tool; /** Field mask for fields to be updated. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export interface Volume { /** Full uc volume name */ - name?: string | undefined; + name: string; } export const unmarshalAppSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -299,8 +299,8 @@ export const unmarshalAppSchema: z.ZodType = z export const unmarshalExampleSchema: z.ZodType = z .object({ name: z.string().optional(), - question: z.string().optional(), - guidelines: z.array(z.string()).optional(), + question: z.string(), + guidelines: z.array(z.string()), example_id: z.string().optional(), }) .transform(d => ({ @@ -312,7 +312,7 @@ export const unmarshalExampleSchema: z.ZodType = z export const unmarshalGenieSpaceSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), }) .transform(d => ({ id: d.id, @@ -322,7 +322,7 @@ export const unmarshalKnowledgeAssistantSchema: z.ZodType = z .object({ serving_endpoint_name: z.string().optional(), - knowledge_assistant_id: z.string().optional(), + knowledge_assistant_id: z.string(), }) .transform(d => ({ servingEndpointName: d.serving_endpoint_name, @@ -366,7 +366,7 @@ export const unmarshalListToolsResponseSchema: z.ZodType = z export const unmarshalSupervisorAgentSchema: z.ZodType = z .object({ name: z.string().optional(), - display_name: z.string().optional(), + display_name: z.string(), description: z.string().optional(), instructions: z.string().optional(), id: z.string().optional(), @@ -396,7 +396,7 @@ export const unmarshalToolSchema: z.ZodType = z .object({ name: z.string().optional(), id: z.string().optional(), - tool_type: z.string().optional(), + tool_type: z.string(), genie_space: z.lazy(() => unmarshalGenieSpaceSchema).optional(), knowledge_assistant: z .lazy(() => unmarshalKnowledgeAssistantSchema) @@ -438,7 +438,7 @@ export const unmarshalToolSchema: z.ZodType = z export const unmarshalUcConnectionSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -446,7 +446,7 @@ export const unmarshalUcConnectionSchema: z.ZodType = z export const unmarshalUcFunctionSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -454,7 +454,7 @@ export const unmarshalUcFunctionSchema: z.ZodType = z export const unmarshalVolumeSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -462,7 +462,7 @@ export const unmarshalVolumeSchema: z.ZodType = z export const marshalAppSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -471,8 +471,8 @@ export const marshalAppSchema: z.ZodType = z export const marshalExampleSchema: z.ZodType = z .object({ name: z.string().optional(), - question: z.string().optional(), - guidelines: z.array(z.string()).optional(), + question: z.string(), + guidelines: z.array(z.string()), exampleId: z.string().optional(), }) .transform(d => ({ @@ -484,7 +484,7 @@ export const marshalExampleSchema: z.ZodType = z export const marshalGenieSpaceSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), }) .transform(d => ({ id: d.id, @@ -493,7 +493,7 @@ export const marshalGenieSpaceSchema: z.ZodType = z export const marshalKnowledgeAssistantSchema: z.ZodType = z .object({ servingEndpointName: z.string().optional(), - knowledgeAssistantId: z.string().optional(), + knowledgeAssistantId: z.string(), }) .transform(d => ({ serving_endpoint_name: d.servingEndpointName, @@ -503,7 +503,7 @@ export const marshalKnowledgeAssistantSchema: z.ZodType = z export const marshalSupervisorAgentSchema: z.ZodType = z .object({ name: z.string().optional(), - displayName: z.string().optional(), + displayName: z.string(), description: z.string().optional(), instructions: z.string().optional(), id: z.string().optional(), @@ -533,7 +533,7 @@ export const marshalToolSchema: z.ZodType = z .object({ name: z.string().optional(), id: z.string().optional(), - toolType: z.string().optional(), + toolType: z.string(), spec: z .discriminatedUnion('$case', [ z.object({ @@ -585,7 +585,7 @@ export const marshalToolSchema: z.ZodType = z export const marshalUcConnectionSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -593,7 +593,7 @@ export const marshalUcConnectionSchema: z.ZodType = z export const marshalUcFunctionSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -601,7 +601,7 @@ export const marshalUcFunctionSchema: z.ZodType = z export const marshalVolumeSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, diff --git a/packages/tagassignments/src/v1/model.ts b/packages/tagassignments/src/v1/model.ts index 52eb60a24..c68a87360 100644 --- a/packages/tagassignments/src/v1/model.ts +++ b/packages/tagassignments/src/v1/model.ts @@ -5,32 +5,32 @@ import type {FieldMaskSchema} from '@databricks/sdk-core/wkt'; import {z} from 'zod'; export interface CreateTagAssignmentRequest { - tagAssignment?: TagAssignment | undefined; + tagAssignment: TagAssignment; } export interface DeleteTagAssignmentRequest { /** The type of entity to which the tag is assigned. Allowed values are apps, dashboards, geniespaces, notebooks */ - entityType?: string | undefined; + entityType: string; /** The identifier of the entity to which the tag is assigned. For apps, the entity_id is the app name */ - entityId?: string | undefined; + entityId: string; /** The key of the tag. The characters , . : / - = and leading/trailing spaces are not allowed */ - tagKey?: string | undefined; + tagKey: string; } export interface GetTagAssignmentRequest { /** The type of entity to which the tag is assigned. Allowed values are apps, dashboards, geniespaces, notebooks */ - entityType?: string | undefined; + entityType: string; /** The identifier of the entity to which the tag is assigned. For apps, the entity_id is the app name */ - entityId?: string | undefined; + entityId: string; /** The key of the tag. The characters , . : / - = and leading/trailing spaces are not allowed */ - tagKey?: string | undefined; + tagKey: string; } export interface ListTagAssignmentsRequest { /** The type of entity to which the tag is assigned. Allowed values are apps, dashboards, geniespaces, notebooks */ - entityType?: string | undefined; + entityType: string; /** The identifier of the entity to which the tag is assigned. For apps, the entity_id is the app name */ - entityId?: string | undefined; + entityId: string; /** Optional. Maximum number of tag assignments to return in a single page */ pageSize?: number | undefined; /** Pagination token to go to the next page of tag assignments. Requests first page if absent. */ @@ -45,18 +45,18 @@ export interface ListTagAssignmentsResponse { export interface TagAssignment { /** The type of entity to which the tag is assigned. Allowed values are apps, dashboards, geniespaces, notebooks */ - entityType?: string | undefined; + entityType: string; /** The identifier of the entity to which the tag is assigned. For apps, the entity_id is the app name */ - entityId?: string | undefined; + entityId: string; /** The key of the tag. The characters , . : / - = and leading/trailing spaces are not allowed */ - tagKey?: string | undefined; + tagKey: string; /** The value of the tag */ tagValue?: string | undefined; } export interface UpdateTagAssignmentRequest { - tagAssignment?: TagAssignment | undefined; - updateMask?: FieldMask | undefined; + tagAssignment: TagAssignment; + updateMask: FieldMask; } export const unmarshalListTagAssignmentsResponseSchema: z.ZodType = @@ -74,9 +74,9 @@ export const unmarshalListTagAssignmentsResponseSchema: z.ZodType = z .object({ - entity_type: z.string().optional(), - entity_id: z.string().optional(), - tag_key: z.string().optional(), + entity_type: z.string(), + entity_id: z.string(), + tag_key: z.string(), tag_value: z.string().optional(), }) .transform(d => ({ @@ -88,9 +88,9 @@ export const unmarshalTagAssignmentSchema: z.ZodType = z export const marshalTagAssignmentSchema: z.ZodType = z .object({ - entityType: z.string().optional(), - entityId: z.string().optional(), - tagKey: z.string().optional(), + entityType: z.string(), + entityId: z.string(), + tagKey: z.string(), tagValue: z.string().optional(), }) .transform(d => ({ diff --git a/packages/tagpolicies/src/v1/model.ts b/packages/tagpolicies/src/v1/model.ts index 89de50eb7..452eee2b6 100644 --- a/packages/tagpolicies/src/v1/model.ts +++ b/packages/tagpolicies/src/v1/model.ts @@ -6,15 +6,15 @@ import type {FieldMaskSchema} from '@databricks/sdk-core/wkt'; import {z} from 'zod'; export interface CreateTagPolicyRequest { - tagPolicy?: TagPolicy | undefined; + tagPolicy: TagPolicy; } export interface DeleteTagPolicyRequest { - tagKey?: string | undefined; + tagKey: string; } export interface GetTagPolicyRequest { - tagKey?: string | undefined; + tagKey: string; } export interface ListTagPoliciesRequest { @@ -34,7 +34,7 @@ export interface ListTagPoliciesResponse { } export interface TagPolicy { - tagKey?: string | undefined; + tagKey: string; id?: string | undefined; description?: string | undefined; values?: Value[] | undefined; @@ -45,12 +45,12 @@ export interface TagPolicy { } export interface UpdateTagPolicyRequest { - tagPolicy?: TagPolicy | undefined; - updateMask?: FieldMask | undefined; + tagPolicy: TagPolicy; + updateMask: FieldMask; } export interface Value { - name?: string | undefined; + name: string; } export const unmarshalListTagPoliciesResponseSchema: z.ZodType = @@ -66,7 +66,7 @@ export const unmarshalListTagPoliciesResponseSchema: z.ZodType = z .object({ - tag_key: z.string().optional(), + tag_key: z.string(), id: z.string().optional(), description: z.string().optional(), values: z.array(z.lazy(() => unmarshalValueSchema)).optional(), @@ -90,7 +90,7 @@ export const unmarshalTagPolicySchema: z.ZodType = z export const unmarshalValueSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -98,7 +98,7 @@ export const unmarshalValueSchema: z.ZodType = z export const marshalTagPolicySchema: z.ZodType = z .object({ - tagKey: z.string().optional(), + tagKey: z.string(), id: z.string().optional(), description: z.string().optional(), values: z.array(z.lazy(() => marshalValueSchema)).optional(), @@ -122,7 +122,7 @@ export const marshalTagPolicySchema: z.ZodType = z export const marshalValueSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, diff --git a/packages/tokenmanagement/src/v1/model.ts b/packages/tokenmanagement/src/v1/model.ts index 60ed83991..299d71529 100644 --- a/packages/tokenmanagement/src/v1/model.ts +++ b/packages/tokenmanagement/src/v1/model.ts @@ -56,7 +56,7 @@ export interface AdminTokenInfo { /** Configuration details for creating on-behalf tokens. */ export interface CreateOnBehalfOfTokenRequest { /** Application ID of the service principal. */ - applicationId?: string | undefined; + applicationId: string; /** The number of seconds before the token expires. */ lifetimeSeconds?: bigint | undefined; /** Comment that describes the purpose of the token. */ @@ -125,9 +125,9 @@ export interface RevokeTokenResponse {} * https://docs.databricks.com/api/workspace/api/scopes. */ export interface UpdateTokenRequest { - token?: AdminTokenInfo | undefined; + token: AdminTokenInfo; /** A list of field name under token, For example, {"update_mask": "comment,scopes"} */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export const unmarshalAdminTokenInfoSchema: z.ZodType = z @@ -247,7 +247,7 @@ export const marshalAdminTokenInfoSchema: z.ZodType = z export const marshalCreateOnBehalfOfTokenRequestSchema: z.ZodType = z .object({ - applicationId: z.string().optional(), + applicationId: z.string(), lifetimeSeconds: z.bigint().optional(), comment: z.string().optional(), scopes: z.array(z.string()).optional(), @@ -263,11 +263,8 @@ export const marshalCreateOnBehalfOfTokenRequestSchema: z.ZodType = z export const marshalUpdateTokenRequestSchema: z.ZodType = z .object({ - token: z.lazy(() => marshalAdminTokenInfoSchema).optional(), - updateMask: z - .any() - .transform((m: FieldMask) => m.toString()) - .optional(), + token: z.lazy(() => marshalAdminTokenInfoSchema), + updateMask: z.any().transform((m: FieldMask) => m.toString()), }) .transform(d => ({ token: d.token, diff --git a/packages/tokens/src/v1/model.ts b/packages/tokens/src/v1/model.ts index 6e75ce4c7..019071dea 100644 --- a/packages/tokens/src/v1/model.ts +++ b/packages/tokens/src/v1/model.ts @@ -78,7 +78,7 @@ export interface PublicTokenInfo { export interface RevokeTokenRequest { /** The ID of the token to be revoked. */ - tokenId?: string | undefined; + tokenId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -90,10 +90,10 @@ export interface RevokeTokenResponse {} */ export interface UpdateTokenRequest { /** The SHA-256 hash of the token to be updated. */ - tokenId?: string | undefined; - token?: PublicTokenInfo | undefined; + tokenId: string; + token: PublicTokenInfo; /** A list of field name under token, For example, {"update_mask": "comment,scopes"} */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -193,7 +193,7 @@ export const marshalPublicTokenInfoSchema: z.ZodType = z export const marshalRevokeTokenRequestSchema: z.ZodType = z .object({ - tokenId: z.string().optional(), + tokenId: z.string(), }) .transform(d => ({ token_id: d.tokenId, @@ -201,12 +201,9 @@ export const marshalRevokeTokenRequestSchema: z.ZodType = z export const marshalUpdateTokenRequestSchema: z.ZodType = z .object({ - tokenId: z.string().optional(), - token: z.lazy(() => marshalPublicTokenInfoSchema).optional(), - updateMask: z - .any() - .transform((m: FieldMask) => m.toString()) - .optional(), + tokenId: z.string(), + token: z.lazy(() => marshalPublicTokenInfoSchema), + updateMask: z.any().transform((m: FieldMask) => m.toString()), }) .transform(d => ({ token_id: d.tokenId, diff --git a/packages/uc/abacpolicies/src/v1/index.ts b/packages/uc/abacpolicies/src/v1/index.ts index bfa8a1cfe..22e3831e7 100644 --- a/packages/uc/abacpolicies/src/v1/index.ts +++ b/packages/uc/abacpolicies/src/v1/index.ts @@ -10,9 +10,11 @@ export {PolicyType, SecurableType} from './model'; export type { ColumnMaskOptions, + ColumnTagValueExtraction, CreatePolicyRequest, DeletePolicyRequest, DeletePolicyResponse, + FunctionArgExpression, FunctionArgument, GetPolicyRequest, GrantOptions, @@ -21,6 +23,8 @@ export type { MatchColumn, PolicyInfo, RowFilterOptions, + TagIntrospectionExpression, + TagValueExtraction, UpdatePolicyRequest, } from './model'; diff --git a/packages/uc/abacpolicies/src/v1/model.ts b/packages/uc/abacpolicies/src/v1/model.ts index 3bf7bb874..0087921b3 100644 --- a/packages/uc/abacpolicies/src/v1/model.ts +++ b/packages/uc/abacpolicies/src/v1/model.ts @@ -37,6 +37,10 @@ export const SecurableType = { EXTERNAL_METADATA: 'EXTERNAL_METADATA', /** TODO: [UC-2980] Staging tables aren't full-fleged securables yet. */ STAGING_TABLE: 'STAGING_TABLE', + MODEL: 'MODEL', + MODEL_SERVICE: 'MODEL_SERVICE', + MCP_SERVICE: 'MCP_SERVICE', + MODEL_PROVIDER_SERVICE: 'MODEL_PROVIDER_SERVICE', } as const; export type SecurableType = | (typeof SecurableType)[keyof typeof SecurableType] @@ -49,13 +53,13 @@ export interface ColumnMaskOptions { * The function's first argument and its return type should match the type of the masked column. * Required on create and update. */ - functionName?: string | undefined; + functionName: string; /** * The alias of the column to be masked. The alias must refer to one of matched columns. * The values of the column is passed to the column mask function as the first argument. * Required on create and update. */ - onColumn?: string | undefined; + onColumn: string; /** * Optional list of column aliases or constant literals to be passed as additional arguments to the column mask function. * The type of each column should match the positional argument of the column mask function. @@ -63,23 +67,45 @@ export interface ColumnMaskOptions { using?: FunctionArgument[] | undefined; } +/** Extracts the value of a column-level tag: get_column_tag_value(col, "tagKey"). */ +export interface ColumnTagValueExtraction { + /** The alias from MATCH COLUMNS that identifies the column. */ + columnAlias: string; + /** 1024 matches the max_length on FunctionArgument.constant above. */ + tagKey: string; +} + export interface CreatePolicyRequest { /** Required. The policy to create. */ - policyInfo?: PolicyInfo | undefined; + policyInfo: PolicyInfo; } export interface DeletePolicyRequest { /** Required. The type of the securable to delete the policy from. */ - onSecurableType?: string | undefined; + onSecurableType: string; /** Required. The fully qualified name of the securable to delete the policy from. */ - onSecurableFullname?: string | undefined; + onSecurableFullname: string; /** Required. The name of the policy to delete */ - name?: string | undefined; + name: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type export interface DeletePolicyResponse {} +/** + * An expression that is evaluated at query time against per-request context. + * New variants (e.g., identity attributes) are added as additional oneof cases. + */ +export interface FunctionArgExpression { + expr?: + | { + $case: 'tagIntrospection'; + /** An expression that introspects tags at query time. */ + tagIntrospection: TagIntrospectionExpression; + } + | undefined; +} + export interface FunctionArgument { /** A positional argument pass to a row filter or column mask function. */ arg?: @@ -93,16 +119,25 @@ export interface FunctionArgument { /** A constant literal. */ constant: string; } + | { + $case: 'functionArgExpression'; + /** + * An expression evaluated at query time. Wraps per-request expression variants + * (e.g., tag introspection) so new variants can be added without extending the + * FunctionArgument oneof. + */ + functionArgExpression: FunctionArgExpression; + } | undefined; } export interface GetPolicyRequest { /** Required. The type of the securable to retrieve the policy for. */ - onSecurableType?: string | undefined; + onSecurableType: string; /** Required. The fully qualified name of securable to retrieve policy for. */ - onSecurableFullname?: string | undefined; + onSecurableFullname: string; /** Required. The name of the policy to retrieve. */ - name?: string | undefined; + name: string; } export interface GrantOptions { @@ -112,14 +147,14 @@ export interface GrantOptions { * if the principal and condition match. * Required on create and update. */ - privileges?: string[] | undefined; + privileges: string[]; } export interface ListPoliciesRequest { /** Required. The type of the securable to list policies for. */ - onSecurableType?: string | undefined; + onSecurableType: string; /** Required. The fully qualified name of securable to list policies for. */ - onSecurableFullname?: string | undefined; + onSecurableFullname: string; /** * Optional. Whether to include policies defined on parent securables. * By default, the inherited policies are not included. @@ -177,18 +212,18 @@ export interface PolicyInfo { * List of user or group names that the policy applies to. * Required on create and optional on update. */ - toPrincipals?: string[] | undefined; + toPrincipals: string[]; /** Optional list of user or group names that should be excluded from the policy. */ exceptPrincipals?: string[] | undefined; /** * Type of securables that the policy should take effect on. * Required on create and optional on update. */ - forSecurableType?: SecurableType | undefined; + forSecurableType: SecurableType; /** Optional condition when the policy should take effect. */ whenCondition?: string | undefined; /** Type of the policy. Required on create. */ - policyType?: PolicyType | undefined; + policyType: PolicyType; /** * (--[Create:REQ Update:OPT] Type-specific options for the Policy--) * Type-specific options for the policy. @@ -245,7 +280,7 @@ export interface RowFilterOptions { * indicating whether the row should be visible to the user. * Required on create and update. */ - functionName?: string | undefined; + functionName: string; /** * Optional list of column aliases or constant literals to be passed as arguments to the row filter function. * The type of each column should match the positional argument of the row filter function. @@ -253,13 +288,36 @@ export interface RowFilterOptions { using?: FunctionArgument[] | undefined; } +/** An expression that introspects tags at query time. */ +export interface TagIntrospectionExpression { + /** The tag introspection variant to evaluate at query time. */ + expr?: + | { + $case: 'tagValue'; + /** Extracts the value of a securable-level tag. */ + tagValue: TagValueExtraction; + } + | { + $case: 'columnTagValue'; + /** Extracts the value of a column-level tag. */ + columnTagValue: ColumnTagValueExtraction; + } + | undefined; +} + +/** Extracts the value of a securable-level tag: get_tag_value("tagKey"). */ +export interface TagValueExtraction { + /** 1024 matches the max_length on FunctionArgument.constant above. */ + tagKey: string; +} + export interface UpdatePolicyRequest { /** Required. The type of the securable to update the policy for. */ - onSecurableType?: string | undefined; + onSecurableType: string; /** Required. The fully qualified name of the securable to update the policy for. */ - onSecurableFullname?: string | undefined; + onSecurableFullname: string; /** Required. The name of the policy to update. */ - name?: string | undefined; + name: string; /** * Optional fields to update. This is the request body for updating a policy. * Use `update_mask` field to specify which fields in the request is to be updated. @@ -279,8 +337,8 @@ export interface UpdatePolicyRequest { export const unmarshalColumnMaskOptionsSchema: z.ZodType = z .object({ - function_name: z.string().optional(), - on_column: z.string().optional(), + function_name: z.string(), + on_column: z.string(), using: z.array(z.lazy(() => unmarshalFunctionArgumentSchema)).optional(), }) .transform(d => ({ @@ -289,13 +347,44 @@ export const unmarshalColumnMaskOptionsSchema: z.ZodType = z using: d.using, })); +export const unmarshalColumnTagValueExtractionSchema: z.ZodType = + z + .object({ + column_alias: z.string(), + tag_key: z.string(), + }) + .transform(d => ({ + columnAlias: d.column_alias, + tagKey: d.tag_key, + })); + export const unmarshalDeletePolicyResponseSchema: z.ZodType = z.object({}); +export const unmarshalFunctionArgExpressionSchema: z.ZodType = + z + .object({ + tag_introspection: z + .lazy(() => unmarshalTagIntrospectionExpressionSchema) + .optional(), + }) + .transform(d => ({ + expr: + d.tag_introspection !== undefined + ? { + $case: 'tagIntrospection' as const, + tagIntrospection: d.tag_introspection, + } + : undefined, + })); + export const unmarshalFunctionArgumentSchema: z.ZodType = z .object({ alias: z.string().optional(), constant: z.string().optional(), + function_arg_expression: z + .lazy(() => unmarshalFunctionArgExpressionSchema) + .optional(), }) .transform(d => ({ arg: @@ -303,12 +392,17 @@ export const unmarshalFunctionArgumentSchema: z.ZodType = z ? {$case: 'alias' as const, alias: d.alias} : d.constant !== undefined ? {$case: 'constant' as const, constant: d.constant} - : undefined, + : d.function_arg_expression !== undefined + ? { + $case: 'functionArgExpression' as const, + functionArgExpression: d.function_arg_expression, + } + : undefined, })); export const unmarshalGrantOptionsSchema: z.ZodType = z .object({ - privileges: z.array(z.string()).optional(), + privileges: z.array(z.string()), }) .transform(d => ({ privileges: d.privileges, @@ -342,11 +436,11 @@ export const unmarshalPolicyInfoSchema: z.ZodType = z on_securable_fullname: z.string().optional(), name: z.string().optional(), comment: z.string().optional(), - to_principals: z.array(z.string()).optional(), + to_principals: z.array(z.string()), except_principals: z.array(z.string()).optional(), - for_securable_type: z.string().optional(), + for_securable_type: z.string(), when_condition: z.string().optional(), - policy_type: z.string().optional(), + policy_type: z.string(), row_filter: z.lazy(() => unmarshalRowFilterOptionsSchema).optional(), column_mask: z.lazy(() => unmarshalColumnMaskOptionsSchema).optional(), grant: z.lazy(() => unmarshalGrantOptionsSchema).optional(), @@ -390,7 +484,7 @@ export const unmarshalPolicyInfoSchema: z.ZodType = z export const unmarshalRowFilterOptionsSchema: z.ZodType = z .object({ - function_name: z.string().optional(), + function_name: z.string(), using: z.array(z.lazy(() => unmarshalFunctionArgumentSchema)).optional(), }) .transform(d => ({ @@ -398,10 +492,39 @@ export const unmarshalRowFilterOptionsSchema: z.ZodType = z using: d.using, })); +export const unmarshalTagIntrospectionExpressionSchema: z.ZodType = + z + .object({ + tag_value: z.lazy(() => unmarshalTagValueExtractionSchema).optional(), + column_tag_value: z + .lazy(() => unmarshalColumnTagValueExtractionSchema) + .optional(), + }) + .transform(d => ({ + expr: + d.tag_value !== undefined + ? {$case: 'tagValue' as const, tagValue: d.tag_value} + : d.column_tag_value !== undefined + ? { + $case: 'columnTagValue' as const, + columnTagValue: d.column_tag_value, + } + : undefined, + })); + +export const unmarshalTagValueExtractionSchema: z.ZodType = + z + .object({ + tag_key: z.string(), + }) + .transform(d => ({ + tagKey: d.tag_key, + })); + export const marshalColumnMaskOptionsSchema: z.ZodType = z .object({ - functionName: z.string().optional(), - onColumn: z.string().optional(), + functionName: z.string(), + onColumn: z.string(), using: z.array(z.lazy(() => marshalFunctionArgumentSchema)).optional(), }) .transform(d => ({ @@ -410,23 +533,61 @@ export const marshalColumnMaskOptionsSchema: z.ZodType = z using: d.using, })); +export const marshalColumnTagValueExtractionSchema: z.ZodType = z + .object({ + columnAlias: z.string(), + tagKey: z.string(), + }) + .transform(d => ({ + column_alias: d.columnAlias, + tag_key: d.tagKey, + })); + +export const marshalFunctionArgExpressionSchema: z.ZodType = z + .object({ + expr: z + .discriminatedUnion('$case', [ + z.object({ + $case: z.literal('tagIntrospection'), + tagIntrospection: z.lazy( + () => marshalTagIntrospectionExpressionSchema + ), + }), + ]) + .optional(), + }) + .transform(d => ({ + ...(d.expr?.$case === 'tagIntrospection' && { + tag_introspection: d.expr.tagIntrospection, + }), + })); + export const marshalFunctionArgumentSchema: z.ZodType = z .object({ arg: z .discriminatedUnion('$case', [ z.object({$case: z.literal('alias'), alias: z.string()}), z.object({$case: z.literal('constant'), constant: z.string()}), + z.object({ + $case: z.literal('functionArgExpression'), + functionArgExpression: z.lazy( + () => marshalFunctionArgExpressionSchema + ), + }), ]) .optional(), }) .transform(d => ({ ...(d.arg?.$case === 'alias' && {alias: d.arg.alias}), ...(d.arg?.$case === 'constant' && {constant: d.arg.constant}), + ...(d.arg?.$case === 'functionArgExpression' && { + function_arg_expression: d.arg.functionArgExpression, + }), })); export const marshalGrantOptionsSchema: z.ZodType = z .object({ - privileges: z.array(z.string()).optional(), + privileges: z.array(z.string()), }) .transform(d => ({ privileges: d.privileges, @@ -449,11 +610,11 @@ export const marshalPolicyInfoSchema: z.ZodType = z onSecurableFullname: z.string().optional(), name: z.string().optional(), comment: z.string().optional(), - toPrincipals: z.array(z.string()).optional(), + toPrincipals: z.array(z.string()), exceptPrincipals: z.array(z.string()).optional(), - forSecurableType: z.string().optional(), + forSecurableType: z.string(), whenCondition: z.string().optional(), - policyType: z.string().optional(), + policyType: z.string(), options: z .discriminatedUnion('$case', [ z.object({ @@ -501,7 +662,7 @@ export const marshalPolicyInfoSchema: z.ZodType = z export const marshalRowFilterOptionsSchema: z.ZodType = z .object({ - functionName: z.string().optional(), + functionName: z.string(), using: z.array(z.lazy(() => marshalFunctionArgumentSchema)).optional(), }) .transform(d => ({ @@ -509,6 +670,36 @@ export const marshalRowFilterOptionsSchema: z.ZodType = z using: d.using, })); +export const marshalTagIntrospectionExpressionSchema: z.ZodType = z + .object({ + expr: z + .discriminatedUnion('$case', [ + z.object({ + $case: z.literal('tagValue'), + tagValue: z.lazy(() => marshalTagValueExtractionSchema), + }), + z.object({ + $case: z.literal('columnTagValue'), + columnTagValue: z.lazy(() => marshalColumnTagValueExtractionSchema), + }), + ]) + .optional(), + }) + .transform(d => ({ + ...(d.expr?.$case === 'tagValue' && {tag_value: d.expr.tagValue}), + ...(d.expr?.$case === 'columnTagValue' && { + column_tag_value: d.expr.columnTagValue, + }), + })); + +export const marshalTagValueExtractionSchema: z.ZodType = z + .object({ + tagKey: z.string(), + }) + .transform(d => ({ + tag_key: d.tagKey, + })); + const columnMaskOptionsFieldMaskSchema: FieldMaskSchema = { functionName: {wire: 'function_name'}, onColumn: {wire: 'on_column'}, diff --git a/packages/uc/artifactallowlists/src/v1/model.ts b/packages/uc/artifactallowlists/src/v1/model.ts index 8deae4b8e..b82856854 100644 --- a/packages/uc/artifactallowlists/src/v1/model.ts +++ b/packages/uc/artifactallowlists/src/v1/model.ts @@ -28,7 +28,7 @@ export type ArtifactMatcher_MatchType = export interface ArtifactAllowlistInfo { /** A list of allowed artifact match patterns. */ - artifactMatchers?: ArtifactMatcher[] | undefined; + artifactMatchers: ArtifactMatcher[]; /** Unique identifier of parent metastore. */ metastoreId?: string | undefined; /** Username of the user who set the artifact allowlist. */ @@ -39,21 +39,21 @@ export interface ArtifactAllowlistInfo { export interface ArtifactMatcher { /** The artifact path or maven coordinate */ - artifact?: string | undefined; + artifact: string; /** The pattern matching type of the artifact */ - matchType?: ArtifactMatcher_MatchType | undefined; + matchType: ArtifactMatcher_MatchType; } export interface GetArtifactAllowlistRequest { /** The artifact type of the allowlist. */ - artifactType?: ArtifactType | undefined; + artifactType: ArtifactType; } export interface SetArtifactAllowlistRequest { /** The artifact type of the allowlist. */ - artifactType?: ArtifactType | undefined; + artifactType: ArtifactType; /** A list of allowed artifact match patterns. */ - artifactMatchers?: ArtifactMatcher[] | undefined; + artifactMatchers: ArtifactMatcher[]; /** Unique identifier of parent metastore. */ metastoreId?: string | undefined; /** Username of the user who set the artifact allowlist. */ @@ -65,9 +65,7 @@ export interface SetArtifactAllowlistRequest { export const unmarshalArtifactAllowlistInfoSchema: z.ZodType = z .object({ - artifact_matchers: z - .array(z.lazy(() => unmarshalArtifactMatcherSchema)) - .optional(), + artifact_matchers: z.array(z.lazy(() => unmarshalArtifactMatcherSchema)), metastore_id: z.string().optional(), created_by: z.string().optional(), created_at: z @@ -84,8 +82,8 @@ export const unmarshalArtifactAllowlistInfoSchema: z.ZodType = z .object({ - artifact: z.string().optional(), - match_type: z.string().optional(), + artifact: z.string(), + match_type: z.string(), }) .transform(d => ({ artifact: d.artifact, @@ -94,8 +92,8 @@ export const unmarshalArtifactMatcherSchema: z.ZodType = z export const marshalArtifactMatcherSchema: z.ZodType = z .object({ - artifact: z.string().optional(), - matchType: z.string().optional(), + artifact: z.string(), + matchType: z.string(), }) .transform(d => ({ artifact: d.artifact, @@ -104,10 +102,8 @@ export const marshalArtifactMatcherSchema: z.ZodType = z export const marshalSetArtifactAllowlistRequestSchema: z.ZodType = z .object({ - artifactType: z.string().optional(), - artifactMatchers: z - .array(z.lazy(() => marshalArtifactMatcherSchema)) - .optional(), + artifactType: z.string(), + artifactMatchers: z.array(z.lazy(() => marshalArtifactMatcherSchema)), metastoreId: z.string().optional(), createdBy: z.string().optional(), createdAt: z.bigint().optional(), diff --git a/packages/uc/catalogs/src/v1/model.ts b/packages/uc/catalogs/src/v1/model.ts index b0cb5de48..486ebbd4f 100644 --- a/packages/uc/catalogs/src/v1/model.ts +++ b/packages/uc/catalogs/src/v1/model.ts @@ -46,6 +46,10 @@ export const SecurableType = { EXTERNAL_METADATA: 'EXTERNAL_METADATA', /** TODO: [UC-2980] Staging tables aren't full-fleged securables yet. */ STAGING_TABLE: 'STAGING_TABLE', + MODEL: 'MODEL', + MODEL_SERVICE: 'MODEL_SERVICE', + MCP_SERVICE: 'MCP_SERVICE', + MODEL_PROVIDER_SERVICE: 'MODEL_PROVIDER_SERVICE', } as const; export type SecurableType = | (typeof SecurableType)[keyof typeof SecurableType] @@ -67,7 +71,7 @@ export type ProvisioningInfo_State = | (string & {}); export interface AzureEncryptionSettings { - azureTenantId?: string | undefined; + azureTenantId: string; azureCmkAccessConnectorId?: string | undefined; azureCmkManagedIdentityId?: string | undefined; } @@ -122,7 +126,7 @@ export interface CatalogInfo { /** Control CMK encryption for managed catalog data */ managedEncryptionSettings?: EncryptionSettings | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; /** A map of key-value properties attached to the securable. */ options?: Record | undefined; } @@ -177,14 +181,14 @@ export interface CreateCatalogRequest { /** Control CMK encryption for managed catalog data */ managedEncryptionSettings?: EncryptionSettings | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; /** A map of key-value properties attached to the securable. */ options?: Record | undefined; } export interface DeleteCatalogRequest { /** The name of the catalog. */ - nameArg?: string | undefined; + nameArg: string; /** Force deletion even if the catalog is not empty. */ force?: boolean | undefined; } @@ -194,7 +198,7 @@ export interface DeleteCatalogResponse {} export interface EffectivePredictiveOptimizationFlag { /** Whether predictive optimization should be enabled for this object and objects under it. */ - value?: string | undefined; + value: string; /** The type of the object from which the flag was inherited. If there was no inheritance, this field is left blank. */ inheritedFromType?: string | undefined; /** The name of the object from which the flag was inherited. If there was no inheritance, this field is left blank. */ @@ -216,7 +220,7 @@ export interface EncryptionSettings { export interface GetCatalogRequest { /** The name of the catalog. */ - nameArg?: string | undefined; + nameArg: string; /** Whether to include catalogs in the response for which the principal can only access selective metadata for */ includeBrowse?: boolean | undefined; } @@ -261,7 +265,7 @@ export interface ProvisioningInfo { export interface UpdateCatalogRequest { /** The name of the catalog. */ - nameArg?: string | undefined; + nameArg: string; /** New name for the catalog. */ newName?: string | undefined; /** Name of catalog. */ @@ -313,7 +317,7 @@ export interface UpdateCatalogRequest { /** Control CMK encryption for managed catalog data */ managedEncryptionSettings?: EncryptionSettings | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; /** A map of key-value properties attached to the securable. */ options?: Record | undefined; } @@ -321,7 +325,7 @@ export interface UpdateCatalogRequest { export const unmarshalAzureEncryptionSettingsSchema: z.ZodType = z .object({ - azure_tenant_id: z.string().optional(), + azure_tenant_id: z.string(), azure_cmk_access_connector_id: z.string().optional(), azure_cmk_managed_identity_id: z.string().optional(), }) @@ -369,7 +373,7 @@ export const unmarshalCatalogInfoSchema: z.ZodType = z managed_encryption_settings: z .lazy(() => unmarshalEncryptionSettingsSchema) .optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), options: z.record(z.string(), z.string()).optional(), }) .transform(d => ({ @@ -407,7 +411,7 @@ export const unmarshalDeleteCatalogResponseSchema: z.ZodType = z .object({ - value: z.string().optional(), + value: z.string(), inherited_from_type: z.string().optional(), inherited_from_name: z.string().optional(), }) @@ -453,7 +457,7 @@ export const unmarshalProvisioningInfoSchema: z.ZodType = z export const marshalAzureEncryptionSettingsSchema: z.ZodType = z .object({ - azureTenantId: z.string().optional(), + azureTenantId: z.string(), azureCmkAccessConnectorId: z.string().optional(), azureCmkManagedIdentityId: z.string().optional(), }) @@ -492,7 +496,7 @@ export const marshalCreateCatalogRequestSchema: z.ZodType = z managedEncryptionSettings: z .lazy(() => marshalEncryptionSettingsSchema) .optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), options: z.record(z.string(), z.string()).optional(), }) .transform(d => ({ @@ -526,7 +530,7 @@ export const marshalCreateCatalogRequestSchema: z.ZodType = z export const marshalEffectivePredictiveOptimizationFlagSchema: z.ZodType = z .object({ - value: z.string().optional(), + value: z.string(), inheritedFromType: z.string().optional(), inheritedFromName: z.string().optional(), }) @@ -560,7 +564,7 @@ export const marshalProvisioningInfoSchema: z.ZodType = z export const marshalUpdateCatalogRequestSchema: z.ZodType = z .object({ - nameArg: z.string().optional(), + nameArg: z.string(), newName: z.string().optional(), name: z.string().optional(), owner: z.string().optional(), @@ -589,7 +593,7 @@ export const marshalUpdateCatalogRequestSchema: z.ZodType = z managedEncryptionSettings: z .lazy(() => marshalEncryptionSettingsSchema) .optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), options: z.record(z.string(), z.string()).optional(), }) .transform(d => ({ diff --git a/packages/uc/connections/src/v1/model.ts b/packages/uc/connections/src/v1/model.ts index 9c4037df2..23b3d2548 100644 --- a/packages/uc/connections/src/v1/model.ts +++ b/packages/uc/connections/src/v1/model.ts @@ -83,6 +83,10 @@ export const SecurableType = { EXTERNAL_METADATA: 'EXTERNAL_METADATA', /** TODO: [UC-2980] Staging tables aren't full-fleged securables yet. */ STAGING_TABLE: 'STAGING_TABLE', + MODEL: 'MODEL', + MODEL_SERVICE: 'MODEL_SERVICE', + MCP_SERVICE: 'MCP_SERVICE', + MODEL_PROVIDER_SERVICE: 'MODEL_PROVIDER_SERVICE', } as const; export type SecurableType = | (typeof SecurableType)[keyof typeof SecurableType] @@ -139,7 +143,7 @@ export interface ConnectionInfo { /** A map of key-value properties attached to the securable. */ options?: Record | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; } export interface CreateConnectionRequest { @@ -183,12 +187,12 @@ export interface CreateConnectionRequest { /** A map of key-value properties attached to the securable. */ options?: Record | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; } export interface DeleteConnectionRequest { /** The name of the connection to be deleted. */ - nameArg?: string | undefined; + nameArg: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -201,7 +205,7 @@ export interface EnvironmentSettings { export interface GetConnectionRequest { /** Name of the connection. */ - nameArg?: string | undefined; + nameArg: string; } export interface ListConnectionsRequest { @@ -237,7 +241,7 @@ export interface ProvisioningInfo { export interface UpdateConnectionRequest { /** Name of the connection. */ - nameArg?: string | undefined; + nameArg: string; /** New name for the connection. */ newName?: string | undefined; /** Name of the connection. */ @@ -275,7 +279,7 @@ export interface UpdateConnectionRequest { /** A map of key-value properties attached to the securable. */ options?: Record | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; } export const unmarshalConnectionInfoSchema: z.ZodType = z @@ -306,7 +310,7 @@ export const unmarshalConnectionInfoSchema: z.ZodType = z securable_type: z.string().optional(), provisioning_info: z.lazy(() => unmarshalProvisioningInfoSchema).optional(), options: z.record(z.string(), z.string()).optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), }) .transform(d => ({ name: d.name, @@ -388,7 +392,7 @@ export const marshalCreateConnectionRequestSchema: z.ZodType = z securableType: z.string().optional(), provisioningInfo: z.lazy(() => marshalProvisioningInfoSchema).optional(), options: z.record(z.string(), z.string()).optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), }) .transform(d => ({ parent: d.parent, @@ -433,7 +437,7 @@ export const marshalProvisioningInfoSchema: z.ZodType = z export const marshalUpdateConnectionRequestSchema: z.ZodType = z .object({ - nameArg: z.string().optional(), + nameArg: z.string(), newName: z.string().optional(), name: z.string().optional(), connectionType: z.string().optional(), @@ -455,7 +459,7 @@ export const marshalUpdateConnectionRequestSchema: z.ZodType = z securableType: z.string().optional(), provisioningInfo: z.lazy(() => marshalProvisioningInfoSchema).optional(), options: z.record(z.string(), z.string()).optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), }) .transform(d => ({ name_arg: d.nameArg, diff --git a/packages/uc/credentials/src/v1/model.ts b/packages/uc/credentials/src/v1/model.ts index ce2ae112a..d4aa7fb72 100644 --- a/packages/uc/credentials/src/v1/model.ts +++ b/packages/uc/credentials/src/v1/model.ts @@ -83,9 +83,9 @@ export type ValidateStorageCredentialRequest_Result = export interface AccountsCreateStorageCredentialRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; credentialInfo?: CreateAccountsStorageCredential | undefined; /** * Optional, default false. @@ -101,11 +101,11 @@ export interface AccountsCreateStorageCredentialResponse { /** Deletes a storage credential for an account */ export interface AccountsDeleteStorageCredentialRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; /** Name of the storage credential. */ - nameArg?: string | undefined; + nameArg: string; /** Force deletion even if the Storage Credential is not empty. Default is false. */ force?: boolean | undefined; } @@ -117,11 +117,11 @@ export interface AccountsDeleteStorageCredentialResponse {} /** Retrieves a single storage credential */ export interface AccountsGetStorageCredentialRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; /** Required. Name of the storage credential. */ - nameArg?: string | undefined; + nameArg: string; } /** The storage credential was successfully retrieved. */ @@ -132,9 +132,9 @@ export interface AccountsGetStorageCredentialResponse { /** Lists all storage credentials for the given account and metastore */ export interface AccountsListStorageCredentialsRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; } /** The metastore storage credentials were successfully returned. */ @@ -146,11 +146,11 @@ export interface AccountsListStorageCredentialsResponse { /** The storage credential to update. */ export interface AccountsUpdateStorageCredentialRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; /** Name of the storage credential. */ - nameArg?: string | undefined; + nameArg: string; credentialInfo?: UpdateAccountsStorageCredential | undefined; /** Optional. Supplying true to this argument skips validation of the updated set of credentials. */ skipValidation?: boolean | undefined; @@ -200,7 +200,7 @@ export interface AzureManagedIdentity { * The Azure resource ID of the Azure Databricks Access Connector. Use the format * `/subscriptions/{guid}/resourceGroups/{rg-name}/providers/Microsoft.Databricks/accessConnectors/{connector-name}`. */ - accessConnectorId?: string | undefined; + accessConnectorId: string; /** * The Azure resource ID of the managed identity. Use the format, * `/subscriptions/{guid}/resourceGroups/{rg-name}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identity-name}` @@ -215,11 +215,11 @@ export interface AzureManagedIdentity { /** The Azure service principal configuration. Only applicable when purpose is **STORAGE**. */ export interface AzureServicePrincipal { /** The directory ID corresponding to the Azure Active Directory (AAD) tenant of the application. */ - directoryId?: string | undefined; + directoryId: string; /** The application ID of the application registration within the referenced AAD tenant. */ - applicationId?: string | undefined; + applicationId: string; /** The client secret generated for the above app ID in AAD. */ - clientSecret?: string | undefined; + clientSecret: string; } /** @@ -237,11 +237,11 @@ export interface AzureUserDelegationSas { */ export interface CloudflareApiToken { /** The access key ID associated with the API token. */ - accessKeyId?: string | undefined; + accessKeyId: string; /** The secret access token generated for the above access key ID. */ - secretAccessKey?: string | undefined; + secretAccessKey: string; /** The ID of the account associated with the API token. */ - accountId?: string | undefined; + accountId: string; } export interface CreateAccountsStorageCredential { @@ -400,9 +400,9 @@ export interface CreateCredentialRequest { } export interface CreateCredentialsRequest { - accountId?: string | undefined; + accountId: string; /** The human-readable name of the credential configuration object. */ - credentialsName?: string | undefined; + credentialsName: string; /** (-- NOTE(austin) This oneof is a future-looking definition when we add other clouds --) */ cloudCredentials?: | {$case: 'awsCredentials'; awsCredentials: CreateCredentialAwsCredentials} @@ -587,7 +587,7 @@ export interface DatabricksGcpServiceAccount { export interface DeleteCredentialRequest { /** Name of the credential. */ - nameArg?: string | undefined; + nameArg: string; /** * Force an update even if there are dependent services (when purpose is * **SERVICE**) or dependent external locations and external tables (when @@ -601,13 +601,13 @@ export interface DeleteCredentialResponse {} export interface DeleteCredentialsRequest { /** Databricks Account API credential configuration ID */ - credentialsId?: string | undefined; - accountId?: string | undefined; + credentialsId: string; + accountId: string; } export interface DeleteStorageCredentialRequest { /** Name of the storage credential. */ - nameArg?: string | undefined; + nameArg: string; /** * Force an update even if there are dependent external locations or external * tables (when purpose is **STORAGE**) or dependent services (when purpose is @@ -642,9 +642,9 @@ export interface GcpServiceAccountKey { export interface GenerateTemporaryPathCredentialRequest { /** URL for path-based access. */ - url?: string | undefined; + url: string; /** The operation being performed on the path. */ - operation?: PathOperation | undefined; + operation: PathOperation; /** * Optional. When set to true, the service will not validate that the generated * credentials can perform write operations, therefore no new paths will be created @@ -775,13 +775,13 @@ export interface GenerateTemporaryVolumeCredentialResponse { export interface GetCredentialRequest { /** Name of the credential. */ - nameArg?: string | undefined; + nameArg: string; } export interface GetCredentialsRequest { /** Credential configuration ID */ - credentialsId?: string | undefined; - accountId?: string | undefined; + credentialsId: string; + accountId: string; } /** @@ -791,11 +791,11 @@ export interface GetCredentialsRequest { */ export interface GetStorageCredentialRequest { /** Name of the storage credential. */ - nameArg?: string | undefined; + nameArg: string; } export interface ListCredentialsPublicRequest { - accountId?: string | undefined; + accountId: string; } /** @@ -1074,7 +1074,7 @@ export interface UpdateAccountsStorageCredential { export interface UpdateCredentialRequest { /** Name of the credential. */ - nameArg?: string | undefined; + nameArg: string; /** New name of credential. */ newName?: string | undefined; /** Supply true to this argument to skip validation of the updated credential. */ @@ -1159,7 +1159,7 @@ export interface UpdateCredentialRequest { export interface UpdateStorageCredentialRequest { /** Name of the storage credential. */ - nameArg?: string | undefined; + nameArg: string; /** New name for the storage credential. */ newName?: string | undefined; /** Supplying true to this argument skips validation of the updated credential. */ @@ -1451,7 +1451,7 @@ export const unmarshalAzureActiveDirectoryTokenSchema: z.ZodType = z .object({ - access_connector_id: z.string().optional(), + access_connector_id: z.string(), managed_identity_id: z.string().optional(), credential_id: z.string().optional(), }) @@ -1464,9 +1464,9 @@ export const unmarshalAzureManagedIdentitySchema: z.ZodType = z .object({ - directory_id: z.string().optional(), - application_id: z.string().optional(), - client_secret: z.string().optional(), + directory_id: z.string(), + application_id: z.string(), + client_secret: z.string(), }) .transform(d => ({ directoryId: d.directory_id, @@ -1486,9 +1486,9 @@ export const unmarshalAzureUserDelegationSasSchema: z.ZodType = z .object({ - access_key_id: z.string().optional(), - secret_access_key: z.string().optional(), - account_id: z.string().optional(), + access_key_id: z.string(), + secret_access_key: z.string(), + account_id: z.string(), }) .transform(d => ({ accessKeyId: d.access_key_id, @@ -2048,8 +2048,8 @@ export const unmarshalValidateStorageCredentialResponseSchema: z.ZodType marshalCreateAccountsStorageCredentialSchema) .optional(), @@ -2064,9 +2064,9 @@ export const marshalAccountsCreateStorageCredentialRequestSchema: z.ZodType = z export const marshalAccountsUpdateStorageCredentialRequestSchema: z.ZodType = z .object({ - accountId: z.string().optional(), - metastoreId: z.string().optional(), - nameArg: z.string().optional(), + accountId: z.string(), + metastoreId: z.string(), + nameArg: z.string(), credentialInfo: z .lazy(() => marshalUpdateAccountsStorageCredentialSchema) .optional(), @@ -2103,7 +2103,7 @@ export const marshalAwsIamRoleSchema: z.ZodType = z export const marshalAzureManagedIdentitySchema: z.ZodType = z .object({ - accessConnectorId: z.string().optional(), + accessConnectorId: z.string(), managedIdentityId: z.string().optional(), credentialId: z.string().optional(), }) @@ -2115,9 +2115,9 @@ export const marshalAzureManagedIdentitySchema: z.ZodType = z export const marshalAzureServicePrincipalSchema: z.ZodType = z .object({ - directoryId: z.string().optional(), - applicationId: z.string().optional(), - clientSecret: z.string().optional(), + directoryId: z.string(), + applicationId: z.string(), + clientSecret: z.string(), }) .transform(d => ({ directory_id: d.directoryId, @@ -2127,9 +2127,9 @@ export const marshalAzureServicePrincipalSchema: z.ZodType = z export const marshalCloudflareApiTokenSchema: z.ZodType = z .object({ - accessKeyId: z.string().optional(), - secretAccessKey: z.string().optional(), - accountId: z.string().optional(), + accessKeyId: z.string(), + secretAccessKey: z.string(), + accountId: z.string(), }) .transform(d => ({ access_key_id: d.accessKeyId, @@ -2320,8 +2320,8 @@ export const marshalCreateCredentialRequestSchema: z.ZodType = z export const marshalCreateCredentialsRequestSchema: z.ZodType = z .object({ - accountId: z.string().optional(), - credentialsName: z.string().optional(), + accountId: z.string(), + credentialsName: z.string(), cloudCredentials: z .discriminatedUnion('$case', [ z.object({ @@ -2451,8 +2451,8 @@ export const marshalGcpServiceAccountKeySchema: z.ZodType = z export const marshalGenerateTemporaryPathCredentialRequestSchema: z.ZodType = z .object({ - url: z.string().optional(), - operation: z.string().optional(), + url: z.string(), + operation: z.string(), dryRun: z.boolean().optional(), }) .transform(d => ({ @@ -2619,7 +2619,7 @@ export const marshalUpdateAccountsStorageCredentialSchema: z.ZodType = z export const marshalUpdateCredentialRequestSchema: z.ZodType = z .object({ - nameArg: z.string().optional(), + nameArg: z.string(), newName: z.string().optional(), skipValidation: z.boolean().optional(), force: z.boolean().optional(), @@ -2709,7 +2709,7 @@ export const marshalUpdateCredentialRequestSchema: z.ZodType = z export const marshalUpdateStorageCredentialRequestSchema: z.ZodType = z .object({ - nameArg: z.string().optional(), + nameArg: z.string(), newName: z.string().optional(), skipValidation: z.boolean().optional(), force: z.boolean().optional(), diff --git a/packages/uc/entitytagassignments/src/v1/model.ts b/packages/uc/entitytagassignments/src/v1/model.ts index cc3bc74af..a52e7f02f 100644 --- a/packages/uc/entitytagassignments/src/v1/model.ts +++ b/packages/uc/entitytagassignments/src/v1/model.ts @@ -21,29 +21,29 @@ export type TagAssignmentSourceType = /** Request to create a new entity tag assignment */ export interface CreateEntityTagAssignmentRequest { - tagAssignment?: EntityTagAssignment | undefined; + tagAssignment: EntityTagAssignment; } /** Request to delete an entity tag assignment */ export interface DeleteEntityTagAssignmentRequest { /** The fully qualified name of the entity to which the tag is assigned */ - entityName?: string | undefined; + entityName: string; /** Required. The key of the tag to delete */ - tagKey?: string | undefined; + tagKey: string; /** The type of the entity to which the tag is assigned. */ - entityType?: string | undefined; + entityType: string; } /** Represents a tag assignment to an entity */ export interface EntityTagAssignment { /** The fully qualified name of the entity to which the tag is assigned */ - entityName?: string | undefined; + entityName: string; /** The key of the tag */ - tagKey?: string | undefined; + tagKey: string; /** The value of the tag */ tagValue?: string | undefined; /** The type of the entity to which the tag is assigned. */ - entityType?: string | undefined; + entityType: string; /** The timestamp when the tag assignment was last updated */ updateTime?: Temporal.Instant | undefined; /** The user or principal who updated the tag assignment */ @@ -55,23 +55,23 @@ export interface EntityTagAssignment { /** Request to get an entity tag assignment */ export interface GetEntityTagAssignmentRequest { /** The fully qualified name of the entity to which the tag is assigned */ - entityName?: string | undefined; + entityName: string; /** Required. The key of the tag */ - tagKey?: string | undefined; + tagKey: string; /** The type of the entity to which the tag is assigned. */ - entityType?: string | undefined; + entityType: string; } /** Request to list entity tag assignments */ export interface ListEntityTagAssignmentsRequest { /** The fully qualified name of the entity to which the tag is assigned */ - entityName?: string | undefined; + entityName: string; /** Optional. Maximum number of tag assignments to return in a single page */ maxResults?: number | undefined; /** Optional. Pagination token to retrieve the next page of results */ pageToken?: string | undefined; /** The type of the entity to which the tag is assigned. */ - entityType?: string | undefined; + entityType: string; } export interface ListEntityTagAssignmentsResponse { @@ -83,17 +83,17 @@ export interface ListEntityTagAssignmentsResponse { /** Request to update an entity tag assignment */ export interface UpdateEntityTagAssignmentRequest { - tagAssignment?: EntityTagAssignment | undefined; - updateMask?: FieldMask | undefined; + tagAssignment: EntityTagAssignment; + updateMask: FieldMask; } export const unmarshalEntityTagAssignmentSchema: z.ZodType = z .object({ - entity_name: z.string().optional(), - tag_key: z.string().optional(), + entity_name: z.string(), + tag_key: z.string(), tag_value: z.string().optional(), - entity_type: z.string().optional(), + entity_type: z.string(), update_time: z .string() .transform(s => Temporal.Instant.from(s)) @@ -126,10 +126,10 @@ export const unmarshalListEntityTagAssignmentsResponseSchema: z.ZodType d.toString()) diff --git a/packages/uc/externallineage/src/v1/model.ts b/packages/uc/externallineage/src/v1/model.ts index b10952713..79f744836 100644 --- a/packages/uc/externallineage/src/v1/model.ts +++ b/packages/uc/externallineage/src/v1/model.ts @@ -53,16 +53,16 @@ export interface ColumnRelationship { } export interface CreateExternalLineageRelationshipRequest { - externalLineageRelationship?: CreateRequestExternalLineage | undefined; + externalLineageRelationship: CreateRequestExternalLineage; } export interface CreateRequestExternalLineage { /** Unique identifier of the external lineage relationship. */ id?: string | undefined; /** Source object of the external lineage relationship. */ - source?: ExternalLineageRelationshipObject | undefined; + source: ExternalLineageRelationshipObject; /** Target object of the external lineage relationship. */ - target?: ExternalLineageRelationshipObject | undefined; + target: ExternalLineageRelationshipObject; /** List of column relationships between source and target objects. */ columns?: ColumnRelationship[] | undefined; /** Key-value properties associated with the external lineage relationship. */ @@ -70,16 +70,16 @@ export interface CreateRequestExternalLineage { } export interface DeleteExternalLineageRelationshipRequest { - externalLineageRelationship?: DeleteRequestExternalLineage | undefined; + externalLineageRelationship: DeleteRequestExternalLineage; } export interface DeleteRequestExternalLineage { /** Unique identifier of the external lineage relationship. */ id?: string | undefined; /** Source object of the external lineage relationship. */ - source?: ExternalLineageRelationshipObject | undefined; + source: ExternalLineageRelationshipObject; /** Target object of the external lineage relationship. */ - target?: ExternalLineageRelationshipObject | undefined; + target: ExternalLineageRelationshipObject; /** List of column relationships between source and target objects. */ columns?: ColumnRelationship[] | undefined; /** Key-value properties associated with the external lineage relationship. */ @@ -108,9 +108,9 @@ export interface ExternalLineageRelationship { /** Unique identifier of the external lineage relationship. */ id?: string | undefined; /** Source object of the external lineage relationship. */ - source?: ExternalLineageRelationshipObject | undefined; + source: ExternalLineageRelationshipObject; /** Target object of the external lineage relationship. */ - target?: ExternalLineageRelationshipObject | undefined; + target: ExternalLineageRelationshipObject; /** List of column relationships between source and target objects. */ columns?: ColumnRelationship[] | undefined; /** Key-value properties associated with the external lineage relationship. */ @@ -203,9 +203,9 @@ export interface ListExternalLineageRelationshipsRequest { * Since this field is a query parameter, please flatten the nested fields. For example, if the object is a table, the query parameter should look like: * `object_info.table.name=main.sales.customers` */ - objectInfo?: ExternalLineageRelationshipObject | undefined; + objectInfo: ExternalLineageRelationshipObject; /** The lineage direction to filter on. */ - lineageDirection?: Direction_LineageDirection | undefined; + lineageDirection: Direction_LineageDirection; /** * Specifies the maximum number of external lineage relationships to return in a single response. * The value must be less than or equal to 1000. @@ -221,17 +221,17 @@ export interface ListExternalLineageRelationshipsResponse { } export interface UpdateExternalLineageRelationshipRequest { - externalLineageRelationship?: UpdateRequestExternalLineage | undefined; - updateMask?: FieldMask | undefined; + externalLineageRelationship: UpdateRequestExternalLineage; + updateMask: FieldMask; } export interface UpdateRequestExternalLineage { /** Unique identifier of the external lineage relationship. */ id?: string | undefined; /** Source object of the external lineage relationship. */ - source?: ExternalLineageRelationshipObject | undefined; + source: ExternalLineageRelationshipObject; /** Target object of the external lineage relationship. */ - target?: ExternalLineageRelationshipObject | undefined; + target: ExternalLineageRelationshipObject; /** List of column relationships between source and target objects. */ columns?: ColumnRelationship[] | undefined; /** Key-value properties associated with the external lineage relationship. */ @@ -276,12 +276,8 @@ export const unmarshalExternalLineageRelationshipSchema: z.ZodType unmarshalExternalLineageRelationshipObjectSchema) - .optional(), - target: z - .lazy(() => unmarshalExternalLineageRelationshipObjectSchema) - .optional(), + source: z.lazy(() => unmarshalExternalLineageRelationshipObjectSchema), + target: z.lazy(() => unmarshalExternalLineageRelationshipObjectSchema), columns: z .array(z.lazy(() => unmarshalColumnRelationshipSchema)) .optional(), @@ -464,12 +460,8 @@ export const marshalColumnRelationshipSchema: z.ZodType = z export const marshalCreateRequestExternalLineageSchema: z.ZodType = z .object({ id: z.string().optional(), - source: z - .lazy(() => marshalExternalLineageRelationshipObjectSchema) - .optional(), - target: z - .lazy(() => marshalExternalLineageRelationshipObjectSchema) - .optional(), + source: z.lazy(() => marshalExternalLineageRelationshipObjectSchema), + target: z.lazy(() => marshalExternalLineageRelationshipObjectSchema), columns: z.array(z.lazy(() => marshalColumnRelationshipSchema)).optional(), properties: z.record(z.string(), z.string()).optional(), }) @@ -484,12 +476,8 @@ export const marshalCreateRequestExternalLineageSchema: z.ZodType = z export const marshalDeleteRequestExternalLineageSchema: z.ZodType = z .object({ id: z.string().optional(), - source: z - .lazy(() => marshalExternalLineageRelationshipObjectSchema) - .optional(), - target: z - .lazy(() => marshalExternalLineageRelationshipObjectSchema) - .optional(), + source: z.lazy(() => marshalExternalLineageRelationshipObjectSchema), + target: z.lazy(() => marshalExternalLineageRelationshipObjectSchema), columns: z.array(z.lazy(() => marshalColumnRelationshipSchema)).optional(), properties: z.record(z.string(), z.string()).optional(), }) @@ -575,12 +563,8 @@ export const marshalExternalLineageRelationshipTableSchema: z.ZodType = z export const marshalUpdateRequestExternalLineageSchema: z.ZodType = z .object({ id: z.string().optional(), - source: z - .lazy(() => marshalExternalLineageRelationshipObjectSchema) - .optional(), - target: z - .lazy(() => marshalExternalLineageRelationshipObjectSchema) - .optional(), + source: z.lazy(() => marshalExternalLineageRelationshipObjectSchema), + target: z.lazy(() => marshalExternalLineageRelationshipObjectSchema), columns: z.array(z.lazy(() => marshalColumnRelationshipSchema)).optional(), properties: z.record(z.string(), z.string()).optional(), }) diff --git a/packages/uc/externallocations/src/v1/model.ts b/packages/uc/externallocations/src/v1/model.ts index 55d5aab43..ade5efdd0 100644 --- a/packages/uc/externallocations/src/v1/model.ts +++ b/packages/uc/externallocations/src/v1/model.ts @@ -58,11 +58,11 @@ export interface CreateExternalLocationRequest { /** Skips validation of the storage credential associated with the external location. */ skipValidation?: boolean | undefined; /** Name of the external location. */ - name?: string | undefined; + name: string; /** Path URL of the external location. */ - url?: string | undefined; + url: string; /** Name of the storage credential used with this location. */ - credentialName?: string | undefined; + credentialName: string; /** Indicates whether the external location is read-only. */ readOnly?: boolean | undefined; /** User-provided free-form text description. */ @@ -107,7 +107,7 @@ export interface CreateExternalLocationRequest { export interface DeleteExternalLocationRequest { /** Name of the external location. */ - nameArg?: string | undefined; + nameArg: string; /** Force deletion even if there are dependent external tables or mounts. */ force?: boolean | undefined; } @@ -128,11 +128,11 @@ export interface EncryptionDetails { export interface ExternalLocationInfo { /** Name of the external location. */ - name?: string | undefined; + name: string; /** Path URL of the external location. */ - url?: string | undefined; + url: string; /** Name of the storage credential used with this location. */ - credentialName?: string | undefined; + credentialName: string; /** Indicates whether the external location is read-only. */ readOnly?: boolean | undefined; /** User-provided free-form text description. */ @@ -200,7 +200,7 @@ export interface GcpPubsub { export interface GetExternalLocationRequest { /** Name of the external location. */ - nameArg?: string | undefined; + nameArg: string; /** Whether to include external locations in the response for which the principal can only access selective metadata for */ includeBrowse?: boolean | undefined; } @@ -248,7 +248,7 @@ export interface SseEncryptionDetails { export interface UpdateExternalLocationRequest { /** Name of the external location. */ - nameArg?: string | undefined; + nameArg: string; /** New name for the external location. */ newName?: string | undefined; /** Force update even if changing url invalidates dependent external tables or mounts. */ @@ -256,11 +256,11 @@ export interface UpdateExternalLocationRequest { /** Skips validation of the storage credential associated with the external location. */ skipValidation?: boolean | undefined; /** Name of the external location. */ - name?: string | undefined; + name: string; /** Path URL of the external location. */ - url?: string | undefined; + url: string; /** Name of the storage credential used with this location. */ - credentialName?: string | undefined; + credentialName: string; /** Indicates whether the external location is read-only. */ readOnly?: boolean | undefined; /** User-provided free-form text description. */ @@ -349,9 +349,9 @@ export const unmarshalEncryptionDetailsSchema: z.ZodType = z export const unmarshalExternalLocationInfoSchema: z.ZodType = z .object({ - name: z.string().optional(), - url: z.string().optional(), - credential_name: z.string().optional(), + name: z.string(), + url: z.string(), + credential_name: z.string(), read_only: z.boolean().optional(), comment: z.string().optional(), enable_file_events: z.boolean().optional(), @@ -495,9 +495,9 @@ export const marshalAzureQueueStorageSchema: z.ZodType = z export const marshalCreateExternalLocationRequestSchema: z.ZodType = z .object({ skipValidation: z.boolean().optional(), - name: z.string().optional(), - url: z.string().optional(), - credentialName: z.string().optional(), + name: z.string(), + url: z.string(), + credentialName: z.string(), readOnly: z.boolean().optional(), comment: z.string().optional(), enableFileEvents: z.boolean().optional(), @@ -637,13 +637,13 @@ export const marshalSseEncryptionDetailsSchema: z.ZodType = z export const marshalUpdateExternalLocationRequestSchema: z.ZodType = z .object({ - nameArg: z.string().optional(), + nameArg: z.string(), newName: z.string().optional(), force: z.boolean().optional(), skipValidation: z.boolean().optional(), - name: z.string().optional(), - url: z.string().optional(), - credentialName: z.string().optional(), + name: z.string(), + url: z.string(), + credentialName: z.string(), readOnly: z.boolean().optional(), comment: z.string().optional(), enableFileEvents: z.boolean().optional(), diff --git a/packages/uc/externalmetadata/src/v1/model.ts b/packages/uc/externalmetadata/src/v1/model.ts index a2d3bd4cd..0d4755a4f 100644 --- a/packages/uc/externalmetadata/src/v1/model.ts +++ b/packages/uc/externalmetadata/src/v1/model.ts @@ -46,11 +46,11 @@ export interface DeleteExternalMetadataRequest { export interface ExternalMetadata { /** Name of the external metadata object. */ - name?: string | undefined; + name: string; /** Type of external system. */ - systemType?: SystemType | undefined; + systemType: SystemType; /** Type of entity within the external system. */ - entityType?: string | undefined; + entityType: string; /** URL associated with the external metadata object. */ url?: string | undefined; /** User-provided free-form text description. */ @@ -96,14 +96,14 @@ export interface ListExternalMetadataResponseV2 { export interface UpdateExternalMetadataRequest { externalMetadata?: ExternalMetadata | undefined; - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export const unmarshalExternalMetadataSchema: z.ZodType = z .object({ - name: z.string().optional(), - system_type: z.string().optional(), - entity_type: z.string().optional(), + name: z.string(), + system_type: z.string(), + entity_type: z.string(), url: z.string().optional(), description: z.string().optional(), columns: z.array(z.string()).optional(), @@ -154,9 +154,9 @@ export const unmarshalListExternalMetadataResponseV2Schema: z.ZodType = z export const unmarshalFunctionDependencySchema: z.ZodType = z .object({ - function_full_name: z.string().optional(), + function_full_name: z.string(), }) .transform(d => ({ functionFullName: d.function_full_name, @@ -550,14 +550,14 @@ export const unmarshalFunctionInfoSchema: z.ZodType = z export const unmarshalFunctionParameterInfoSchema: z.ZodType = z .object({ - name: z.string().optional(), - type_text: z.string().optional(), + name: z.string(), + type_text: z.string(), type_json: z.string().optional(), - type_name: z.string().optional(), + type_name: z.string(), type_precision: z.number().optional(), type_scale: z.number().optional(), type_interval_type: z.string().optional(), - position: z.number().optional(), + position: z.number(), parameter_mode: z.string().optional(), parameter_type: z.string().optional(), parameter_default: z.string().optional(), @@ -602,7 +602,7 @@ export const unmarshalListFunctionsResponseSchema: z.ZodType = z .object({ - table_full_name: z.string().optional(), + table_full_name: z.string(), }) .transform(d => ({ tableFullName: d.table_full_name, @@ -684,7 +684,7 @@ export const marshalCreateFunctionSchema: z.ZodType = z export const marshalCreateFunctionRequestSchema: z.ZodType = z .object({ - functionInfo: z.lazy(() => marshalCreateFunctionSchema).optional(), + functionInfo: z.lazy(() => marshalCreateFunctionSchema), }) .transform(d => ({ function_info: d.functionInfo, @@ -738,7 +738,7 @@ export const marshalDependencyListSchema: z.ZodType = z export const marshalFunctionDependencySchema: z.ZodType = z .object({ - functionFullName: z.string().optional(), + functionFullName: z.string(), }) .transform(d => ({ function_full_name: d.functionFullName, @@ -746,14 +746,14 @@ export const marshalFunctionDependencySchema: z.ZodType = z export const marshalFunctionParameterInfoSchema: z.ZodType = z .object({ - name: z.string().optional(), - typeText: z.string().optional(), + name: z.string(), + typeText: z.string(), typeJson: z.string().optional(), - typeName: z.string().optional(), + typeName: z.string(), typePrecision: z.number().optional(), typeScale: z.number().optional(), typeIntervalType: z.string().optional(), - position: z.number().optional(), + position: z.number(), parameterMode: z.string().optional(), parameterType: z.string().optional(), parameterDefault: z.string().optional(), @@ -786,7 +786,7 @@ export const marshalFunctionParameterInfosSchema: z.ZodType = z export const marshalTableDependencySchema: z.ZodType = z .object({ - tableFullName: z.string().optional(), + tableFullName: z.string(), }) .transform(d => ({ table_full_name: d.tableFullName, @@ -794,7 +794,7 @@ export const marshalTableDependencySchema: z.ZodType = z export const marshalUpdateFunctionRequestSchema: z.ZodType = z .object({ - fullNameArg: z.string().optional(), + fullNameArg: z.string(), name: z.string().optional(), catalogName: z.string().optional(), schemaName: z.string().optional(), diff --git a/packages/uc/grants/src/v1/model.ts b/packages/uc/grants/src/v1/model.ts index 21f501bb7..35515f6c8 100644 --- a/packages/uc/grants/src/v1/model.ts +++ b/packages/uc/grants/src/v1/model.ts @@ -26,7 +26,7 @@ export interface EffectivePrivilegeAssignment { export interface GetEffectivePermissionsRequest { /** Type of securable. */ - securableType?: string | undefined; + securableType: string; /** Full name of securable. */ securableFullName?: string | undefined; /** If provided, only the effective permissions for the specified principal (user or group) are returned. */ @@ -61,7 +61,7 @@ export interface GetEffectivePermissionsResponse { export interface GetPermissionsRequest { /** Type of securable. */ - securableType?: string | undefined; + securableType: string; /** Full name of securable. */ securableFullName?: string | undefined; /** If provided, only the permissions for the specified principal (user or group) are returned. */ @@ -96,9 +96,9 @@ export interface GetPermissionsResponse { export interface ListEffectivePrivilegeAssignmentsRequest { /** Type of securable. */ - securableType?: string | undefined; + securableType: string; /** Full name of securable. */ - fullName?: string | undefined; + fullName: string; /** If provided, only the effective permissions for the specified principal (user or group) are returned. */ principal?: string | undefined; /** @@ -131,9 +131,9 @@ export interface ListEffectivePrivilegeAssignmentsResponse { export interface ListPrivilegeAssignmentsRequest { /** Type of securable. */ - securableType?: string | undefined; + securableType: string; /** Full name of securable. */ - fullName?: string | undefined; + fullName: string; /** If provided, only the permissions for the specified principal (user or group) are returned. */ principal?: string | undefined; /** @@ -187,7 +187,7 @@ export interface PrivilegeAssignment { export interface UpdatePermissionsRequest { /** Type of securable. */ - securableType?: string | undefined; + securableType: string; /** Full name of securable. */ securableFullName?: string | undefined; /** Optional, default false. Specifies whether all the permissions should be returned in the response. */ @@ -315,7 +315,7 @@ export const marshalPermissionsChangeSchema: z.ZodType = z export const marshalUpdatePermissionsRequestSchema: z.ZodType = z .object({ - securableType: z.string().optional(), + securableType: z.string(), securableFullName: z.string().optional(), omitPermissionsInResponse: z.boolean().optional(), changes: z.array(z.lazy(() => marshalPermissionsChangeSchema)).optional(), diff --git a/packages/uc/metastores/src/v1/model.ts b/packages/uc/metastores/src/v1/model.ts index bd26f2ddd..53c36ad53 100644 --- a/packages/uc/metastores/src/v1/model.ts +++ b/packages/uc/metastores/src/v1/model.ts @@ -24,11 +24,11 @@ export type DeltaSharingScope_Enum = /** The mapping from workspace to metastore. */ export interface AccountsCreateMetastoreAssignmentRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Workspace ID. */ workspaceId?: bigint | undefined; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; metastoreAssignment?: MetastoreAssignment | undefined; } @@ -39,7 +39,7 @@ export interface AccountsCreateMetastoreAssignmentResponse {} /** Properties of the new metastore. */ export interface AccountsCreateMetastoreRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; metastoreInfo?: CreateAccountsMetastore | undefined; } @@ -50,11 +50,11 @@ export interface AccountsCreateMetastoreResponse { /** Delete a metastore assignment to a workspace */ export interface AccountsDeleteMetastoreAssignmentRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Workspace ID. */ workspaceId?: bigint | undefined; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; } /** The metastore assignment was successfully deleted. */ @@ -64,9 +64,9 @@ export interface AccountsDeleteMetastoreAssignmentResponse {} /** Delete a metastore for the given account */ export interface AccountsDeleteMetastoreRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; /** Force deletion even if the metastore is not empty. Default is false. */ force?: boolean | undefined; } @@ -78,9 +78,9 @@ export interface AccountsDeleteMetastoreResponse {} /** Retrieves the assignment of which metastore to a given workspace */ export interface AccountsGetMetastoreAssignmentRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Workspace ID. */ - workspaceId?: bigint | undefined; + workspaceId: bigint; } /** The workspace metastore assignment was successfully returned. */ @@ -91,9 +91,9 @@ export interface AccountsGetMetastoreAssignmentResponse { /** Get a metastore for a given account */ export interface AccountsGetMetastoreRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; } /** The metastore was successfully returned. */ @@ -104,7 +104,7 @@ export interface AccountsGetMetastoreResponse { /** List the metastores for an account */ export interface AccountsListMetastoresRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; } /** Metastores were returned successfully. */ @@ -116,9 +116,9 @@ export interface AccountsListMetastoresResponse { /** Lists all workspace IDs for a given metastore */ export interface AccountsListWorkspaceIdsForMetastoreRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; } /** The metastore assignments were successfully returned. */ @@ -129,11 +129,11 @@ export interface AccountsListWorkspaceIdsForMetastoreResponse { /** The metastore assignment to update. */ export interface AccountsUpdateMetastoreAssignmentRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Workspace ID. */ workspaceId?: bigint | undefined; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; metastoreAssignment?: MetastoreAssignment | undefined; } @@ -144,9 +144,9 @@ export interface AccountsUpdateMetastoreAssignmentResponse {} /** Properties of the metastore to change. */ export interface AccountsUpdateMetastoreRequest { /** account ID of any type. For non-E2 account types, get your account ID from the [Accounts Console](https://docs.databricks.com/administration-guide/account-settings/usage.html) */ - accountId?: string | undefined; + accountId: string; /** Unity Catalog metastore ID */ - metastoreId?: string | undefined; + metastoreId: string; /** Properties of the metastore to change. */ metastoreInfo?: UpdateAccountsMetastore | undefined; } @@ -199,15 +199,15 @@ export interface CreateAccountsMetastore { export interface CreateMetastoreAssignmentRequest { /** A workspace ID. */ - workspaceId?: bigint | undefined; + workspaceId: bigint; /** The unique ID of the metastore. */ - metastoreId?: string | undefined; + metastoreId: string; /** * The name of the default catalog in the metastore. * This field is deprecated. Please use "Default Namespace API" to * configure the default catalog for a workspace. */ - defaultCatalogName?: string | undefined; + defaultCatalogName: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -256,9 +256,9 @@ export interface CreateMetastoreRequest { export interface DeleteMetastoreAssignmentRequest { /** A workspace ID. */ - workspaceId?: bigint | undefined; + workspaceId: bigint; /** Query for the ID of the metastore to delete. */ - metastoreId?: string | undefined; + metastoreId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -266,7 +266,7 @@ export interface DeleteMetastoreAssignmentResponse {} export interface DeleteMetastoreRequest { /** Unique ID of the metastore. */ - id?: string | undefined; + id: string; /** Force deletion even if the metastore is not empty. Default is false. */ force?: boolean | undefined; } @@ -282,7 +282,7 @@ export interface GetCurrentMetastoreAssignmentRequest {} export interface GetMetastoreRequest { /** Unique ID of the metastore. */ - id?: string | undefined; + id: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -356,9 +356,9 @@ export interface ListMetastoresResponse { export interface MetastoreAssignment { /** The unique ID of the workspace. */ - workspaceId?: bigint | undefined; + workspaceId: bigint; /** The unique ID of the metastore. */ - metastoreId?: string | undefined; + metastoreId: string; /** * The name of the default catalog in the metastore. This field is deprecated. * Please use "Default Namespace API" to configure the default catalog for a workspace. @@ -450,7 +450,7 @@ export interface UpdateAccountsMetastore { export interface UpdateMetastoreAssignmentRequest { /** A workspace ID. */ - workspaceId?: bigint | undefined; + workspaceId: bigint; /** The unique ID of the metastore. */ metastoreId?: string | undefined; /** @@ -466,7 +466,7 @@ export interface UpdateMetastoreAssignmentResponse {} export interface UpdateMetastoreRequest { /** Unique ID of the metastore. */ - id?: string | undefined; + id: string; /** New name for the metastore. */ newName?: string | undefined; /** The user-specified name of the metastore. */ @@ -667,9 +667,8 @@ export const unmarshalMetastoreAssignmentSchema: z.ZodType .object({ workspace_id: z .union([z.number(), z.bigint(), z.string()]) - .transform(v => BigInt(v)) - .optional(), - metastore_id: z.string().optional(), + .transform(v => BigInt(v)), + metastore_id: z.string(), default_catalog_name: z.string().optional(), }) .transform(d => ({ @@ -738,9 +737,9 @@ export const unmarshalUpdateMetastoreAssignmentResponseSchema: z.ZodType marshalMetastoreAssignmentSchema) .optional(), @@ -754,7 +753,7 @@ export const marshalAccountsCreateMetastoreAssignmentRequestSchema: z.ZodType = export const marshalAccountsCreateMetastoreRequestSchema: z.ZodType = z .object({ - accountId: z.string().optional(), + accountId: z.string(), metastoreInfo: z .lazy(() => marshalCreateAccountsMetastoreSchema) .optional(), @@ -767,9 +766,9 @@ export const marshalAccountsCreateMetastoreRequestSchema: z.ZodType = z export const marshalAccountsUpdateMetastoreAssignmentRequestSchema: z.ZodType = z .object({ - accountId: z.string().optional(), + accountId: z.string(), workspaceId: z.bigint().optional(), - metastoreId: z.string().optional(), + metastoreId: z.string(), metastoreAssignment: z .lazy(() => marshalMetastoreAssignmentSchema) .optional(), @@ -783,8 +782,8 @@ export const marshalAccountsUpdateMetastoreAssignmentRequestSchema: z.ZodType = export const marshalAccountsUpdateMetastoreRequestSchema: z.ZodType = z .object({ - accountId: z.string().optional(), - metastoreId: z.string().optional(), + accountId: z.string(), + metastoreId: z.string(), metastoreInfo: z .lazy(() => marshalUpdateAccountsMetastoreSchema) .optional(), @@ -842,9 +841,9 @@ export const marshalCreateAccountsMetastoreSchema: z.ZodType = z export const marshalCreateMetastoreAssignmentRequestSchema: z.ZodType = z .object({ - workspaceId: z.bigint().optional(), - metastoreId: z.string().optional(), - defaultCatalogName: z.string().optional(), + workspaceId: z.bigint(), + metastoreId: z.string(), + defaultCatalogName: z.string(), }) .transform(d => ({ workspace_id: d.workspaceId, @@ -899,8 +898,8 @@ export const marshalCreateMetastoreRequestSchema: z.ZodType = z export const marshalMetastoreAssignmentSchema: z.ZodType = z .object({ - workspaceId: z.bigint().optional(), - metastoreId: z.string().optional(), + workspaceId: z.bigint(), + metastoreId: z.string(), defaultCatalogName: z.string().optional(), }) .transform(d => ({ @@ -956,7 +955,7 @@ export const marshalUpdateAccountsMetastoreSchema: z.ZodType = z export const marshalUpdateMetastoreAssignmentRequestSchema: z.ZodType = z .object({ - workspaceId: z.bigint().optional(), + workspaceId: z.bigint(), metastoreId: z.string().optional(), defaultCatalogName: z.string().optional(), }) @@ -968,7 +967,7 @@ export const marshalUpdateMetastoreAssignmentRequestSchema: z.ZodType = z export const marshalUpdateMetastoreRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), newName: z.string().optional(), name: z.string().optional(), storageRoot: z.string().optional(), diff --git a/packages/uc/registeredmodels/src/v1/model.ts b/packages/uc/registeredmodels/src/v1/model.ts index 2bd64e0cd..01653bf39 100644 --- a/packages/uc/registeredmodels/src/v1/model.ts +++ b/packages/uc/registeredmodels/src/v1/model.ts @@ -61,9 +61,9 @@ export interface CredentialDependency { export interface DeleteModelVersionRequest { /** The three-level (fully qualified) name of the model version */ - fullNameArg?: string | undefined; + fullNameArg: string; /** The integer version number of the model version */ - versionArg?: bigint | undefined; + versionArg: bigint; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -71,9 +71,9 @@ export interface DeleteModelVersionResponse {} export interface DeleteRegisteredModelAliasRequest { /** The three-level (fully qualified) name of the registered model */ - fullNameArg?: string | undefined; + fullNameArg: string; /** The name of the alias */ - aliasArg?: string | undefined; + aliasArg: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -81,7 +81,7 @@ export interface DeleteRegisteredModelAliasResponse {} export interface DeleteRegisteredModelRequest { /** The three-level (fully qualified) name of the registered model */ - fullNameArg?: string | undefined; + fullNameArg: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -109,23 +109,23 @@ export interface DependencyList { /** A function that is dependent on a SQL object. */ export interface FunctionDependency { /** Full name of the dependent function, in the form of __catalog_name__.__schema_name__.__function_name__. */ - functionFullName?: string | undefined; + functionFullName: string; } export interface GetModelVersionByAliasRequest { /** The three-level (fully qualified) name of the registered model */ - fullNameArg?: string | undefined; + fullNameArg: string; /** The name of the alias */ - aliasArg?: string | undefined; + aliasArg: string; /** Whether to include aliases associated with the model version in the response */ includeAliases?: boolean | undefined; } export interface GetModelVersionRequest { /** The three-level (fully qualified) name of the model version */ - fullNameArg?: string | undefined; + fullNameArg: string; /** The integer version number of the model version */ - versionArg?: bigint | undefined; + versionArg: bigint; /** Whether to include aliases associated with the model version in the response */ includeAliases?: boolean | undefined; /** Whether to include model versions in the response for which the principal can only access selective metadata for */ @@ -134,7 +134,7 @@ export interface GetModelVersionRequest { export interface GetRegisteredModelRequest { /** The three-level (fully qualified) name of the registered model */ - fullNameArg?: string | undefined; + fullNameArg: string; /** Whether to include registered model aliases in the response */ includeAliases?: boolean | undefined; /** Whether to include registered models in the response for which the principal can only access selective metadata for */ @@ -143,7 +143,7 @@ export interface GetRegisteredModelRequest { export interface ListModelVersionsRequest { /** The full three-level name of the registered model under which to list model versions */ - fullNameArg?: string | undefined; + fullNameArg: string; /** * Maximum number of model versions to return. * If not set, the page length is set to a server configured value (100, as of 1/3/2024). @@ -305,24 +305,24 @@ export interface RegisteredModelInfo { export interface SetRegisteredModelAliasRequest { /** The three-level (fully qualified) name of the registered model */ - fullNameArg?: string | undefined; + fullNameArg: string; /** The name of the alias */ - aliasArg?: string | undefined; + aliasArg: string; /** The version number of the model version to which the alias points */ - versionNum?: bigint | undefined; + versionNum: bigint; } /** A table that is dependent on a SQL object. */ export interface TableDependency { /** Full name of the dependent table, in the form of __catalog_name__.__schema_name__.__table_name__. */ - tableFullName?: string | undefined; + tableFullName: string; } export interface UpdateModelVersionRequest { /** The three-level (fully qualified) name of the model version */ - fullNameArg?: string | undefined; + fullNameArg: string; /** The integer version number of the model version */ - versionArg?: bigint | undefined; + versionArg: bigint; /** The name of the parent registered model of the model version, relative to parent schema */ modelName?: string | undefined; /** The name of the catalog containing the model version */ @@ -372,7 +372,7 @@ export interface UpdateModelVersionRequest { export interface UpdateRegisteredModelRequest { /** The three-level (fully qualified) name of the registered model */ - fullNameArg?: string | undefined; + fullNameArg: string; /** New name for the registered model. */ newName?: string | undefined; /** The name of the registered model */ @@ -463,7 +463,7 @@ export const unmarshalDependencyListSchema: z.ZodType = z export const unmarshalFunctionDependencySchema: z.ZodType = z .object({ - function_full_name: z.string().optional(), + function_full_name: z.string(), }) .transform(d => ({ functionFullName: d.function_full_name, @@ -620,7 +620,7 @@ export const unmarshalRegisteredModelInfoSchema: z.ZodType export const unmarshalTableDependencySchema: z.ZodType = z .object({ - table_full_name: z.string().optional(), + table_full_name: z.string(), }) .transform(d => ({ tableFullName: d.table_full_name, @@ -718,7 +718,7 @@ export const marshalDependencyListSchema: z.ZodType = z export const marshalFunctionDependencySchema: z.ZodType = z .object({ - functionFullName: z.string().optional(), + functionFullName: z.string(), }) .transform(d => ({ function_full_name: d.functionFullName, @@ -744,9 +744,9 @@ export const marshalRegisteredModelAliasInfoSchema: z.ZodType = z export const marshalSetRegisteredModelAliasRequestSchema: z.ZodType = z .object({ - fullNameArg: z.string().optional(), - aliasArg: z.string().optional(), - versionNum: z.bigint().optional(), + fullNameArg: z.string(), + aliasArg: z.string(), + versionNum: z.bigint(), }) .transform(d => ({ full_name_arg: d.fullNameArg, @@ -756,7 +756,7 @@ export const marshalSetRegisteredModelAliasRequestSchema: z.ZodType = z export const marshalTableDependencySchema: z.ZodType = z .object({ - tableFullName: z.string().optional(), + tableFullName: z.string(), }) .transform(d => ({ table_full_name: d.tableFullName, @@ -764,8 +764,8 @@ export const marshalTableDependencySchema: z.ZodType = z export const marshalUpdateModelVersionRequestSchema: z.ZodType = z .object({ - fullNameArg: z.string().optional(), - versionArg: z.bigint().optional(), + fullNameArg: z.string(), + versionArg: z.bigint(), modelName: z.string().optional(), catalogName: z.string().optional(), schemaName: z.string().optional(), @@ -814,7 +814,7 @@ export const marshalUpdateModelVersionRequestSchema: z.ZodType = z export const marshalUpdateRegisteredModelRequestSchema: z.ZodType = z .object({ - fullNameArg: z.string().optional(), + fullNameArg: z.string(), newName: z.string().optional(), name: z.string().optional(), catalogName: z.string().optional(), diff --git a/packages/uc/resourcequotas/src/v1/model.ts b/packages/uc/resourcequotas/src/v1/model.ts index 9b70dcb78..34c9127c0 100644 --- a/packages/uc/resourcequotas/src/v1/model.ts +++ b/packages/uc/resourcequotas/src/v1/model.ts @@ -23,6 +23,10 @@ export const SecurableType = { EXTERNAL_METADATA: 'EXTERNAL_METADATA', /** TODO: [UC-2980] Staging tables aren't full-fleged securables yet. */ STAGING_TABLE: 'STAGING_TABLE', + MODEL: 'MODEL', + MODEL_SERVICE: 'MODEL_SERVICE', + MCP_SERVICE: 'MCP_SERVICE', + MODEL_PROVIDER_SERVICE: 'MODEL_PROVIDER_SERVICE', } as const; export type SecurableType = | (typeof SecurableType)[keyof typeof SecurableType] @@ -30,11 +34,11 @@ export type SecurableType = export interface GetQuotaRequest { /** Securable type of the quota parent. */ - parentSecurableType?: string | undefined; + parentSecurableType: string; /** Full name of the parent resource. Provide the metastore ID if the parent is a metastore. */ - parentFullName?: string | undefined; + parentFullName: string; /** Name of the quota. Follows the pattern of the quota type, with "-quota" added as a suffix. */ - quotaName?: string | undefined; + quotaName: string; } export interface GetQuotaResponse { diff --git a/packages/uc/rfa/src/v1/model.ts b/packages/uc/rfa/src/v1/model.ts index 9e52e5f0c..e012167e5 100644 --- a/packages/uc/rfa/src/v1/model.ts +++ b/packages/uc/rfa/src/v1/model.ts @@ -49,6 +49,10 @@ export const SecurableType = { EXTERNAL_METADATA: 'EXTERNAL_METADATA', /** TODO: [UC-2980] Staging tables aren't full-fleged securables yet. */ STAGING_TABLE: 'STAGING_TABLE', + MODEL: 'MODEL', + MODEL_SERVICE: 'MODEL_SERVICE', + MCP_SERVICE: 'MCP_SERVICE', + MODEL_PROVIDER_SERVICE: 'MODEL_PROVIDER_SERVICE', } as const; export type SecurableType = | (typeof SecurableType)[keyof typeof SecurableType] @@ -78,7 +82,7 @@ export interface AccessRequestDestinations { /** The access request destinations for the securable. */ destinations?: NotificationDestination[] | undefined; /** The securable for which the access request destinations are being modified or read. */ - securable?: Securable | undefined; + securable: Securable; /** * Indicates whether any destinations are hidden from the caller due to a lack of permissions. * This value is true if the caller does not have permission to see all destinations. @@ -205,8 +209,8 @@ export interface UpdateAccessRequestDestinationsRequest { * The access request destinations to assign to the securable. * For each destination, a **destination_id** and **destination_type** must be defined. */ - accessRequestDestinations?: AccessRequestDestinations | undefined; - updateMask?: FieldMask | undefined; + accessRequestDestinations: AccessRequestDestinations; + updateMask: FieldMask; } export const unmarshalAccessRequestDestinationsSchema: z.ZodType = @@ -215,7 +219,7 @@ export const unmarshalAccessRequestDestinationsSchema: z.ZodType unmarshalNotificationDestinationSchema)) .optional(), - securable: z.lazy(() => unmarshalSecurableSchema).optional(), + securable: z.lazy(() => unmarshalSecurableSchema), are_any_destinations_hidden: z.boolean().optional(), destination_source_securable: z .lazy(() => unmarshalSecurableSchema) @@ -296,7 +300,7 @@ export const marshalAccessRequestDestinationsSchema: z.ZodType = z destinations: z .array(z.lazy(() => marshalNotificationDestinationSchema)) .optional(), - securable: z.lazy(() => marshalSecurableSchema).optional(), + securable: z.lazy(() => marshalSecurableSchema), areAnyDestinationsHidden: z.boolean().optional(), destinationSourceSecurable: z.lazy(() => marshalSecurableSchema).optional(), securableType: z.string().optional(), diff --git a/packages/uc/schemas/src/v1/model.ts b/packages/uc/schemas/src/v1/model.ts index 9113f0ccf..1d0e2caf0 100644 --- a/packages/uc/schemas/src/v1/model.ts +++ b/packages/uc/schemas/src/v1/model.ts @@ -18,9 +18,9 @@ export type CatalogType = export interface CreateSchemaRequest { /** Name of schema, relative to parent catalog. */ - name?: string | undefined; + name: string; /** Name of parent catalog. */ - catalogName?: string | undefined; + catalogName: string; /** Username of current owner of schema. */ owner?: string | undefined; /** User-provided free-form text description. */ @@ -55,14 +55,14 @@ export interface CreateSchemaRequest { /** Custom maximum retention period in hours for the schema. */ customMaxRetentionHours?: bigint | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; /** A map of key-value properties attached to the securable. */ options?: Record | undefined; } export interface DeleteSchemaRequest { /** Full name of the schema. */ - fullNameArg?: string | undefined; + fullNameArg: string; /** Force deletion even if the schema is not empty. */ force?: boolean | undefined; } @@ -72,7 +72,7 @@ export interface DeleteSchemaResponse {} export interface EffectivePredictiveOptimizationFlag { /** Whether predictive optimization should be enabled for this object and objects under it. */ - value?: string | undefined; + value: string; /** The type of the object from which the flag was inherited. If there was no inheritance, this field is left blank. */ inheritedFromType?: string | undefined; /** The name of the object from which the flag was inherited. If there was no inheritance, this field is left blank. */ @@ -81,14 +81,14 @@ export interface EffectivePredictiveOptimizationFlag { export interface GetSchemaRequest { /** Full name of the schema. */ - fullNameArg?: string | undefined; + fullNameArg: string; /** Whether to include schemas in the response for which the principal can only access selective metadata for */ includeBrowse?: boolean | undefined; } export interface ListSchemasRequest { /** Parent catalog for schemas of interest. */ - catalogName?: string | undefined; + catalogName: string; /** * Maximum number of schemas to return. * If not set, all the schemas are returned (not recommended). @@ -115,9 +115,9 @@ export interface ListSchemasResponse { export interface SchemaInfo { /** Name of schema, relative to parent catalog. */ - name?: string | undefined; + name: string; /** Name of parent catalog. */ - catalogName?: string | undefined; + catalogName: string; /** Username of current owner of schema. */ owner?: string | undefined; /** User-provided free-form text description. */ @@ -152,20 +152,20 @@ export interface SchemaInfo { /** Custom maximum retention period in hours for the schema. */ customMaxRetentionHours?: bigint | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; /** A map of key-value properties attached to the securable. */ options?: Record | undefined; } export interface UpdateSchemaRequest { /** Full name of the schema. */ - fullNameArg?: string | undefined; + fullNameArg: string; /** New name for the schema. */ newName?: string | undefined; /** Name of schema, relative to parent catalog. */ - name?: string | undefined; + name: string; /** Name of parent catalog. */ - catalogName?: string | undefined; + catalogName: string; /** Username of current owner of schema. */ owner?: string | undefined; /** User-provided free-form text description. */ @@ -200,7 +200,7 @@ export interface UpdateSchemaRequest { /** Custom maximum retention period in hours for the schema. */ customMaxRetentionHours?: bigint | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; /** A map of key-value properties attached to the securable. */ options?: Record | undefined; } @@ -211,7 +211,7 @@ export const unmarshalDeleteSchemaResponseSchema: z.ZodType = z .object({ - value: z.string().optional(), + value: z.string(), inherited_from_type: z.string().optional(), inherited_from_name: z.string().optional(), }) @@ -234,8 +234,8 @@ export const unmarshalListSchemasResponseSchema: z.ZodType export const unmarshalSchemaInfoSchema: z.ZodType = z .object({ - name: z.string().optional(), - catalog_name: z.string().optional(), + name: z.string(), + catalog_name: z.string(), owner: z.string().optional(), comment: z.string().optional(), storage_root: z.string().optional(), @@ -263,7 +263,7 @@ export const unmarshalSchemaInfoSchema: z.ZodType = z .union([z.number(), z.bigint(), z.string()]) .transform(v => BigInt(v)) .optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), options: z.record(z.string(), z.string()).optional(), }) .transform(d => ({ @@ -292,8 +292,8 @@ export const unmarshalSchemaInfoSchema: z.ZodType = z export const marshalCreateSchemaRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - catalogName: z.string().optional(), + name: z.string(), + catalogName: z.string(), owner: z.string().optional(), comment: z.string().optional(), storageRoot: z.string().optional(), @@ -312,7 +312,7 @@ export const marshalCreateSchemaRequestSchema: z.ZodType = z schemaId: z.string().optional(), browseOnly: z.boolean().optional(), customMaxRetentionHours: z.bigint().optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), options: z.record(z.string(), z.string()).optional(), }) .transform(d => ({ @@ -341,7 +341,7 @@ export const marshalCreateSchemaRequestSchema: z.ZodType = z export const marshalEffectivePredictiveOptimizationFlagSchema: z.ZodType = z .object({ - value: z.string().optional(), + value: z.string(), inheritedFromType: z.string().optional(), inheritedFromName: z.string().optional(), }) @@ -353,10 +353,10 @@ export const marshalEffectivePredictiveOptimizationFlagSchema: z.ZodType = z export const marshalUpdateSchemaRequestSchema: z.ZodType = z .object({ - fullNameArg: z.string().optional(), + fullNameArg: z.string(), newName: z.string().optional(), - name: z.string().optional(), - catalogName: z.string().optional(), + name: z.string(), + catalogName: z.string(), owner: z.string().optional(), comment: z.string().optional(), storageRoot: z.string().optional(), @@ -375,7 +375,7 @@ export const marshalUpdateSchemaRequestSchema: z.ZodType = z schemaId: z.string().optional(), browseOnly: z.boolean().optional(), customMaxRetentionHours: z.bigint().optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), options: z.record(z.string(), z.string()).optional(), }) .transform(d => ({ diff --git a/packages/uc/secrets/src/v1/model.ts b/packages/uc/secrets/src/v1/model.ts index 13b9687ef..665763267 100644 --- a/packages/uc/secrets/src/v1/model.ts +++ b/packages/uc/secrets/src/v1/model.ts @@ -11,7 +11,7 @@ export interface CreateSecretRequest { * The secret object to create. The **name**, **catalog_name**, **schema_name**, and **value** * fields are required. */ - secret?: Secret | undefined; + secret: Secret; } /** Request message for DeleteSecret. */ @@ -20,7 +20,7 @@ export interface DeleteSecretRequest { * The three-level (fully qualified) name of the secret * (for example, **catalog_name.schema_name.secret_name**). */ - fullName?: string | undefined; + fullName: string; } /** Request message for GetSecret. */ @@ -29,7 +29,7 @@ export interface GetSecretRequest { * The three-level (fully qualified) name of the secret * (for example, **catalog_name.schema_name.secret_name**). */ - fullName?: string | undefined; + fullName: string; /** * Whether to include the secret value in the response. Defaults to false. Requires the * **READ_SECRET** privilege. @@ -83,7 +83,7 @@ export interface ListSecretsResponse { */ export interface Secret { /** The name of the secret, relative to its parent schema. */ - name?: string | undefined; + name: string; /** * The owner of the secret. Defaults to the creating principal on creation. Can be updated to * transfer ownership of the secret to another principal. @@ -109,16 +109,16 @@ export interface Secret { /** The three-level (fully qualified) name of the secret, in the form of **catalog_name.schema_name.secret_name**. */ fullName?: string | undefined; /** The name of the catalog where the schema and the secret reside. */ - catalogName?: string | undefined; + catalogName: string; /** The name of the schema where the secret resides. */ - schemaName?: string | undefined; + schemaName: string; /** * The secret value to store. This field is input-only and is not returned in responses — use * the **effective_value** field (via GetSecret with **include_value** set to true) to read the * secret value. The maximum size is 60 KiB (pre-encryption). Accepted content includes * passwords, tokens, keys, and other sensitive credential data. */ - value?: string | undefined; + value: string; /** * The secret value. Only populated in responses when you have the **READ_SECRET** * privilege and **include_value** is set to true in the request. The maximum size is 60 KiB. @@ -138,12 +138,12 @@ export interface UpdateSecretRequest { * The three-level (fully qualified) name of the secret * (for example, **catalog_name.schema_name.secret_name**). */ - fullName?: string | undefined; + fullName: string; /** * The secret object containing the fields to update. Only fields specified in **update_mask** * will be updated. */ - secret?: Secret | undefined; + secret: Secret; /** * The field mask specifying which fields of the secret to update. * - If **update_mask** is **"*"**, all fields specified in **secret** are updated. @@ -152,7 +152,7 @@ export interface UpdateSecretRequest { * Supported fields: **value**, **comment**, **owner**, **expire_time**. To change the secret * name, delete and recreate the secret. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; } export const unmarshalListSecretsResponseSchema: z.ZodType = @@ -168,7 +168,7 @@ export const unmarshalListSecretsResponseSchema: z.ZodType export const unmarshalSecretSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), owner: z.string().optional(), effective_owner: z.string().optional(), metastore_id: z.string().optional(), @@ -184,9 +184,9 @@ export const unmarshalSecretSchema: z.ZodType = z updated_by: z.string().optional(), comment: z.string().optional(), full_name: z.string().optional(), - catalog_name: z.string().optional(), - schema_name: z.string().optional(), - value: z.string().optional(), + catalog_name: z.string(), + schema_name: z.string(), + value: z.string(), effective_value: z.string().optional(), expire_time: z .string() @@ -213,7 +213,7 @@ export const unmarshalSecretSchema: z.ZodType = z export const marshalSecretSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), owner: z.string().optional(), effectiveOwner: z.string().optional(), metastoreId: z.string().optional(), @@ -229,9 +229,9 @@ export const marshalSecretSchema: z.ZodType = z updatedBy: z.string().optional(), comment: z.string().optional(), fullName: z.string().optional(), - catalogName: z.string().optional(), - schemaName: z.string().optional(), - value: z.string().optional(), + catalogName: z.string(), + schemaName: z.string(), + value: z.string(), effectiveValue: z.string().optional(), expireTime: z .any() diff --git a/packages/uc/systemschemas/src/v1/model.ts b/packages/uc/systemschemas/src/v1/model.ts index 14abcd155..5baebe976 100644 --- a/packages/uc/systemschemas/src/v1/model.ts +++ b/packages/uc/systemschemas/src/v1/model.ts @@ -4,9 +4,9 @@ import {z} from 'zod'; export interface DisableSystemSchemaRequest { /** Full name of the system schema. */ - schema?: string | undefined; + schema: string; /** The metastore ID under which the system schema lives. */ - metastoreId?: string | undefined; + metastoreId: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -14,9 +14,9 @@ export interface DisableSystemSchemaResponse {} export interface EnableSystemSchemaRequest { /** Full name of the system schema. */ - schema?: string | undefined; + schema: string; /** The metastore ID under which the system schema lives. */ - metastoreId?: string | undefined; + metastoreId: string; /** the catalog for which the system schema is to enabled in */ catalogName?: string | undefined; } @@ -26,7 +26,7 @@ export interface EnableSystemSchemaResponse {} export interface ListSystemSchemasRequest { /** The ID for the metastore in which the system schema resides. */ - metastoreId?: string | undefined; + metastoreId: string; /** * Maximum number of schemas to return. * - When set to 0, the page length is set to a server configured value (recommended); @@ -90,8 +90,8 @@ export const unmarshalSystemSchemaInfoSchema: z.ZodType = z export const marshalEnableSystemSchemaRequestSchema: z.ZodType = z .object({ - schema: z.string().optional(), - metastoreId: z.string().optional(), + schema: z.string(), + metastoreId: z.string(), catalogName: z.string().optional(), }) .transform(d => ({ diff --git a/packages/uc/tables/src/v1/model.ts b/packages/uc/tables/src/v1/model.ts index a70bd46d3..112afdc06 100644 --- a/packages/uc/tables/src/v1/model.ts +++ b/packages/uc/tables/src/v1/model.ts @@ -206,6 +206,10 @@ export const SecurableType = { EXTERNAL_METADATA: 'EXTERNAL_METADATA', /** TODO: [UC-2980] Staging tables aren't full-fleged securables yet. */ STAGING_TABLE: 'STAGING_TABLE', + MODEL: 'MODEL', + MODEL_SERVICE: 'MODEL_SERVICE', + MCP_SERVICE: 'MCP_SERVICE', + MODEL_PROVIDER_SERVICE: 'MODEL_PROVIDER_SERVICE', } as const; export type SecurableType = | (typeof SecurableType)[keyof typeof SecurableType] @@ -312,9 +316,9 @@ export interface ColumnMask { */ usingColumnNames?: string[] | undefined; /** - * The list of additional table columns or literals to be passed as additional arguments to - * a column mask function. This is the replacement of the deprecated using_column_names field and - * carries information about the types (alias or constant) of the arguments to the mask function. + * The list of table columns or literals to be passed as additional arguments to a column mask + * function, carrying the type (column reference vs constant literal) of each argument. + * Deprecated: use using_column_names instead. */ usingArguments?: PolicyFunctionArgument[] | undefined; } @@ -327,8 +331,8 @@ export interface ConnectionDependency { export interface CreateTableConstraintRequest { /** The full name of the table referenced by the constraint. */ - fullNameArg?: string | undefined; - constraint?: TableConstraint | undefined; + fullNameArg: string; + constraint: TableConstraint; } export interface CreateTableRequest { @@ -399,7 +403,7 @@ export interface CreateTableRequest { /** The array of __ColumnInfo__ definitions of the table's columns. */ columns?: ColumnInfo[] | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; } /** A credential that is dependent on a SQL object. */ @@ -410,14 +414,14 @@ export interface CredentialDependency { export interface DeleteTableConstraintRequest { /** Full name of the table referenced by the constraint. */ - fullNameArg?: string | undefined; + fullNameArg: string; /** The name of the constraint to delete. */ - constraintName?: string | undefined; + constraintName: string; /** * If true, try deleting all child constraints of the current constraint. * If false, reject this operation if the current constraint has any child constraints. */ - cascade?: boolean | undefined; + cascade: boolean; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -425,7 +429,7 @@ export interface DeleteTableConstraintResponse {} export interface DeleteTableRequest { /** Full name of the table. */ - fullNameArg?: string | undefined; + fullNameArg: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -437,7 +441,7 @@ export interface DeleteTableResponse {} */ export interface DeltaRuntimePropertiesKvPairs { /** A map of key-value properties attached to the securable. */ - deltaRuntimeProperties?: Record | undefined; + deltaRuntimeProperties: Record; } /** @@ -461,7 +465,7 @@ export interface DependencyList { export interface EffectivePredictiveOptimizationFlag { /** Whether predictive optimization should be enabled for this object and objects under it. */ - value?: string | undefined; + value: string; /** The type of the object from which the flag was inherited. If there was no inheritance, this field is left blank. */ inheritedFromType?: string | undefined; /** The name of the object from which the flag was inherited. If there was no inheritance, this field is left blank. */ @@ -481,13 +485,13 @@ export interface EncryptionDetails { export interface ForeignKeyConstraint { /** The name of the constraint. */ - name?: string | undefined; + name: string; /** Column names for this constraint. */ - childColumns?: string[] | undefined; + childColumns: string[]; /** The full name of the parent constraint. */ - parentTable?: string | undefined; + parentTable: string; /** Column names for this constraint. */ - parentColumns?: string[] | undefined; + parentColumns: string[]; /** True if the constraint is RELY, false or unset if NORELY. */ rely?: boolean | undefined; } @@ -495,12 +499,12 @@ export interface ForeignKeyConstraint { /** A function that is dependent on a SQL object. */ export interface FunctionDependency { /** Full name of the dependent function, in the form of __catalog_name__.__schema_name__.__function_name__. */ - functionFullName?: string | undefined; + functionFullName: string; } export interface GetTableRequest { /** Full name of the table. */ - fullNameArg?: string | undefined; + fullNameArg: string; /** Whether delta metadata should be included in the response. */ includeDeltaMetadata?: boolean | undefined; /** Whether to include tables in the response for which the principal can only access selective metadata for. */ @@ -511,7 +515,7 @@ export interface GetTableRequest { export interface ListTableSummariesRequest { /** Name of parent catalog for tables of interest. */ - catalogName?: string | undefined; + catalogName: string; /** * A sql LIKE pattern (% and _) for schema names. * All schemas will be returned if not set or empty. @@ -548,9 +552,9 @@ export interface ListTableSummariesResponse { export interface ListTablesRequest { /** Name of parent catalog for tables of interest. */ - catalogName?: string | undefined; + catalogName: string; /** Parent schema of tables. */ - schemaName?: string | undefined; + schemaName: string; /** * Maximum number of tables to return. * If not set, all the tables are returned (not recommended). @@ -585,7 +589,7 @@ export interface ListTablesResponse { export interface NamedTableConstraint { /** The name of the constraint. */ - name?: string | undefined; + name: string; } /** @@ -652,9 +656,9 @@ export interface PolicyFunctionArgument { export interface PrimaryKeyConstraint { /** The name of the constraint. */ - name?: string | undefined; + name: string; /** Column names for this constraint. */ - childColumns?: string[] | undefined; + childColumns: string[]; /** Column names that represent a timeseries. */ timeseriesColumns?: string[] | undefined; /** True if the constraint is RELY, false or unset if NORELY. */ @@ -663,16 +667,16 @@ export interface PrimaryKeyConstraint { export interface RowFilter { /** The full name of the row filter SQL UDF. */ - functionName?: string | undefined; + functionName: string; /** * The list of table columns to be passed as input to the row filter function. The column types * should match the types of the filter function arguments. */ - inputColumnNames?: string[] | undefined; + inputColumnNames: string[]; /** - * The list of additional table columns or literals to be passed as additional arguments to - * a row filter function. This is the replacement of the deprecated input_column_names field and - * carries information about the types (alias or constant) of the arguments to the filter function. + * The list of table columns or literals to be passed as additional arguments to a row filter + * function, carrying the type (column reference vs constant literal) of each argument. + * Deprecated: use input_column_names instead. */ inputArguments?: PolicyFunctionArgument[] | undefined; } @@ -726,12 +730,12 @@ export interface TableConstraint { /** A table that is dependent on a SQL object. */ export interface TableDependency { /** Full name of the dependent table, in the form of __catalog_name__.__schema_name__.__table_name__. */ - tableFullName?: string | undefined; + tableFullName: string; } export interface TableExistsRequest { /** Full name of the table. */ - fullNameArg?: string | undefined; + fullNameArg: string; } export interface TableExistsResponse { @@ -807,7 +811,7 @@ export interface TableInfo { /** The array of __ColumnInfo__ definitions of the table's columns. */ columns?: ColumnInfo[] | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; } export interface TableSummary { @@ -820,7 +824,7 @@ export interface TableSummary { export interface UpdateTableRequest { /** Full name of the table. */ - fullNameArg?: string | undefined; + fullNameArg: string; /** Name of table, relative to parent schema. */ name?: string | undefined; /** Name of parent catalog. */ @@ -888,7 +892,7 @@ export interface UpdateTableRequest { /** The array of __ColumnInfo__ definitions of the table's columns. */ columns?: ColumnInfo[] | undefined; /** A map of key-value properties attached to the securable. */ - properties?: Record | undefined; + properties: Record; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -965,7 +969,7 @@ export const unmarshalDeleteTableResponseSchema: z.ZodType export const unmarshalDeltaRuntimePropertiesKvPairsSchema: z.ZodType = z .object({ - delta_runtime_properties: z.record(z.string(), z.string()).optional(), + delta_runtime_properties: z.record(z.string(), z.string()), }) .transform(d => ({ deltaRuntimeProperties: d.delta_runtime_properties, @@ -1002,7 +1006,7 @@ export const unmarshalDependencyListSchema: z.ZodType = z export const unmarshalEffectivePredictiveOptimizationFlagSchema: z.ZodType = z .object({ - value: z.string().optional(), + value: z.string(), inherited_from_type: z.string().optional(), inherited_from_name: z.string().optional(), }) @@ -1031,10 +1035,10 @@ export const unmarshalEncryptionDetailsSchema: z.ZodType = z export const unmarshalForeignKeyConstraintSchema: z.ZodType = z .object({ - name: z.string().optional(), - child_columns: z.array(z.string()).optional(), - parent_table: z.string().optional(), - parent_columns: z.array(z.string()).optional(), + name: z.string(), + child_columns: z.array(z.string()), + parent_table: z.string(), + parent_columns: z.array(z.string()), rely: z.boolean().optional(), }) .transform(d => ({ @@ -1048,7 +1052,7 @@ export const unmarshalForeignKeyConstraintSchema: z.ZodType = z .object({ - function_full_name: z.string().optional(), + function_full_name: z.string(), }) .transform(d => ({ functionFullName: d.function_full_name, @@ -1079,7 +1083,7 @@ export const unmarshalListTablesResponseSchema: z.ZodType = export const unmarshalNamedTableConstraintSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -1137,8 +1141,8 @@ export const unmarshalPolicyFunctionArgumentSchema: z.ZodType = z .object({ - name: z.string().optional(), - child_columns: z.array(z.string()).optional(), + name: z.string(), + child_columns: z.array(z.string()), timeseries_columns: z.array(z.string()).optional(), rely: z.boolean().optional(), }) @@ -1151,8 +1155,8 @@ export const unmarshalPrimaryKeyConstraintSchema: z.ZodType = z .object({ - function_name: z.string().optional(), - input_column_names: z.array(z.string()).optional(), + function_name: z.string(), + input_column_names: z.array(z.string()), input_arguments: z .array(z.lazy(() => unmarshalPolicyFunctionArgumentSchema)) .optional(), @@ -1225,7 +1229,7 @@ export const unmarshalTableConstraintSchema: z.ZodType = z export const unmarshalTableDependencySchema: z.ZodType = z .object({ - table_full_name: z.string().optional(), + table_full_name: z.string(), }) .transform(d => ({ tableFullName: d.table_full_name, @@ -1293,7 +1297,7 @@ export const unmarshalTableInfoSchema: z.ZodType = z .lazy(() => unmarshalSecurableKindManifestSchema) .optional(), columns: z.array(z.lazy(() => unmarshalColumnInfoSchema)).optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), }) .transform(d => ({ name: d.name, @@ -1403,8 +1407,8 @@ export const marshalConnectionDependencySchema: z.ZodType = z export const marshalCreateTableConstraintRequestSchema: z.ZodType = z .object({ - fullNameArg: z.string().optional(), - constraint: z.lazy(() => marshalTableConstraintSchema).optional(), + fullNameArg: z.string(), + constraint: z.lazy(() => marshalTableConstraintSchema), }) .transform(d => ({ full_name_arg: d.fullNameArg, @@ -1453,7 +1457,7 @@ export const marshalCreateTableRequestSchema: z.ZodType = z .lazy(() => marshalSecurableKindManifestSchema) .optional(), columns: z.array(z.lazy(() => marshalColumnInfoSchema)).optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), }) .transform(d => ({ name: d.name, @@ -1502,7 +1506,7 @@ export const marshalCredentialDependencySchema: z.ZodType = z export const marshalDeltaRuntimePropertiesKvPairsSchema: z.ZodType = z .object({ - deltaRuntimeProperties: z.record(z.string(), z.string()).optional(), + deltaRuntimeProperties: z.record(z.string(), z.string()), }) .transform(d => ({ delta_runtime_properties: d.deltaRuntimeProperties, @@ -1548,7 +1552,7 @@ export const marshalDependencyListSchema: z.ZodType = z export const marshalEffectivePredictiveOptimizationFlagSchema: z.ZodType = z .object({ - value: z.string().optional(), + value: z.string(), inheritedFromType: z.string().optional(), inheritedFromName: z.string().optional(), }) @@ -1577,10 +1581,10 @@ export const marshalEncryptionDetailsSchema: z.ZodType = z export const marshalForeignKeyConstraintSchema: z.ZodType = z .object({ - name: z.string().optional(), - childColumns: z.array(z.string()).optional(), - parentTable: z.string().optional(), - parentColumns: z.array(z.string()).optional(), + name: z.string(), + childColumns: z.array(z.string()), + parentTable: z.string(), + parentColumns: z.array(z.string()), rely: z.boolean().optional(), }) .transform(d => ({ @@ -1593,7 +1597,7 @@ export const marshalForeignKeyConstraintSchema: z.ZodType = z export const marshalFunctionDependencySchema: z.ZodType = z .object({ - functionFullName: z.string().optional(), + functionFullName: z.string(), }) .transform(d => ({ function_full_name: d.functionFullName, @@ -1601,7 +1605,7 @@ export const marshalFunctionDependencySchema: z.ZodType = z export const marshalNamedTableConstraintSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -1657,8 +1661,8 @@ export const marshalPolicyFunctionArgumentSchema: z.ZodType = z export const marshalPrimaryKeyConstraintSchema: z.ZodType = z .object({ - name: z.string().optional(), - childColumns: z.array(z.string()).optional(), + name: z.string(), + childColumns: z.array(z.string()), timeseriesColumns: z.array(z.string()).optional(), rely: z.boolean().optional(), }) @@ -1671,8 +1675,8 @@ export const marshalPrimaryKeyConstraintSchema: z.ZodType = z export const marshalRowFilterSchema: z.ZodType = z .object({ - functionName: z.string().optional(), - inputColumnNames: z.array(z.string()).optional(), + functionName: z.string(), + inputColumnNames: z.array(z.string()), inputArguments: z .array(z.lazy(() => marshalPolicyFunctionArgumentSchema)) .optional(), @@ -1742,7 +1746,7 @@ export const marshalTableConstraintSchema: z.ZodType = z export const marshalTableDependencySchema: z.ZodType = z .object({ - tableFullName: z.string().optional(), + tableFullName: z.string(), }) .transform(d => ({ table_full_name: d.tableFullName, @@ -1750,7 +1754,7 @@ export const marshalTableDependencySchema: z.ZodType = z export const marshalUpdateTableRequestSchema: z.ZodType = z .object({ - fullNameArg: z.string().optional(), + fullNameArg: z.string(), name: z.string().optional(), catalogName: z.string().optional(), schemaName: z.string().optional(), @@ -1791,7 +1795,7 @@ export const marshalUpdateTableRequestSchema: z.ZodType = z .lazy(() => marshalSecurableKindManifestSchema) .optional(), columns: z.array(z.lazy(() => marshalColumnInfoSchema)).optional(), - properties: z.record(z.string(), z.string()).optional(), + properties: z.record(z.string(), z.string()), }) .transform(d => ({ full_name_arg: d.fullNameArg, diff --git a/packages/uc/volumes/src/v1/model.ts b/packages/uc/volumes/src/v1/model.ts index ba2265cc8..71f6d8465 100644 --- a/packages/uc/volumes/src/v1/model.ts +++ b/packages/uc/volumes/src/v1/model.ts @@ -61,7 +61,7 @@ export interface CreateVolumeRequest { export interface DeleteVolumeRequest { /** The three-level (fully qualified) name of the volume */ - fullNameArg?: string | undefined; + fullNameArg: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -80,16 +80,16 @@ export interface EncryptionDetails { export interface GetVolumeRequest { /** The three-level (fully qualified) name of the volume */ - fullNameArg?: string | undefined; + fullNameArg: string; /** Whether to include volumes in the response for which the principal can only access selective metadata for */ includeBrowse?: boolean | undefined; } export interface ListVolumesRequest { /** The identifier of the catalog */ - catalogName?: string | undefined; + catalogName: string; /** The identifier of the schema */ - schemaName?: string | undefined; + schemaName: string; /** Whether to include volumes in the response for which the principal can only access selective metadata for */ includeBrowse?: boolean | undefined; /** @@ -130,7 +130,7 @@ export interface SseEncryptionDetails { export interface UpdateVolumeRequest { /** The three-level (fully qualified) name of the volume */ - fullNameArg?: string | undefined; + fullNameArg: string; /** New name for the volume. */ newName?: string | undefined; /** The name of the volume */ @@ -366,7 +366,7 @@ export const marshalSseEncryptionDetailsSchema: z.ZodType = z export const marshalUpdateVolumeRequestSchema: z.ZodType = z .object({ - fullNameArg: z.string().optional(), + fullNameArg: z.string(), newName: z.string().optional(), name: z.string().optional(), catalogName: z.string().optional(), diff --git a/packages/uc/workspacebindings/src/v1/model.ts b/packages/uc/workspacebindings/src/v1/model.ts index 4138fd416..4940eb33e 100644 --- a/packages/uc/workspacebindings/src/v1/model.ts +++ b/packages/uc/workspacebindings/src/v1/model.ts @@ -15,7 +15,7 @@ export type BindingType = export interface GetCatalogWorkspaceBindingsRequest { /** The name of the catalog. */ - catalogName?: string | undefined; + catalogName: string; } export interface GetCatalogWorkspaceBindingsResponse { @@ -25,9 +25,9 @@ export interface GetCatalogWorkspaceBindingsResponse { export interface GetWorkspaceBindingsRequest { /** The type of the securable to bind to a workspace (catalog, storage_credential, credential, or external_location). */ - securableType?: string | undefined; + securableType: string; /** The name of the securable. */ - securableFullName?: string | undefined; + securableFullName: string; /** * Maximum number of workspace bindings to return. * - When set to 0, the page length is set to a server configured value (recommended); @@ -52,7 +52,7 @@ export interface GetWorkspaceBindingsResponse { export interface UpdateCatalogWorkspaceBindingsRequest { /** The name of the catalog. */ - catalogName?: string | undefined; + catalogName: string; /** A list of workspace IDs. */ assignWorkspaces?: bigint[] | undefined; /** A list of workspace IDs. */ @@ -66,9 +66,9 @@ export interface UpdateCatalogWorkspaceBindingsResponse { export interface UpdateWorkspaceBindingsRequest { /** The type of the securable to bind to a workspace (catalog, storage_credential, credential, or external_location). */ - securableType?: string | undefined; + securableType: string; /** The name of the securable. */ - securableFullName?: string | undefined; + securableFullName: string; /** * List of workspace bindings to add. If a binding for the workspace already exists with a * different binding_type, adding it again with a new binding_type will update the existing @@ -87,7 +87,7 @@ export interface UpdateWorkspaceBindingsResponse { export interface WorkspaceBindingInfo { /** Required */ - workspaceId?: bigint | undefined; + workspaceId: bigint; /** One of READ_WRITE/READ_ONLY. Default is READ_WRITE. */ bindingType?: BindingType | undefined; } @@ -151,8 +151,7 @@ export const unmarshalWorkspaceBindingInfoSchema: z.ZodType BigInt(v)) - .optional(), + .transform(v => BigInt(v)), binding_type: z.string().optional(), }) .transform(d => ({ @@ -162,7 +161,7 @@ export const unmarshalWorkspaceBindingInfoSchema: z.ZodType marshalWorkspaceBindingInfoSchema)).optional(), remove: z.array(z.lazy(() => marshalWorkspaceBindingInfoSchema)).optional(), }) @@ -188,7 +187,7 @@ export const marshalUpdateWorkspaceBindingsRequestSchema: z.ZodType = z export const marshalWorkspaceBindingInfoSchema: z.ZodType = z .object({ - workspaceId: z.bigint().optional(), + workspaceId: z.bigint(), bindingType: z.string().optional(), }) .transform(d => ({ diff --git a/packages/vectorsearch/src/v1/model.ts b/packages/vectorsearch/src/v1/model.ts index 9968e4bff..1c8b7edb3 100644 --- a/packages/vectorsearch/src/v1/model.ts +++ b/packages/vectorsearch/src/v1/model.ts @@ -124,9 +124,9 @@ export interface ColumnInfo { export interface CreateEndpointRequest { /** Name of the AI Search endpoint */ - name?: string | undefined; + name: string; /** Type of endpoint */ - endpointType?: EndpointType | undefined; + endpointType: EndpointType; /** The budget policy id to be applied */ budgetPolicyId?: string | undefined; /** The usage policy id to be applied once we've migrated to usage policies */ @@ -141,12 +141,12 @@ export interface CreateEndpointRequest { export interface CreateVectorIndexRequest { /** Name of the index */ - name?: string | undefined; + name: string; /** Name of the endpoint to be used for serving the index */ - endpointName?: string | undefined; + endpointName: string; /** Primary key of the index */ - primaryKey?: string | undefined; - indexType?: VectorIndexType | undefined; + primaryKey: string; + indexType: VectorIndexType; indexSpec?: | { $case: 'directAccessIndexSpec'; @@ -165,7 +165,7 @@ export interface CreateVectorIndexRequest { export interface CustomTag { /** Key field for an AI Search endpoint tag. */ - key?: string | undefined; + key: string; /** [Optional] Value field for an AI Search endpoint tag. */ value?: string | undefined; } @@ -173,9 +173,9 @@ export interface CustomTag { /** Request payload for deleting data from a vector index. */ export interface DeleteDataVectorIndexRequest { /** Name of the vector index where data is to be deleted. Must be a Direct Vector Access Index. */ - name?: string | undefined; + name: string; /** List of primary keys for the data to be deleted. */ - primaryKeys?: string[] | undefined; + primaryKeys: string[]; } export interface DeleteDataVectorIndexResponse { @@ -187,7 +187,7 @@ export interface DeleteDataVectorIndexResponse { export interface DeleteEndpointRequest { /** Name of the AI Search endpoint */ - name?: string | undefined; + name: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -195,7 +195,7 @@ export interface DeleteEndpointResponse {} export interface DeleteVectorIndexRequest { /** Name of the index */ - name?: string | undefined; + name: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -357,12 +357,12 @@ export interface FacetResultData { export interface GetEndpointRequest { /** Name of the endpoint */ - name?: string | undefined; + name: string; } export interface GetVectorIndexRequest { /** Name of the index */ - name?: string | undefined; + name: string; /** * If true, the URL returned for the index is guaranteed to be compatible with the reranker. * Currently this means we return the CP URL regardless of how the index is being accessed. @@ -391,7 +391,7 @@ export interface ListValue { export interface ListVectorIndexRequest { /** Name of the endpoint */ - endpointName?: string | undefined; + endpointName: string; /** Token for pagination */ pageToken?: string | undefined; } @@ -473,9 +473,9 @@ export interface MiniVectorIndex { export interface PatchEndpointBudgetPolicyRequest { /** Name of the AI Search endpoint */ - name?: string | undefined; + name: string; /** The budget policy id to be applied */ - budgetPolicyId?: string | undefined; + budgetPolicyId: string; } export interface PatchEndpointBudgetPolicyResponse { @@ -486,7 +486,7 @@ export interface PatchEndpointBudgetPolicyResponse { export interface PatchEndpointRequest { /** Name of the AI Search endpoint */ - name?: string | undefined; + name: string; /** * Target QPS for the endpoint. Best-effort; the system does not guarantee this QPS * will be achieved. @@ -497,7 +497,7 @@ export interface PatchEndpointRequest { /** Request payload for getting next page of results. */ export interface QueryVectorIndexNextPageRequest { /** Name of the vector index to query. */ - name?: string | undefined; + name: string; /** Name of the endpoint. */ endpointName?: string | undefined; /** Page token returned from previous `QueryVectorIndex` or `QueryVectorIndexNextPage` API. */ @@ -506,11 +506,11 @@ export interface QueryVectorIndexNextPageRequest { export interface QueryVectorIndexRequest { /** Name of the vector index to query. */ - name?: string | undefined; + name: string; /** Number of results to return. Defaults to 10. */ numResults?: number | undefined; /** List of column names to include in the response. */ - columns?: string[] | undefined; + columns: string[]; /** * JSON string representing query filters. * @@ -611,7 +611,7 @@ export interface ResultManifest { /** Request to retrieve user-visible metrics */ export interface RetrieveUserVisibleMetricsRequest { /** AI Search endpoint name */ - name?: string | undefined; + name: string; /** Start time for metrics query */ startTime?: Temporal.Instant | undefined; /** End time for metrics query */ @@ -634,7 +634,7 @@ export interface RetrieveUserVisibleMetricsResponse { export interface ScanVectorIndexRequest { /** Name of the vector index to scan. */ - name?: string | undefined; + name: string; /** Number of results to return. Defaults to 10. */ numResults?: number | undefined; /** Primary key of the last entry returned in the previous scan. */ @@ -656,7 +656,7 @@ export interface Struct { export interface SyncVectorIndexRequest { /** Name of the vector index to synchronize. Must be a Delta Sync Index. */ - name?: string | undefined; + name: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -664,9 +664,9 @@ export interface SyncVectorIndexResponse {} export interface UpdateEndpointCustomTagsRequest { /** Name of the AI Search endpoint */ - name?: string | undefined; + name: string; /** The new custom tags for the AI Search endpoint */ - customTags?: CustomTag[] | undefined; + customTags: CustomTag[]; } export interface UpdateEndpointCustomTagsResponse { @@ -678,9 +678,9 @@ export interface UpdateEndpointCustomTagsResponse { export interface UpsertDataVectorIndexRequest { /** Name of the vector index where data is to be upserted. Must be a Direct Vector Access Index. */ - name?: string | undefined; + name: string; /** JSON string representing the data to be upserted. */ - inputsJson?: string | undefined; + inputsJson: string; } export interface UpsertDataVectorIndexResponse { @@ -758,7 +758,7 @@ export const unmarshalColumnInfoSchema: z.ZodType = z export const unmarshalCustomTagSchema: z.ZodType = z .object({ - key: z.string().optional(), + key: z.string(), value: z.string().optional(), }) .transform(d => ({ @@ -1262,8 +1262,8 @@ export const unmarshalVectorIndexStatusSchema: z.ZodType = z export const marshalCreateEndpointRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - endpointType: z.string().optional(), + name: z.string(), + endpointType: z.string(), budgetPolicyId: z.string().optional(), usagePolicyId: z.string().optional(), targetQps: z.bigint().optional(), @@ -1278,10 +1278,10 @@ export const marshalCreateEndpointRequestSchema: z.ZodType = z export const marshalCreateVectorIndexRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - endpointName: z.string().optional(), - primaryKey: z.string().optional(), - indexType: z.string().optional(), + name: z.string(), + endpointName: z.string(), + primaryKey: z.string(), + indexType: z.string(), indexSpec: z .discriminatedUnion('$case', [ z.object({ @@ -1316,7 +1316,7 @@ export const marshalCreateVectorIndexRequestSchema: z.ZodType = z export const marshalCustomTagSchema: z.ZodType = z .object({ - key: z.string().optional(), + key: z.string(), value: z.string().optional(), }) .transform(d => ({ @@ -1422,8 +1422,8 @@ export const marshalMetricLabelSchema: z.ZodType = z export const marshalPatchEndpointBudgetPolicyRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - budgetPolicyId: z.string().optional(), + name: z.string(), + budgetPolicyId: z.string(), }) .transform(d => ({ name: d.name, @@ -1432,7 +1432,7 @@ export const marshalPatchEndpointBudgetPolicyRequestSchema: z.ZodType = z export const marshalPatchEndpointRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), targetQps: z.bigint().optional(), }) .transform(d => ({ @@ -1442,7 +1442,7 @@ export const marshalPatchEndpointRequestSchema: z.ZodType = z export const marshalQueryVectorIndexNextPageRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), endpointName: z.string().optional(), pageToken: z.string().optional(), }) @@ -1454,9 +1454,9 @@ export const marshalQueryVectorIndexNextPageRequestSchema: z.ZodType = z export const marshalQueryVectorIndexRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), numResults: z.number().optional(), - columns: z.array(z.string()).optional(), + columns: z.array(z.string()), filtersJson: z.string().optional(), queryVector: z.array(z.number()).optional(), queryText: z.string().optional(), @@ -1507,7 +1507,7 @@ export const marshalRerankerConfig_RerankerParametersSchema: z.ZodType = z export const marshalRetrieveUserVisibleMetricsRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), startTime: z .any() .transform((d: Temporal.Instant) => d.toString()) @@ -1531,7 +1531,7 @@ export const marshalRetrieveUserVisibleMetricsRequestSchema: z.ZodType = z export const marshalScanVectorIndexRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), numResults: z.number().optional(), lastPrimaryKey: z.string().optional(), }) @@ -1543,7 +1543,7 @@ export const marshalScanVectorIndexRequestSchema: z.ZodType = z export const marshalSyncVectorIndexRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), + name: z.string(), }) .transform(d => ({ name: d.name, @@ -1551,8 +1551,8 @@ export const marshalSyncVectorIndexRequestSchema: z.ZodType = z export const marshalUpdateEndpointCustomTagsRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - customTags: z.array(z.lazy(() => marshalCustomTagSchema)).optional(), + name: z.string(), + customTags: z.array(z.lazy(() => marshalCustomTagSchema)), }) .transform(d => ({ name: d.name, @@ -1561,8 +1561,8 @@ export const marshalUpdateEndpointCustomTagsRequestSchema: z.ZodType = z export const marshalUpsertDataVectorIndexRequestSchema: z.ZodType = z .object({ - name: z.string().optional(), - inputsJson: z.string().optional(), + name: z.string(), + inputsJson: z.string(), }) .transform(d => ({ name: d.name, diff --git a/packages/warehouses/src/v1/model.ts b/packages/warehouses/src/v1/model.ts index df5fabe7e..2a3d82d7e 100644 --- a/packages/warehouses/src/v1/model.ts +++ b/packages/warehouses/src/v1/model.ts @@ -772,9 +772,9 @@ export interface CreateDefaultWarehouseOverrideRequest { * of the override's resource name. * Can be a numeric user ID or the literal string "me" for the current user. */ - defaultWarehouseOverrideId?: string | undefined; + defaultWarehouseOverrideId: string; /** Required. The default warehouse override to create. */ - defaultWarehouseOverride?: DefaultWarehouseOverride | undefined; + defaultWarehouseOverride: DefaultWarehouseOverride; } /** Creates a new SQL warehouse. */ @@ -896,7 +896,7 @@ export interface DefaultWarehouseOverride { /** The ID component of the resource name (user ID). */ defaultWarehouseOverrideId?: string | undefined; /** The type of override behavior. */ - type?: DefaultWarehouseOverrideType | undefined; + type: DefaultWarehouseOverrideType; /** * The specific warehouse ID when type is CUSTOM. * Not set for LAST_SELECTED type. @@ -911,7 +911,7 @@ export interface DeleteDefaultWarehouseOverrideRequest { * Format: default-warehouse-overrides/{default_warehouse_override_id} * The default_warehouse_override_id can be a numeric user ID or the literal string "me" for the current user. */ - name?: string | undefined; + name: string; } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -924,7 +924,7 @@ export interface DeleteWarehouseResponse {} */ export interface EditWarehouseRequest { /** Required. Id of the warehouse to configure. */ - id?: string | undefined; + id: string; /** * Logical name for the cluster. * @@ -1165,13 +1165,13 @@ export interface GetDefaultWarehouseOverrideRequest { * Format: default-warehouse-overrides/{default_warehouse_override_id} * The default_warehouse_override_id can be a numeric user ID or the literal string "me" for the current user. */ - name?: string | undefined; + name: string; } /** Fetches the warehouse info for a single SQL warehouse. */ export interface GetWarehouseRequest { /** Required. Id of the SQL warehouse. */ - id?: string | undefined; + id: string; } export interface GetWarehouseResponse { @@ -1455,14 +1455,14 @@ export interface UpdateDefaultWarehouseOverrideRequest { * The name field must be set in the format: default-warehouse-overrides/{default_warehouse_override_id} * The default_warehouse_override_id can be a numeric user ID or the literal string "me" for the current user. */ - defaultWarehouseOverride?: DefaultWarehouseOverride | undefined; + defaultWarehouseOverride: DefaultWarehouseOverride; /** * Required. Field mask specifying which fields to update. * Only the fields specified in the mask will be updated. * Use "*" to update all fields. * When allow_missing is true, this field is ignored and all fields are applied. */ - updateMask?: FieldMask | undefined; + updateMask: FieldMask; /** * If set to true, and the override is not found, a new override will be created. * In this situation, `update_mask` is ignored and all fields are applied. @@ -1491,7 +1491,7 @@ export interface WarehouseTypePair { */ export interface DeleteWarehouseRequest { /** Required. Id of the SQL warehouse. */ - id?: string | undefined; + id: string; } /** @@ -1524,7 +1524,7 @@ export interface ListWarehousesRequest { */ export interface StartRequest { /** Required. Id of the SQL warehouse. */ - id?: string | undefined; + id: string; } /** @@ -1533,7 +1533,7 @@ export interface StartRequest { */ export interface StopRequest { /** Required. Id of the SQL warehouse. */ - id?: string | undefined; + id: string; } export const unmarshalChannelSchema: z.ZodType = z @@ -1560,7 +1560,7 @@ export const unmarshalDefaultWarehouseOverrideSchema: z.ZodType ({ @@ -1890,7 +1890,7 @@ export const marshalDefaultWarehouseOverrideSchema: z.ZodType = z .object({ name: z.string().optional(), defaultWarehouseOverrideId: z.string().optional(), - type: z.string().optional(), + type: z.string(), warehouseId: z.string().optional(), }) .transform(d => ({ @@ -1902,7 +1902,7 @@ export const marshalDefaultWarehouseOverrideSchema: z.ZodType = z export const marshalEditWarehouseRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), name: z.string().optional(), clusterSize: z.string().optional(), minNumClusters: z.number().optional(), @@ -2022,7 +2022,7 @@ export const marshalWarehouseTypePairSchema: z.ZodType = z export const marshalStartRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), }) .transform(d => ({ id: d.id, @@ -2030,7 +2030,7 @@ export const marshalStartRequestSchema: z.ZodType = z export const marshalStopRequestSchema: z.ZodType = z .object({ - id: z.string().optional(), + id: z.string(), }) .transform(d => ({ id: d.id, diff --git a/packages/workspaces/src/v1/model.ts b/packages/workspaces/src/v1/model.ts index 670b822c8..530509187 100644 --- a/packages/workspaces/src/v1/model.ts +++ b/packages/workspaces/src/v1/model.ts @@ -139,7 +139,7 @@ export interface CloudResourceContainer { } export interface CreateWorkspaceRequest { - accountId?: string | undefined; + accountId: string; /** The human-readable name of the workspace. */ workspaceName?: string | undefined; /** @@ -193,8 +193,8 @@ export interface CreateWorkspaceRequest { } export interface DeleteWorkspaceRequest { - workspaceId?: bigint | undefined; - accountId?: string | undefined; + workspaceId: bigint; + accountId: string; } export interface GcpCloudResourceContainer { @@ -230,8 +230,8 @@ export interface GcpManagedNetworkConfig { } export interface GetWorkspaceRequest { - workspaceId?: bigint | undefined; - accountId?: string | undefined; + workspaceId: bigint; + accountId: string; } /** The configurations of the GKE cluster used by the GCP workspace. */ @@ -246,7 +246,7 @@ export interface GkeConfig { } export interface ListWorkspacesRequest { - accountId?: string | undefined; + accountId: string; } export interface ListWorkspacesResponse { @@ -254,7 +254,7 @@ export interface ListWorkspacesResponse { } export interface UpdateWorkspaceRequest { - customerFacingWorkspace?: Workspace | undefined; + customerFacingWorkspace: Workspace; updateMask?: FieldMask | undefined; } @@ -561,7 +561,7 @@ export const marshalCloudResourceContainerSchema: z.ZodType = z export const marshalCreateWorkspaceRequestSchema: z.ZodType = z .object({ - accountId: z.string().optional(), + accountId: z.string(), workspaceName: z.string().optional(), deploymentName: z.string().optional(), awsRegion: z.string().optional(),