@distilled.cloud/starburst-galaxy 0.0.0 → 1.0.0-rc.21
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/LICENSE +201 -0
- package/README.md +110 -4
- package/lib/.lazy.json +1 -0
- package/lib/_bundle/lazy.js +4 -0
- package/lib/_bundle/sdk.js +2 -0
- package/lib/_bundle/sdk.js.map +1 -0
- package/lib/credentials.d.ts +84 -0
- package/lib/credentials.d.ts.map +1 -0
- package/lib/credentials.js +1 -0
- package/lib/errors.d.ts +83 -0
- package/lib/errors.d.ts.map +1 -0
- package/lib/errors.js +1 -0
- package/lib/index.d.ts +42 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +6 -0
- package/lib/pagination.d.ts +10 -0
- package/lib/pagination.d.ts.map +1 -0
- package/lib/pagination.js +1 -0
- package/lib/protocol.d.ts +29 -0
- package/lib/protocol.d.ts.map +1 -0
- package/lib/protocol.js +1 -0
- package/lib/retry.d.ts +32 -0
- package/lib/retry.d.ts.map +1 -0
- package/lib/retry.js +1 -0
- package/lib/services/catalog.d.ts +2791 -0
- package/lib/services/catalog.d.ts.map +1 -0
- package/lib/services/catalog.js +101 -0
- package/lib/services/catalog.js.map +1 -0
- package/lib/services/cluster.d.ts +248 -0
- package/lib/services/cluster.d.ts.map +1 -0
- package/lib/services/cluster.js +2 -0
- package/lib/services/cluster.js.map +1 -0
- package/lib/services/column_mask.d.ts +162 -0
- package/lib/services/column_mask.d.ts.map +1 -0
- package/lib/services/column_mask.js +2 -0
- package/lib/services/column_mask.js.map +1 -0
- package/lib/services/cross_account_iam_role.d.ts +133 -0
- package/lib/services/cross_account_iam_role.d.ts.map +1 -0
- package/lib/services/cross_account_iam_role.js +2 -0
- package/lib/services/cross_account_iam_role.js.map +1 -0
- package/lib/services/data_domain.d.ts +223 -0
- package/lib/services/data_domain.d.ts.map +1 -0
- package/lib/services/data_domain.js +2 -0
- package/lib/services/data_domain.js.map +1 -0
- package/lib/services/data_product.d.ts +290 -0
- package/lib/services/data_product.d.ts.map +1 -0
- package/lib/services/data_product.js +2 -0
- package/lib/services/data_product.js.map +1 -0
- package/lib/services/data_product_usage_example.d.ts +158 -0
- package/lib/services/data_product_usage_example.d.ts.map +1 -0
- package/lib/services/data_product_usage_example.js +2 -0
- package/lib/services/data_product_usage_example.js.map +1 -0
- package/lib/services/data_quality.d.ts +344 -0
- package/lib/services/data_quality.d.ts.map +1 -0
- package/lib/services/data_quality.js +2 -0
- package/lib/services/data_quality.js.map +1 -0
- package/lib/services/data_quality_metrics.d.ts +282 -0
- package/lib/services/data_quality_metrics.d.ts.map +1 -0
- package/lib/services/data_quality_metrics.js +2 -0
- package/lib/services/data_quality_metrics.js.map +1 -0
- package/lib/services/data_quality_schedule.d.ts +220 -0
- package/lib/services/data_quality_schedule.d.ts.map +1 -0
- package/lib/services/data_quality_schedule.js +2 -0
- package/lib/services/data_quality_schedule.js.map +1 -0
- package/lib/services/discovery.d.ts +439 -0
- package/lib/services/discovery.d.ts.map +1 -0
- package/lib/services/discovery.js +36 -0
- package/lib/services/discovery.js.map +1 -0
- package/lib/services/file_ingest_source.d.ts +205 -0
- package/lib/services/file_ingest_source.d.ts.map +1 -0
- package/lib/services/file_ingest_source.js +2 -0
- package/lib/services/file_ingest_source.js.map +1 -0
- package/lib/services/group.d.ts +140 -0
- package/lib/services/group.d.ts.map +1 -0
- package/lib/services/group.js +2 -0
- package/lib/services/group.js.map +1 -0
- package/lib/services/index.d.ts +26 -0
- package/lib/services/index.d.ts.map +1 -0
- package/lib/services/index.js +25 -0
- package/lib/services/kafka_ingest_source.d.ts +236 -0
- package/lib/services/kafka_ingest_source.d.ts.map +1 -0
- package/lib/services/kafka_ingest_source.js +2 -0
- package/lib/services/kafka_ingest_source.js.map +1 -0
- package/lib/services/live_table.d.ts +851 -0
- package/lib/services/live_table.d.ts.map +1 -0
- package/lib/services/live_table.js +20 -0
- package/lib/services/live_table.js.map +1 -0
- package/lib/services/policy.d.ts +213 -0
- package/lib/services/policy.d.ts.map +1 -0
- package/lib/services/policy.js +2 -0
- package/lib/services/policy.js.map +1 -0
- package/lib/services/privatelink.d.ts +95 -0
- package/lib/services/privatelink.d.ts.map +1 -0
- package/lib/services/privatelink.js +2 -0
- package/lib/services/privatelink.js.map +1 -0
- package/lib/services/privilege.d.ts +167 -0
- package/lib/services/privilege.d.ts.map +1 -0
- package/lib/services/privilege.js +2 -0
- package/lib/services/privilege.js.map +1 -0
- package/lib/services/role.d.ts +222 -0
- package/lib/services/role.d.ts.map +1 -0
- package/lib/services/role.js +2 -0
- package/lib/services/role.js.map +1 -0
- package/lib/services/row_filter.d.ts +155 -0
- package/lib/services/row_filter.d.ts.map +1 -0
- package/lib/services/row_filter.js +2 -0
- package/lib/services/row_filter.js.map +1 -0
- package/lib/services/schema_discovery.d.ts +236 -0
- package/lib/services/schema_discovery.d.ts.map +1 -0
- package/lib/services/schema_discovery.js +2 -0
- package/lib/services/schema_discovery.js.map +1 -0
- package/lib/services/service_account.d.ts +206 -0
- package/lib/services/service_account.d.ts.map +1 -0
- package/lib/services/service_account.js +2 -0
- package/lib/services/service_account.js.map +1 -0
- package/lib/services/sql_jobs.d.ts +264 -0
- package/lib/services/sql_jobs.d.ts.map +1 -0
- package/lib/services/sql_jobs.js +2 -0
- package/lib/services/sql_jobs.js.map +1 -0
- package/lib/services/tag.d.ts +287 -0
- package/lib/services/tag.d.ts.map +1 -0
- package/lib/services/tag.js +2 -0
- package/lib/services/tag.js.map +1 -0
- package/lib/services/user.d.ts +175 -0
- package/lib/services/user.d.ts.map +1 -0
- package/lib/services/user.js +2 -0
- package/lib/services/user.js.map +1 -0
- package/lib/services.lazy/catalog.js +4 -0
- package/lib/services.lazy/cluster.js +1 -0
- package/lib/services.lazy/column_mask.js +1 -0
- package/lib/services.lazy/cross_account_iam_role.js +1 -0
- package/lib/services.lazy/data_domain.js +1 -0
- package/lib/services.lazy/data_product.js +1 -0
- package/lib/services.lazy/data_product_usage_example.js +1 -0
- package/lib/services.lazy/data_quality.js +1 -0
- package/lib/services.lazy/data_quality_metrics.js +1 -0
- package/lib/services.lazy/data_quality_schedule.js +1 -0
- package/lib/services.lazy/discovery.js +4 -0
- package/lib/services.lazy/file_ingest_source.js +1 -0
- package/lib/services.lazy/group.js +1 -0
- package/lib/services.lazy/index.js +3 -0
- package/lib/services.lazy/kafka_ingest_source.js +1 -0
- package/lib/services.lazy/live_table.js +4 -0
- package/lib/services.lazy/policy.js +1 -0
- package/lib/services.lazy/privatelink.js +1 -0
- package/lib/services.lazy/privilege.js +1 -0
- package/lib/services.lazy/role.js +1 -0
- package/lib/services.lazy/row_filter.js +1 -0
- package/lib/services.lazy/schema_discovery.js +1 -0
- package/lib/services.lazy/service_account.js +1 -0
- package/lib/services.lazy/sql_jobs.js +1 -0
- package/lib/services.lazy/tag.js +1 -0
- package/lib/services.lazy/user.js +1 -0
- package/lib/traits.d.ts +11 -0
- package/lib/traits.d.ts.map +1 -0
- package/lib/traits.js +1 -0
- package/package.json +82 -2
- package/src/credentials.ts +205 -0
- package/src/errors.ts +102 -0
- package/src/index.ts +45 -0
- package/src/pagination.ts +9 -0
- package/src/protocol.ts +94 -0
- package/src/retry.ts +50 -0
- package/src/services/catalog.ts +6636 -0
- package/src/services/cluster.ts +492 -0
- package/src/services/column_mask.ts +388 -0
- package/src/services/cross_account_iam_role.ts +328 -0
- package/src/services/data_domain.ts +509 -0
- package/src/services/data_product.ts +641 -0
- package/src/services/data_product_usage_example.ts +380 -0
- package/src/services/data_quality.ts +771 -0
- package/src/services/data_quality_metrics.ts +580 -0
- package/src/services/data_quality_schedule.ts +454 -0
- package/src/services/discovery.ts +1257 -0
- package/src/services/file_ingest_source.ts +480 -0
- package/src/services/group.ts +282 -0
- package/src/services/index.ts +26 -0
- package/src/services/kafka_ingest_source.ts +545 -0
- package/src/services/live_table.ts +1537 -0
- package/src/services/policy.ts +526 -0
- package/src/services/privatelink.ts +209 -0
- package/src/services/privilege.ts +423 -0
- package/src/services/role.ts +501 -0
- package/src/services/row_filter.ts +365 -0
- package/src/services/schema_discovery.ts +516 -0
- package/src/services/service_account.ts +525 -0
- package/src/services/sql_jobs.ts +621 -0
- package/src/services/tag.ts +785 -0
- package/src/services/user.ts +375 -0
- package/src/traits.ts +44 -0
|
@@ -0,0 +1,525 @@
|
|
|
1
|
+
import * as API from "@distilled.cloud/core/api";
|
|
2
|
+
import * as C from "@distilled.cloud/core/category";
|
|
3
|
+
// AUTO-GENERATED by scripts/generate.ts from .generated-specs (specs/spec-mirror-starburst-galaxy/specs/{v1,v2}.json). Do not edit.
|
|
4
|
+
import * as S from "@distilled.cloud/core/schema-lite";
|
|
5
|
+
import * as __L from "@distilled.cloud/core/schema-lite";
|
|
6
|
+
import type * as Redacted from "effect/Redacted";
|
|
7
|
+
import { StarburstGalaxyServiceErrors } from "../errors.ts";
|
|
8
|
+
import { paginateToken } from "../pagination.ts";
|
|
9
|
+
import {
|
|
10
|
+
StarburstGalaxyProtocol,
|
|
11
|
+
type StarburstGalaxyOpError,
|
|
12
|
+
type StarburstGalaxyOpContext,
|
|
13
|
+
} from "../protocol.ts";
|
|
14
|
+
import * as Retry from "../retry.ts";
|
|
15
|
+
import * as T from "../traits.ts";
|
|
16
|
+
// Schema table, filled on first reach (see __S at the end).
|
|
17
|
+
const __s: any[] = [];
|
|
18
|
+
|
|
19
|
+
export type { StarburstGalaxyOpError, StarburstGalaxyOpContext };
|
|
20
|
+
|
|
21
|
+
/** Span facts shared by every operation (com.distilled.telemetry#service). */
|
|
22
|
+
const TELEMETRY = {
|
|
23
|
+
system: "starburst-galaxy-api",
|
|
24
|
+
responseHeaders: [
|
|
25
|
+
{ header: "x-request-id", name: "http.response.header.x-request-id", transform: "list" },
|
|
26
|
+
{ header: "request-id", name: "http.response.header.request-id", transform: "list" },
|
|
27
|
+
],
|
|
28
|
+
prefix: "StarburstGalaxy",
|
|
29
|
+
service: "ServiceAccountService",
|
|
30
|
+
labels: "starburst_galaxy",
|
|
31
|
+
propagate: "w3c",
|
|
32
|
+
} as const;
|
|
33
|
+
|
|
34
|
+
export class BadRequest
|
|
35
|
+
extends /*@__PURE__*/ T.applyErrorMatchers(
|
|
36
|
+
/*@__PURE__*/ S.TaggedError<BadRequest>()("BadRequest", {
|
|
37
|
+
message: S.String,
|
|
38
|
+
body: S.Unknown,
|
|
39
|
+
headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
|
|
40
|
+
}).pipe(C.withBadRequestError),
|
|
41
|
+
[{ status: 400 }],
|
|
42
|
+
) {}
|
|
43
|
+
|
|
44
|
+
export class Conflict
|
|
45
|
+
extends /*@__PURE__*/ T.applyErrorMatchers(
|
|
46
|
+
/*@__PURE__*/ S.TaggedError<Conflict>()("Conflict", {
|
|
47
|
+
message: S.String,
|
|
48
|
+
body: S.Unknown,
|
|
49
|
+
headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
|
|
50
|
+
}).pipe(C.withConflictError),
|
|
51
|
+
[{ status: 409 }],
|
|
52
|
+
) {}
|
|
53
|
+
|
|
54
|
+
export class Forbidden
|
|
55
|
+
extends /*@__PURE__*/ T.applyErrorMatchers(
|
|
56
|
+
/*@__PURE__*/ S.TaggedError<Forbidden>()("Forbidden", {
|
|
57
|
+
message: S.String,
|
|
58
|
+
body: S.Unknown,
|
|
59
|
+
headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
|
|
60
|
+
}).pipe(C.withAuthError),
|
|
61
|
+
[{ status: 403 }],
|
|
62
|
+
) {}
|
|
63
|
+
|
|
64
|
+
export class NotFound
|
|
65
|
+
extends /*@__PURE__*/ T.applyErrorMatchers(
|
|
66
|
+
/*@__PURE__*/ S.TaggedError<NotFound>()("NotFound", {
|
|
67
|
+
message: S.String,
|
|
68
|
+
body: S.Unknown,
|
|
69
|
+
headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
|
|
70
|
+
}).pipe(C.withBadRequestError),
|
|
71
|
+
[{ status: 404 }],
|
|
72
|
+
) {}
|
|
73
|
+
|
|
74
|
+
/** Additional role IDs (read only) */
|
|
75
|
+
export type CreateServiceAccountRequestAdditionalRoleIdsList = Array<string>;
|
|
76
|
+
export interface CreateServiceAccountRequest {
|
|
77
|
+
/** Service account name (read only) */
|
|
78
|
+
username: string;
|
|
79
|
+
/** Default role ID (read only) */
|
|
80
|
+
roleId?: string | undefined;
|
|
81
|
+
/** Additional role IDs (read only) */
|
|
82
|
+
additionalRoleIds: CreateServiceAccountRequestAdditionalRoleIdsList;
|
|
83
|
+
/** Whether to create an initial password (read only) */
|
|
84
|
+
withInitialPassword: boolean;
|
|
85
|
+
}
|
|
86
|
+
/** Additional roles (read only) */
|
|
87
|
+
export type ServiceAccountAdditionalRoleIdsList = Array<string>;
|
|
88
|
+
/** Passwords (read only) */
|
|
89
|
+
export interface ServiceAccountPassword {
|
|
90
|
+
/** Used to ensure consistency for resource updates. A syncToken that is returned from the server is valid until the resource is updated when a new syncToken will be generated. Only the latest version of the object is maintained. (read only) */
|
|
91
|
+
syncToken: string;
|
|
92
|
+
/** Service account password ID (read only) */
|
|
93
|
+
serviceAccountPasswordId: string;
|
|
94
|
+
/** Service account password prefix (read only) */
|
|
95
|
+
passwordPrefix: string | Redacted.Redacted<string>;
|
|
96
|
+
/** Service account password (read only) */
|
|
97
|
+
password?: string | Redacted.Redacted<string> | undefined;
|
|
98
|
+
/** Description (read only) */
|
|
99
|
+
description?: string | undefined;
|
|
100
|
+
/** Creation time (read only) */
|
|
101
|
+
created: string;
|
|
102
|
+
/** Last login time (read only) */
|
|
103
|
+
lastLogin?: string | undefined;
|
|
104
|
+
}
|
|
105
|
+
/** Passwords (read only) */
|
|
106
|
+
export type ServiceAccountPasswordsList = Array<ServiceAccountPassword>;
|
|
107
|
+
/** A service account */
|
|
108
|
+
export interface ServiceAccount {
|
|
109
|
+
/** Used to ensure consistency for resource updates. A syncToken that is returned from the server is valid until the resource is updated when a new syncToken will be generated. Only the latest version of the object is maintained. (read only) */
|
|
110
|
+
syncToken: string;
|
|
111
|
+
/** Service account ID (read only) */
|
|
112
|
+
serviceAccountId: string;
|
|
113
|
+
/** Service account user name (read only) */
|
|
114
|
+
userName: string;
|
|
115
|
+
/** Default role (read only) */
|
|
116
|
+
roleId: string;
|
|
117
|
+
/** Additional roles (read only) */
|
|
118
|
+
additionalRoleIds: ServiceAccountAdditionalRoleIdsList;
|
|
119
|
+
/** Passwords (read only) */
|
|
120
|
+
passwords: ServiceAccountPasswordsList;
|
|
121
|
+
}
|
|
122
|
+
export interface CreateServiceAccountPasswordRequest {
|
|
123
|
+
/** A service account */
|
|
124
|
+
serviceAccountId: string;
|
|
125
|
+
/** Service account password description (read only) */
|
|
126
|
+
description?: string | undefined;
|
|
127
|
+
}
|
|
128
|
+
export interface DeleteServiceAccountRequest {
|
|
129
|
+
/** A service account */
|
|
130
|
+
serviceAccountId: string;
|
|
131
|
+
}
|
|
132
|
+
export interface DeleteServiceAccountResponse {}
|
|
133
|
+
export interface DeleteServiceAccountPasswordRequest {
|
|
134
|
+
/** A service account */
|
|
135
|
+
serviceAccountId: string;
|
|
136
|
+
/** A service account password */
|
|
137
|
+
serviceAccountPasswordId: string;
|
|
138
|
+
}
|
|
139
|
+
export interface DeleteServiceAccountPasswordResponse {}
|
|
140
|
+
export interface GetServiceAccountRequest {
|
|
141
|
+
/** A service account */
|
|
142
|
+
serviceAccountId: string;
|
|
143
|
+
}
|
|
144
|
+
export interface ListServiceAccountsRequest {
|
|
145
|
+
/** Pagination token */
|
|
146
|
+
pageToken?: string | undefined;
|
|
147
|
+
/** Page size or 0 for default (current maximum is 100) */
|
|
148
|
+
pageSize?: number | undefined;
|
|
149
|
+
}
|
|
150
|
+
/** A page of results. */
|
|
151
|
+
export type PaginatedServiceAccountResultList = Array<ServiceAccount>;
|
|
152
|
+
export interface PaginatedServiceAccount {
|
|
153
|
+
/** The next page token to use or "" if there are no more pages. */
|
|
154
|
+
nextPageToken?: string | undefined;
|
|
155
|
+
/** A page of results. */
|
|
156
|
+
result: PaginatedServiceAccountResultList;
|
|
157
|
+
}
|
|
158
|
+
/** Additional roles */
|
|
159
|
+
export type UpdateServiceAccountRequestAdditionalRoleIdsList = Array<string>;
|
|
160
|
+
export interface UpdateServiceAccountRequest {
|
|
161
|
+
/** A service account */
|
|
162
|
+
serviceAccountId: string;
|
|
163
|
+
/** Default role ID */
|
|
164
|
+
roleId?: string | undefined;
|
|
165
|
+
/** Additional roles */
|
|
166
|
+
additionalRoleIds?: UpdateServiceAccountRequestAdditionalRoleIdsList | undefined;
|
|
167
|
+
}
|
|
168
|
+
/** Any fields/values that are invalid or incorrect */
|
|
169
|
+
export type BadRequestFieldsList = Array<string>;
|
|
170
|
+
/** Invalid request */
|
|
171
|
+
export interface BadRequest2 {
|
|
172
|
+
/** Description of the error */
|
|
173
|
+
message?: string | undefined;
|
|
174
|
+
/** Any fields/values that are invalid or incorrect */
|
|
175
|
+
fields?: BadRequestFieldsList | undefined;
|
|
176
|
+
}
|
|
177
|
+
/** Already exists */
|
|
178
|
+
export interface Exists {
|
|
179
|
+
message?: string | undefined;
|
|
180
|
+
}
|
|
181
|
+
/** Authorization failed */
|
|
182
|
+
export type Forbidden2 = Exists;
|
|
183
|
+
/** Error details (read only) */
|
|
184
|
+
export interface Resourceinfo {
|
|
185
|
+
/** Name of the resource (read only) */
|
|
186
|
+
resourceName: string;
|
|
187
|
+
/** Violation description (read only) */
|
|
188
|
+
description: string;
|
|
189
|
+
}
|
|
190
|
+
/** A specified resource is not found. */
|
|
191
|
+
export interface NotFoundError {
|
|
192
|
+
/** Description of the error */
|
|
193
|
+
message: string;
|
|
194
|
+
detail: Resourceinfo;
|
|
195
|
+
}
|
|
196
|
+
/** Any fields/values that weren't found */
|
|
197
|
+
export type NotFoundFieldsList = Array<string>;
|
|
198
|
+
/** A resource or required component was not found */
|
|
199
|
+
export interface NotFound2 {
|
|
200
|
+
/** Name of the resource */
|
|
201
|
+
message: string;
|
|
202
|
+
/** Violation description */
|
|
203
|
+
description?: string | undefined;
|
|
204
|
+
/** Any fields/values that weren't found */
|
|
205
|
+
fields?: NotFoundFieldsList | undefined;
|
|
206
|
+
}
|
|
207
|
+
export type CreateServiceAccountError =
|
|
208
|
+
| BadRequest
|
|
209
|
+
| Forbidden
|
|
210
|
+
| NotFound
|
|
211
|
+
| Conflict
|
|
212
|
+
| StarburstGalaxyOpError;
|
|
213
|
+
/** Create a service account */
|
|
214
|
+
export const createServiceAccount: API.OperationMethod<
|
|
215
|
+
CreateServiceAccountRequest,
|
|
216
|
+
ServiceAccount,
|
|
217
|
+
CreateServiceAccountError,
|
|
218
|
+
StarburstGalaxyOpContext
|
|
219
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
220
|
+
input: __S(4, __c1, 0) as any as S.Schema<CreateServiceAccountRequest>,
|
|
221
|
+
output: __S(14, __c3, 2) as any as S.Schema<ServiceAccount>,
|
|
222
|
+
errors: [BadRequest, Forbidden, NotFound, Conflict],
|
|
223
|
+
serviceErrors: StarburstGalaxyServiceErrors,
|
|
224
|
+
protocol: StarburstGalaxyProtocol,
|
|
225
|
+
retry: Retry.Retry,
|
|
226
|
+
telemetry: TELEMETRY,
|
|
227
|
+
span: "CreateServiceAccount",
|
|
228
|
+
}));
|
|
229
|
+
|
|
230
|
+
export type CreateServiceAccountPasswordError =
|
|
231
|
+
| BadRequest
|
|
232
|
+
| Forbidden
|
|
233
|
+
| NotFound
|
|
234
|
+
| Conflict
|
|
235
|
+
| StarburstGalaxyOpError;
|
|
236
|
+
/** Create a new service account password. To construct the password to be used for querying, concatenate the following strings without the angle brackets: GXY$<passwordPrefix><password>. The values for these can be found in the reply JSON */
|
|
237
|
+
export const createServiceAccountPassword: API.OperationMethod<
|
|
238
|
+
CreateServiceAccountPasswordRequest,
|
|
239
|
+
ServiceAccountPassword,
|
|
240
|
+
CreateServiceAccountPasswordError,
|
|
241
|
+
StarburstGalaxyOpContext
|
|
242
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
243
|
+
input: __S(16, __c4, 0) as any as S.Schema<CreateServiceAccountPasswordRequest>,
|
|
244
|
+
output: __S(8, __c2, 0) as any as S.Schema<ServiceAccountPassword>,
|
|
245
|
+
errors: [BadRequest, Forbidden, NotFound, Conflict],
|
|
246
|
+
serviceErrors: StarburstGalaxyServiceErrors,
|
|
247
|
+
protocol: StarburstGalaxyProtocol,
|
|
248
|
+
retry: Retry.Retry,
|
|
249
|
+
telemetry: TELEMETRY,
|
|
250
|
+
span: "CreateServiceAccountPassword",
|
|
251
|
+
}));
|
|
252
|
+
|
|
253
|
+
export type DeleteServiceAccountError = BadRequest | Forbidden | NotFound | StarburstGalaxyOpError;
|
|
254
|
+
/** Delete a service account */
|
|
255
|
+
export const deleteServiceAccount: API.OperationMethod<
|
|
256
|
+
DeleteServiceAccountRequest,
|
|
257
|
+
DeleteServiceAccountResponse,
|
|
258
|
+
DeleteServiceAccountError,
|
|
259
|
+
StarburstGalaxyOpContext
|
|
260
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
261
|
+
input: __S(20, __c5, 0) as any as S.Schema<DeleteServiceAccountRequest>,
|
|
262
|
+
output: __S(24, __c6, 0) as any as S.Schema<DeleteServiceAccountResponse>,
|
|
263
|
+
errors: [BadRequest, Forbidden, NotFound],
|
|
264
|
+
serviceErrors: StarburstGalaxyServiceErrors,
|
|
265
|
+
protocol: StarburstGalaxyProtocol,
|
|
266
|
+
retry: Retry.Retry,
|
|
267
|
+
telemetry: TELEMETRY,
|
|
268
|
+
span: "DeleteServiceAccount",
|
|
269
|
+
}));
|
|
270
|
+
|
|
271
|
+
export type DeleteServiceAccountPasswordError =
|
|
272
|
+
| BadRequest
|
|
273
|
+
| Forbidden
|
|
274
|
+
| NotFound
|
|
275
|
+
| StarburstGalaxyOpError;
|
|
276
|
+
/** Delete a service account password */
|
|
277
|
+
export const deleteServiceAccountPassword: API.OperationMethod<
|
|
278
|
+
DeleteServiceAccountPasswordRequest,
|
|
279
|
+
DeleteServiceAccountPasswordResponse,
|
|
280
|
+
DeleteServiceAccountPasswordError,
|
|
281
|
+
StarburstGalaxyOpContext
|
|
282
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
283
|
+
input: __S(28, __c7, 0) as any as S.Schema<DeleteServiceAccountPasswordRequest>,
|
|
284
|
+
output: __S(24, __c6, 0) as any as S.Schema<DeleteServiceAccountPasswordResponse>,
|
|
285
|
+
errors: [BadRequest, Forbidden, NotFound],
|
|
286
|
+
serviceErrors: StarburstGalaxyServiceErrors,
|
|
287
|
+
protocol: StarburstGalaxyProtocol,
|
|
288
|
+
retry: Retry.Retry,
|
|
289
|
+
telemetry: TELEMETRY,
|
|
290
|
+
span: "DeleteServiceAccountPassword",
|
|
291
|
+
}));
|
|
292
|
+
|
|
293
|
+
export type GetServiceAccountError = BadRequest | Forbidden | NotFound | StarburstGalaxyOpError;
|
|
294
|
+
/** Get a service account by user id */
|
|
295
|
+
export const getServiceAccount: API.OperationMethod<
|
|
296
|
+
GetServiceAccountRequest,
|
|
297
|
+
ServiceAccount,
|
|
298
|
+
GetServiceAccountError,
|
|
299
|
+
StarburstGalaxyOpContext
|
|
300
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
301
|
+
input: __S(32, __c8, 0) as any as S.Schema<GetServiceAccountRequest>,
|
|
302
|
+
output: __S(14, __c3, 2) as any as S.Schema<ServiceAccount>,
|
|
303
|
+
errors: [BadRequest, Forbidden, NotFound],
|
|
304
|
+
serviceErrors: StarburstGalaxyServiceErrors,
|
|
305
|
+
protocol: StarburstGalaxyProtocol,
|
|
306
|
+
retry: Retry.Retry,
|
|
307
|
+
telemetry: TELEMETRY,
|
|
308
|
+
span: "GetServiceAccount",
|
|
309
|
+
}));
|
|
310
|
+
|
|
311
|
+
export type ListServiceAccountsError = BadRequest | Forbidden | NotFound | StarburstGalaxyOpError;
|
|
312
|
+
/** Return all service accounts defined for your account */
|
|
313
|
+
export const listServiceAccounts: API.PaginatedOperationMethod<
|
|
314
|
+
ListServiceAccountsRequest,
|
|
315
|
+
PaginatedServiceAccount,
|
|
316
|
+
ListServiceAccountsError,
|
|
317
|
+
StarburstGalaxyOpContext,
|
|
318
|
+
ServiceAccount
|
|
319
|
+
> = /*@__PURE__*/ API.makePaginated(
|
|
320
|
+
() => ({
|
|
321
|
+
input: __S(36, __c9, 0) as any as S.Schema<ListServiceAccountsRequest>,
|
|
322
|
+
output: __S(38, __c9, 2) as any as S.Schema<PaginatedServiceAccount>,
|
|
323
|
+
errors: [BadRequest, Forbidden, NotFound],
|
|
324
|
+
serviceErrors: StarburstGalaxyServiceErrors,
|
|
325
|
+
protocol: StarburstGalaxyProtocol,
|
|
326
|
+
retry: Retry.Retry,
|
|
327
|
+
telemetry: TELEMETRY,
|
|
328
|
+
span: "ListServiceAccounts",
|
|
329
|
+
pagination: {
|
|
330
|
+
mode: "token",
|
|
331
|
+
inputToken: "pageToken",
|
|
332
|
+
outputToken: "nextPageToken",
|
|
333
|
+
items: "result",
|
|
334
|
+
pageSize: "pageSize",
|
|
335
|
+
} as const,
|
|
336
|
+
}),
|
|
337
|
+
paginateToken,
|
|
338
|
+
) as any;
|
|
339
|
+
|
|
340
|
+
export type UpdateServiceAccountError =
|
|
341
|
+
| BadRequest
|
|
342
|
+
| Forbidden
|
|
343
|
+
| NotFound
|
|
344
|
+
| Conflict
|
|
345
|
+
| StarburstGalaxyOpError;
|
|
346
|
+
/** Update a service account Only include fields you wish to update. Missing or unrecognized fields are ignored. */
|
|
347
|
+
export const updateServiceAccount: API.OperationMethod<
|
|
348
|
+
UpdateServiceAccountRequest,
|
|
349
|
+
ServiceAccount,
|
|
350
|
+
UpdateServiceAccountError,
|
|
351
|
+
StarburstGalaxyOpContext
|
|
352
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
353
|
+
input: __S(0, __c0, 0) as any as S.Schema<UpdateServiceAccountRequest>,
|
|
354
|
+
output: __S(14, __c3, 2) as any as S.Schema<ServiceAccount>,
|
|
355
|
+
errors: [BadRequest, Forbidden, NotFound, Conflict],
|
|
356
|
+
serviceErrors: StarburstGalaxyServiceErrors,
|
|
357
|
+
protocol: StarburstGalaxyProtocol,
|
|
358
|
+
retry: Retry.Retry,
|
|
359
|
+
telemetry: TELEMETRY,
|
|
360
|
+
span: "UpdateServiceAccount",
|
|
361
|
+
}));
|
|
362
|
+
|
|
363
|
+
// Schema builders: each runs one schema initializer, on that schema's first use.
|
|
364
|
+
function __c0(j: number): any {
|
|
365
|
+
switch (j) {
|
|
366
|
+
case 0:
|
|
367
|
+
return S.suspend(() =>
|
|
368
|
+
S.Struct({
|
|
369
|
+
serviceAccountId: S.String.pipe(T.Label()),
|
|
370
|
+
roleId: S.optional(S.String),
|
|
371
|
+
additionalRoleIds: S.optional(__S(12, __c3, 0)),
|
|
372
|
+
}).pipe(
|
|
373
|
+
T.Http({
|
|
374
|
+
method: "PATCH",
|
|
375
|
+
uri: "/public/api/v1/serviceAccount/{serviceAccountId}",
|
|
376
|
+
code: 200,
|
|
377
|
+
}),
|
|
378
|
+
),
|
|
379
|
+
).annotate({ identifier: "UpdateServiceAccountRequest" });
|
|
380
|
+
}
|
|
381
|
+
}
|
|
382
|
+
function __c1(j: number): any {
|
|
383
|
+
switch (j) {
|
|
384
|
+
case 0:
|
|
385
|
+
return S.suspend(() =>
|
|
386
|
+
S.Struct({
|
|
387
|
+
username: S.String,
|
|
388
|
+
roleId: S.optional(S.String),
|
|
389
|
+
additionalRoleIds: __S(12, __c3, 0),
|
|
390
|
+
withInitialPassword: S.Boolean,
|
|
391
|
+
}).pipe(T.Http({ method: "POST", uri: "/public/api/v1/serviceAccount", code: 200 })),
|
|
392
|
+
).annotate({ identifier: "CreateServiceAccountRequest" });
|
|
393
|
+
}
|
|
394
|
+
}
|
|
395
|
+
function __c2(j: number): any {
|
|
396
|
+
switch (j) {
|
|
397
|
+
case 0:
|
|
398
|
+
return S.suspend(() =>
|
|
399
|
+
S.Struct({
|
|
400
|
+
syncToken: S.String,
|
|
401
|
+
serviceAccountPasswordId: S.String,
|
|
402
|
+
passwordPrefix: S.String.pipe(T.SensitiveValue({})),
|
|
403
|
+
password: S.optional(S.String.pipe(T.SensitiveValue({}))),
|
|
404
|
+
description: S.optional(S.String),
|
|
405
|
+
created: S.String,
|
|
406
|
+
lastLogin: S.optional(S.String),
|
|
407
|
+
}),
|
|
408
|
+
).annotate({ identifier: "ServiceAccountPassword" });
|
|
409
|
+
}
|
|
410
|
+
}
|
|
411
|
+
function __c3(j: number): any {
|
|
412
|
+
switch (j) {
|
|
413
|
+
case 0:
|
|
414
|
+
return S.Array(S.String);
|
|
415
|
+
case 1:
|
|
416
|
+
return S.Array(__S(8, __c2, 0));
|
|
417
|
+
case 2:
|
|
418
|
+
return S.suspend(() =>
|
|
419
|
+
S.Struct({
|
|
420
|
+
syncToken: S.String,
|
|
421
|
+
serviceAccountId: S.String,
|
|
422
|
+
userName: S.String,
|
|
423
|
+
roleId: S.String,
|
|
424
|
+
additionalRoleIds: __S(12, __c3, 0),
|
|
425
|
+
passwords: __S(13, __c3, 1),
|
|
426
|
+
}),
|
|
427
|
+
).annotate({ identifier: "ServiceAccount" });
|
|
428
|
+
}
|
|
429
|
+
}
|
|
430
|
+
function __c4(j: number): any {
|
|
431
|
+
switch (j) {
|
|
432
|
+
case 0:
|
|
433
|
+
return S.suspend(() =>
|
|
434
|
+
S.Struct({
|
|
435
|
+
serviceAccountId: S.String.pipe(T.Label()),
|
|
436
|
+
description: S.optional(S.String),
|
|
437
|
+
}).pipe(
|
|
438
|
+
T.Http({
|
|
439
|
+
method: "POST",
|
|
440
|
+
uri: "/public/api/v1/serviceAccount/{serviceAccountId}/serviceAccountPassword",
|
|
441
|
+
code: 200,
|
|
442
|
+
}),
|
|
443
|
+
),
|
|
444
|
+
).annotate({ identifier: "CreateServiceAccountPasswordRequest" });
|
|
445
|
+
}
|
|
446
|
+
}
|
|
447
|
+
function __c5(j: number): any {
|
|
448
|
+
switch (j) {
|
|
449
|
+
case 0:
|
|
450
|
+
return S.suspend(() =>
|
|
451
|
+
S.Struct({
|
|
452
|
+
serviceAccountId: S.String.pipe(T.Label()),
|
|
453
|
+
}).pipe(
|
|
454
|
+
T.Http({
|
|
455
|
+
method: "DELETE",
|
|
456
|
+
uri: "/public/api/v1/serviceAccount/{serviceAccountId}",
|
|
457
|
+
code: 200,
|
|
458
|
+
}),
|
|
459
|
+
),
|
|
460
|
+
).annotate({ identifier: "DeleteServiceAccountRequest" });
|
|
461
|
+
}
|
|
462
|
+
}
|
|
463
|
+
function __c6(j: number): any {
|
|
464
|
+
switch (j) {
|
|
465
|
+
case 0:
|
|
466
|
+
return S.suspend(() => S.Struct({})).annotate({ identifier: "DeleteServiceAccountResponse" });
|
|
467
|
+
}
|
|
468
|
+
}
|
|
469
|
+
function __c7(j: number): any {
|
|
470
|
+
switch (j) {
|
|
471
|
+
case 0:
|
|
472
|
+
return S.suspend(() =>
|
|
473
|
+
S.Struct({
|
|
474
|
+
serviceAccountId: S.String.pipe(T.Label()),
|
|
475
|
+
serviceAccountPasswordId: S.String.pipe(T.Label()),
|
|
476
|
+
}).pipe(
|
|
477
|
+
T.Http({
|
|
478
|
+
method: "DELETE",
|
|
479
|
+
uri: "/public/api/v1/serviceAccount/{serviceAccountId}/serviceAccountPassword/{serviceAccountPasswordId}",
|
|
480
|
+
code: 200,
|
|
481
|
+
}),
|
|
482
|
+
),
|
|
483
|
+
).annotate({ identifier: "DeleteServiceAccountPasswordRequest" });
|
|
484
|
+
}
|
|
485
|
+
}
|
|
486
|
+
function __c8(j: number): any {
|
|
487
|
+
switch (j) {
|
|
488
|
+
case 0:
|
|
489
|
+
return S.suspend(() =>
|
|
490
|
+
S.Struct({
|
|
491
|
+
serviceAccountId: S.String.pipe(T.Label()),
|
|
492
|
+
}).pipe(
|
|
493
|
+
T.Http({
|
|
494
|
+
method: "GET",
|
|
495
|
+
uri: "/public/api/v1/serviceAccount/{serviceAccountId}",
|
|
496
|
+
code: 200,
|
|
497
|
+
}),
|
|
498
|
+
),
|
|
499
|
+
).annotate({ identifier: "GetServiceAccountRequest" });
|
|
500
|
+
}
|
|
501
|
+
}
|
|
502
|
+
function __c9(j: number): any {
|
|
503
|
+
switch (j) {
|
|
504
|
+
case 0:
|
|
505
|
+
return S.suspend(() =>
|
|
506
|
+
S.Struct({
|
|
507
|
+
pageToken: S.optional(S.String.pipe(T.Query())),
|
|
508
|
+
pageSize: S.optional(S.Number.pipe(T.Query())),
|
|
509
|
+
}).pipe(T.Http({ method: "GET", uri: "/public/api/v1/serviceAccount", code: 200 })),
|
|
510
|
+
).annotate({ identifier: "ListServiceAccountsRequest" });
|
|
511
|
+
case 1:
|
|
512
|
+
return S.Array(__S(14, __c3, 2));
|
|
513
|
+
case 2:
|
|
514
|
+
return S.suspend(() =>
|
|
515
|
+
S.Struct({
|
|
516
|
+
nextPageToken: S.optional(S.String),
|
|
517
|
+
result: __S(37, __c9, 1),
|
|
518
|
+
}),
|
|
519
|
+
).annotate({ identifier: "PaginatedServiceAccount" });
|
|
520
|
+
}
|
|
521
|
+
}
|
|
522
|
+
// Schema table: entry i is schema j of builder f, made on first reach.
|
|
523
|
+
function __S(i: number, f: (j: number) => unknown, j: number): any {
|
|
524
|
+
return (__s[i] ??= __L.at(f, j));
|
|
525
|
+
}
|