@databricks/sdk-uc-schemas 0.34.0 → 0.35.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/v1/model.js CHANGED
@@ -1,199 +1,175 @@
1
- // Code generated from API definition by Databricks SDK Generator. DO NOT EDIT.
2
- import { z } from 'zod';
1
+ import { z } from "zod";
2
+
3
+ //#region src/v1/model.ts
3
4
  /** The type of the catalog. */
4
- // eslint-disable-next-line @typescript-eslint/naming-convention -- Enum-style const object.
5
- export const CatalogType = {
6
- MANAGED_CATALOG: 'MANAGED_CATALOG',
7
- DELTASHARING_CATALOG: 'DELTASHARING_CATALOG',
8
- SYSTEM_CATALOG: 'SYSTEM_CATALOG',
9
- INTERNAL_CATALOG: 'INTERNAL_CATALOG',
10
- FOREIGN_CATALOG: 'FOREIGN_CATALOG',
11
- MANAGED_ONLINE_CATALOG: 'MANAGED_ONLINE_CATALOG',
5
+ const CatalogType = {
6
+ MANAGED_CATALOG: "MANAGED_CATALOG",
7
+ DELTASHARING_CATALOG: "DELTASHARING_CATALOG",
8
+ SYSTEM_CATALOG: "SYSTEM_CATALOG",
9
+ INTERNAL_CATALOG: "INTERNAL_CATALOG",
10
+ FOREIGN_CATALOG: "FOREIGN_CATALOG",
11
+ MANAGED_ONLINE_CATALOG: "MANAGED_ONLINE_CATALOG"
12
12
  };
13
- export const unmarshalDeleteSchemaResponseSchema = z.object({});
14
- export const unmarshalEffectivePredictiveOptimizationFlagSchema = z
15
- .object({
16
- value: z.string().optional(),
17
- inherited_from_type: z.string().optional(),
18
- inherited_from_name: z.string().optional(),
19
- })
20
- .transform(d => ({
21
- value: d.value,
22
- inheritedFromType: d.inherited_from_type,
23
- inheritedFromName: d.inherited_from_name,
13
+ const unmarshalDeleteSchemaResponseSchema = z.object({});
14
+ const unmarshalEffectivePredictiveOptimizationFlagSchema = z.object({
15
+ value: z.string().optional(),
16
+ inherited_from_type: z.string().optional(),
17
+ inherited_from_name: z.string().optional()
18
+ }).transform((d) => ({
19
+ value: d.value,
20
+ inheritedFromType: d.inherited_from_type,
21
+ inheritedFromName: d.inherited_from_name
24
22
  }));
25
- export const unmarshalListSchemasResponseSchema = z
26
- .object({
27
- schemas: z.array(z.lazy(() => unmarshalSchemaInfoSchema)).optional(),
28
- next_page_token: z.string().optional(),
29
- })
30
- .transform(d => ({
31
- schemas: d.schemas,
32
- nextPageToken: d.next_page_token,
23
+ const unmarshalListSchemasResponseSchema = z.object({
24
+ schemas: z.array(z.lazy(() => unmarshalSchemaInfoSchema)).optional(),
25
+ next_page_token: z.string().optional()
26
+ }).transform((d) => ({
27
+ schemas: d.schemas,
28
+ nextPageToken: d.next_page_token
33
29
  }));
34
- export const unmarshalSchemaInfoSchema = z
35
- .object({
36
- name: z.string().optional(),
37
- catalog_name: z.string().optional(),
38
- owner: z.string().optional(),
39
- comment: z.string().optional(),
40
- storage_root: z.string().optional(),
41
- enable_predictive_optimization: z.string().optional(),
42
- metastore_id: z.string().optional(),
43
- full_name: z.string().optional(),
44
- created_at: z
45
- .union([z.number(), z.bigint()])
46
- .transform(v => BigInt(v))
47
- .optional(),
48
- created_by: z.string().optional(),
49
- updated_at: z
50
- .union([z.number(), z.bigint()])
51
- .transform(v => BigInt(v))
52
- .optional(),
53
- updated_by: z.string().optional(),
54
- catalog_type: z.string().optional(),
55
- storage_location: z.string().optional(),
56
- effective_predictive_optimization_flag: z
57
- .lazy(() => unmarshalEffectivePredictiveOptimizationFlagSchema)
58
- .optional(),
59
- schema_id: z.string().optional(),
60
- browse_only: z.boolean().optional(),
61
- custom_max_retention_hours: z
62
- .union([z.number(), z.bigint()])
63
- .transform(v => BigInt(v))
64
- .optional(),
65
- properties: z.record(z.string(), z.string()).optional(),
66
- options: z.record(z.string(), z.string()).optional(),
67
- })
68
- .transform(d => ({
69
- name: d.name,
70
- catalogName: d.catalog_name,
71
- owner: d.owner,
72
- comment: d.comment,
73
- storageRoot: d.storage_root,
74
- enablePredictiveOptimization: d.enable_predictive_optimization,
75
- metastoreId: d.metastore_id,
76
- fullName: d.full_name,
77
- createdAt: d.created_at,
78
- createdBy: d.created_by,
79
- updatedAt: d.updated_at,
80
- updatedBy: d.updated_by,
81
- catalogType: d.catalog_type,
82
- storageLocation: d.storage_location,
83
- effectivePredictiveOptimizationFlag: d.effective_predictive_optimization_flag,
84
- schemaId: d.schema_id,
85
- browseOnly: d.browse_only,
86
- customMaxRetentionHours: d.custom_max_retention_hours,
87
- properties: d.properties,
88
- options: d.options,
30
+ const unmarshalSchemaInfoSchema = z.object({
31
+ name: z.string().optional(),
32
+ catalog_name: z.string().optional(),
33
+ owner: z.string().optional(),
34
+ comment: z.string().optional(),
35
+ storage_root: z.string().optional(),
36
+ enable_predictive_optimization: z.string().optional(),
37
+ metastore_id: z.string().optional(),
38
+ full_name: z.string().optional(),
39
+ created_at: z.union([z.number(), z.bigint()]).transform((v) => BigInt(v)).optional(),
40
+ created_by: z.string().optional(),
41
+ updated_at: z.union([z.number(), z.bigint()]).transform((v) => BigInt(v)).optional(),
42
+ updated_by: z.string().optional(),
43
+ catalog_type: z.string().optional(),
44
+ storage_location: z.string().optional(),
45
+ effective_predictive_optimization_flag: z.lazy(() => unmarshalEffectivePredictiveOptimizationFlagSchema).optional(),
46
+ schema_id: z.string().optional(),
47
+ browse_only: z.boolean().optional(),
48
+ custom_max_retention_hours: z.union([z.number(), z.bigint()]).transform((v) => BigInt(v)).optional(),
49
+ properties: z.record(z.string(), z.string()).optional(),
50
+ options: z.record(z.string(), z.string()).optional()
51
+ }).transform((d) => ({
52
+ name: d.name,
53
+ catalogName: d.catalog_name,
54
+ owner: d.owner,
55
+ comment: d.comment,
56
+ storageRoot: d.storage_root,
57
+ enablePredictiveOptimization: d.enable_predictive_optimization,
58
+ metastoreId: d.metastore_id,
59
+ fullName: d.full_name,
60
+ createdAt: d.created_at,
61
+ createdBy: d.created_by,
62
+ updatedAt: d.updated_at,
63
+ updatedBy: d.updated_by,
64
+ catalogType: d.catalog_type,
65
+ storageLocation: d.storage_location,
66
+ effectivePredictiveOptimizationFlag: d.effective_predictive_optimization_flag,
67
+ schemaId: d.schema_id,
68
+ browseOnly: d.browse_only,
69
+ customMaxRetentionHours: d.custom_max_retention_hours,
70
+ properties: d.properties,
71
+ options: d.options
89
72
  }));
90
- export const marshalCreateSchemaRequestSchema = z
91
- .object({
92
- name: z.string().optional(),
93
- catalogName: z.string().optional(),
94
- owner: z.string().optional(),
95
- comment: z.string().optional(),
96
- storageRoot: z.string().optional(),
97
- enablePredictiveOptimization: z.string().optional(),
98
- metastoreId: z.string().optional(),
99
- fullName: z.string().optional(),
100
- createdAt: z.bigint().optional(),
101
- createdBy: z.string().optional(),
102
- updatedAt: z.bigint().optional(),
103
- updatedBy: z.string().optional(),
104
- catalogType: z.string().optional(),
105
- storageLocation: z.string().optional(),
106
- effectivePredictiveOptimizationFlag: z
107
- .lazy(() => marshalEffectivePredictiveOptimizationFlagSchema)
108
- .optional(),
109
- schemaId: z.string().optional(),
110
- browseOnly: z.boolean().optional(),
111
- customMaxRetentionHours: z.bigint().optional(),
112
- properties: z.record(z.string(), z.string()).optional(),
113
- options: z.record(z.string(), z.string()).optional(),
114
- })
115
- .transform(d => ({
116
- name: d.name,
117
- catalog_name: d.catalogName,
118
- owner: d.owner,
119
- comment: d.comment,
120
- storage_root: d.storageRoot,
121
- enable_predictive_optimization: d.enablePredictiveOptimization,
122
- metastore_id: d.metastoreId,
123
- full_name: d.fullName,
124
- created_at: d.createdAt,
125
- created_by: d.createdBy,
126
- updated_at: d.updatedAt,
127
- updated_by: d.updatedBy,
128
- catalog_type: d.catalogType,
129
- storage_location: d.storageLocation,
130
- effective_predictive_optimization_flag: d.effectivePredictiveOptimizationFlag,
131
- schema_id: d.schemaId,
132
- browse_only: d.browseOnly,
133
- custom_max_retention_hours: d.customMaxRetentionHours,
134
- properties: d.properties,
135
- options: d.options,
73
+ const marshalCreateSchemaRequestSchema = z.object({
74
+ name: z.string().optional(),
75
+ catalogName: z.string().optional(),
76
+ owner: z.string().optional(),
77
+ comment: z.string().optional(),
78
+ storageRoot: z.string().optional(),
79
+ enablePredictiveOptimization: z.string().optional(),
80
+ metastoreId: z.string().optional(),
81
+ fullName: z.string().optional(),
82
+ createdAt: z.bigint().optional(),
83
+ createdBy: z.string().optional(),
84
+ updatedAt: z.bigint().optional(),
85
+ updatedBy: z.string().optional(),
86
+ catalogType: z.string().optional(),
87
+ storageLocation: z.string().optional(),
88
+ effectivePredictiveOptimizationFlag: z.lazy(() => marshalEffectivePredictiveOptimizationFlagSchema).optional(),
89
+ schemaId: z.string().optional(),
90
+ browseOnly: z.boolean().optional(),
91
+ customMaxRetentionHours: z.bigint().optional(),
92
+ properties: z.record(z.string(), z.string()).optional(),
93
+ options: z.record(z.string(), z.string()).optional()
94
+ }).transform((d) => ({
95
+ name: d.name,
96
+ catalog_name: d.catalogName,
97
+ owner: d.owner,
98
+ comment: d.comment,
99
+ storage_root: d.storageRoot,
100
+ enable_predictive_optimization: d.enablePredictiveOptimization,
101
+ metastore_id: d.metastoreId,
102
+ full_name: d.fullName,
103
+ created_at: d.createdAt,
104
+ created_by: d.createdBy,
105
+ updated_at: d.updatedAt,
106
+ updated_by: d.updatedBy,
107
+ catalog_type: d.catalogType,
108
+ storage_location: d.storageLocation,
109
+ effective_predictive_optimization_flag: d.effectivePredictiveOptimizationFlag,
110
+ schema_id: d.schemaId,
111
+ browse_only: d.browseOnly,
112
+ custom_max_retention_hours: d.customMaxRetentionHours,
113
+ properties: d.properties,
114
+ options: d.options
136
115
  }));
137
- export const marshalEffectivePredictiveOptimizationFlagSchema = z
138
- .object({
139
- value: z.string().optional(),
140
- inheritedFromType: z.string().optional(),
141
- inheritedFromName: z.string().optional(),
142
- })
143
- .transform(d => ({
144
- value: d.value,
145
- inherited_from_type: d.inheritedFromType,
146
- inherited_from_name: d.inheritedFromName,
116
+ const marshalEffectivePredictiveOptimizationFlagSchema = z.object({
117
+ value: z.string().optional(),
118
+ inheritedFromType: z.string().optional(),
119
+ inheritedFromName: z.string().optional()
120
+ }).transform((d) => ({
121
+ value: d.value,
122
+ inherited_from_type: d.inheritedFromType,
123
+ inherited_from_name: d.inheritedFromName
147
124
  }));
148
- export const marshalUpdateSchemaRequestSchema = z
149
- .object({
150
- fullNameArg: z.string().optional(),
151
- newName: z.string().optional(),
152
- name: z.string().optional(),
153
- catalogName: z.string().optional(),
154
- owner: z.string().optional(),
155
- comment: z.string().optional(),
156
- storageRoot: z.string().optional(),
157
- enablePredictiveOptimization: z.string().optional(),
158
- metastoreId: z.string().optional(),
159
- fullName: z.string().optional(),
160
- createdAt: z.bigint().optional(),
161
- createdBy: z.string().optional(),
162
- updatedAt: z.bigint().optional(),
163
- updatedBy: z.string().optional(),
164
- catalogType: z.string().optional(),
165
- storageLocation: z.string().optional(),
166
- effectivePredictiveOptimizationFlag: z
167
- .lazy(() => marshalEffectivePredictiveOptimizationFlagSchema)
168
- .optional(),
169
- schemaId: z.string().optional(),
170
- browseOnly: z.boolean().optional(),
171
- customMaxRetentionHours: z.bigint().optional(),
172
- properties: z.record(z.string(), z.string()).optional(),
173
- options: z.record(z.string(), z.string()).optional(),
174
- })
175
- .transform(d => ({
176
- full_name_arg: d.fullNameArg,
177
- new_name: d.newName,
178
- name: d.name,
179
- catalog_name: d.catalogName,
180
- owner: d.owner,
181
- comment: d.comment,
182
- storage_root: d.storageRoot,
183
- enable_predictive_optimization: d.enablePredictiveOptimization,
184
- metastore_id: d.metastoreId,
185
- full_name: d.fullName,
186
- created_at: d.createdAt,
187
- created_by: d.createdBy,
188
- updated_at: d.updatedAt,
189
- updated_by: d.updatedBy,
190
- catalog_type: d.catalogType,
191
- storage_location: d.storageLocation,
192
- effective_predictive_optimization_flag: d.effectivePredictiveOptimizationFlag,
193
- schema_id: d.schemaId,
194
- browse_only: d.browseOnly,
195
- custom_max_retention_hours: d.customMaxRetentionHours,
196
- properties: d.properties,
197
- options: d.options,
125
+ const marshalUpdateSchemaRequestSchema = z.object({
126
+ fullNameArg: z.string().optional(),
127
+ newName: z.string().optional(),
128
+ name: z.string().optional(),
129
+ catalogName: z.string().optional(),
130
+ owner: z.string().optional(),
131
+ comment: z.string().optional(),
132
+ storageRoot: z.string().optional(),
133
+ enablePredictiveOptimization: z.string().optional(),
134
+ metastoreId: z.string().optional(),
135
+ fullName: z.string().optional(),
136
+ createdAt: z.bigint().optional(),
137
+ createdBy: z.string().optional(),
138
+ updatedAt: z.bigint().optional(),
139
+ updatedBy: z.string().optional(),
140
+ catalogType: z.string().optional(),
141
+ storageLocation: z.string().optional(),
142
+ effectivePredictiveOptimizationFlag: z.lazy(() => marshalEffectivePredictiveOptimizationFlagSchema).optional(),
143
+ schemaId: z.string().optional(),
144
+ browseOnly: z.boolean().optional(),
145
+ customMaxRetentionHours: z.bigint().optional(),
146
+ properties: z.record(z.string(), z.string()).optional(),
147
+ options: z.record(z.string(), z.string()).optional()
148
+ }).transform((d) => ({
149
+ full_name_arg: d.fullNameArg,
150
+ new_name: d.newName,
151
+ name: d.name,
152
+ catalog_name: d.catalogName,
153
+ owner: d.owner,
154
+ comment: d.comment,
155
+ storage_root: d.storageRoot,
156
+ enable_predictive_optimization: d.enablePredictiveOptimization,
157
+ metastore_id: d.metastoreId,
158
+ full_name: d.fullName,
159
+ created_at: d.createdAt,
160
+ created_by: d.createdBy,
161
+ updated_at: d.updatedAt,
162
+ updated_by: d.updatedBy,
163
+ catalog_type: d.catalogType,
164
+ storage_location: d.storageLocation,
165
+ effective_predictive_optimization_flag: d.effectivePredictiveOptimizationFlag,
166
+ schema_id: d.schemaId,
167
+ browse_only: d.browseOnly,
168
+ custom_max_retention_hours: d.customMaxRetentionHours,
169
+ properties: d.properties,
170
+ options: d.options
198
171
  }));
172
+
173
+ //#endregion
174
+ export { CatalogType, marshalCreateSchemaRequestSchema, marshalEffectivePredictiveOptimizationFlagSchema, marshalUpdateSchemaRequestSchema, unmarshalDeleteSchemaResponseSchema, unmarshalEffectivePredictiveOptimizationFlagSchema, unmarshalListSchemasResponseSchema, unmarshalSchemaInfoSchema };
199
175
  //# sourceMappingURL=model.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"model.js","sourceRoot":"","sources":["../../src/v1/model.ts"],"names":[],"mappings":"AAAA,+EAA+E;AAE/E,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,+BAA+B;AAC/B,4FAA4F;AAC5F,MAAM,CAAC,MAAM,WAAW,GAAG;IACzB,eAAe,EAAE,iBAAiB;IAClC,oBAAoB,EAAE,sBAAsB;IAC5C,cAAc,EAAE,gBAAgB;IAChC,gBAAgB,EAAE,kBAAkB;IACpC,eAAe,EAAE,iBAAiB;IAClC,sBAAsB,EAAE,wBAAwB;CACxC,CAAC;AAkMX,MAAM,CAAC,MAAM,mCAAmC,GAC9C,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;AAEf,MAAM,CAAC,MAAM,kDAAkD,GAC7D,CAAC;KACE,MAAM,CAAC;IACN,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC5B,mBAAmB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC1C,mBAAmB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC3C,CAAC;KACD,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;IACf,KAAK,EAAE,CAAC,CAAC,KAAK;IACd,iBAAiB,EAAE,CAAC,CAAC,mBAAmB;IACxC,iBAAiB,EAAE,CAAC,CAAC,mBAAmB;CACzC,CAAC,CAAC,CAAC;AAER,MAAM,CAAC,MAAM,kCAAkC,GAC7C,CAAC;KACE,MAAM,CAAC;IACN,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,yBAAyB,CAAC,CAAC,CAAC,QAAQ,EAAE;IACpE,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;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;IAC3B,KAAK,EAAE,CAAC,CAAC,KAAK;IACd,OAAO,EAAE,CAAC,CAAC,OAAO;IAClB,YAAY,EAAE,CAAC,CAAC,WAAW;IAC3B,8BAA8B,EAAE,CAAC,CAAC,4BAA4B;IAC9D,YAAY,EAAE,CAAC,CAAC,WAAW;IAC3B,SAAS,EAAE,CAAC,CAAC,QAAQ;IACrB,UAAU,EAAE,CAAC,CAAC,SAAS;IACvB,UAAU,EAAE,CAAC,CAAC,SAAS;IACvB,UAAU,EAAE,CAAC,CAAC,SAAS;IACvB,UAAU,EAAE,CAAC,CAAC,SAAS;IACvB,YAAY,EAAE,CAAC,CAAC,WAAW;IAC3B,gBAAgB,EAAE,CAAC,CAAC,eAAe;IACnC,sCAAsC,EACpC,CAAC,CAAC,mCAAmC;IACvC,SAAS,EAAE,CAAC,CAAC,QAAQ;IACrB,WAAW,EAAE,CAAC,CAAC,UAAU;IACzB,0BAA0B,EAAE,CAAC,CAAC,uBAAuB;IACrD,UAAU,EAAE,CAAC,CAAC,UAAU;IACxB,OAAO,EAAE,CAAC,CAAC,OAAO;CACnB,CAAC,CAAC,CAAC"}
1
+ {"version":3,"file":"model.js","names":[],"sources":["../../src/v1/model.ts"],"sourcesContent":["// Code generated from API definition by Databricks SDK Generator. DO NOT EDIT.\n\nimport {z} from 'zod';\n\n/** The type of the catalog. */\n// eslint-disable-next-line @typescript-eslint/naming-convention -- Enum-style const object.\nexport const CatalogType = {\n MANAGED_CATALOG: 'MANAGED_CATALOG',\n DELTASHARING_CATALOG: 'DELTASHARING_CATALOG',\n SYSTEM_CATALOG: 'SYSTEM_CATALOG',\n INTERNAL_CATALOG: 'INTERNAL_CATALOG',\n FOREIGN_CATALOG: 'FOREIGN_CATALOG',\n MANAGED_ONLINE_CATALOG: 'MANAGED_ONLINE_CATALOG',\n} as const;\nexport type CatalogType =\n | (typeof CatalogType)[keyof typeof CatalogType]\n | (string & {});\n\nexport interface CreateSchemaRequest {\n /** Name of schema, relative to parent catalog. */\n name?: string | undefined;\n /** Name of parent catalog. */\n catalogName?: string | undefined;\n /** Username of current owner of schema. */\n owner?: string | undefined;\n /** User-provided free-form text description. */\n comment?: string | undefined;\n /** Storage root URL for managed tables within schema. */\n storageRoot?: string | undefined;\n /** Whether predictive optimization should be enabled for this object and objects under it. */\n enablePredictiveOptimization?: string | undefined;\n /** Unique identifier of parent metastore. */\n metastoreId?: string | undefined;\n /** Full name of schema, in form of __catalog_name__.__schema_name__. */\n fullName?: string | undefined;\n /** Time at which this schema was created, in epoch milliseconds. */\n createdAt?: bigint | undefined;\n /** Username of schema creator. */\n createdBy?: string | undefined;\n /** Time at which this schema was created, in epoch milliseconds. */\n updatedAt?: bigint | undefined;\n /** Username of user who last modified schema. */\n updatedBy?: string | undefined;\n /** The type of the parent catalog. */\n catalogType?: CatalogType | undefined;\n /** Storage location for managed tables within schema. */\n storageLocation?: string | undefined;\n effectivePredictiveOptimizationFlag?:\n | EffectivePredictiveOptimizationFlag\n | undefined;\n /** The unique identifier of the schema. */\n schemaId?: string | undefined;\n /** Indicates whether the principal is limited to retrieving metadata for the associated object through the BROWSE privilege when include_browse is enabled in the request. */\n browseOnly?: boolean | undefined;\n /** Custom maximum retention period in hours for the schema. */\n customMaxRetentionHours?: bigint | undefined;\n /** A map of key-value properties attached to the securable. */\n properties?: Record<string, string> | undefined;\n /** A map of key-value properties attached to the securable. */\n options?: Record<string, string> | undefined;\n}\n\nexport interface DeleteSchemaRequest {\n /** Full name of the schema. */\n fullNameArg?: string | undefined;\n /** Force deletion even if the schema is not empty. */\n force?: boolean | undefined;\n}\n\n// eslint-disable-next-line @typescript-eslint/no-empty-object-type\nexport interface DeleteSchemaResponse {}\n\nexport interface EffectivePredictiveOptimizationFlag {\n /** Whether predictive optimization should be enabled for this object and objects under it. */\n value?: string | undefined;\n /** The type of the object from which the flag was inherited. If there was no inheritance, this field is left blank. */\n inheritedFromType?: string | undefined;\n /** The name of the object from which the flag was inherited. If there was no inheritance, this field is left blank. */\n inheritedFromName?: string | undefined;\n}\n\nexport interface GetSchemaRequest {\n /** Full name of the schema. */\n fullNameArg?: string | undefined;\n /** Whether to include schemas in the response for which the principal can only access selective metadata for */\n includeBrowse?: boolean | undefined;\n}\n\nexport interface ListSchemasRequest {\n /** Parent catalog for schemas of interest. */\n catalogName?: string | undefined;\n /**\n * Maximum number of schemas to return.\n * If not set, all the schemas are returned (not recommended).\n * - when set to a value greater than 0, the page length is the minimum of this value and a server configured value;\n * - when set to 0, the page length is set to a server configured value (recommended);\n * - when set to a value less than 0, an invalid parameter error is returned;\n */\n maxResults?: number | undefined;\n /** Opaque pagination token to go to next page based on previous query. */\n pageToken?: string | undefined;\n /** Whether to include schemas in the response for which the principal can only access selective metadata for */\n includeBrowse?: boolean | undefined;\n}\n\nexport interface ListSchemasResponse {\n /** An array of schema information objects. */\n schemas?: SchemaInfo[] | undefined;\n /**\n * Opaque token to retrieve the next page of results. Absent if there are no more pages.\n * __page_token__ should be set to this value for the next request (for the next page of results).\n */\n nextPageToken?: string | undefined;\n}\n\nexport interface SchemaInfo {\n /** Name of schema, relative to parent catalog. */\n name?: string | undefined;\n /** Name of parent catalog. */\n catalogName?: string | undefined;\n /** Username of current owner of schema. */\n owner?: string | undefined;\n /** User-provided free-form text description. */\n comment?: string | undefined;\n /** Storage root URL for managed tables within schema. */\n storageRoot?: string | undefined;\n /** Whether predictive optimization should be enabled for this object and objects under it. */\n enablePredictiveOptimization?: string | undefined;\n /** Unique identifier of parent metastore. */\n metastoreId?: string | undefined;\n /** Full name of schema, in form of __catalog_name__.__schema_name__. */\n fullName?: string | undefined;\n /** Time at which this schema was created, in epoch milliseconds. */\n createdAt?: bigint | undefined;\n /** Username of schema creator. */\n createdBy?: string | undefined;\n /** Time at which this schema was created, in epoch milliseconds. */\n updatedAt?: bigint | undefined;\n /** Username of user who last modified schema. */\n updatedBy?: string | undefined;\n /** The type of the parent catalog. */\n catalogType?: CatalogType | undefined;\n /** Storage location for managed tables within schema. */\n storageLocation?: string | undefined;\n effectivePredictiveOptimizationFlag?:\n | EffectivePredictiveOptimizationFlag\n | undefined;\n /** The unique identifier of the schema. */\n schemaId?: string | undefined;\n /** Indicates whether the principal is limited to retrieving metadata for the associated object through the BROWSE privilege when include_browse is enabled in the request. */\n browseOnly?: boolean | undefined;\n /** Custom maximum retention period in hours for the schema. */\n customMaxRetentionHours?: bigint | undefined;\n /** A map of key-value properties attached to the securable. */\n properties?: Record<string, string> | undefined;\n /** A map of key-value properties attached to the securable. */\n options?: Record<string, string> | undefined;\n}\n\nexport interface UpdateSchemaRequest {\n /** Full name of the schema. */\n fullNameArg?: string | undefined;\n /** New name for the schema. */\n newName?: string | undefined;\n /** Name of schema, relative to parent catalog. */\n name?: string | undefined;\n /** Name of parent catalog. */\n catalogName?: string | undefined;\n /** Username of current owner of schema. */\n owner?: string | undefined;\n /** User-provided free-form text description. */\n comment?: string | undefined;\n /** Storage root URL for managed tables within schema. */\n storageRoot?: string | undefined;\n /** Whether predictive optimization should be enabled for this object and objects under it. */\n enablePredictiveOptimization?: string | undefined;\n /** Unique identifier of parent metastore. */\n metastoreId?: string | undefined;\n /** Full name of schema, in form of __catalog_name__.__schema_name__. */\n fullName?: string | undefined;\n /** Time at which this schema was created, in epoch milliseconds. */\n createdAt?: bigint | undefined;\n /** Username of schema creator. */\n createdBy?: string | undefined;\n /** Time at which this schema was created, in epoch milliseconds. */\n updatedAt?: bigint | undefined;\n /** Username of user who last modified schema. */\n updatedBy?: string | undefined;\n /** The type of the parent catalog. */\n catalogType?: CatalogType | undefined;\n /** Storage location for managed tables within schema. */\n storageLocation?: string | undefined;\n effectivePredictiveOptimizationFlag?:\n | EffectivePredictiveOptimizationFlag\n | undefined;\n /** The unique identifier of the schema. */\n schemaId?: string | undefined;\n /** Indicates whether the principal is limited to retrieving metadata for the associated object through the BROWSE privilege when include_browse is enabled in the request. */\n browseOnly?: boolean | undefined;\n /** Custom maximum retention period in hours for the schema. */\n customMaxRetentionHours?: bigint | undefined;\n /** A map of key-value properties attached to the securable. */\n properties?: Record<string, string> | undefined;\n /** A map of key-value properties attached to the securable. */\n options?: Record<string, string> | undefined;\n}\n\nexport const unmarshalDeleteSchemaResponseSchema: z.ZodType<DeleteSchemaResponse> =\n z.object({});\n\nexport const unmarshalEffectivePredictiveOptimizationFlagSchema: z.ZodType<EffectivePredictiveOptimizationFlag> =\n z\n .object({\n value: z.string().optional(),\n inherited_from_type: z.string().optional(),\n inherited_from_name: z.string().optional(),\n })\n .transform(d => ({\n value: d.value,\n inheritedFromType: d.inherited_from_type,\n inheritedFromName: d.inherited_from_name,\n }));\n\nexport const unmarshalListSchemasResponseSchema: z.ZodType<ListSchemasResponse> =\n z\n .object({\n schemas: z.array(z.lazy(() => unmarshalSchemaInfoSchema)).optional(),\n next_page_token: z.string().optional(),\n })\n .transform(d => ({\n schemas: d.schemas,\n nextPageToken: d.next_page_token,\n }));\n\nexport const unmarshalSchemaInfoSchema: z.ZodType<SchemaInfo> = z\n .object({\n name: z.string().optional(),\n catalog_name: z.string().optional(),\n owner: z.string().optional(),\n comment: z.string().optional(),\n storage_root: z.string().optional(),\n enable_predictive_optimization: z.string().optional(),\n metastore_id: z.string().optional(),\n full_name: z.string().optional(),\n created_at: z\n .union([z.number(), z.bigint()])\n .transform(v => BigInt(v))\n .optional(),\n created_by: z.string().optional(),\n updated_at: z\n .union([z.number(), z.bigint()])\n .transform(v => BigInt(v))\n .optional(),\n updated_by: z.string().optional(),\n catalog_type: z.string().optional(),\n storage_location: z.string().optional(),\n effective_predictive_optimization_flag: z\n .lazy(() => unmarshalEffectivePredictiveOptimizationFlagSchema)\n .optional(),\n schema_id: z.string().optional(),\n browse_only: z.boolean().optional(),\n custom_max_retention_hours: z\n .union([z.number(), z.bigint()])\n .transform(v => BigInt(v))\n .optional(),\n properties: z.record(z.string(), z.string()).optional(),\n options: z.record(z.string(), z.string()).optional(),\n })\n .transform(d => ({\n name: d.name,\n catalogName: d.catalog_name,\n owner: d.owner,\n comment: d.comment,\n storageRoot: d.storage_root,\n enablePredictiveOptimization: d.enable_predictive_optimization,\n metastoreId: d.metastore_id,\n fullName: d.full_name,\n createdAt: d.created_at,\n createdBy: d.created_by,\n updatedAt: d.updated_at,\n updatedBy: d.updated_by,\n catalogType: d.catalog_type,\n storageLocation: d.storage_location,\n effectivePredictiveOptimizationFlag:\n d.effective_predictive_optimization_flag,\n schemaId: d.schema_id,\n browseOnly: d.browse_only,\n customMaxRetentionHours: d.custom_max_retention_hours,\n properties: d.properties,\n options: d.options,\n }));\n\nexport const marshalCreateSchemaRequestSchema: z.ZodType = z\n .object({\n name: z.string().optional(),\n catalogName: z.string().optional(),\n owner: z.string().optional(),\n comment: z.string().optional(),\n storageRoot: z.string().optional(),\n enablePredictiveOptimization: z.string().optional(),\n metastoreId: z.string().optional(),\n fullName: z.string().optional(),\n createdAt: z.bigint().optional(),\n createdBy: z.string().optional(),\n updatedAt: z.bigint().optional(),\n updatedBy: z.string().optional(),\n catalogType: z.string().optional(),\n storageLocation: z.string().optional(),\n effectivePredictiveOptimizationFlag: z\n .lazy(() => marshalEffectivePredictiveOptimizationFlagSchema)\n .optional(),\n schemaId: z.string().optional(),\n browseOnly: z.boolean().optional(),\n customMaxRetentionHours: z.bigint().optional(),\n properties: z.record(z.string(), z.string()).optional(),\n options: z.record(z.string(), z.string()).optional(),\n })\n .transform(d => ({\n name: d.name,\n catalog_name: d.catalogName,\n owner: d.owner,\n comment: d.comment,\n storage_root: d.storageRoot,\n enable_predictive_optimization: d.enablePredictiveOptimization,\n metastore_id: d.metastoreId,\n full_name: d.fullName,\n created_at: d.createdAt,\n created_by: d.createdBy,\n updated_at: d.updatedAt,\n updated_by: d.updatedBy,\n catalog_type: d.catalogType,\n storage_location: d.storageLocation,\n effective_predictive_optimization_flag:\n d.effectivePredictiveOptimizationFlag,\n schema_id: d.schemaId,\n browse_only: d.browseOnly,\n custom_max_retention_hours: d.customMaxRetentionHours,\n properties: d.properties,\n options: d.options,\n }));\n\nexport const marshalEffectivePredictiveOptimizationFlagSchema: z.ZodType = z\n .object({\n value: z.string().optional(),\n inheritedFromType: z.string().optional(),\n inheritedFromName: z.string().optional(),\n })\n .transform(d => ({\n value: d.value,\n inherited_from_type: d.inheritedFromType,\n inherited_from_name: d.inheritedFromName,\n }));\n\nexport const marshalUpdateSchemaRequestSchema: z.ZodType = z\n .object({\n fullNameArg: z.string().optional(),\n newName: z.string().optional(),\n name: z.string().optional(),\n catalogName: z.string().optional(),\n owner: z.string().optional(),\n comment: z.string().optional(),\n storageRoot: z.string().optional(),\n enablePredictiveOptimization: z.string().optional(),\n metastoreId: z.string().optional(),\n fullName: z.string().optional(),\n createdAt: z.bigint().optional(),\n createdBy: z.string().optional(),\n updatedAt: z.bigint().optional(),\n updatedBy: z.string().optional(),\n catalogType: z.string().optional(),\n storageLocation: z.string().optional(),\n effectivePredictiveOptimizationFlag: z\n .lazy(() => marshalEffectivePredictiveOptimizationFlagSchema)\n .optional(),\n schemaId: z.string().optional(),\n browseOnly: z.boolean().optional(),\n customMaxRetentionHours: z.bigint().optional(),\n properties: z.record(z.string(), z.string()).optional(),\n options: z.record(z.string(), z.string()).optional(),\n })\n .transform(d => ({\n full_name_arg: d.fullNameArg,\n new_name: d.newName,\n name: d.name,\n catalog_name: d.catalogName,\n owner: d.owner,\n comment: d.comment,\n storage_root: d.storageRoot,\n enable_predictive_optimization: d.enablePredictiveOptimization,\n metastore_id: d.metastoreId,\n full_name: d.fullName,\n created_at: d.createdAt,\n created_by: d.createdBy,\n updated_at: d.updatedAt,\n updated_by: d.updatedBy,\n catalog_type: d.catalogType,\n storage_location: d.storageLocation,\n effective_predictive_optimization_flag:\n d.effectivePredictiveOptimizationFlag,\n schema_id: d.schemaId,\n browse_only: d.browseOnly,\n custom_max_retention_hours: d.customMaxRetentionHours,\n properties: d.properties,\n options: d.options,\n }));\n"],"mappings":";;;;AAMA,MAAa,cAAc;CACzB,iBAAiB;CACjB,sBAAsB;CACtB,gBAAgB;CAChB,kBAAkB;CAClB,iBAA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,EAAE"}
@@ -1,23 +1,25 @@
1
- import type { HttpClient } from '@databricks/sdk-core/http';
2
- import type { ClientOptions } from '@databricks/sdk-options/client';
1
+ import { HttpClient } from "@databricks/sdk-core/http";
2
+ import { ClientOptions } from "@databricks/sdk-options/client";
3
+
4
+ //#region src/v1/transport.d.ts
3
5
  /**
4
6
  * The configuration a client needs to issue requests, resolved from
5
7
  * {@link ClientOptions} and a configuration profile.
6
8
  */
7
- export interface ResolvedClientConfig {
8
- /** Host with any trailing slash removed. */
9
- host: string;
10
- /**
11
- * Default account ID for account-level paths that contain an account_id
12
- * segment. A request's own accountId still wins.
13
- */
14
- accountId?: string;
15
- /**
16
- * Workspace ID used to route workspace-level calls on unified hosts (SPOG).
17
- */
18
- workspaceId?: string;
19
- /** HTTP client with authentication, and any configured timeout, applied. */
20
- httpClient: HttpClient;
9
+ interface ResolvedClientConfig {
10
+ /** Host with any trailing slash removed. */
11
+ host: string;
12
+ /**
13
+ * Default account ID for account-level paths that contain an account_id
14
+ * segment. A request's own accountId still wins.
15
+ */
16
+ accountId?: string;
17
+ /**
18
+ * Workspace ID used to route workspace-level calls on unified hosts (SPOG).
19
+ */
20
+ workspaceId?: string;
21
+ /** HTTP client with authentication, and any configured timeout, applied. */
22
+ httpClient: HttpClient;
21
23
  }
22
24
  /**
23
25
  * Resolves {@link ClientOptions} into a {@link ResolvedClientConfig}.
@@ -29,5 +31,7 @@ export interface ResolvedClientConfig {
29
31
  *
30
32
  * @throws if host is neither provided nor present in the resolved profile.
31
33
  */
32
- export declare function resolveClientConfig(options: ClientOptions): Promise<ResolvedClientConfig>;
34
+ declare function resolveClientConfig(options: ClientOptions): Promise<ResolvedClientConfig>;
35
+ //#endregion
36
+ export { ResolvedClientConfig, resolveClientConfig };
33
37
  //# sourceMappingURL=transport.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"transport.d.ts","sourceRoot":"","sources":["../../src/v1/transport.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,UAAU,EAGX,MAAM,2BAA2B,CAAC;AAInC,OAAO,KAAK,EAAC,aAAa,EAAC,MAAM,gCAAgC,CAAC;AAElE;;;GAGG;AACH,MAAM,WAAW,oBAAoB;IACnC,4CAA4C;IAC5C,IAAI,EAAE,MAAM,CAAC;IAEb;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,4EAA4E;IAC5E,UAAU,EAAE,UAAU,CAAC;CACxB;AAED;;;;;;;;;GASG;AACH,wBAAsB,mBAAmB,CACvC,OAAO,EAAE,aAAa,GACrB,OAAO,CAAC,oBAAoB,CAAC,CA4B/B"}
1
+ {"version":3,"file":"transport.d.ts","names":[],"sources":["../../src/v1/transport.ts"],"mappings":";;;;;;AAkBA;;UAAiB,oBAAA;EAgBO;EAdtB,IAAA;EAMA;;;;EAAA,SAAA;EAQsB;AAaxB;;EAhBE,WAAA;EAiBS;EAdT,UAAA,EAAY,UAAA;AAAA;;;;;;;;;;;iBAaQ,mBAAA,CACpB,OAAA,EAAS,aAAA,GACR,OAAA,CAAQ,oBAAA"}
@@ -1,74 +1,65 @@
1
- // Code generated from API definition by Databricks SDK Generator. DO NOT EDIT.
2
- import { defaultCredentials } from '@databricks/sdk-auth/credentials';
3
- import { newFetchHttpClient } from '@databricks/sdk-core/http';
4
- import { resolve } from '@databricks/sdk-core/profiles';
1
+ import { defaultCredentials } from "@databricks/sdk-auth/credentials";
2
+ import { newFetchHttpClient } from "@databricks/sdk-core/http";
3
+ import { resolve } from "@databricks/sdk-core/profiles";
4
+
5
+ //#region src/v1/transport.ts
5
6
  /**
6
- * Resolves {@link ClientOptions} into a {@link ResolvedClientConfig}.
7
- *
8
- * A configuration profile is always resolved from the config file and
9
- * environment variables (per options.profileOptions); it supplies host,
10
- * accountId, workspaceId, and credentials wherever the caller did not set them
11
- * explicitly. Explicit options always take precedence.
12
- *
13
- * @throws if host is neither provided nor present in the resolved profile.
14
- */
15
- export async function resolveClientConfig(options) {
16
- const profile = await resolve(options.profileOptions);
17
- const host = options.host ?? profile.host;
18
- if (host === undefined) {
19
- throw new Error('Host is required.');
20
- }
21
- // The provided httpClient (or the default fetch client) is the base wire;
22
- // authentication and the optional timeout are layered on top of it. The
23
- // default credential chain reuses the profile resolved above so that the
24
- // same profileOptions govern host and authentication alike.
25
- const base = options.httpClient ?? newFetchHttpClient();
26
- const credentials = options.credentials ?? defaultCredentials({ profile });
27
- let httpClient = new AuthHttpClient(base, credentials);
28
- if (options.timeout !== undefined) {
29
- httpClient = new TimeoutHttpClient(httpClient, options.timeout);
30
- }
31
- const accountId = options.accountId ?? profile.accountId;
32
- const workspaceId = options.workspaceId ?? profile.workspaceId;
33
- return {
34
- host: host.replace(/\/$/, ''),
35
- httpClient,
36
- ...(accountId !== undefined && { accountId }),
37
- ...(workspaceId !== undefined && { workspaceId }),
38
- };
7
+ * Resolves {@link ClientOptions} into a {@link ResolvedClientConfig}.
8
+ *
9
+ * A configuration profile is always resolved from the config file and
10
+ * environment variables (per options.profileOptions); it supplies host,
11
+ * accountId, workspaceId, and credentials wherever the caller did not set them
12
+ * explicitly. Explicit options always take precedence.
13
+ *
14
+ * @throws if host is neither provided nor present in the resolved profile.
15
+ */
16
+ async function resolveClientConfig(options) {
17
+ const profile = await resolve(options.profileOptions);
18
+ const host = options.host ?? profile.host;
19
+ if (host === void 0) throw new Error("Host is required.");
20
+ let httpClient = new AuthHttpClient(options.httpClient ?? newFetchHttpClient(), options.credentials ?? defaultCredentials({ profile }));
21
+ if (options.timeout !== void 0) httpClient = new TimeoutHttpClient(httpClient, options.timeout);
22
+ const accountId = options.accountId ?? profile.accountId;
23
+ const workspaceId = options.workspaceId ?? profile.workspaceId;
24
+ return {
25
+ host: host.replace(/\/$/, ""),
26
+ httpClient,
27
+ ...accountId !== void 0 && { accountId },
28
+ ...workspaceId !== void 0 && { workspaceId }
29
+ };
39
30
  }
40
31
  /** Wraps an HttpClient and adds authentication headers to requests. */
41
- class AuthHttpClient {
42
- base;
43
- credentials;
44
- constructor(base, credentials) {
45
- this.base = base;
46
- this.credentials = credentials;
47
- }
48
- async send(request) {
49
- const authHeaders = await this.credentials.authHeaders();
50
- // Do not modify the original request.
51
- const headers = new Headers(request.headers);
52
- for (const h of authHeaders) {
53
- headers.set(h.key, h.value);
54
- }
55
- return this.base.send({ ...request, headers });
56
- }
57
- }
32
+ var AuthHttpClient = class {
33
+ constructor(base, credentials) {
34
+ this.base = base;
35
+ this.credentials = credentials;
36
+ }
37
+ async send(request) {
38
+ const authHeaders = await this.credentials.authHeaders();
39
+ const headers = new Headers(request.headers);
40
+ for (const h of authHeaders) headers.set(h.key, h.value);
41
+ return this.base.send({
42
+ ...request,
43
+ headers
44
+ });
45
+ }
46
+ };
58
47
  /** Wraps an HttpClient and applies a default timeout to requests. */
59
- class TimeoutHttpClient {
60
- base;
61
- timeout;
62
- constructor(base, timeout) {
63
- this.base = base;
64
- this.timeout = timeout;
65
- }
66
- async send(request) {
67
- const timeoutSignal = AbortSignal.timeout(this.timeout);
68
- const signal = request.signal !== undefined
69
- ? AbortSignal.any([request.signal, timeoutSignal])
70
- : timeoutSignal;
71
- return this.base.send({ ...request, signal });
72
- }
73
- }
48
+ var TimeoutHttpClient = class {
49
+ constructor(base, timeout) {
50
+ this.base = base;
51
+ this.timeout = timeout;
52
+ }
53
+ async send(request) {
54
+ const timeoutSignal = AbortSignal.timeout(this.timeout);
55
+ const signal = request.signal !== void 0 ? AbortSignal.any([request.signal, timeoutSignal]) : timeoutSignal;
56
+ return this.base.send({
57
+ ...request,
58
+ signal
59
+ });
60
+ }
61
+ };
62
+
63
+ //#endregion
64
+ export { resolveClientConfig };
74
65
  //# sourceMappingURL=transport.js.map