@distilled.cloud/namespacelabs 1.0.0-rc.20 → 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.
Files changed (310) hide show
  1. package/README.md +19 -10
  2. package/lib/.lazy.json +1 -1
  3. package/lib/_bundle/sdk.js +1 -1
  4. package/lib/_bundle/sdk.js.map +1 -1
  5. package/lib/credentials.d.ts +27 -9
  6. package/lib/credentials.d.ts.map +1 -1
  7. package/lib/errors.d.ts +26 -0
  8. package/lib/errors.d.ts.map +1 -1
  9. package/lib/errors.js +1 -1
  10. package/lib/index.d.ts +10 -8
  11. package/lib/index.d.ts.map +1 -1
  12. package/lib/index.js +0 -1
  13. package/lib/pagination.d.ts.map +1 -1
  14. package/lib/protocol.d.ts +11 -7
  15. package/lib/protocol.d.ts.map +1 -1
  16. package/lib/retry.d.ts.map +1 -1
  17. package/lib/services/buildkite_jobs.d.ts +8 -0
  18. package/lib/services/buildkite_jobs.d.ts.map +1 -1
  19. package/lib/services/buildkite_jobs.js +1 -1
  20. package/lib/services/buildkite_jobs.js.map +1 -1
  21. package/lib/services/buildkite_queue.d.ts +8 -0
  22. package/lib/services/buildkite_queue.d.ts.map +1 -1
  23. package/lib/services/buildkite_queue.js +1 -1
  24. package/lib/services/buildkite_queue.js.map +1 -1
  25. package/lib/services/index.d.ts +0 -27
  26. package/lib/services/index.d.ts.map +1 -1
  27. package/lib/services/index.js +0 -27
  28. package/lib/services.lazy/index.js +2 -2
  29. package/lib/traits.d.ts.map +1 -1
  30. package/lib/{services → unstable-services}/artifacts.d.ts +8 -0
  31. package/lib/unstable-services/artifacts.d.ts.map +1 -0
  32. package/lib/unstable-services/artifacts.js +2 -0
  33. package/lib/unstable-services/artifacts.js.map +1 -0
  34. package/lib/{services → unstable-services}/audit.d.ts +8 -0
  35. package/lib/unstable-services/audit.d.ts.map +1 -0
  36. package/lib/unstable-services/audit.js +2 -0
  37. package/lib/unstable-services/audit.js.map +1 -0
  38. package/lib/{services → unstable-services}/bazel.d.ts +8 -0
  39. package/lib/unstable-services/bazel.d.ts.map +1 -0
  40. package/lib/unstable-services/bazel.js +2 -0
  41. package/lib/unstable-services/bazel.js.map +1 -0
  42. package/lib/{services → unstable-services}/bazel_cache.d.ts +8 -0
  43. package/lib/unstable-services/bazel_cache.d.ts.map +1 -0
  44. package/lib/unstable-services/bazel_cache.js +2 -0
  45. package/lib/unstable-services/bazel_cache.js.map +1 -0
  46. package/lib/{services → unstable-services}/builder.d.ts +8 -0
  47. package/lib/unstable-services/builder.d.ts.map +1 -0
  48. package/lib/unstable-services/builder.js +2 -0
  49. package/lib/unstable-services/builder.js.map +1 -0
  50. package/lib/{services → unstable-services}/compute.d.ts +67 -0
  51. package/lib/unstable-services/compute.d.ts.map +1 -0
  52. package/lib/unstable-services/compute.js +47 -0
  53. package/lib/unstable-services/compute.js.map +1 -0
  54. package/lib/{services → unstable-services}/compute_command.d.ts +8 -0
  55. package/lib/unstable-services/compute_command.d.ts.map +1 -0
  56. package/lib/unstable-services/compute_command.js +2 -0
  57. package/lib/unstable-services/compute_command.js.map +1 -0
  58. package/lib/{services → unstable-services}/compute_observability.d.ts +8 -0
  59. package/lib/unstable-services/compute_observability.d.ts.map +1 -0
  60. package/lib/unstable-services/compute_observability.js +2 -0
  61. package/lib/unstable-services/compute_observability.js.map +1 -0
  62. package/lib/{services → unstable-services}/compute_storage.d.ts +8 -0
  63. package/lib/unstable-services/compute_storage.d.ts.map +1 -0
  64. package/lib/unstable-services/compute_storage.js +33 -0
  65. package/lib/unstable-services/compute_storage.js.map +1 -0
  66. package/lib/{services → unstable-services}/compute_usage.d.ts +8 -0
  67. package/lib/unstable-services/compute_usage.d.ts.map +1 -0
  68. package/lib/unstable-services/compute_usage.js +2 -0
  69. package/lib/unstable-services/compute_usage.js.map +1 -0
  70. package/lib/{services → unstable-services}/egress.d.ts +8 -0
  71. package/lib/unstable-services/egress.d.ts.map +1 -0
  72. package/lib/unstable-services/egress.js +2 -0
  73. package/lib/unstable-services/egress.js.map +1 -0
  74. package/lib/{services → unstable-services}/experimental_compute_reservation.d.ts +11 -1
  75. package/lib/unstable-services/experimental_compute_reservation.d.ts.map +1 -0
  76. package/lib/unstable-services/experimental_compute_reservation.js +23 -0
  77. package/lib/unstable-services/experimental_compute_reservation.js.map +1 -0
  78. package/lib/{services → unstable-services}/experimental_remote_results.d.ts +8 -0
  79. package/lib/unstable-services/experimental_remote_results.d.ts.map +1 -0
  80. package/lib/unstable-services/experimental_remote_results.js +2 -0
  81. package/lib/unstable-services/experimental_remote_results.js.map +1 -0
  82. package/lib/{services → unstable-services}/github_image.d.ts +8 -0
  83. package/lib/unstable-services/github_image.d.ts.map +1 -0
  84. package/lib/unstable-services/github_image.js +2 -0
  85. package/lib/unstable-services/github_image.js.map +1 -0
  86. package/lib/{services → unstable-services}/github_jobs.d.ts +8 -0
  87. package/lib/unstable-services/github_jobs.d.ts.map +1 -0
  88. package/lib/unstable-services/github_jobs.js +2 -0
  89. package/lib/unstable-services/github_jobs.js.map +1 -0
  90. package/lib/{services → unstable-services}/github_profile.d.ts +8 -0
  91. package/lib/unstable-services/github_profile.d.ts.map +1 -0
  92. package/lib/unstable-services/github_profile.js +2 -0
  93. package/lib/unstable-services/github_profile.js.map +1 -0
  94. package/lib/{services → unstable-services}/gradle_cache.d.ts +8 -0
  95. package/lib/unstable-services/gradle_cache.d.ts.map +1 -0
  96. package/lib/unstable-services/gradle_cache.js +2 -0
  97. package/lib/unstable-services/gradle_cache.js.map +1 -0
  98. package/lib/{services → unstable-services}/httpcache.d.ts +8 -0
  99. package/lib/unstable-services/httpcache.d.ts.map +1 -0
  100. package/lib/unstable-services/httpcache.js +2 -0
  101. package/lib/unstable-services/httpcache.js.map +1 -0
  102. package/lib/{services → unstable-services}/iam_tenant.d.ts +95 -11
  103. package/lib/unstable-services/iam_tenant.d.ts.map +1 -0
  104. package/lib/unstable-services/iam_tenant.js +45 -0
  105. package/lib/unstable-services/iam_tenant.js.map +1 -0
  106. package/lib/{services → unstable-services}/iam_tenant_membership.d.ts +8 -0
  107. package/lib/unstable-services/iam_tenant_membership.d.ts.map +1 -0
  108. package/lib/unstable-services/iam_tenant_membership.js +2 -0
  109. package/lib/unstable-services/iam_tenant_membership.js.map +1 -0
  110. package/lib/{services → unstable-services}/iam_token.d.ts +8 -0
  111. package/lib/unstable-services/iam_token.d.ts.map +1 -0
  112. package/lib/unstable-services/iam_token.js +2 -0
  113. package/lib/unstable-services/iam_token.js.map +1 -0
  114. package/lib/{services → unstable-services}/image.d.ts +8 -0
  115. package/lib/unstable-services/image.d.ts.map +1 -0
  116. package/lib/unstable-services/image.js +2 -0
  117. package/lib/unstable-services/image.js.map +1 -0
  118. package/lib/unstable-services/index.d.ts +28 -0
  119. package/lib/unstable-services/index.d.ts.map +1 -0
  120. package/lib/unstable-services/index.js +27 -0
  121. package/lib/{services → unstable-services}/private_devbox.d.ts +24 -0
  122. package/lib/unstable-services/private_devbox.d.ts.map +1 -0
  123. package/lib/unstable-services/private_devbox.js +81 -0
  124. package/lib/unstable-services/private_devbox.js.map +1 -0
  125. package/lib/{services → unstable-services}/private_user_sessions.d.ts +8 -0
  126. package/lib/unstable-services/private_user_sessions.d.ts.map +1 -0
  127. package/lib/unstable-services/private_user_sessions.js +2 -0
  128. package/lib/unstable-services/private_user_sessions.js.map +1 -0
  129. package/lib/{services → unstable-services}/registry.d.ts +8 -0
  130. package/lib/unstable-services/registry.d.ts.map +1 -0
  131. package/lib/unstable-services/registry.js +34 -0
  132. package/lib/unstable-services/registry.js.map +1 -0
  133. package/lib/{services → unstable-services}/testing.d.ts +8 -0
  134. package/lib/unstable-services/testing.d.ts.map +1 -0
  135. package/lib/unstable-services/testing.js +2 -0
  136. package/lib/unstable-services/testing.js.map +1 -0
  137. package/lib/{services → unstable-services}/vault.d.ts +8 -0
  138. package/lib/unstable-services/vault.d.ts.map +1 -0
  139. package/lib/unstable-services/vault.js +2 -0
  140. package/lib/unstable-services/vault.js.map +1 -0
  141. package/lib/unstable-services.lazy/artifacts.js +1 -0
  142. package/lib/unstable-services.lazy/audit.js +1 -0
  143. package/lib/unstable-services.lazy/bazel.js +1 -0
  144. package/lib/unstable-services.lazy/bazel_cache.js +1 -0
  145. package/lib/unstable-services.lazy/builder.js +1 -0
  146. package/lib/unstable-services.lazy/compute.js +4 -0
  147. package/lib/unstable-services.lazy/compute_command.js +1 -0
  148. package/lib/unstable-services.lazy/compute_observability.js +1 -0
  149. package/lib/{services.lazy → unstable-services.lazy}/compute_storage.js +1 -1
  150. package/lib/unstable-services.lazy/compute_usage.js +1 -0
  151. package/lib/unstable-services.lazy/egress.js +1 -0
  152. package/lib/{services.lazy → unstable-services.lazy}/experimental_compute_reservation.js +1 -1
  153. package/lib/unstable-services.lazy/experimental_remote_results.js +1 -0
  154. package/lib/unstable-services.lazy/github_image.js +1 -0
  155. package/lib/unstable-services.lazy/github_jobs.js +1 -0
  156. package/lib/unstable-services.lazy/github_profile.js +1 -0
  157. package/lib/unstable-services.lazy/gradle_cache.js +1 -0
  158. package/lib/unstable-services.lazy/httpcache.js +1 -0
  159. package/lib/unstable-services.lazy/iam_tenant.js +4 -0
  160. package/lib/unstable-services.lazy/iam_tenant_membership.js +1 -0
  161. package/lib/unstable-services.lazy/iam_token.js +1 -0
  162. package/lib/unstable-services.lazy/image.js +1 -0
  163. package/lib/unstable-services.lazy/index.js +3 -0
  164. package/lib/{services.lazy → unstable-services.lazy}/private_devbox.js +1 -1
  165. package/lib/unstable-services.lazy/private_user_sessions.js +1 -0
  166. package/lib/{services.lazy → unstable-services.lazy}/registry.js +1 -1
  167. package/lib/unstable-services.lazy/testing.js +1 -0
  168. package/lib/unstable-services.lazy/vault.js +1 -0
  169. package/package.json +12 -5
  170. package/src/credentials.ts +84 -40
  171. package/src/errors.ts +24 -0
  172. package/src/index.ts +10 -8
  173. package/src/protocol.ts +27 -26
  174. package/src/services/buildkite_jobs.ts +10 -2
  175. package/src/services/buildkite_queue.ts +12 -4
  176. package/src/services/index.ts +0 -27
  177. package/src/{services → unstable-services}/artifacts.ts +16 -8
  178. package/src/{services → unstable-services}/audit.ts +10 -2
  179. package/src/{services → unstable-services}/bazel.ts +12 -4
  180. package/src/{services → unstable-services}/bazel_cache.ts +10 -2
  181. package/src/{services → unstable-services}/builder.ts +13 -5
  182. package/src/{services → unstable-services}/compute.ts +422 -225
  183. package/src/{services → unstable-services}/compute_command.ts +10 -2
  184. package/src/{services → unstable-services}/compute_observability.ts +12 -4
  185. package/src/{services → unstable-services}/compute_storage.ts +20 -12
  186. package/src/{services → unstable-services}/compute_usage.ts +14 -6
  187. package/src/{services → unstable-services}/egress.ts +13 -5
  188. package/src/{services → unstable-services}/experimental_compute_reservation.ts +44 -33
  189. package/src/{services → unstable-services}/experimental_remote_results.ts +15 -7
  190. package/src/{services → unstable-services}/github_image.ts +10 -2
  191. package/src/{services → unstable-services}/github_jobs.ts +11 -3
  192. package/src/{services → unstable-services}/github_profile.ts +14 -6
  193. package/src/{services → unstable-services}/gradle_cache.ts +11 -3
  194. package/src/{services → unstable-services}/httpcache.ts +11 -3
  195. package/src/{services → unstable-services}/iam_tenant.ts +524 -159
  196. package/src/{services → unstable-services}/iam_tenant_membership.ts +11 -3
  197. package/src/{services → unstable-services}/iam_token.ts +17 -9
  198. package/src/{services → unstable-services}/image.ts +14 -6
  199. package/src/unstable-services/index.ts +28 -0
  200. package/src/{services → unstable-services}/private_devbox.ts +82 -43
  201. package/src/{services → unstable-services}/private_user_sessions.ts +13 -5
  202. package/src/{services → unstable-services}/registry.ts +22 -14
  203. package/src/{services → unstable-services}/testing.ts +12 -4
  204. package/src/{services → unstable-services}/vault.ts +14 -6
  205. package/lib/index.lazy.js +0 -7
  206. package/lib/index.lazy.js.map +0 -1
  207. package/lib/services/artifacts.d.ts.map +0 -1
  208. package/lib/services/artifacts.js +0 -2
  209. package/lib/services/artifacts.js.map +0 -1
  210. package/lib/services/audit.d.ts.map +0 -1
  211. package/lib/services/audit.js +0 -2
  212. package/lib/services/audit.js.map +0 -1
  213. package/lib/services/bazel.d.ts.map +0 -1
  214. package/lib/services/bazel.js +0 -2
  215. package/lib/services/bazel.js.map +0 -1
  216. package/lib/services/bazel_cache.d.ts.map +0 -1
  217. package/lib/services/bazel_cache.js +0 -2
  218. package/lib/services/bazel_cache.js.map +0 -1
  219. package/lib/services/builder.d.ts.map +0 -1
  220. package/lib/services/builder.js +0 -2
  221. package/lib/services/builder.js.map +0 -1
  222. package/lib/services/compute.d.ts.map +0 -1
  223. package/lib/services/compute.js +0 -43
  224. package/lib/services/compute.js.map +0 -1
  225. package/lib/services/compute_command.d.ts.map +0 -1
  226. package/lib/services/compute_command.js +0 -2
  227. package/lib/services/compute_command.js.map +0 -1
  228. package/lib/services/compute_observability.d.ts.map +0 -1
  229. package/lib/services/compute_observability.js +0 -2
  230. package/lib/services/compute_observability.js.map +0 -1
  231. package/lib/services/compute_storage.d.ts.map +0 -1
  232. package/lib/services/compute_storage.js +0 -33
  233. package/lib/services/compute_storage.js.map +0 -1
  234. package/lib/services/compute_usage.d.ts.map +0 -1
  235. package/lib/services/compute_usage.js +0 -2
  236. package/lib/services/compute_usage.js.map +0 -1
  237. package/lib/services/egress.d.ts.map +0 -1
  238. package/lib/services/egress.js +0 -2
  239. package/lib/services/egress.js.map +0 -1
  240. package/lib/services/experimental_compute_reservation.d.ts.map +0 -1
  241. package/lib/services/experimental_compute_reservation.js +0 -23
  242. package/lib/services/experimental_compute_reservation.js.map +0 -1
  243. package/lib/services/experimental_remote_results.d.ts.map +0 -1
  244. package/lib/services/experimental_remote_results.js +0 -2
  245. package/lib/services/experimental_remote_results.js.map +0 -1
  246. package/lib/services/github_image.d.ts.map +0 -1
  247. package/lib/services/github_image.js +0 -2
  248. package/lib/services/github_image.js.map +0 -1
  249. package/lib/services/github_jobs.d.ts.map +0 -1
  250. package/lib/services/github_jobs.js +0 -2
  251. package/lib/services/github_jobs.js.map +0 -1
  252. package/lib/services/github_profile.d.ts.map +0 -1
  253. package/lib/services/github_profile.js +0 -2
  254. package/lib/services/github_profile.js.map +0 -1
  255. package/lib/services/gradle_cache.d.ts.map +0 -1
  256. package/lib/services/gradle_cache.js +0 -2
  257. package/lib/services/gradle_cache.js.map +0 -1
  258. package/lib/services/httpcache.d.ts.map +0 -1
  259. package/lib/services/httpcache.js +0 -2
  260. package/lib/services/httpcache.js.map +0 -1
  261. package/lib/services/iam_tenant.d.ts.map +0 -1
  262. package/lib/services/iam_tenant.js +0 -39
  263. package/lib/services/iam_tenant.js.map +0 -1
  264. package/lib/services/iam_tenant_membership.d.ts.map +0 -1
  265. package/lib/services/iam_tenant_membership.js +0 -2
  266. package/lib/services/iam_tenant_membership.js.map +0 -1
  267. package/lib/services/iam_token.d.ts.map +0 -1
  268. package/lib/services/iam_token.js +0 -2
  269. package/lib/services/iam_token.js.map +0 -1
  270. package/lib/services/image.d.ts.map +0 -1
  271. package/lib/services/image.js +0 -2
  272. package/lib/services/image.js.map +0 -1
  273. package/lib/services/private_devbox.d.ts.map +0 -1
  274. package/lib/services/private_devbox.js +0 -81
  275. package/lib/services/private_devbox.js.map +0 -1
  276. package/lib/services/private_user_sessions.d.ts.map +0 -1
  277. package/lib/services/private_user_sessions.js +0 -2
  278. package/lib/services/private_user_sessions.js.map +0 -1
  279. package/lib/services/registry.d.ts.map +0 -1
  280. package/lib/services/registry.js +0 -34
  281. package/lib/services/registry.js.map +0 -1
  282. package/lib/services/testing.d.ts.map +0 -1
  283. package/lib/services/testing.js +0 -2
  284. package/lib/services/testing.js.map +0 -1
  285. package/lib/services/vault.d.ts.map +0 -1
  286. package/lib/services/vault.js +0 -2
  287. package/lib/services/vault.js.map +0 -1
  288. package/lib/services.lazy/artifacts.js +0 -1
  289. package/lib/services.lazy/audit.js +0 -1
  290. package/lib/services.lazy/bazel.js +0 -1
  291. package/lib/services.lazy/bazel_cache.js +0 -1
  292. package/lib/services.lazy/builder.js +0 -1
  293. package/lib/services.lazy/compute.js +0 -4
  294. package/lib/services.lazy/compute_command.js +0 -1
  295. package/lib/services.lazy/compute_observability.js +0 -1
  296. package/lib/services.lazy/compute_usage.js +0 -1
  297. package/lib/services.lazy/egress.js +0 -1
  298. package/lib/services.lazy/experimental_remote_results.js +0 -1
  299. package/lib/services.lazy/github_image.js +0 -1
  300. package/lib/services.lazy/github_jobs.js +0 -1
  301. package/lib/services.lazy/github_profile.js +0 -1
  302. package/lib/services.lazy/gradle_cache.js +0 -1
  303. package/lib/services.lazy/httpcache.js +0 -1
  304. package/lib/services.lazy/iam_tenant.js +0 -4
  305. package/lib/services.lazy/iam_tenant_membership.js +0 -1
  306. package/lib/services.lazy/iam_token.js +0 -1
  307. package/lib/services.lazy/image.js +0 -1
  308. package/lib/services.lazy/private_user_sessions.js +0 -1
  309. package/lib/services.lazy/testing.js +0 -1
  310. package/lib/services.lazy/vault.js +0 -1
@@ -4,7 +4,7 @@ import * as C from "@distilled.cloud/core/category";
4
4
  import * as S from "@distilled.cloud/core/schema-lite";
5
5
  import * as __L from "@distilled.cloud/core/schema-lite";
6
6
  import type * as Redacted from "effect/Redacted";
7
- import { UnknownNamespaceLabsError } from "../errors.ts";
7
+ import { NamespaceLabsServiceErrors } from "../errors.ts";
8
8
  import { paginateCursor } from "../pagination.ts";
9
9
  import {
10
10
  NamespaceLabsProtocol,
@@ -35,6 +35,7 @@ export class AlreadyExists
35
35
  /*@__PURE__*/ S.TaggedError<AlreadyExists>()("AlreadyExists", {
36
36
  message: S.String,
37
37
  body: S.Unknown,
38
+ headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
38
39
  }).pipe(C.withConflictError),
39
40
  [{ status: 409, body: { "/code": "already_exists" } }],
40
41
  ) {}
@@ -44,6 +45,7 @@ export class FailedPrecondition
44
45
  /*@__PURE__*/ S.TaggedError<FailedPrecondition>()("FailedPrecondition", {
45
46
  message: S.String,
46
47
  body: S.Unknown,
48
+ headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
47
49
  }).pipe(C.withBadRequestError),
48
50
  [{ status: 400, body: { "/code": "failed_precondition" } }],
49
51
  ) {}
@@ -53,6 +55,7 @@ export class InvalidArgument
53
55
  /*@__PURE__*/ S.TaggedError<InvalidArgument>()("InvalidArgument", {
54
56
  message: S.String,
55
57
  body: S.Unknown,
58
+ headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
56
59
  }).pipe(C.withBadRequestError),
57
60
  [{ status: 400, body: { "/code": "invalid_argument" } }],
58
61
  ) {}
@@ -62,6 +65,7 @@ export class NotFound
62
65
  /*@__PURE__*/ S.TaggedError<NotFound>()("NotFound", {
63
66
  message: S.String,
64
67
  body: S.Unknown,
68
+ headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
65
69
  }).pipe(C.withBadRequestError),
66
70
  [{ status: 404 }],
67
71
  ) {}
@@ -71,6 +75,7 @@ export class PermissionDenied
71
75
  /*@__PURE__*/ S.TaggedError<PermissionDenied>()("PermissionDenied", {
72
76
  message: S.String,
73
77
  body: S.Unknown,
78
+ headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
74
79
  }).pipe(C.withAuthError),
75
80
  [{ status: 403 }],
76
81
  ) {}
@@ -80,6 +85,8 @@ export class ResourceExhausted
80
85
  /*@__PURE__*/ S.TaggedError<ResourceExhausted>()("ResourceExhausted", {
81
86
  message: S.String,
82
87
  body: S.Unknown,
88
+ headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
89
+ retryAfter: /*@__PURE__*/ S.optional(S.Duration),
83
90
  }).pipe(C.withThrottlingError),
84
91
  [{ status: 429 }],
85
92
  ) {}
@@ -89,6 +96,7 @@ export class Unauthenticated
89
96
  /*@__PURE__*/ S.TaggedError<Unauthenticated>()("Unauthenticated", {
90
97
  message: S.String,
91
98
  body: S.Unknown,
99
+ headers: /*@__PURE__*/ S.optional(/*@__PURE__*/ S.Record(S.String, S.String)),
92
100
  }).pipe(C.withAuthError),
93
101
  [{ status: 401 }],
94
102
  ) {}
@@ -146,11 +154,51 @@ export interface Tenant {
146
154
  export interface CreateTenantResponse {
147
155
  tenant?: Tenant | undefined;
148
156
  }
157
+ export type StringList = Array<string>;
158
+ /** Defines a permission grant on a resource. Permissions are used to restrict what a token is allowed to do. See https://namespace.so/docs/security/permissions for a list of available resource types and actions. */
159
+ export interface Permission {
160
+ /** The type of resource this permission applies to, e.g. "instance", "vault/object", "token/revokable". */
161
+ resourceType?: string | undefined;
162
+ /** The specific resource ID, or empty for all resources of this type. */
163
+ resourceId?: string | undefined;
164
+ /** The set of actions allowed on the resource, e.g. "create", "list", "describe". */
165
+ actions?: StringList | undefined;
166
+ }
167
+ export type PermissionList = Array<Permission>;
168
+ export type StringMap = { [key: string]: string | undefined };
169
+ export interface TrustRelationshipSpec {
170
+ /** Exact OIDC issuer URL. Namespace discovers its public signing keys. */
171
+ issuer?: string | undefined;
172
+ /** Glob pattern for the token's subject claim. */
173
+ subjectMatch?: string | undefined;
174
+ /** Defaults to https://federation.namespaceapis.com. */
175
+ audience?: string | undefined;
176
+ /** Permissions granted to exchanged tokens. If empty, tenant defaults apply. */
177
+ defaultPermissions?: PermissionList | undefined;
178
+ /** Defaults to one hour, capped by maximum_token_duration. */
179
+ defaultTokenDuration?: string | undefined;
180
+ /** Up to 24 hours. */
181
+ maximumTokenDuration?: string | undefined;
182
+ /** Glob patterns for additional string claims. All must match. Does not support iss, sub, or aud. */
183
+ claimMatches?: StringMap | undefined;
184
+ }
185
+ export interface CreateTrustRelationshipRequest {
186
+ spec?: TrustRelationshipSpec | undefined;
187
+ }
188
+ export interface CreateTrustRelationshipResponse {
189
+ id: string;
190
+ }
149
191
  export interface DeleteTenantGroupRequest {
150
192
  /** A canonical name for the Tenant group. Tenant groups are identified by name and scoped per Namespace Partner. */
151
193
  name?: string | undefined;
152
194
  }
153
195
  export interface DeleteTenantGroupResponse {}
196
+ export interface DeleteTrustRelationshipRequest {
197
+ id?: string | undefined;
198
+ /** Only delete if generation matches. Obtain the current value from ListTrustRelationships or DescribeTrustRelationship. */
199
+ generation?: string | undefined;
200
+ }
201
+ export interface DeleteTrustRelationshipResponse {}
154
202
  export interface DescribePoliciesRequest {}
155
203
  export interface DescribePoliciesResponse {
156
204
  policies: TenantPolicyList;
@@ -167,7 +215,6 @@ export interface TenantGroupPolicy {
167
215
  value?: string | undefined;
168
216
  }
169
217
  export type TenantGroupPolicyList = Array<TenantGroupPolicy>;
170
- export type StringList = Array<string>;
171
218
  export interface DescribeTenantGroupResponse {
172
219
  /** A canonical name for the Tenant group. Tenant groups are identified by name and scoped per Namespace Partner. */
173
220
  name: string;
@@ -178,6 +225,15 @@ export interface DescribeTenantGroupResponse {
178
225
  /** The full history of policy revisions, latest first. Each version entry corresponds to one stored revision of the policy. */
179
226
  versions: TenantGroupPolicyList;
180
227
  }
228
+ export interface DescribeTrustRelationshipRequest {
229
+ id?: string | undefined;
230
+ }
231
+ export interface DescribeTrustRelationshipResponse {
232
+ generation: string;
233
+ id: string;
234
+ createdAt?: string | undefined;
235
+ spec?: TrustRelationshipSpec | undefined;
236
+ }
181
237
  export interface EnsureTenantForExternalAccountRequest {
182
238
  /** Specify the Tenant's visible name, e.g. "Foobar (production)". The Tenant's name is visible in Namespace-based interfaces, such as the Dashboard or the CLI. A visible name is optional. */
183
239
  visibleName?: string | undefined;
@@ -202,16 +258,6 @@ export interface EnsureTenantGroupRequest {
202
258
  export interface EnsureTenantGroupResponse {
203
259
  name: string;
204
260
  }
205
- /** Defines a permission grant on a resource. Permissions are used to restrict what a token is allowed to do. See https://namespace.so/docs/security/permissions for a list of available resource types and actions. */
206
- export interface Permission {
207
- /** The type of resource this permission applies to, e.g. "instance", "vault/object", "token/revokable". */
208
- resourceType?: string | undefined;
209
- /** The specific resource ID, or empty for all resources of this type. */
210
- resourceId?: string | undefined;
211
- /** The set of actions allowed on the resource, e.g. "create", "list", "describe". */
212
- actions?: StringList | undefined;
213
- }
214
- export type PermissionList = Array<Permission>;
215
261
  export interface ExchangeTenantTokenForClientCertRequest {
216
262
  /** The public key for which the certificate should be issued. This must contain exactly one PEM "PUBLIC KEY" block. */
217
263
  publicKeyPem?: string | undefined;
@@ -298,6 +344,17 @@ export interface ListTenantsResponse {
298
344
  /** If present, then there are additional tenants that match the original query, but were not returned in this response. Issue a 2nd List call, passing in the cursor, to obtain the next set. */
299
345
  cursor: string;
300
346
  }
347
+ export interface ListTrustRelationshipsRequest {}
348
+ export interface ListTrustRelationshipsResponseEntry {
349
+ id: string;
350
+ createdAt?: string | undefined;
351
+ spec?: TrustRelationshipSpec | undefined;
352
+ generation: string;
353
+ }
354
+ export type ListTrustRelationshipsResponseEntryList = Array<ListTrustRelationshipsResponseEntry>;
355
+ export interface ListTrustRelationshipsResponse {
356
+ trustRelationships: ListTrustRelationshipsResponseEntryList;
357
+ }
301
358
  export interface RemoveTenantRequest {
302
359
  /** The ID of the Tenant that is the target of a particular call. */
303
360
  tenantId?: string | undefined;
@@ -335,6 +392,13 @@ export interface UpdateTenantRequest {
335
392
  export interface UpdateTenantResponse {
336
393
  tenant?: Tenant | undefined;
337
394
  }
395
+ export interface UpdateTrustRelationshipRequest {
396
+ id?: string | undefined;
397
+ /** Only update if generation matches. Obtain the current value from ListTrustRelationships or DescribeTrustRelationship. */
398
+ generation?: string | undefined;
399
+ spec?: TrustRelationshipSpec | undefined;
400
+ }
401
+ export interface UpdateTrustRelationshipResponse {}
338
402
  export type CreateTenantError =
339
403
  | InvalidArgument
340
404
  | FailedPrecondition
@@ -351,8 +415,8 @@ export const createTenant: API.OperationMethod<
351
415
  CreateTenantError,
352
416
  NamespaceLabsOpContext
353
417
  > = /*@__PURE__*/ API.make(() => ({
354
- input: __S(68, __c17, 0) as any as S.Schema<CreateTenantRequest>,
355
- output: __S(76, __c19, 0) as any as S.Schema<CreateTenantResponse>,
418
+ input: __S(80, __c20, 0) as any as S.Schema<CreateTenantRequest>,
419
+ output: __S(92, __c23, 0) as any as S.Schema<CreateTenantResponse>,
356
420
  errors: [
357
421
  InvalidArgument,
358
422
  FailedPrecondition,
@@ -361,14 +425,48 @@ export const createTenant: API.OperationMethod<
361
425
  NotFound,
362
426
  AlreadyExists,
363
427
  ResourceExhausted,
364
- UnknownNamespaceLabsError,
365
428
  ],
429
+ serviceErrors: NamespaceLabsServiceErrors,
366
430
  protocol: NamespaceLabsProtocol,
367
431
  retry: Retry.Retry,
368
432
  telemetry: TELEMETRY,
369
433
  span: "CreateTenant",
370
434
  }));
371
435
 
436
+ export type CreateTrustRelationshipError =
437
+ | InvalidArgument
438
+ | FailedPrecondition
439
+ | Unauthenticated
440
+ | PermissionDenied
441
+ | NotFound
442
+ | AlreadyExists
443
+ | ResourceExhausted
444
+ | NamespaceLabsOpError;
445
+ /** Creates an OIDC trust relationship in the tenant. */
446
+ export const createTrustRelationship: API.OperationMethod<
447
+ CreateTrustRelationshipRequest,
448
+ CreateTrustRelationshipResponse,
449
+ CreateTrustRelationshipError,
450
+ NamespaceLabsOpContext
451
+ > = /*@__PURE__*/ API.make(() => ({
452
+ input: __S(96, __c24, 0) as any as S.Schema<CreateTrustRelationshipRequest>,
453
+ output: __S(97, __c24, 1) as any as S.Schema<CreateTrustRelationshipResponse>,
454
+ errors: [
455
+ InvalidArgument,
456
+ FailedPrecondition,
457
+ Unauthenticated,
458
+ PermissionDenied,
459
+ NotFound,
460
+ AlreadyExists,
461
+ ResourceExhausted,
462
+ ],
463
+ serviceErrors: NamespaceLabsServiceErrors,
464
+ protocol: NamespaceLabsProtocol,
465
+ retry: Retry.Retry,
466
+ telemetry: TELEMETRY,
467
+ span: "CreateTrustRelationship",
468
+ }));
469
+
372
470
  export type DeleteTenantGroupError =
373
471
  | InvalidArgument
374
472
  | FailedPrecondition
@@ -385,8 +483,8 @@ export const deleteTenantGroup: API.OperationMethod<
385
483
  DeleteTenantGroupError,
386
484
  NamespaceLabsOpContext
387
485
  > = /*@__PURE__*/ API.make(() => ({
388
- input: __S(84, __c21, 0) as any as S.Schema<DeleteTenantGroupRequest>,
389
- output: __S(88, __c22, 0) as any as S.Schema<DeleteTenantGroupResponse>,
486
+ input: __S(112, __c28, 0) as any as S.Schema<DeleteTenantGroupRequest>,
487
+ output: __S(116, __c29, 0) as any as S.Schema<DeleteTenantGroupResponse>,
390
488
  errors: [
391
489
  InvalidArgument,
392
490
  FailedPrecondition,
@@ -395,14 +493,48 @@ export const deleteTenantGroup: API.OperationMethod<
395
493
  NotFound,
396
494
  AlreadyExists,
397
495
  ResourceExhausted,
398
- UnknownNamespaceLabsError,
399
496
  ],
497
+ serviceErrors: NamespaceLabsServiceErrors,
400
498
  protocol: NamespaceLabsProtocol,
401
499
  retry: Retry.Retry,
402
500
  telemetry: TELEMETRY,
403
501
  span: "DeleteTenantGroup",
404
502
  }));
405
503
 
504
+ export type DeleteTrustRelationshipError =
505
+ | InvalidArgument
506
+ | FailedPrecondition
507
+ | Unauthenticated
508
+ | PermissionDenied
509
+ | NotFound
510
+ | AlreadyExists
511
+ | ResourceExhausted
512
+ | NamespaceLabsOpError;
513
+ /** Deletes an OIDC trust relationship from the tenant. ### Errors - If the relationship does not exist, a `NotFound` status is returned. - If the generation does not match, a `FailedPrecondition` status is returned. The current generation can be retrieved from ListTrustRelationships or DescribeTrustRelationship. */
514
+ export const deleteTrustRelationship: API.OperationMethod<
515
+ DeleteTrustRelationshipRequest,
516
+ DeleteTrustRelationshipResponse,
517
+ DeleteTrustRelationshipError,
518
+ NamespaceLabsOpContext
519
+ > = /*@__PURE__*/ API.make(() => ({
520
+ input: __S(0, __c0, 0) as any as S.Schema<DeleteTrustRelationshipRequest>,
521
+ output: __S(116, __c29, 0) as any as S.Schema<DeleteTrustRelationshipResponse>,
522
+ errors: [
523
+ InvalidArgument,
524
+ FailedPrecondition,
525
+ Unauthenticated,
526
+ PermissionDenied,
527
+ NotFound,
528
+ AlreadyExists,
529
+ ResourceExhausted,
530
+ ],
531
+ serviceErrors: NamespaceLabsServiceErrors,
532
+ protocol: NamespaceLabsProtocol,
533
+ retry: Retry.Retry,
534
+ telemetry: TELEMETRY,
535
+ span: "DeleteTrustRelationship",
536
+ }));
537
+
406
538
  export type DescribePoliciesError =
407
539
  | InvalidArgument
408
540
  | FailedPrecondition
@@ -419,8 +551,8 @@ export const describePolicies: API.OperationMethod<
419
551
  DescribePoliciesError,
420
552
  NamespaceLabsOpContext
421
553
  > = /*@__PURE__*/ API.make(() => ({
422
- input: __S(92, __c23, 0) as any as S.Schema<DescribePoliciesRequest>,
423
- output: __S(93, __c23, 1) as any as S.Schema<DescribePoliciesResponse>,
554
+ input: __S(4, __c1, 0) as any as S.Schema<DescribePoliciesRequest>,
555
+ output: __S(5, __c1, 1) as any as S.Schema<DescribePoliciesResponse>,
424
556
  errors: [
425
557
  InvalidArgument,
426
558
  FailedPrecondition,
@@ -429,8 +561,8 @@ export const describePolicies: API.OperationMethod<
429
561
  NotFound,
430
562
  AlreadyExists,
431
563
  ResourceExhausted,
432
- UnknownNamespaceLabsError,
433
564
  ],
565
+ serviceErrors: NamespaceLabsServiceErrors,
434
566
  protocol: NamespaceLabsProtocol,
435
567
  retry: Retry.Retry,
436
568
  telemetry: TELEMETRY,
@@ -453,8 +585,8 @@ export const describeTenantGroup: API.OperationMethod<
453
585
  DescribeTenantGroupError,
454
586
  NamespaceLabsOpContext
455
587
  > = /*@__PURE__*/ API.make(() => ({
456
- input: __S(0, __c0, 0) as any as S.Schema<DescribeTenantGroupRequest>,
457
- output: __S(1, __c0, 1) as any as S.Schema<DescribeTenantGroupResponse>,
588
+ input: __S(8, __c2, 0) as any as S.Schema<DescribeTenantGroupRequest>,
589
+ output: __S(9, __c2, 1) as any as S.Schema<DescribeTenantGroupResponse>,
458
590
  errors: [
459
591
  InvalidArgument,
460
592
  FailedPrecondition,
@@ -463,14 +595,48 @@ export const describeTenantGroup: API.OperationMethod<
463
595
  NotFound,
464
596
  AlreadyExists,
465
597
  ResourceExhausted,
466
- UnknownNamespaceLabsError,
467
598
  ],
599
+ serviceErrors: NamespaceLabsServiceErrors,
468
600
  protocol: NamespaceLabsProtocol,
469
601
  retry: Retry.Retry,
470
602
  telemetry: TELEMETRY,
471
603
  span: "DescribeTenantGroup",
472
604
  }));
473
605
 
606
+ export type DescribeTrustRelationshipError =
607
+ | InvalidArgument
608
+ | FailedPrecondition
609
+ | Unauthenticated
610
+ | PermissionDenied
611
+ | NotFound
612
+ | AlreadyExists
613
+ | ResourceExhausted
614
+ | NamespaceLabsOpError;
615
+ /** Retrieves an OIDC trust relationship from the tenant. ### Errors - If the relationship does not exist, a `NotFound` status is returned. */
616
+ export const describeTrustRelationship: API.OperationMethod<
617
+ DescribeTrustRelationshipRequest,
618
+ DescribeTrustRelationshipResponse,
619
+ DescribeTrustRelationshipError,
620
+ NamespaceLabsOpContext
621
+ > = /*@__PURE__*/ API.make(() => ({
622
+ input: __S(16, __c4, 0) as any as S.Schema<DescribeTrustRelationshipRequest>,
623
+ output: __S(17, __c4, 1) as any as S.Schema<DescribeTrustRelationshipResponse>,
624
+ errors: [
625
+ InvalidArgument,
626
+ FailedPrecondition,
627
+ Unauthenticated,
628
+ PermissionDenied,
629
+ NotFound,
630
+ AlreadyExists,
631
+ ResourceExhausted,
632
+ ],
633
+ serviceErrors: NamespaceLabsServiceErrors,
634
+ protocol: NamespaceLabsProtocol,
635
+ retry: Retry.Retry,
636
+ telemetry: TELEMETRY,
637
+ span: "DescribeTrustRelationship",
638
+ }));
639
+
474
640
  export type EnsureTenantForExternalAccountError =
475
641
  | InvalidArgument
476
642
  | FailedPrecondition
@@ -487,8 +653,8 @@ export const ensureTenantForExternalAccount: API.OperationMethod<
487
653
  EnsureTenantForExternalAccountError,
488
654
  NamespaceLabsOpContext
489
655
  > = /*@__PURE__*/ API.make(() => ({
490
- input: __S(12, __c3, 0) as any as S.Schema<EnsureTenantForExternalAccountRequest>,
491
- output: __S(76, __c19, 0) as any as S.Schema<EnsureTenantForExternalAccountResponse>,
656
+ input: __S(20, __c5, 0) as any as S.Schema<EnsureTenantForExternalAccountRequest>,
657
+ output: __S(92, __c23, 0) as any as S.Schema<EnsureTenantForExternalAccountResponse>,
492
658
  errors: [
493
659
  InvalidArgument,
494
660
  FailedPrecondition,
@@ -497,8 +663,8 @@ export const ensureTenantForExternalAccount: API.OperationMethod<
497
663
  NotFound,
498
664
  AlreadyExists,
499
665
  ResourceExhausted,
500
- UnknownNamespaceLabsError,
501
666
  ],
667
+ serviceErrors: NamespaceLabsServiceErrors,
502
668
  protocol: NamespaceLabsProtocol,
503
669
  retry: Retry.Retry,
504
670
  telemetry: TELEMETRY,
@@ -521,8 +687,8 @@ export const ensureTenantGroup: API.OperationMethod<
521
687
  EnsureTenantGroupError,
522
688
  NamespaceLabsOpContext
523
689
  > = /*@__PURE__*/ API.make(() => ({
524
- input: __S(16, __c4, 0) as any as S.Schema<EnsureTenantGroupRequest>,
525
- output: __S(17, __c4, 1) as any as S.Schema<EnsureTenantGroupResponse>,
690
+ input: __S(24, __c6, 0) as any as S.Schema<EnsureTenantGroupRequest>,
691
+ output: __S(25, __c6, 1) as any as S.Schema<EnsureTenantGroupResponse>,
526
692
  errors: [
527
693
  InvalidArgument,
528
694
  FailedPrecondition,
@@ -531,8 +697,8 @@ export const ensureTenantGroup: API.OperationMethod<
531
697
  NotFound,
532
698
  AlreadyExists,
533
699
  ResourceExhausted,
534
- UnknownNamespaceLabsError,
535
700
  ],
701
+ serviceErrors: NamespaceLabsServiceErrors,
536
702
  protocol: NamespaceLabsProtocol,
537
703
  retry: Retry.Retry,
538
704
  telemetry: TELEMETRY,
@@ -555,8 +721,8 @@ export const exchangeTenantTokenForClientCert: API.OperationMethod<
555
721
  ExchangeTenantTokenForClientCertError,
556
722
  NamespaceLabsOpContext
557
723
  > = /*@__PURE__*/ API.make(() => ({
558
- input: __S(20, __c5, 0) as any as S.Schema<ExchangeTenantTokenForClientCertRequest>,
559
- output: __S(21, __c5, 1) as any as S.Schema<ExchangeTenantTokenForClientCertResponse>,
724
+ input: __S(28, __c7, 0) as any as S.Schema<ExchangeTenantTokenForClientCertRequest>,
725
+ output: __S(29, __c7, 1) as any as S.Schema<ExchangeTenantTokenForClientCertResponse>,
560
726
  errors: [
561
727
  InvalidArgument,
562
728
  FailedPrecondition,
@@ -565,8 +731,8 @@ export const exchangeTenantTokenForClientCert: API.OperationMethod<
565
731
  NotFound,
566
732
  AlreadyExists,
567
733
  ResourceExhausted,
568
- UnknownNamespaceLabsError,
569
734
  ],
735
+ serviceErrors: NamespaceLabsServiceErrors,
570
736
  protocol: NamespaceLabsProtocol,
571
737
  retry: Retry.Retry,
572
738
  telemetry: TELEMETRY,
@@ -589,8 +755,8 @@ export const issueTenantClientCertificate: API.OperationMethod<
589
755
  IssueTenantClientCertificateError,
590
756
  NamespaceLabsOpContext
591
757
  > = /*@__PURE__*/ API.make(() => ({
592
- input: __S(28, __c7, 0) as any as S.Schema<IssueTenantClientCertificateRequest>,
593
- output: __S(29, __c7, 1) as any as S.Schema<IssueTenantClientCertificateResponse>,
758
+ input: __S(32, __c8, 0) as any as S.Schema<IssueTenantClientCertificateRequest>,
759
+ output: __S(33, __c8, 1) as any as S.Schema<IssueTenantClientCertificateResponse>,
594
760
  errors: [
595
761
  InvalidArgument,
596
762
  FailedPrecondition,
@@ -599,8 +765,8 @@ export const issueTenantClientCertificate: API.OperationMethod<
599
765
  NotFound,
600
766
  AlreadyExists,
601
767
  ResourceExhausted,
602
- UnknownNamespaceLabsError,
603
768
  ],
769
+ serviceErrors: NamespaceLabsServiceErrors,
604
770
  protocol: NamespaceLabsProtocol,
605
771
  retry: Retry.Retry,
606
772
  telemetry: TELEMETRY,
@@ -623,8 +789,8 @@ export const issueTenantToken: API.OperationMethod<
623
789
  IssueTenantTokenError,
624
790
  NamespaceLabsOpContext
625
791
  > = /*@__PURE__*/ API.make(() => ({
626
- input: __S(36, __c9, 0) as any as S.Schema<IssueTenantTokenRequest>,
627
- output: __S(37, __c9, 1) as any as S.Schema<IssueTenantTokenResponse>,
792
+ input: __S(40, __c10, 0) as any as S.Schema<IssueTenantTokenRequest>,
793
+ output: __S(41, __c10, 1) as any as S.Schema<IssueTenantTokenResponse>,
628
794
  errors: [
629
795
  InvalidArgument,
630
796
  FailedPrecondition,
@@ -633,8 +799,8 @@ export const issueTenantToken: API.OperationMethod<
633
799
  NotFound,
634
800
  AlreadyExists,
635
801
  ResourceExhausted,
636
- UnknownNamespaceLabsError,
637
802
  ],
803
+ serviceErrors: NamespaceLabsServiceErrors,
638
804
  protocol: NamespaceLabsProtocol,
639
805
  retry: Retry.Retry,
640
806
  telemetry: TELEMETRY,
@@ -657,8 +823,8 @@ export const listTenantGroups: API.OperationMethod<
657
823
  ListTenantGroupsError,
658
824
  NamespaceLabsOpContext
659
825
  > = /*@__PURE__*/ API.make(() => ({
660
- input: __S(40, __c10, 0) as any as S.Schema<ListTenantGroupsRequest>,
661
- output: __S(43, __c10, 3) as any as S.Schema<ListTenantGroupsResponse>,
826
+ input: __S(44, __c11, 0) as any as S.Schema<ListTenantGroupsRequest>,
827
+ output: __S(47, __c11, 3) as any as S.Schema<ListTenantGroupsResponse>,
662
828
  errors: [
663
829
  InvalidArgument,
664
830
  FailedPrecondition,
@@ -667,8 +833,8 @@ export const listTenantGroups: API.OperationMethod<
667
833
  NotFound,
668
834
  AlreadyExists,
669
835
  ResourceExhausted,
670
- UnknownNamespaceLabsError,
671
836
  ],
837
+ serviceErrors: NamespaceLabsServiceErrors,
672
838
  protocol: NamespaceLabsProtocol,
673
839
  retry: Retry.Retry,
674
840
  telemetry: TELEMETRY,
@@ -693,8 +859,8 @@ export const listTenants: API.PaginatedOperationMethod<
693
859
  Tenant
694
860
  > = /*@__PURE__*/ API.makePaginated(
695
861
  () => ({
696
- input: __S(44, __c11, 0) as any as S.Schema<ListTenantsRequest>,
697
- output: __S(46, __c11, 2) as any as S.Schema<ListTenantsResponse>,
862
+ input: __S(48, __c12, 0) as any as S.Schema<ListTenantsRequest>,
863
+ output: __S(50, __c12, 2) as any as S.Schema<ListTenantsResponse>,
698
864
  errors: [
699
865
  InvalidArgument,
700
866
  FailedPrecondition,
@@ -703,8 +869,8 @@ export const listTenants: API.PaginatedOperationMethod<
703
869
  NotFound,
704
870
  AlreadyExists,
705
871
  ResourceExhausted,
706
- UnknownNamespaceLabsError,
707
872
  ],
873
+ serviceErrors: NamespaceLabsServiceErrors,
708
874
  protocol: NamespaceLabsProtocol,
709
875
  retry: Retry.Retry,
710
876
  telemetry: TELEMETRY,
@@ -720,6 +886,40 @@ export const listTenants: API.PaginatedOperationMethod<
720
886
  paginateCursor,
721
887
  ) as any;
722
888
 
889
+ export type ListTrustRelationshipsError =
890
+ | InvalidArgument
891
+ | FailedPrecondition
892
+ | Unauthenticated
893
+ | PermissionDenied
894
+ | NotFound
895
+ | AlreadyExists
896
+ | ResourceExhausted
897
+ | NamespaceLabsOpError;
898
+ /** Lists the tenant's OIDC trust relationships. */
899
+ export const listTrustRelationships: API.OperationMethod<
900
+ ListTrustRelationshipsRequest,
901
+ ListTrustRelationshipsResponse,
902
+ ListTrustRelationshipsError,
903
+ NamespaceLabsOpContext
904
+ > = /*@__PURE__*/ API.make(() => ({
905
+ input: __S(52, __c13, 0) as any as S.Schema<ListTrustRelationshipsRequest>,
906
+ output: __S(55, __c13, 3) as any as S.Schema<ListTrustRelationshipsResponse>,
907
+ errors: [
908
+ InvalidArgument,
909
+ FailedPrecondition,
910
+ Unauthenticated,
911
+ PermissionDenied,
912
+ NotFound,
913
+ AlreadyExists,
914
+ ResourceExhausted,
915
+ ],
916
+ serviceErrors: NamespaceLabsServiceErrors,
917
+ protocol: NamespaceLabsProtocol,
918
+ retry: Retry.Retry,
919
+ telemetry: TELEMETRY,
920
+ span: "ListTrustRelationships",
921
+ }));
922
+
723
923
  export type RemoveTenantError =
724
924
  | InvalidArgument
725
925
  | FailedPrecondition
@@ -736,8 +936,8 @@ export const removeTenant: API.OperationMethod<
736
936
  RemoveTenantError,
737
937
  NamespaceLabsOpContext
738
938
  > = /*@__PURE__*/ API.make(() => ({
739
- input: __S(48, __c12, 0) as any as S.Schema<RemoveTenantRequest>,
740
- output: __S(88, __c22, 0) as any as S.Schema<RemoveTenantResponse>,
939
+ input: __S(56, __c14, 0) as any as S.Schema<RemoveTenantRequest>,
940
+ output: __S(116, __c29, 0) as any as S.Schema<RemoveTenantResponse>,
741
941
  errors: [
742
942
  InvalidArgument,
743
943
  FailedPrecondition,
@@ -746,8 +946,8 @@ export const removeTenant: API.OperationMethod<
746
946
  NotFound,
747
947
  AlreadyExists,
748
948
  ResourceExhausted,
749
- UnknownNamespaceLabsError,
750
949
  ],
950
+ serviceErrors: NamespaceLabsServiceErrors,
751
951
  protocol: NamespaceLabsProtocol,
752
952
  retry: Retry.Retry,
753
953
  telemetry: TELEMETRY,
@@ -770,8 +970,8 @@ export const resumeTenant: API.OperationMethod<
770
970
  ResumeTenantError,
771
971
  NamespaceLabsOpContext
772
972
  > = /*@__PURE__*/ API.make(() => ({
773
- input: __S(52, __c13, 0) as any as S.Schema<ResumeTenantRequest>,
774
- output: __S(88, __c22, 0) as any as S.Schema<ResumeTenantResponse>,
973
+ input: __S(60, __c15, 0) as any as S.Schema<ResumeTenantRequest>,
974
+ output: __S(116, __c29, 0) as any as S.Schema<ResumeTenantResponse>,
775
975
  errors: [
776
976
  InvalidArgument,
777
977
  FailedPrecondition,
@@ -780,8 +980,8 @@ export const resumeTenant: API.OperationMethod<
780
980
  NotFound,
781
981
  AlreadyExists,
782
982
  ResourceExhausted,
783
- UnknownNamespaceLabsError,
784
983
  ],
984
+ serviceErrors: NamespaceLabsServiceErrors,
785
985
  protocol: NamespaceLabsProtocol,
786
986
  retry: Retry.Retry,
787
987
  telemetry: TELEMETRY,
@@ -804,8 +1004,8 @@ export const suspendTenant: API.OperationMethod<
804
1004
  SuspendTenantError,
805
1005
  NamespaceLabsOpContext
806
1006
  > = /*@__PURE__*/ API.make(() => ({
807
- input: __S(56, __c14, 0) as any as S.Schema<SuspendTenantRequest>,
808
- output: __S(88, __c22, 0) as any as S.Schema<SuspendTenantResponse>,
1007
+ input: __S(64, __c16, 0) as any as S.Schema<SuspendTenantRequest>,
1008
+ output: __S(116, __c29, 0) as any as S.Schema<SuspendTenantResponse>,
809
1009
  errors: [
810
1010
  InvalidArgument,
811
1011
  FailedPrecondition,
@@ -814,8 +1014,8 @@ export const suspendTenant: API.OperationMethod<
814
1014
  NotFound,
815
1015
  AlreadyExists,
816
1016
  ResourceExhausted,
817
- UnknownNamespaceLabsError,
818
1017
  ],
1018
+ serviceErrors: NamespaceLabsServiceErrors,
819
1019
  protocol: NamespaceLabsProtocol,
820
1020
  retry: Retry.Retry,
821
1021
  telemetry: TELEMETRY,
@@ -838,8 +1038,8 @@ export const updatePolicies: API.OperationMethod<
838
1038
  UpdatePoliciesError,
839
1039
  NamespaceLabsOpContext
840
1040
  > = /*@__PURE__*/ API.make(() => ({
841
- input: __S(60, __c15, 0) as any as S.Schema<UpdatePoliciesRequest>,
842
- output: __S(88, __c22, 0) as any as S.Schema<UpdatePoliciesResponse>,
1041
+ input: __S(68, __c17, 0) as any as S.Schema<UpdatePoliciesRequest>,
1042
+ output: __S(116, __c29, 0) as any as S.Schema<UpdatePoliciesResponse>,
843
1043
  errors: [
844
1044
  InvalidArgument,
845
1045
  FailedPrecondition,
@@ -848,8 +1048,8 @@ export const updatePolicies: API.OperationMethod<
848
1048
  NotFound,
849
1049
  AlreadyExists,
850
1050
  ResourceExhausted,
851
- UnknownNamespaceLabsError,
852
1051
  ],
1052
+ serviceErrors: NamespaceLabsServiceErrors,
853
1053
  protocol: NamespaceLabsProtocol,
854
1054
  retry: Retry.Retry,
855
1055
  telemetry: TELEMETRY,
@@ -872,8 +1072,8 @@ export const updateTenant: API.OperationMethod<
872
1072
  UpdateTenantError,
873
1073
  NamespaceLabsOpContext
874
1074
  > = /*@__PURE__*/ API.make(() => ({
875
- input: __S(64, __c16, 0) as any as S.Schema<UpdateTenantRequest>,
876
- output: __S(76, __c19, 0) as any as S.Schema<UpdateTenantResponse>,
1075
+ input: __S(72, __c18, 0) as any as S.Schema<UpdateTenantRequest>,
1076
+ output: __S(92, __c23, 0) as any as S.Schema<UpdateTenantResponse>,
877
1077
  errors: [
878
1078
  InvalidArgument,
879
1079
  FailedPrecondition,
@@ -882,16 +1082,88 @@ export const updateTenant: API.OperationMethod<
882
1082
  NotFound,
883
1083
  AlreadyExists,
884
1084
  ResourceExhausted,
885
- UnknownNamespaceLabsError,
886
1085
  ],
1086
+ serviceErrors: NamespaceLabsServiceErrors,
887
1087
  protocol: NamespaceLabsProtocol,
888
1088
  retry: Retry.Retry,
889
1089
  telemetry: TELEMETRY,
890
1090
  span: "UpdateTenant",
891
1091
  }));
892
1092
 
1093
+ export type UpdateTrustRelationshipError =
1094
+ | InvalidArgument
1095
+ | FailedPrecondition
1096
+ | Unauthenticated
1097
+ | PermissionDenied
1098
+ | NotFound
1099
+ | AlreadyExists
1100
+ | ResourceExhausted
1101
+ | NamespaceLabsOpError;
1102
+ /** Replaces an OIDC trust relationship's configuration without changing its ID or creation time. ### Errors - If the relationship does not exist, a `NotFound` status is returned. - If the generation does not match, a `FailedPrecondition` status is returned. The current generation can be retrieved from ListTrustRelationships or DescribeTrustRelationship. */
1103
+ export const updateTrustRelationship: API.OperationMethod<
1104
+ UpdateTrustRelationshipRequest,
1105
+ UpdateTrustRelationshipResponse,
1106
+ UpdateTrustRelationshipError,
1107
+ NamespaceLabsOpContext
1108
+ > = /*@__PURE__*/ API.make(() => ({
1109
+ input: __S(76, __c19, 0) as any as S.Schema<UpdateTrustRelationshipRequest>,
1110
+ output: __S(116, __c29, 0) as any as S.Schema<UpdateTrustRelationshipResponse>,
1111
+ errors: [
1112
+ InvalidArgument,
1113
+ FailedPrecondition,
1114
+ Unauthenticated,
1115
+ PermissionDenied,
1116
+ NotFound,
1117
+ AlreadyExists,
1118
+ ResourceExhausted,
1119
+ ],
1120
+ serviceErrors: NamespaceLabsServiceErrors,
1121
+ protocol: NamespaceLabsProtocol,
1122
+ retry: Retry.Retry,
1123
+ telemetry: TELEMETRY,
1124
+ span: "UpdateTrustRelationship",
1125
+ }));
1126
+
893
1127
  // Schema builders: each runs one schema initializer, on that schema's first use.
894
1128
  function __c0(j: number): any {
1129
+ switch (j) {
1130
+ case 0:
1131
+ return S.suspend(() =>
1132
+ S.Struct({
1133
+ id: S.optional(S.String),
1134
+ generation: S.optional(S.String),
1135
+ }).pipe(
1136
+ T.Http({
1137
+ method: "POST",
1138
+ uri: "/namespace.cloud.iam.v1beta.TenantService/DeleteTrustRelationship",
1139
+ code: 200,
1140
+ }),
1141
+ ),
1142
+ ).annotate({ identifier: "DeleteTrustRelationshipRequest" });
1143
+ }
1144
+ }
1145
+ function __c1(j: number): any {
1146
+ switch (j) {
1147
+ case 0:
1148
+ return S.suspend(() =>
1149
+ S.Struct({}).pipe(
1150
+ T.Http({
1151
+ method: "POST",
1152
+ uri: "/namespace.cloud.iam.v1beta.TenantService/DescribePolicies",
1153
+ code: 200,
1154
+ }),
1155
+ ),
1156
+ ).annotate({ identifier: "DescribePoliciesRequest" });
1157
+ case 1:
1158
+ return S.suspend(() =>
1159
+ S.Struct({
1160
+ policies: __S(86, __c21, 2),
1161
+ revision: S.String,
1162
+ }),
1163
+ ).annotate({ identifier: "DescribePoliciesResponse" });
1164
+ }
1165
+ }
1166
+ function __c2(j: number): any {
895
1167
  switch (j) {
896
1168
  case 0:
897
1169
  return S.suspend(() =>
@@ -909,20 +1181,14 @@ function __c0(j: number): any {
909
1181
  return S.suspend(() =>
910
1182
  S.Struct({
911
1183
  name: S.String,
912
- policies: __S(9, __c2, 1),
913
- enrolledTenantIds: __S(4, __c1, 0),
914
- versions: __S(9, __c2, 1),
1184
+ policies: __S(13, __c3, 1),
1185
+ enrolledTenantIds: __S(100, __c25, 0),
1186
+ versions: __S(13, __c3, 1),
915
1187
  }),
916
1188
  ).annotate({ identifier: "DescribeTenantGroupResponse" });
917
1189
  }
918
1190
  }
919
- function __c1(j: number): any {
920
- switch (j) {
921
- case 0:
922
- return S.Array(S.String);
923
- }
924
- }
925
- function __c2(j: number): any {
1191
+ function __c3(j: number): any {
926
1192
  switch (j) {
927
1193
  case 0:
928
1194
  return S.suspend(() =>
@@ -932,19 +1198,44 @@ function __c2(j: number): any {
932
1198
  }),
933
1199
  ).annotate({ identifier: "TenantGroupPolicy" });
934
1200
  case 1:
935
- return S.Array(__S(8, __c2, 0));
1201
+ return S.Array(__S(12, __c3, 0));
936
1202
  }
937
1203
  }
938
- function __c3(j: number): any {
1204
+ function __c4(j: number): any {
1205
+ switch (j) {
1206
+ case 0:
1207
+ return S.suspend(() =>
1208
+ S.Struct({
1209
+ id: S.optional(S.String),
1210
+ }).pipe(
1211
+ T.Http({
1212
+ method: "POST",
1213
+ uri: "/namespace.cloud.iam.v1beta.TenantService/DescribeTrustRelationship",
1214
+ code: 200,
1215
+ }),
1216
+ ),
1217
+ ).annotate({ identifier: "DescribeTrustRelationshipRequest" });
1218
+ case 1:
1219
+ return S.suspend(() =>
1220
+ S.Struct({
1221
+ generation: S.String,
1222
+ id: S.String,
1223
+ createdAt: S.optional(S.String),
1224
+ spec: S.optional(__S(109, __c27, 1)),
1225
+ }),
1226
+ ).annotate({ identifier: "DescribeTrustRelationshipResponse" });
1227
+ }
1228
+ }
1229
+ function __c5(j: number): any {
939
1230
  switch (j) {
940
1231
  case 0:
941
1232
  return S.suspend(() =>
942
1233
  S.Struct({
943
1234
  visibleName: S.optional(S.String),
944
- policies: S.optional(__S(82, __c20, 2)),
1235
+ policies: S.optional(__S(86, __c21, 2)),
945
1236
  externalAccountId: S.optional(S.String),
946
- labels: S.optional(__S(73, __c18, 1)),
947
- enrolledGroups: S.optional(__S(4, __c1, 0)),
1237
+ labels: S.optional(__S(89, __c22, 1)),
1238
+ enrolledGroups: S.optional(__S(100, __c25, 0)),
948
1239
  }).pipe(
949
1240
  T.Http({
950
1241
  method: "POST",
@@ -955,13 +1246,13 @@ function __c3(j: number): any {
955
1246
  ).annotate({ identifier: "EnsureTenantForExternalAccountRequest" });
956
1247
  }
957
1248
  }
958
- function __c4(j: number): any {
1249
+ function __c6(j: number): any {
959
1250
  switch (j) {
960
1251
  case 0:
961
1252
  return S.suspend(() =>
962
1253
  S.Struct({
963
1254
  name: S.optional(S.String),
964
- policies: S.optional(__S(9, __c2, 1)),
1255
+ policies: S.optional(__S(13, __c3, 1)),
965
1256
  }).pipe(
966
1257
  T.Http({
967
1258
  method: "POST",
@@ -978,13 +1269,13 @@ function __c4(j: number): any {
978
1269
  ).annotate({ identifier: "EnsureTenantGroupResponse" });
979
1270
  }
980
1271
  }
981
- function __c5(j: number): any {
1272
+ function __c7(j: number): any {
982
1273
  switch (j) {
983
1274
  case 0:
984
1275
  return S.suspend(() =>
985
1276
  S.Struct({
986
1277
  publicKeyPem: S.optional(S.String),
987
- permissions: S.optional(__S(25, __c6, 1)),
1278
+ permissions: S.optional(__S(105, __c26, 1)),
988
1279
  }).pipe(
989
1280
  T.Http({
990
1281
  method: "POST",
@@ -1001,21 +1292,7 @@ function __c5(j: number): any {
1001
1292
  ).annotate({ identifier: "ExchangeTenantTokenForClientCertResponse" });
1002
1293
  }
1003
1294
  }
1004
- function __c6(j: number): any {
1005
- switch (j) {
1006
- case 0:
1007
- return S.suspend(() =>
1008
- S.Struct({
1009
- resourceType: S.optional(S.String),
1010
- resourceId: S.optional(S.String),
1011
- actions: S.optional(__S(4, __c1, 0)),
1012
- }),
1013
- ).annotate({ identifier: "Permission" });
1014
- case 1:
1015
- return S.Array(__S(24, __c6, 0));
1016
- }
1017
- }
1018
- function __c7(j: number): any {
1295
+ function __c8(j: number): any {
1019
1296
  switch (j) {
1020
1297
  case 0:
1021
1298
  return S.suspend(() =>
@@ -1023,8 +1300,8 @@ function __c7(j: number): any {
1023
1300
  tenantId: S.optional(S.String),
1024
1301
  actorId: S.optional(S.String),
1025
1302
  durationSecs: S.optional(S.String),
1026
- policies: S.optional(__S(33, __c8, 1)),
1027
- access: S.optional(__S(34, __c8, 2)),
1303
+ policies: S.optional(__S(37, __c9, 1)),
1304
+ access: S.optional(__S(38, __c9, 2)),
1028
1305
  publicKeyPem: S.optional(S.String),
1029
1306
  }).pipe(
1030
1307
  T.Http({
@@ -1043,7 +1320,7 @@ function __c7(j: number): any {
1043
1320
  ).annotate({ identifier: "IssueTenantClientCertificateResponse" });
1044
1321
  }
1045
1322
  }
1046
- function __c8(j: number): any {
1323
+ function __c9(j: number): any {
1047
1324
  switch (j) {
1048
1325
  case 0:
1049
1326
  return S.suspend(() =>
@@ -1053,16 +1330,16 @@ function __c8(j: number): any {
1053
1330
  }),
1054
1331
  ).annotate({ identifier: "TenantTokenPolicy" });
1055
1332
  case 1:
1056
- return S.Array(__S(32, __c8, 0));
1333
+ return S.Array(__S(36, __c9, 0));
1057
1334
  case 2:
1058
1335
  return S.suspend(() =>
1059
1336
  S.Struct({
1060
- grants: S.optional(__S(25, __c6, 1)),
1337
+ grants: S.optional(__S(105, __c26, 1)),
1061
1338
  }),
1062
1339
  ).annotate({ identifier: "AccessPolicy" });
1063
1340
  }
1064
1341
  }
1065
- function __c9(j: number): any {
1342
+ function __c10(j: number): any {
1066
1343
  switch (j) {
1067
1344
  case 0:
1068
1345
  return S.suspend(() =>
@@ -1070,8 +1347,8 @@ function __c9(j: number): any {
1070
1347
  tenantId: S.optional(S.String),
1071
1348
  actorId: S.optional(S.String),
1072
1349
  durationSecs: S.optional(S.String),
1073
- policies: S.optional(__S(33, __c8, 1)),
1074
- access: S.optional(__S(34, __c8, 2)),
1350
+ policies: S.optional(__S(37, __c9, 1)),
1351
+ access: S.optional(__S(38, __c9, 2)),
1075
1352
  }).pipe(
1076
1353
  T.Http({
1077
1354
  method: "POST",
@@ -1088,7 +1365,7 @@ function __c9(j: number): any {
1088
1365
  ).annotate({ identifier: "IssueTenantTokenResponse" });
1089
1366
  }
1090
1367
  }
1091
- function __c10(j: number): any {
1368
+ function __c11(j: number): any {
1092
1369
  switch (j) {
1093
1370
  case 0:
1094
1371
  return S.suspend(() =>
@@ -1104,21 +1381,21 @@ function __c10(j: number): any {
1104
1381
  return S.suspend(() =>
1105
1382
  S.Struct({
1106
1383
  name: S.String,
1107
- policies: __S(9, __c2, 1),
1108
- versions: __S(9, __c2, 1),
1384
+ policies: __S(13, __c3, 1),
1385
+ versions: __S(13, __c3, 1),
1109
1386
  }),
1110
1387
  ).annotate({ identifier: "ListTenantGroupsResponseTenantGroup" });
1111
1388
  case 2:
1112
- return S.Array(__S(41, __c10, 1));
1389
+ return S.Array(__S(45, __c11, 1));
1113
1390
  case 3:
1114
1391
  return S.suspend(() =>
1115
1392
  S.Struct({
1116
- tenantGroups: __S(42, __c10, 2),
1393
+ tenantGroups: __S(46, __c11, 2),
1117
1394
  }),
1118
1395
  ).annotate({ identifier: "ListTenantGroupsResponse" });
1119
1396
  }
1120
1397
  }
1121
- function __c11(j: number): any {
1398
+ function __c12(j: number): any {
1122
1399
  switch (j) {
1123
1400
  case 0:
1124
1401
  return S.suspend(() =>
@@ -1136,17 +1413,48 @@ function __c11(j: number): any {
1136
1413
  ),
1137
1414
  ).annotate({ identifier: "ListTenantsRequest" });
1138
1415
  case 1:
1139
- return S.Array(__S(74, __c18, 2));
1416
+ return S.Array(__S(90, __c22, 2));
1140
1417
  case 2:
1141
1418
  return S.suspend(() =>
1142
1419
  S.Struct({
1143
- tenants: __S(45, __c11, 1),
1420
+ tenants: __S(49, __c12, 1),
1144
1421
  cursor: S.String,
1145
1422
  }),
1146
1423
  ).annotate({ identifier: "ListTenantsResponse" });
1147
1424
  }
1148
1425
  }
1149
- function __c12(j: number): any {
1426
+ function __c13(j: number): any {
1427
+ switch (j) {
1428
+ case 0:
1429
+ return S.suspend(() =>
1430
+ S.Struct({}).pipe(
1431
+ T.Http({
1432
+ method: "POST",
1433
+ uri: "/namespace.cloud.iam.v1beta.TenantService/ListTrustRelationships",
1434
+ code: 200,
1435
+ }),
1436
+ ),
1437
+ ).annotate({ identifier: "ListTrustRelationshipsRequest" });
1438
+ case 1:
1439
+ return S.suspend(() =>
1440
+ S.Struct({
1441
+ id: S.String,
1442
+ createdAt: S.optional(S.String),
1443
+ spec: S.optional(__S(109, __c27, 1)),
1444
+ generation: S.String,
1445
+ }),
1446
+ ).annotate({ identifier: "ListTrustRelationshipsResponseEntry" });
1447
+ case 2:
1448
+ return S.Array(__S(53, __c13, 1));
1449
+ case 3:
1450
+ return S.suspend(() =>
1451
+ S.Struct({
1452
+ trustRelationships: __S(54, __c13, 2),
1453
+ }),
1454
+ ).annotate({ identifier: "ListTrustRelationshipsResponse" });
1455
+ }
1456
+ }
1457
+ function __c14(j: number): any {
1150
1458
  switch (j) {
1151
1459
  case 0:
1152
1460
  return S.suspend(() =>
@@ -1162,7 +1470,7 @@ function __c12(j: number): any {
1162
1470
  ).annotate({ identifier: "RemoveTenantRequest" });
1163
1471
  }
1164
1472
  }
1165
- function __c13(j: number): any {
1473
+ function __c15(j: number): any {
1166
1474
  switch (j) {
1167
1475
  case 0:
1168
1476
  return S.suspend(() =>
@@ -1178,7 +1486,7 @@ function __c13(j: number): any {
1178
1486
  ).annotate({ identifier: "ResumeTenantRequest" });
1179
1487
  }
1180
1488
  }
1181
- function __c14(j: number): any {
1489
+ function __c16(j: number): any {
1182
1490
  switch (j) {
1183
1491
  case 0:
1184
1492
  return S.suspend(() =>
@@ -1194,13 +1502,13 @@ function __c14(j: number): any {
1194
1502
  ).annotate({ identifier: "SuspendTenantRequest" });
1195
1503
  }
1196
1504
  }
1197
- function __c15(j: number): any {
1505
+ function __c17(j: number): any {
1198
1506
  switch (j) {
1199
1507
  case 0:
1200
1508
  return S.suspend(() =>
1201
1509
  S.Struct({
1202
1510
  tenantId: S.optional(S.String),
1203
- policies: S.optional(__S(82, __c20, 2)),
1511
+ policies: S.optional(__S(86, __c21, 2)),
1204
1512
  revision: S.optional(S.String),
1205
1513
  }).pipe(
1206
1514
  T.Http({
@@ -1212,15 +1520,15 @@ function __c15(j: number): any {
1212
1520
  ).annotate({ identifier: "UpdatePoliciesRequest" });
1213
1521
  }
1214
1522
  }
1215
- function __c16(j: number): any {
1523
+ function __c18(j: number): any {
1216
1524
  switch (j) {
1217
1525
  case 0:
1218
1526
  return S.suspend(() =>
1219
1527
  S.Struct({
1220
1528
  tenantId: S.optional(S.String),
1221
1529
  visibleName: S.optional(S.String),
1222
- policies: S.optional(__S(82, __c20, 2)),
1223
- labels: S.optional(__S(73, __c18, 1)),
1530
+ policies: S.optional(__S(86, __c21, 2)),
1531
+ labels: S.optional(__S(89, __c22, 1)),
1224
1532
  }).pipe(
1225
1533
  T.Http({
1226
1534
  method: "POST",
@@ -1231,16 +1539,34 @@ function __c16(j: number): any {
1231
1539
  ).annotate({ identifier: "UpdateTenantRequest" });
1232
1540
  }
1233
1541
  }
1234
- function __c17(j: number): any {
1542
+ function __c19(j: number): any {
1543
+ switch (j) {
1544
+ case 0:
1545
+ return S.suspend(() =>
1546
+ S.Struct({
1547
+ id: S.optional(S.String),
1548
+ generation: S.optional(S.String),
1549
+ spec: S.optional(__S(109, __c27, 1)),
1550
+ }).pipe(
1551
+ T.Http({
1552
+ method: "POST",
1553
+ uri: "/namespace.cloud.iam.v1beta.TenantService/UpdateTrustRelationship",
1554
+ code: 200,
1555
+ }),
1556
+ ),
1557
+ ).annotate({ identifier: "UpdateTrustRelationshipRequest" });
1558
+ }
1559
+ }
1560
+ function __c20(j: number): any {
1235
1561
  switch (j) {
1236
1562
  case 0:
1237
1563
  return S.suspend(() =>
1238
1564
  S.Struct({
1239
1565
  creatorId: S.optional(S.String),
1240
1566
  visibleName: S.optional(S.String),
1241
- policies: S.optional(__S(82, __c20, 2)),
1567
+ policies: S.optional(__S(86, __c21, 2)),
1242
1568
  externalAccountId: S.optional(S.String),
1243
- labels: S.optional(__S(73, __c18, 1)),
1569
+ labels: S.optional(__S(89, __c22, 1)),
1244
1570
  }).pipe(
1245
1571
  T.Http({
1246
1572
  method: "POST",
@@ -1251,7 +1577,28 @@ function __c17(j: number): any {
1251
1577
  ).annotate({ identifier: "CreateTenantRequest" });
1252
1578
  }
1253
1579
  }
1254
- function __c18(j: number): any {
1580
+ function __c21(j: number): any {
1581
+ switch (j) {
1582
+ case 0:
1583
+ return S.suspend(() =>
1584
+ S.Struct({
1585
+ expiresAt: S.optional(S.String),
1586
+ }),
1587
+ ).annotate({ identifier: "TenantPolicyExpirationPolicy" });
1588
+ case 1:
1589
+ return S.suspend(() =>
1590
+ S.Struct({
1591
+ id: S.optional(S.String),
1592
+ policy: S.optional(S.String),
1593
+ value: S.optional(S.String),
1594
+ expirationPolicy: S.optional(__S(84, __c21, 0)),
1595
+ }),
1596
+ ).annotate({ identifier: "TenantPolicy" });
1597
+ case 2:
1598
+ return S.Array(__S(85, __c21, 1));
1599
+ }
1600
+ }
1601
+ function __c22(j: number): any {
1255
1602
  switch (j) {
1256
1603
  case 0:
1257
1604
  return S.suspend(() =>
@@ -1261,7 +1608,7 @@ function __c18(j: number): any {
1261
1608
  }),
1262
1609
  ).annotate({ identifier: "Label" });
1263
1610
  case 1:
1264
- return S.Array(__S(72, __c18, 0));
1611
+ return S.Array(__S(88, __c22, 0));
1265
1612
  case 2:
1266
1613
  return S.suspend(() =>
1267
1614
  S.Struct({
@@ -1270,43 +1617,82 @@ function __c18(j: number): any {
1270
1617
  externalAccountId: S.String,
1271
1618
  createdAt: S.optional(S.String),
1272
1619
  visibleName: S.String,
1273
- labels: __S(73, __c18, 1),
1620
+ labels: __S(89, __c22, 1),
1274
1621
  }),
1275
1622
  ).annotate({ identifier: "Tenant" });
1276
1623
  }
1277
1624
  }
1278
- function __c19(j: number): any {
1625
+ function __c23(j: number): any {
1279
1626
  switch (j) {
1280
1627
  case 0:
1281
1628
  return S.suspend(() =>
1282
1629
  S.Struct({
1283
- tenant: S.optional(__S(74, __c18, 2)),
1630
+ tenant: S.optional(__S(90, __c22, 2)),
1284
1631
  }),
1285
1632
  ).annotate({ identifier: "CreateTenantResponse" });
1286
1633
  }
1287
1634
  }
1288
- function __c20(j: number): any {
1635
+ function __c24(j: number): any {
1289
1636
  switch (j) {
1290
1637
  case 0:
1291
1638
  return S.suspend(() =>
1292
1639
  S.Struct({
1293
- expiresAt: S.optional(S.String),
1640
+ spec: S.optional(__S(109, __c27, 1)),
1641
+ }).pipe(
1642
+ T.Http({
1643
+ method: "POST",
1644
+ uri: "/namespace.cloud.iam.v1beta.TenantService/CreateTrustRelationship",
1645
+ code: 200,
1646
+ }),
1647
+ ),
1648
+ ).annotate({ identifier: "CreateTrustRelationshipRequest" });
1649
+ case 1:
1650
+ return S.suspend(() =>
1651
+ S.Struct({
1652
+ id: S.String,
1294
1653
  }),
1295
- ).annotate({ identifier: "TenantPolicyExpirationPolicy" });
1654
+ ).annotate({ identifier: "CreateTrustRelationshipResponse" });
1655
+ }
1656
+ }
1657
+ function __c25(j: number): any {
1658
+ switch (j) {
1659
+ case 0:
1660
+ return S.Array(S.String);
1661
+ }
1662
+ }
1663
+ function __c26(j: number): any {
1664
+ switch (j) {
1665
+ case 0:
1666
+ return S.suspend(() =>
1667
+ S.Struct({
1668
+ resourceType: S.optional(S.String),
1669
+ resourceId: S.optional(S.String),
1670
+ actions: S.optional(__S(100, __c25, 0)),
1671
+ }),
1672
+ ).annotate({ identifier: "Permission" });
1673
+ case 1:
1674
+ return S.Array(__S(104, __c26, 0));
1675
+ }
1676
+ }
1677
+ function __c27(j: number): any {
1678
+ switch (j) {
1679
+ case 0:
1680
+ return S.Record(S.String, S.String);
1296
1681
  case 1:
1297
1682
  return S.suspend(() =>
1298
1683
  S.Struct({
1299
- id: S.optional(S.String),
1300
- policy: S.optional(S.String),
1301
- value: S.optional(S.String),
1302
- expirationPolicy: S.optional(__S(80, __c20, 0)),
1684
+ issuer: S.optional(S.String),
1685
+ subjectMatch: S.optional(S.String),
1686
+ audience: S.optional(S.String),
1687
+ defaultPermissions: S.optional(__S(105, __c26, 1)),
1688
+ defaultTokenDuration: S.optional(S.String),
1689
+ maximumTokenDuration: S.optional(S.String),
1690
+ claimMatches: S.optional(__S(108, __c27, 0)),
1303
1691
  }),
1304
- ).annotate({ identifier: "TenantPolicy" });
1305
- case 2:
1306
- return S.Array(__S(81, __c20, 1));
1692
+ ).annotate({ identifier: "TrustRelationshipSpec" });
1307
1693
  }
1308
1694
  }
1309
- function __c21(j: number): any {
1695
+ function __c28(j: number): any {
1310
1696
  switch (j) {
1311
1697
  case 0:
1312
1698
  return S.suspend(() =>
@@ -1322,33 +1708,12 @@ function __c21(j: number): any {
1322
1708
  ).annotate({ identifier: "DeleteTenantGroupRequest" });
1323
1709
  }
1324
1710
  }
1325
- function __c22(j: number): any {
1711
+ function __c29(j: number): any {
1326
1712
  switch (j) {
1327
1713
  case 0:
1328
1714
  return S.suspend(() => S.Struct({})).annotate({ identifier: "DeleteTenantGroupResponse" });
1329
1715
  }
1330
1716
  }
1331
- function __c23(j: number): any {
1332
- switch (j) {
1333
- case 0:
1334
- return S.suspend(() =>
1335
- S.Struct({}).pipe(
1336
- T.Http({
1337
- method: "POST",
1338
- uri: "/namespace.cloud.iam.v1beta.TenantService/DescribePolicies",
1339
- code: 200,
1340
- }),
1341
- ),
1342
- ).annotate({ identifier: "DescribePoliciesRequest" });
1343
- case 1:
1344
- return S.suspend(() =>
1345
- S.Struct({
1346
- policies: __S(82, __c20, 2),
1347
- revision: S.String,
1348
- }),
1349
- ).annotate({ identifier: "DescribePoliciesResponse" });
1350
- }
1351
- }
1352
1717
  // Schema table: entry i is schema j of builder f, made on first reach.
1353
1718
  function __S(i: number, f: (j: number) => unknown, j: number): any {
1354
1719
  return (__s[i] ??= __L.at(f, j));