@homeflare/distilled-proxmox 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (78) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +87 -0
  3. package/dist/credentials.d.ts +41 -0
  4. package/dist/credentials.d.ts.map +1 -0
  5. package/dist/credentials.js +67 -0
  6. package/dist/credentials.js.map +1 -0
  7. package/dist/errors.d.ts +128 -0
  8. package/dist/errors.d.ts.map +1 -0
  9. package/dist/errors.js +91 -0
  10. package/dist/errors.js.map +1 -0
  11. package/dist/index.d.ts +30 -0
  12. package/dist/index.d.ts.map +1 -0
  13. package/dist/index.js +30 -0
  14. package/dist/index.js.map +1 -0
  15. package/dist/protocol.d.ts +18 -0
  16. package/dist/protocol.d.ts.map +1 -0
  17. package/dist/protocol.js +167 -0
  18. package/dist/protocol.js.map +1 -0
  19. package/dist/protocol.test.d.ts +2 -0
  20. package/dist/protocol.test.d.ts.map +1 -0
  21. package/dist/protocol.test.js +64 -0
  22. package/dist/protocol.test.js.map +1 -0
  23. package/dist/retry.d.ts +50 -0
  24. package/dist/retry.d.ts.map +1 -0
  25. package/dist/retry.js +43 -0
  26. package/dist/retry.js.map +1 -0
  27. package/dist/services/access.d.ts +975 -0
  28. package/dist/services/access.d.ts.map +1 -0
  29. package/dist/services/access.js +1208 -0
  30. package/dist/services/access.js.map +1 -0
  31. package/dist/services/cluster.d.ts +5940 -0
  32. package/dist/services/cluster.d.ts.map +1 -0
  33. package/dist/services/cluster.js +7405 -0
  34. package/dist/services/cluster.js.map +1 -0
  35. package/dist/services/index.d.ts +7 -0
  36. package/dist/services/index.d.ts.map +1 -0
  37. package/dist/services/index.js +8 -0
  38. package/dist/services/index.js.map +1 -0
  39. package/dist/services/nodes.d.ts +7887 -0
  40. package/dist/services/nodes.d.ts.map +1 -0
  41. package/dist/services/nodes.js +10253 -0
  42. package/dist/services/nodes.js.map +1 -0
  43. package/dist/services/pools.d.ts +133 -0
  44. package/dist/services/pools.d.ts.map +1 -0
  45. package/dist/services/pools.js +183 -0
  46. package/dist/services/pools.js.map +1 -0
  47. package/dist/services/storage.d.ts +317 -0
  48. package/dist/services/storage.d.ts.map +1 -0
  49. package/dist/services/storage.js +239 -0
  50. package/dist/services/storage.js.map +1 -0
  51. package/dist/services/version.d.ts +20 -0
  52. package/dist/services/version.d.ts.map +1 -0
  53. package/dist/services/version.js +27 -0
  54. package/dist/services/version.js.map +1 -0
  55. package/dist/task.d.ts +51 -0
  56. package/dist/task.d.ts.map +1 -0
  57. package/dist/task.js +60 -0
  58. package/dist/task.js.map +1 -0
  59. package/dist/traits.d.ts +12 -0
  60. package/dist/traits.d.ts.map +1 -0
  61. package/dist/traits.js +14 -0
  62. package/dist/traits.js.map +1 -0
  63. package/package.json +81 -0
  64. package/src/credentials.ts +101 -0
  65. package/src/errors.ts +152 -0
  66. package/src/index.ts +33 -0
  67. package/src/protocol.test.ts +101 -0
  68. package/src/protocol.ts +204 -0
  69. package/src/retry.ts +74 -0
  70. package/src/services/access.ts +2722 -0
  71. package/src/services/cluster.ts +18550 -0
  72. package/src/services/index.ts +7 -0
  73. package/src/services/nodes.ts +25537 -0
  74. package/src/services/pools.ts +397 -0
  75. package/src/services/storage.ts +711 -0
  76. package/src/services/version.ts +54 -0
  77. package/src/task.ts +87 -0
  78. package/src/traits.ts +45 -0
@@ -0,0 +1,1208 @@
1
+ // AUTO-GENERATED by scripts/generate.ts from .generated-specs (apidata.js, via scripts/apidoc.ts — see its header). Do not edit.
2
+ import * as S from "@distilled.cloud/core/schema";
3
+ import * as API from "@distilled.cloud/core/api";
4
+ import * as T from "../traits.js";
5
+ import { ProxmoxProtocol, } from "../protocol.js";
6
+ import * as Retry from "../retry.js";
7
+ export const CreateAccessDomainRequestMode = S.String;
8
+ export const CreateAccessDomainRequestSslversion = S.String;
9
+ export const CreateAccessDomainRequestType = S.String;
10
+ export const CreateAccessDomainRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
11
+ acr_values: S.optional(S.String.pipe(T.Body("acr-values"))),
12
+ audiences: S.optional(S.String),
13
+ autocreate: S.optional(S.String),
14
+ base_dn: S.optional(S.String),
15
+ bind_dn: S.optional(S.String),
16
+ capath: S.optional(S.String),
17
+ case_sensitive: S.optional(S.String.pipe(T.Body("case-sensitive"))),
18
+ cert: S.optional(S.String),
19
+ certkey: S.optional(S.String),
20
+ check_connection: S.optional(S.String.pipe(T.Body("check-connection"))),
21
+ client_id: S.optional(S.String.pipe(T.Body("client-id"))),
22
+ client_key: S.optional(S.String.pipe(T.Body("client-key"))),
23
+ comment: S.optional(S.String),
24
+ default: S.optional(S.String),
25
+ domain: S.optional(S.String),
26
+ filter: S.optional(S.String),
27
+ group_classes: S.optional(S.String),
28
+ group_dn: S.optional(S.String),
29
+ group_filter: S.optional(S.String),
30
+ group_name_attr: S.optional(S.String),
31
+ groups_autocreate: S.optional(S.String.pipe(T.Body("groups-autocreate"))),
32
+ groups_claim: S.optional(S.String.pipe(T.Body("groups-claim"))),
33
+ groups_overwrite: S.optional(S.String.pipe(T.Body("groups-overwrite"))),
34
+ issuer_url: S.optional(S.String.pipe(T.Body("issuer-url"))),
35
+ mode: S.optional(CreateAccessDomainRequestMode),
36
+ password: S.optional(S.String),
37
+ port: S.optional(S.String),
38
+ prompt: S.optional(S.String),
39
+ query_userinfo: S.optional(S.String.pipe(T.Body("query-userinfo"))),
40
+ realm: S.String,
41
+ scopes: S.optional(S.String),
42
+ secure: S.optional(S.String),
43
+ server1: S.optional(S.String),
44
+ server2: S.optional(S.String),
45
+ sslversion: S.optional(CreateAccessDomainRequestSslversion),
46
+ sync_defaults_options: S.optional(S.String.pipe(T.Body("sync-defaults-options"))),
47
+ sync_attributes: S.optional(S.String),
48
+ tfa: S.optional(S.String),
49
+ type: CreateAccessDomainRequestType,
50
+ user_attr: S.optional(S.String),
51
+ user_classes: S.optional(S.String),
52
+ username_claim: S.optional(S.String.pipe(T.Body("username-claim"))),
53
+ verify: S.optional(S.String),
54
+ }).pipe(T.Http({
55
+ method: "POST",
56
+ uri: "/access/domains",
57
+ code: 200,
58
+ contentType: "form-urlencoded",
59
+ }))).annotate({
60
+ identifier: "CreateAccessDomainRequest",
61
+ });
62
+ export const CreateAccessDomainResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
63
+ identifier: "CreateAccessDomainResponse",
64
+ });
65
+ export const CreateAccessGroupRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
66
+ comment: S.optional(S.String),
67
+ groupid: S.String,
68
+ }).pipe(T.Http({
69
+ method: "POST",
70
+ uri: "/access/groups",
71
+ code: 200,
72
+ contentType: "form-urlencoded",
73
+ }))).annotate({
74
+ identifier: "CreateAccessGroupRequest",
75
+ });
76
+ export const CreateAccessGroupResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
77
+ identifier: "CreateAccessGroupResponse",
78
+ });
79
+ export const CreateAccessOpenidAuthUrlRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
80
+ realm: S.String,
81
+ redirect_url: S.String.pipe(T.Body("redirect-url")),
82
+ }).pipe(T.Http({
83
+ method: "POST",
84
+ uri: "/access/openid/auth-url",
85
+ code: 200,
86
+ contentType: "form-urlencoded",
87
+ }))).annotate({
88
+ identifier: "CreateAccessOpenidAuthUrlRequest",
89
+ });
90
+ export const CreateAccessOpenidAuthUrlResponse = /*@__PURE__*/ S.suspend(() => S.String.pipe(T.RawResponseRoot())).annotate({
91
+ identifier: "CreateAccessOpenidAuthUrlResponse",
92
+ });
93
+ export const CreateAccessRoleRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
94
+ privs: S.optional(S.String),
95
+ roleid: S.String,
96
+ }).pipe(T.Http({
97
+ method: "POST",
98
+ uri: "/access/roles",
99
+ code: 200,
100
+ contentType: "form-urlencoded",
101
+ }))).annotate({
102
+ identifier: "CreateAccessRoleRequest",
103
+ });
104
+ export const CreateAccessRoleResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
105
+ identifier: "CreateAccessRoleResponse",
106
+ });
107
+ export const CreateAccessTicketRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
108
+ new_format: S.optional(S.String.pipe(T.Body("new-format"))),
109
+ otp: S.optional(S.String),
110
+ password: S.String,
111
+ path: S.optional(S.String),
112
+ privs: S.optional(S.String),
113
+ realm: S.optional(S.String),
114
+ tfa_challenge: S.optional(S.String.pipe(T.Body("tfa-challenge"))),
115
+ username: S.String,
116
+ }).pipe(T.Http({
117
+ method: "POST",
118
+ uri: "/access/ticket",
119
+ code: 200,
120
+ contentType: "form-urlencoded",
121
+ }))).annotate({
122
+ identifier: "CreateAccessTicketRequest",
123
+ });
124
+ export const CreateAccessTicketResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
125
+ CSRFPreventionToken: S.optional(S.String),
126
+ clustername: S.optional(S.String),
127
+ ticket: S.optional(S.String),
128
+ username: S.String,
129
+ })).annotate({
130
+ identifier: "CreateAccessTicketResponse",
131
+ });
132
+ export const CreateAccessUserRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
133
+ comment: S.optional(S.String),
134
+ email: S.optional(S.String),
135
+ enable: S.optional(S.String),
136
+ expire: S.optional(S.String),
137
+ firstname: S.optional(S.String),
138
+ groups: S.optional(S.String),
139
+ keys: S.optional(S.String),
140
+ lastname: S.optional(S.String),
141
+ password: S.optional(S.String),
142
+ userid: S.String,
143
+ }).pipe(T.Http({
144
+ method: "POST",
145
+ uri: "/access/users",
146
+ code: 200,
147
+ contentType: "form-urlencoded",
148
+ }))).annotate({
149
+ identifier: "CreateAccessUserRequest",
150
+ });
151
+ export const CreateAccessUserResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
152
+ identifier: "CreateAccessUserResponse",
153
+ });
154
+ export const CreateAccessVncticketRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
155
+ authid: S.String,
156
+ path: S.String,
157
+ port: S.optional(S.String),
158
+ privs: S.String,
159
+ vncticket: S.String,
160
+ }).pipe(T.Http({
161
+ method: "POST",
162
+ uri: "/access/vncticket",
163
+ code: 200,
164
+ contentType: "form-urlencoded",
165
+ }))).annotate({
166
+ identifier: "CreateAccessVncticketRequest",
167
+ });
168
+ export const CreateAccessVncticketResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
169
+ identifier: "CreateAccessVncticketResponse",
170
+ });
171
+ export const DeleteAccessDomainRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
172
+ realm: S.String.pipe(T.Label()),
173
+ }).pipe(T.Http({ method: "DELETE", uri: "/access/domains/{realm}", code: 200 }))).annotate({
174
+ identifier: "DeleteAccessDomainRequest",
175
+ });
176
+ export const DeleteAccessDomainResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
177
+ identifier: "DeleteAccessDomainResponse",
178
+ });
179
+ export const DeleteAccessGroupRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
180
+ groupid: S.String.pipe(T.Label()),
181
+ }).pipe(T.Http({ method: "DELETE", uri: "/access/groups/{groupid}", code: 200 }))).annotate({
182
+ identifier: "DeleteAccessGroupRequest",
183
+ });
184
+ export const DeleteAccessGroupResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
185
+ identifier: "DeleteAccessGroupResponse",
186
+ });
187
+ export const DeleteAccessRoleRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
188
+ roleid: S.String.pipe(T.Label()),
189
+ }).pipe(T.Http({ method: "DELETE", uri: "/access/roles/{roleid}", code: 200 }))).annotate({
190
+ identifier: "DeleteAccessRoleRequest",
191
+ });
192
+ export const DeleteAccessRoleResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
193
+ identifier: "DeleteAccessRoleResponse",
194
+ });
195
+ export const DeleteAccessTfaRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
196
+ userid: S.String.pipe(T.Label()),
197
+ id: S.String.pipe(T.Label()),
198
+ password: S.optional(S.String),
199
+ }).pipe(T.Http({
200
+ method: "DELETE",
201
+ uri: "/access/tfa/{userid}/{id}",
202
+ code: 200,
203
+ contentType: "form-urlencoded",
204
+ }))).annotate({
205
+ identifier: "DeleteAccessTfaRequest",
206
+ });
207
+ export const DeleteAccessTfaResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
208
+ identifier: "DeleteAccessTfaResponse",
209
+ });
210
+ export const DeleteAccessUserRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
211
+ userid: S.String.pipe(T.Label()),
212
+ }).pipe(T.Http({ method: "DELETE", uri: "/access/users/{userid}", code: 200 }))).annotate({
213
+ identifier: "DeleteAccessUserRequest",
214
+ });
215
+ export const DeleteAccessUserResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
216
+ identifier: "DeleteAccessUserResponse",
217
+ });
218
+ export const DeleteAccessUserTokenRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
219
+ userid: S.String.pipe(T.Label()),
220
+ tokenid: S.String.pipe(T.Label()),
221
+ }).pipe(T.Http({
222
+ method: "DELETE",
223
+ uri: "/access/users/{userid}/token/{tokenid}",
224
+ code: 200,
225
+ }))).annotate({
226
+ identifier: "DeleteAccessUserTokenRequest",
227
+ });
228
+ export const DeleteAccessUserTokenResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
229
+ identifier: "DeleteAccessUserTokenResponse",
230
+ });
231
+ export const GetAccessDomainRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
232
+ realm: S.String.pipe(T.Label()),
233
+ }).pipe(T.Http({ method: "GET", uri: "/access/domains/{realm}", code: 200 }))).annotate({
234
+ identifier: "GetAccessDomainRequest",
235
+ });
236
+ export const GetAccessDomainResponse = /*@__PURE__*/ S.suspend(() => S.Unknown.pipe(T.RawResponseRoot())).annotate({
237
+ identifier: "GetAccessDomainResponse",
238
+ });
239
+ export const GetAccessGroupRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
240
+ groupid: S.String.pipe(T.Label()),
241
+ }).pipe(T.Http({ method: "GET", uri: "/access/groups/{groupid}", code: 200 }))).annotate({
242
+ identifier: "GetAccessGroupRequest",
243
+ });
244
+ export const GetAccessGroupResponseMembersList = /*@__PURE__*/ S.Array(S.String);
245
+ export const GetAccessGroupResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
246
+ comment: S.optional(S.String),
247
+ members: GetAccessGroupResponseMembersList,
248
+ })).annotate({
249
+ identifier: "GetAccessGroupResponse",
250
+ });
251
+ export const GetAccessPermissionsRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
252
+ path: S.optional(S.String.pipe(T.Query())),
253
+ userid: S.optional(S.String.pipe(T.Query())),
254
+ }).pipe(T.Http({ method: "GET", uri: "/access/permissions", code: 200 }))).annotate({
255
+ identifier: "GetAccessPermissionsRequest",
256
+ });
257
+ export const GetAccessPermissionsResponse = /*@__PURE__*/ S.suspend(() => S.Unknown.pipe(T.RawResponseRoot())).annotate({
258
+ identifier: "GetAccessPermissionsResponse",
259
+ });
260
+ export const GetAccessRoleRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
261
+ roleid: S.String.pipe(T.Label()),
262
+ }).pipe(T.Http({ method: "GET", uri: "/access/roles/{roleid}", code: 200 }))).annotate({
263
+ identifier: "GetAccessRoleRequest",
264
+ });
265
+ export const GetAccessRoleResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
266
+ Datastore_Allocate: S.optional(S.Unknown.pipe(T.Body("Datastore.Allocate"))),
267
+ Datastore_AllocateSpace: S.optional(S.Unknown.pipe(T.Body("Datastore.AllocateSpace"))),
268
+ Datastore_AllocateTemplate: S.optional(S.Unknown.pipe(T.Body("Datastore.AllocateTemplate"))),
269
+ Datastore_Audit: S.optional(S.Unknown.pipe(T.Body("Datastore.Audit"))),
270
+ Group_Allocate: S.optional(S.Unknown.pipe(T.Body("Group.Allocate"))),
271
+ Mapping_Audit: S.optional(S.Unknown.pipe(T.Body("Mapping.Audit"))),
272
+ Mapping_Modify: S.optional(S.Unknown.pipe(T.Body("Mapping.Modify"))),
273
+ Mapping_Use: S.optional(S.Unknown.pipe(T.Body("Mapping.Use"))),
274
+ Permissions_Modify: S.optional(S.Unknown.pipe(T.Body("Permissions.Modify"))),
275
+ Pool_Allocate: S.optional(S.Unknown.pipe(T.Body("Pool.Allocate"))),
276
+ Pool_Audit: S.optional(S.Unknown.pipe(T.Body("Pool.Audit"))),
277
+ Realm_Allocate: S.optional(S.Unknown.pipe(T.Body("Realm.Allocate"))),
278
+ Realm_AllocateUser: S.optional(S.Unknown.pipe(T.Body("Realm.AllocateUser"))),
279
+ SDN_Allocate: S.optional(S.Unknown.pipe(T.Body("SDN.Allocate"))),
280
+ SDN_Audit: S.optional(S.Unknown.pipe(T.Body("SDN.Audit"))),
281
+ SDN_Use: S.optional(S.Unknown.pipe(T.Body("SDN.Use"))),
282
+ Sys_AccessNetwork: S.optional(S.Unknown.pipe(T.Body("Sys.AccessNetwork"))),
283
+ Sys_Audit: S.optional(S.Unknown.pipe(T.Body("Sys.Audit"))),
284
+ Sys_Console: S.optional(S.Unknown.pipe(T.Body("Sys.Console"))),
285
+ Sys_Incoming: S.optional(S.Unknown.pipe(T.Body("Sys.Incoming"))),
286
+ Sys_Modify: S.optional(S.Unknown.pipe(T.Body("Sys.Modify"))),
287
+ Sys_PowerMgmt: S.optional(S.Unknown.pipe(T.Body("Sys.PowerMgmt"))),
288
+ Sys_Syslog: S.optional(S.Unknown.pipe(T.Body("Sys.Syslog"))),
289
+ User_Modify: S.optional(S.Unknown.pipe(T.Body("User.Modify"))),
290
+ VM_Allocate: S.optional(S.Unknown.pipe(T.Body("VM.Allocate"))),
291
+ VM_Audit: S.optional(S.Unknown.pipe(T.Body("VM.Audit"))),
292
+ VM_Backup: S.optional(S.Unknown.pipe(T.Body("VM.Backup"))),
293
+ VM_Clone: S.optional(S.Unknown.pipe(T.Body("VM.Clone"))),
294
+ VM_Config_CDROM: S.optional(S.Unknown.pipe(T.Body("VM.Config.CDROM"))),
295
+ VM_Config_CPU: S.optional(S.Unknown.pipe(T.Body("VM.Config.CPU"))),
296
+ VM_Config_Cloudinit: S.optional(S.Unknown.pipe(T.Body("VM.Config.Cloudinit"))),
297
+ VM_Config_Disk: S.optional(S.Unknown.pipe(T.Body("VM.Config.Disk"))),
298
+ VM_Config_HWType: S.optional(S.Unknown.pipe(T.Body("VM.Config.HWType"))),
299
+ VM_Config_Memory: S.optional(S.Unknown.pipe(T.Body("VM.Config.Memory"))),
300
+ VM_Config_Network: S.optional(S.Unknown.pipe(T.Body("VM.Config.Network"))),
301
+ VM_Config_Options: S.optional(S.Unknown.pipe(T.Body("VM.Config.Options"))),
302
+ VM_Console: S.optional(S.Unknown.pipe(T.Body("VM.Console"))),
303
+ VM_GuestAgent_Audit: S.optional(S.Unknown.pipe(T.Body("VM.GuestAgent.Audit"))),
304
+ VM_GuestAgent_FileRead: S.optional(S.Unknown.pipe(T.Body("VM.GuestAgent.FileRead"))),
305
+ VM_GuestAgent_FileSystemMgmt: S.optional(S.Unknown.pipe(T.Body("VM.GuestAgent.FileSystemMgmt"))),
306
+ VM_GuestAgent_FileWrite: S.optional(S.Unknown.pipe(T.Body("VM.GuestAgent.FileWrite"))),
307
+ VM_GuestAgent_Unrestricted: S.optional(S.Unknown.pipe(T.Body("VM.GuestAgent.Unrestricted"))),
308
+ VM_Migrate: S.optional(S.Unknown.pipe(T.Body("VM.Migrate"))),
309
+ VM_PowerMgmt: S.optional(S.Unknown.pipe(T.Body("VM.PowerMgmt"))),
310
+ VM_Replicate: S.optional(S.Unknown.pipe(T.Body("VM.Replicate"))),
311
+ VM_Snapshot: S.optional(S.Unknown.pipe(T.Body("VM.Snapshot"))),
312
+ VM_Snapshot_Rollback: S.optional(S.Unknown.pipe(T.Body("VM.Snapshot.Rollback"))),
313
+ })).annotate({
314
+ identifier: "GetAccessRoleResponse",
315
+ });
316
+ export const GetAccessTfaRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
317
+ userid: S.String.pipe(T.Label()),
318
+ }).pipe(T.Http({ method: "GET", uri: "/access/tfa/{userid}", code: 200 }))).annotate({
319
+ identifier: "GetAccessTfaRequest",
320
+ });
321
+ export const GetAccessTfaResponseBodyItemType = S.String;
322
+ export const GetAccessTfaResponseBodyItem = /*@__PURE__*/ S.suspend(() => S.Struct({
323
+ created: S.Number,
324
+ description: S.String,
325
+ enable: S.optional(S.Unknown),
326
+ id: S.String,
327
+ type: GetAccessTfaResponseBodyItemType,
328
+ })).annotate({
329
+ identifier: "GetAccessTfaResponseBodyItem",
330
+ });
331
+ export const GetAccessTfaResponseBodyList = /*@__PURE__*/ S.Array(GetAccessTfaResponseBodyItem);
332
+ export const GetAccessTfaResponse = /*@__PURE__*/ S.suspend(() => GetAccessTfaResponseBodyList.pipe(T.RawResponseRoot())).annotate({
333
+ identifier: "GetAccessTfaResponse",
334
+ });
335
+ export const GetAccessTfa2Request = /*@__PURE__*/ S.suspend(() => S.Struct({
336
+ userid: S.String.pipe(T.Label()),
337
+ id: S.String.pipe(T.Label()),
338
+ }).pipe(T.Http({ method: "GET", uri: "/access/tfa/{userid}/{id}", code: 200 }))).annotate({
339
+ identifier: "GetAccessTfa2Request",
340
+ });
341
+ export const GetAccessTfa2ResponseType = S.String;
342
+ export const GetAccessTfa2Response = /*@__PURE__*/ S.suspend(() => S.Struct({
343
+ created: S.Number,
344
+ description: S.String,
345
+ enable: S.optional(S.Unknown),
346
+ id: S.String,
347
+ type: GetAccessTfa2ResponseType,
348
+ })).annotate({
349
+ identifier: "GetAccessTfa2Response",
350
+ });
351
+ export const GetAccessTicketRequest = /*@__PURE__*/ S.suspend(() => S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access/ticket", code: 200 }))).annotate({
352
+ identifier: "GetAccessTicketRequest",
353
+ });
354
+ export const GetAccessTicketResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
355
+ identifier: "GetAccessTicketResponse",
356
+ });
357
+ export const GetAccessUserRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
358
+ userid: S.String.pipe(T.Label()),
359
+ }).pipe(T.Http({ method: "GET", uri: "/access/users/{userid}", code: 200 }))).annotate({
360
+ identifier: "GetAccessUserRequest",
361
+ });
362
+ export const GetAccessUserResponseGroupsList = /*@__PURE__*/ S.Array(S.String);
363
+ export const GetAccessUserResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
364
+ comment: S.optional(S.String),
365
+ email: S.optional(S.String),
366
+ enable: S.optional(S.Unknown),
367
+ expire: S.optional(S.Number),
368
+ firstname: S.optional(S.String),
369
+ groups: S.optional(GetAccessUserResponseGroupsList),
370
+ keys: S.optional(S.String),
371
+ lastname: S.optional(S.String),
372
+ tokens: S.optional(S.Unknown),
373
+ })).annotate({
374
+ identifier: "GetAccessUserResponse",
375
+ });
376
+ export const GetAccessUserTfaRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
377
+ userid: S.String.pipe(T.Label()),
378
+ multiple: S.optional(S.String.pipe(T.Query())),
379
+ }).pipe(T.Http({ method: "GET", uri: "/access/users/{userid}/tfa", code: 200 }))).annotate({
380
+ identifier: "GetAccessUserTfaRequest",
381
+ });
382
+ export const GetAccessUserTfaResponseRealm = S.String;
383
+ export const GetAccessUserTfaResponseTypesItem = S.String;
384
+ export const GetAccessUserTfaResponseTypesList = /*@__PURE__*/ S.Array(GetAccessUserTfaResponseTypesItem);
385
+ export const GetAccessUserTfaResponseUser = S.String;
386
+ export const GetAccessUserTfaResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
387
+ realm: S.optional(GetAccessUserTfaResponseRealm),
388
+ types: S.optional(GetAccessUserTfaResponseTypesList),
389
+ user: S.optional(GetAccessUserTfaResponseUser),
390
+ })).annotate({
391
+ identifier: "GetAccessUserTfaResponse",
392
+ });
393
+ export const GetAccessUserTokenRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
394
+ userid: S.String.pipe(T.Label()),
395
+ tokenid: S.String.pipe(T.Label()),
396
+ }).pipe(T.Http({
397
+ method: "GET",
398
+ uri: "/access/users/{userid}/token/{tokenid}",
399
+ code: 200,
400
+ }))).annotate({
401
+ identifier: "GetAccessUserTokenRequest",
402
+ });
403
+ export const GetAccessUserTokenResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
404
+ comment: S.optional(S.String),
405
+ expire: S.optional(S.Number),
406
+ privsep: S.optional(S.Unknown),
407
+ })).annotate({
408
+ identifier: "GetAccessUserTokenResponse",
409
+ });
410
+ export const ListAccessRequest = /*@__PURE__*/ S.suspend(() => S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access", code: 200 }))).annotate({
411
+ identifier: "ListAccessRequest",
412
+ });
413
+ export const ListAccessResponseBodyItem = /*@__PURE__*/ S.suspend(() => S.Struct({
414
+ subdir: S.String,
415
+ })).annotate({
416
+ identifier: "ListAccessResponseBodyItem",
417
+ });
418
+ export const ListAccessResponseBodyList = /*@__PURE__*/ S.Array(ListAccessResponseBodyItem);
419
+ export const ListAccessResponse = /*@__PURE__*/ S.suspend(() => ListAccessResponseBodyList.pipe(T.RawResponseRoot())).annotate({
420
+ identifier: "ListAccessResponse",
421
+ });
422
+ export const ListAccessAclRequest = /*@__PURE__*/ S.suspend(() => S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access/acl", code: 200 }))).annotate({
423
+ identifier: "ListAccessAclRequest",
424
+ });
425
+ export const ListAccessAclResponseBodyItemType = S.String;
426
+ export const ListAccessAclResponseBodyItem = /*@__PURE__*/ S.suspend(() => S.Struct({
427
+ path: S.String,
428
+ propagate: S.optional(S.Unknown),
429
+ roleid: S.String,
430
+ type: ListAccessAclResponseBodyItemType,
431
+ ugid: S.String,
432
+ })).annotate({
433
+ identifier: "ListAccessAclResponseBodyItem",
434
+ });
435
+ export const ListAccessAclResponseBodyList = /*@__PURE__*/ S.Array(ListAccessAclResponseBodyItem);
436
+ export const ListAccessAclResponse = /*@__PURE__*/ S.suspend(() => ListAccessAclResponseBodyList.pipe(T.RawResponseRoot())).annotate({
437
+ identifier: "ListAccessAclResponse",
438
+ });
439
+ export const ListAccessDomainsRequest = /*@__PURE__*/ S.suspend(() => S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access/domains", code: 200 }))).annotate({
440
+ identifier: "ListAccessDomainsRequest",
441
+ });
442
+ export const ListAccessDomainsResponseBodyItemTfa = S.String;
443
+ export const ListAccessDomainsResponseBodyItem = /*@__PURE__*/ S.suspend(() => S.Struct({
444
+ comment: S.optional(S.String),
445
+ realm: S.String,
446
+ tfa: S.optional(ListAccessDomainsResponseBodyItemTfa),
447
+ type: S.String,
448
+ })).annotate({
449
+ identifier: "ListAccessDomainsResponseBodyItem",
450
+ });
451
+ export const ListAccessDomainsResponseBodyList = /*@__PURE__*/ S.Array(ListAccessDomainsResponseBodyItem);
452
+ export const ListAccessDomainsResponse = /*@__PURE__*/ S.suspend(() => ListAccessDomainsResponseBodyList.pipe(T.RawResponseRoot())).annotate({
453
+ identifier: "ListAccessDomainsResponse",
454
+ });
455
+ export const ListAccessGroupsRequest = /*@__PURE__*/ S.suspend(() => S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access/groups", code: 200 }))).annotate({
456
+ identifier: "ListAccessGroupsRequest",
457
+ });
458
+ export const ListAccessGroupsResponseBodyItem = /*@__PURE__*/ S.suspend(() => S.Struct({
459
+ comment: S.optional(S.String),
460
+ groupid: S.String,
461
+ users: S.optional(S.String),
462
+ })).annotate({
463
+ identifier: "ListAccessGroupsResponseBodyItem",
464
+ });
465
+ export const ListAccessGroupsResponseBodyList = /*@__PURE__*/ S.Array(ListAccessGroupsResponseBodyItem);
466
+ export const ListAccessGroupsResponse = /*@__PURE__*/ S.suspend(() => ListAccessGroupsResponseBodyList.pipe(T.RawResponseRoot())).annotate({
467
+ identifier: "ListAccessGroupsResponse",
468
+ });
469
+ export const ListAccessOpenidRequest = /*@__PURE__*/ S.suspend(() => S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access/openid", code: 200 }))).annotate({
470
+ identifier: "ListAccessOpenidRequest",
471
+ });
472
+ export const ListAccessOpenidResponseBodyItem = ListAccessResponseBodyItem;
473
+ export const ListAccessOpenidResponseBodyList = /*@__PURE__*/ S.Array(ListAccessResponseBodyItem);
474
+ export const ListAccessOpenidResponse = /*@__PURE__*/ S.suspend(() => ListAccessOpenidResponseBodyList.pipe(T.RawResponseRoot())).annotate({
475
+ identifier: "ListAccessOpenidResponse",
476
+ });
477
+ export const ListAccessRolesRequest = /*@__PURE__*/ S.suspend(() => S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access/roles", code: 200 }))).annotate({
478
+ identifier: "ListAccessRolesRequest",
479
+ });
480
+ export const ListAccessRolesResponseBodyItem = /*@__PURE__*/ S.suspend(() => S.Struct({
481
+ privs: S.optional(S.String),
482
+ roleid: S.String,
483
+ special: S.optional(S.Unknown),
484
+ })).annotate({
485
+ identifier: "ListAccessRolesResponseBodyItem",
486
+ });
487
+ export const ListAccessRolesResponseBodyList = /*@__PURE__*/ S.Array(ListAccessRolesResponseBodyItem);
488
+ export const ListAccessRolesResponse = /*@__PURE__*/ S.suspend(() => ListAccessRolesResponseBodyList.pipe(T.RawResponseRoot())).annotate({
489
+ identifier: "ListAccessRolesResponse",
490
+ });
491
+ export const ListAccessTfaRequest = /*@__PURE__*/ S.suspend(() => S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access/tfa", code: 200 }))).annotate({
492
+ identifier: "ListAccessTfaRequest",
493
+ });
494
+ export const ListAccessTfaResponseBodyItemEntriesItemType = S.String;
495
+ export const ListAccessTfaResponseBodyItemEntriesItem = /*@__PURE__*/ S.suspend(() => S.Struct({
496
+ created: S.Number,
497
+ description: S.String,
498
+ enable: S.optional(S.Unknown),
499
+ id: S.String,
500
+ type: ListAccessTfaResponseBodyItemEntriesItemType,
501
+ })).annotate({
502
+ identifier: "ListAccessTfaResponseBodyItemEntriesItem",
503
+ });
504
+ export const ListAccessTfaResponseBodyItemEntriesList = /*@__PURE__*/ S.Array(ListAccessTfaResponseBodyItemEntriesItem);
505
+ export const ListAccessTfaResponseBodyItem = /*@__PURE__*/ S.suspend(() => S.Struct({
506
+ entries: ListAccessTfaResponseBodyItemEntriesList,
507
+ tfa_locked_until: S.optional(S.Number.pipe(T.Body("tfa-locked-until"))),
508
+ totp_locked: S.optional(S.Unknown.pipe(T.Body("totp-locked"))),
509
+ userid: S.String,
510
+ })).annotate({
511
+ identifier: "ListAccessTfaResponseBodyItem",
512
+ });
513
+ export const ListAccessTfaResponseBodyList = /*@__PURE__*/ S.Array(ListAccessTfaResponseBodyItem);
514
+ export const ListAccessTfaResponse = /*@__PURE__*/ S.suspend(() => ListAccessTfaResponseBodyList.pipe(T.RawResponseRoot())).annotate({
515
+ identifier: "ListAccessTfaResponse",
516
+ });
517
+ export const ListAccessUsersRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
518
+ enabled: S.optional(S.String.pipe(T.Query())),
519
+ full: S.optional(S.String.pipe(T.Query())),
520
+ }).pipe(T.Http({ method: "GET", uri: "/access/users", code: 200 }))).annotate({
521
+ identifier: "ListAccessUsersRequest",
522
+ });
523
+ export const ListAccessUsersResponseBodyItemTokensItem =
524
+ /*@__PURE__*/ S.suspend(() => S.Struct({
525
+ comment: S.optional(S.String),
526
+ expire: S.optional(S.Number),
527
+ privsep: S.optional(S.Unknown),
528
+ tokenid: S.String,
529
+ })).annotate({
530
+ identifier: "ListAccessUsersResponseBodyItemTokensItem",
531
+ });
532
+ export const ListAccessUsersResponseBodyItemTokensList = /*@__PURE__*/ S.Array(ListAccessUsersResponseBodyItemTokensItem);
533
+ export const ListAccessUsersResponseBodyItem = /*@__PURE__*/ S.suspend(() => S.Struct({
534
+ comment: S.optional(S.String),
535
+ email: S.optional(S.String),
536
+ enable: S.optional(S.Unknown),
537
+ expire: S.optional(S.Number),
538
+ firstname: S.optional(S.String),
539
+ groups: S.optional(S.String),
540
+ keys: S.optional(S.String),
541
+ lastname: S.optional(S.String),
542
+ realm_type: S.optional(S.String.pipe(T.Body("realm-type"))),
543
+ tfa_locked_until: S.optional(S.Number.pipe(T.Body("tfa-locked-until"))),
544
+ tokens: S.optional(ListAccessUsersResponseBodyItemTokensList),
545
+ totp_locked: S.optional(S.Unknown.pipe(T.Body("totp-locked"))),
546
+ userid: S.String,
547
+ })).annotate({
548
+ identifier: "ListAccessUsersResponseBodyItem",
549
+ });
550
+ export const ListAccessUsersResponseBodyList = /*@__PURE__*/ S.Array(ListAccessUsersResponseBodyItem);
551
+ export const ListAccessUsersResponse = /*@__PURE__*/ S.suspend(() => ListAccessUsersResponseBodyList.pipe(T.RawResponseRoot())).annotate({
552
+ identifier: "ListAccessUsersResponse",
553
+ });
554
+ export const ListAccessUserTokenRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
555
+ userid: S.String.pipe(T.Label()),
556
+ }).pipe(T.Http({ method: "GET", uri: "/access/users/{userid}/token", code: 200 }))).annotate({
557
+ identifier: "ListAccessUserTokenRequest",
558
+ });
559
+ export const ListAccessUserTokenResponseBodyItem = ListAccessUsersResponseBodyItemTokensItem;
560
+ export const ListAccessUserTokenResponseBodyList = /*@__PURE__*/ S.Array(ListAccessUsersResponseBodyItemTokensItem);
561
+ export const ListAccessUserTokenResponse = /*@__PURE__*/ S.suspend(() => ListAccessUserTokenResponseBodyList.pipe(T.RawResponseRoot())).annotate({
562
+ identifier: "ListAccessUserTokenResponse",
563
+ });
564
+ export const LoginAccessOpenidRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
565
+ code: S.String,
566
+ redirect_url: S.String.pipe(T.Body("redirect-url")),
567
+ state: S.String,
568
+ }).pipe(T.Http({
569
+ method: "POST",
570
+ uri: "/access/openid/login",
571
+ code: 200,
572
+ contentType: "form-urlencoded",
573
+ }))).annotate({
574
+ identifier: "LoginAccessOpenidRequest",
575
+ });
576
+ export const LoginAccessOpenidResponse = /*@__PURE__*/ S.suspend(() => S.Unknown.pipe(T.RawResponseRoot())).annotate({
577
+ identifier: "LoginAccessOpenidResponse",
578
+ });
579
+ export const PutAccessAclRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
580
+ delete: S.optional(S.String),
581
+ groups: S.optional(S.String),
582
+ path: S.String,
583
+ propagate: S.optional(S.String),
584
+ roles: S.String,
585
+ tokens: S.optional(S.String),
586
+ users: S.optional(S.String),
587
+ }).pipe(T.Http({
588
+ method: "PUT",
589
+ uri: "/access/acl",
590
+ code: 200,
591
+ contentType: "form-urlencoded",
592
+ }))).annotate({
593
+ identifier: "PutAccessAclRequest",
594
+ });
595
+ export const PutAccessAclResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
596
+ identifier: "PutAccessAclResponse",
597
+ });
598
+ export const PutAccessDomainRequestMode = S.String;
599
+ export const PutAccessDomainRequestSslversion = S.String;
600
+ export const PutAccessDomainRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
601
+ realm: S.String.pipe(T.Label()),
602
+ acr_values: S.optional(S.String.pipe(T.Body("acr-values"))),
603
+ audiences: S.optional(S.String),
604
+ autocreate: S.optional(S.String),
605
+ base_dn: S.optional(S.String),
606
+ bind_dn: S.optional(S.String),
607
+ capath: S.optional(S.String),
608
+ case_sensitive: S.optional(S.String.pipe(T.Body("case-sensitive"))),
609
+ cert: S.optional(S.String),
610
+ certkey: S.optional(S.String),
611
+ check_connection: S.optional(S.String.pipe(T.Body("check-connection"))),
612
+ client_id: S.optional(S.String.pipe(T.Body("client-id"))),
613
+ client_key: S.optional(S.String.pipe(T.Body("client-key"))),
614
+ comment: S.optional(S.String),
615
+ default: S.optional(S.String),
616
+ delete: S.optional(S.String),
617
+ digest: S.optional(S.String),
618
+ domain: S.optional(S.String),
619
+ filter: S.optional(S.String),
620
+ group_classes: S.optional(S.String),
621
+ group_dn: S.optional(S.String),
622
+ group_filter: S.optional(S.String),
623
+ group_name_attr: S.optional(S.String),
624
+ groups_autocreate: S.optional(S.String.pipe(T.Body("groups-autocreate"))),
625
+ groups_claim: S.optional(S.String.pipe(T.Body("groups-claim"))),
626
+ groups_overwrite: S.optional(S.String.pipe(T.Body("groups-overwrite"))),
627
+ issuer_url: S.optional(S.String.pipe(T.Body("issuer-url"))),
628
+ mode: S.optional(PutAccessDomainRequestMode),
629
+ password: S.optional(S.String),
630
+ port: S.optional(S.String),
631
+ prompt: S.optional(S.String),
632
+ query_userinfo: S.optional(S.String.pipe(T.Body("query-userinfo"))),
633
+ scopes: S.optional(S.String),
634
+ secure: S.optional(S.String),
635
+ server1: S.optional(S.String),
636
+ server2: S.optional(S.String),
637
+ sslversion: S.optional(PutAccessDomainRequestSslversion),
638
+ sync_defaults_options: S.optional(S.String.pipe(T.Body("sync-defaults-options"))),
639
+ sync_attributes: S.optional(S.String),
640
+ tfa: S.optional(S.String),
641
+ user_attr: S.optional(S.String),
642
+ user_classes: S.optional(S.String),
643
+ verify: S.optional(S.String),
644
+ }).pipe(T.Http({
645
+ method: "PUT",
646
+ uri: "/access/domains/{realm}",
647
+ code: 200,
648
+ contentType: "form-urlencoded",
649
+ }))).annotate({
650
+ identifier: "PutAccessDomainRequest",
651
+ });
652
+ export const PutAccessDomainResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
653
+ identifier: "PutAccessDomainResponse",
654
+ });
655
+ export const PutAccessGroupRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
656
+ groupid: S.String.pipe(T.Label()),
657
+ comment: S.optional(S.String),
658
+ }).pipe(T.Http({
659
+ method: "PUT",
660
+ uri: "/access/groups/{groupid}",
661
+ code: 200,
662
+ contentType: "form-urlencoded",
663
+ }))).annotate({
664
+ identifier: "PutAccessGroupRequest",
665
+ });
666
+ export const PutAccessGroupResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
667
+ identifier: "PutAccessGroupResponse",
668
+ });
669
+ export const PutAccessPasswordRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
670
+ confirmation_password: S.optional(S.String.pipe(T.Body("confirmation-password"))),
671
+ password: S.String,
672
+ userid: S.String,
673
+ }).pipe(T.Http({
674
+ method: "PUT",
675
+ uri: "/access/password",
676
+ code: 200,
677
+ contentType: "form-urlencoded",
678
+ }))).annotate({
679
+ identifier: "PutAccessPasswordRequest",
680
+ });
681
+ export const PutAccessPasswordResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
682
+ identifier: "PutAccessPasswordResponse",
683
+ });
684
+ export const PutAccessRoleRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
685
+ roleid: S.String.pipe(T.Label()),
686
+ append: S.optional(S.String),
687
+ privs: S.optional(S.String),
688
+ }).pipe(T.Http({
689
+ method: "PUT",
690
+ uri: "/access/roles/{roleid}",
691
+ code: 200,
692
+ contentType: "form-urlencoded",
693
+ }))).annotate({
694
+ identifier: "PutAccessRoleRequest",
695
+ });
696
+ export const PutAccessRoleResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
697
+ identifier: "PutAccessRoleResponse",
698
+ });
699
+ export const PutAccessTfaRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
700
+ userid: S.String.pipe(T.Label()),
701
+ id: S.String.pipe(T.Label()),
702
+ description: S.optional(S.String),
703
+ enable: S.optional(S.String),
704
+ password: S.optional(S.String),
705
+ }).pipe(T.Http({
706
+ method: "PUT",
707
+ uri: "/access/tfa/{userid}/{id}",
708
+ code: 200,
709
+ contentType: "form-urlencoded",
710
+ }))).annotate({
711
+ identifier: "PutAccessTfaRequest",
712
+ });
713
+ export const PutAccessTfaResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
714
+ identifier: "PutAccessTfaResponse",
715
+ });
716
+ export const PutAccessUserRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
717
+ userid: S.String.pipe(T.Label()),
718
+ append: S.optional(S.String),
719
+ comment: S.optional(S.String),
720
+ email: S.optional(S.String),
721
+ enable: S.optional(S.String),
722
+ expire: S.optional(S.String),
723
+ firstname: S.optional(S.String),
724
+ groups: S.optional(S.String),
725
+ keys: S.optional(S.String),
726
+ lastname: S.optional(S.String),
727
+ }).pipe(T.Http({
728
+ method: "PUT",
729
+ uri: "/access/users/{userid}",
730
+ code: 200,
731
+ contentType: "form-urlencoded",
732
+ }))).annotate({
733
+ identifier: "PutAccessUserRequest",
734
+ });
735
+ export const PutAccessUserResponse = /*@__PURE__*/ S.suspend(() => S.Struct({})).annotate({
736
+ identifier: "PutAccessUserResponse",
737
+ });
738
+ export const PutAccessUserTokenRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
739
+ userid: S.String.pipe(T.Label()),
740
+ tokenid: S.String.pipe(T.Label()),
741
+ comment: S.optional(S.String),
742
+ delete: S.optional(S.String),
743
+ expire: S.optional(S.String),
744
+ privsep: S.optional(S.String),
745
+ regenerate: S.optional(S.String),
746
+ }).pipe(T.Http({
747
+ method: "PUT",
748
+ uri: "/access/users/{userid}/token/{tokenid}",
749
+ code: 200,
750
+ contentType: "form-urlencoded",
751
+ }))).annotate({
752
+ identifier: "PutAccessUserTokenRequest",
753
+ });
754
+ export const PutAccessUserTokenResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
755
+ comment: S.optional(S.String),
756
+ expire: S.optional(S.Number),
757
+ full_tokenid: S.optional(S.String.pipe(T.Body("full-tokenid"))),
758
+ privsep: S.optional(S.Unknown),
759
+ value: S.optional(S.String),
760
+ })).annotate({
761
+ identifier: "PutAccessUserTokenResponse",
762
+ });
763
+ export const PutAccessUserUnlockTfaRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
764
+ userid: S.String.pipe(T.Label()),
765
+ }).pipe(T.Http({
766
+ method: "PUT",
767
+ uri: "/access/users/{userid}/unlock-tfa",
768
+ code: 200,
769
+ }))).annotate({
770
+ identifier: "PutAccessUserUnlockTfaRequest",
771
+ });
772
+ export const PutAccessUserUnlockTfaResponse = /*@__PURE__*/ S.suspend(() => S.Unknown.pipe(T.RawResponseRoot())).annotate({
773
+ identifier: "PutAccessUserUnlockTfaResponse",
774
+ });
775
+ export const SyncAccessDomainRequestScope = S.String;
776
+ export const SyncAccessDomainRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
777
+ realm: S.String.pipe(T.Label()),
778
+ dry_run: S.optional(S.String.pipe(T.Body("dry-run"))),
779
+ enable_new: S.String.pipe(T.Body("enable-new")),
780
+ full: S.String,
781
+ purge: S.String,
782
+ remove_vanished: S.String.pipe(T.Body("remove-vanished")),
783
+ scope: SyncAccessDomainRequestScope,
784
+ }).pipe(T.Http({
785
+ method: "POST",
786
+ uri: "/access/domains/{realm}/sync",
787
+ code: 200,
788
+ contentType: "form-urlencoded",
789
+ }))).annotate({
790
+ identifier: "SyncAccessDomainRequest",
791
+ });
792
+ export const SyncAccessDomainResponse = /*@__PURE__*/ S.suspend(() => S.String.pipe(T.RawResponseRoot())).annotate({
793
+ identifier: "SyncAccessDomainResponse",
794
+ });
795
+ export const UpdateAccessTfaRequestType = S.String;
796
+ export const UpdateAccessTfaRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
797
+ userid: S.String.pipe(T.Label()),
798
+ challenge: S.optional(S.String),
799
+ description: S.optional(S.String),
800
+ password: S.optional(S.String),
801
+ totp: S.optional(S.String),
802
+ type: UpdateAccessTfaRequestType,
803
+ value: S.optional(S.String),
804
+ }).pipe(T.Http({
805
+ method: "POST",
806
+ uri: "/access/tfa/{userid}",
807
+ code: 200,
808
+ contentType: "form-urlencoded",
809
+ }))).annotate({
810
+ identifier: "UpdateAccessTfaRequest",
811
+ });
812
+ export const UpdateAccessTfaResponseRecoveryList = /*@__PURE__*/ S.Array(S.String);
813
+ export const UpdateAccessTfaResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
814
+ challenge: S.optional(S.String),
815
+ id: S.String,
816
+ recovery: S.optional(UpdateAccessTfaResponseRecoveryList),
817
+ })).annotate({
818
+ identifier: "UpdateAccessTfaResponse",
819
+ });
820
+ export const UpdateAccessUserTokenRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
821
+ userid: S.String.pipe(T.Label()),
822
+ tokenid: S.String.pipe(T.Label()),
823
+ comment: S.optional(S.String),
824
+ expire: S.optional(S.String),
825
+ privsep: S.optional(S.String),
826
+ }).pipe(T.Http({
827
+ method: "POST",
828
+ uri: "/access/users/{userid}/token/{tokenid}",
829
+ code: 200,
830
+ contentType: "form-urlencoded",
831
+ }))).annotate({
832
+ identifier: "UpdateAccessUserTokenRequest",
833
+ });
834
+ export const UpdateAccessUserTokenResponseInfo = /*@__PURE__*/ S.suspend(() => S.Struct({
835
+ comment: S.optional(S.String),
836
+ expire: S.optional(S.Number),
837
+ privsep: S.optional(S.Unknown),
838
+ })).annotate({
839
+ identifier: "UpdateAccessUserTokenResponseInfo",
840
+ });
841
+ export const UpdateAccessUserTokenResponse = /*@__PURE__*/ S.suspend(() => S.Struct({
842
+ full_tokenid: S.optional(S.String.pipe(T.Body("full-tokenid"))),
843
+ info: UpdateAccessUserTokenResponseInfo,
844
+ value: S.String,
845
+ })).annotate({
846
+ identifier: "UpdateAccessUserTokenResponse",
847
+ });
848
+ /** Add an authentication server. (root-privileged endpoint) */
849
+ export const createAccessDomain = /*@__PURE__*/ API.make(() => ({
850
+ input: CreateAccessDomainRequest,
851
+ output: CreateAccessDomainResponse,
852
+ errors: [],
853
+ protocol: ProxmoxProtocol,
854
+ retry: Retry.Retry,
855
+ }));
856
+ /** Create new group. (root-privileged endpoint) */
857
+ export const createAccessGroup = /*@__PURE__*/ API.make(() => ({
858
+ input: CreateAccessGroupRequest,
859
+ output: CreateAccessGroupResponse,
860
+ errors: [],
861
+ protocol: ProxmoxProtocol,
862
+ retry: Retry.Retry,
863
+ }));
864
+ /** Get the OpenId Authorization Url for the specified realm. (root-privileged endpoint) */
865
+ export const createAccessOpenidAuthUrl = /*@__PURE__*/ API.make(() => ({
866
+ input: CreateAccessOpenidAuthUrlRequest,
867
+ output: CreateAccessOpenidAuthUrlResponse,
868
+ errors: [],
869
+ protocol: ProxmoxProtocol,
870
+ retry: Retry.Retry,
871
+ }));
872
+ /** Create new role. (root-privileged endpoint) */
873
+ export const createAccessRole = /*@__PURE__*/ API.make(() => ({
874
+ input: CreateAccessRoleRequest,
875
+ output: CreateAccessRoleResponse,
876
+ errors: [],
877
+ protocol: ProxmoxProtocol,
878
+ retry: Retry.Retry,
879
+ }));
880
+ /** Create or verify authentication ticket. (root-privileged endpoint) */
881
+ export const createAccessTicket = /*@__PURE__*/ API.make(() => ({
882
+ input: CreateAccessTicketRequest,
883
+ output: CreateAccessTicketResponse,
884
+ errors: [],
885
+ protocol: ProxmoxProtocol,
886
+ retry: Retry.Retry,
887
+ }));
888
+ /** Create new user. (root-privileged endpoint) */
889
+ export const createAccessUser = /*@__PURE__*/ API.make(() => ({
890
+ input: CreateAccessUserRequest,
891
+ output: CreateAccessUserResponse,
892
+ errors: [],
893
+ protocol: ProxmoxProtocol,
894
+ retry: Retry.Retry,
895
+ }));
896
+ /** verify VNC authentication ticket. (root-privileged endpoint) */
897
+ export const createAccessVncticket = /*@__PURE__*/ API.make(() => ({
898
+ input: CreateAccessVncticketRequest,
899
+ output: CreateAccessVncticketResponse,
900
+ errors: [],
901
+ protocol: ProxmoxProtocol,
902
+ retry: Retry.Retry,
903
+ }));
904
+ /** Delete an authentication server. (root-privileged endpoint) */
905
+ export const deleteAccessDomain = /*@__PURE__*/ API.make(() => ({
906
+ input: DeleteAccessDomainRequest,
907
+ output: DeleteAccessDomainResponse,
908
+ errors: [],
909
+ protocol: ProxmoxProtocol,
910
+ retry: Retry.Retry,
911
+ }));
912
+ /** Delete group. (root-privileged endpoint) */
913
+ export const deleteAccessGroup = /*@__PURE__*/ API.make(() => ({
914
+ input: DeleteAccessGroupRequest,
915
+ output: DeleteAccessGroupResponse,
916
+ errors: [],
917
+ protocol: ProxmoxProtocol,
918
+ retry: Retry.Retry,
919
+ }));
920
+ /** Delete role. (root-privileged endpoint) */
921
+ export const deleteAccessRole = /*@__PURE__*/ API.make(() => ({
922
+ input: DeleteAccessRoleRequest,
923
+ output: DeleteAccessRoleResponse,
924
+ errors: [],
925
+ protocol: ProxmoxProtocol,
926
+ retry: Retry.Retry,
927
+ }));
928
+ /** Delete a TFA entry by ID. (root-privileged endpoint) */
929
+ export const deleteAccessTfa = /*@__PURE__*/ API.make(() => ({
930
+ input: DeleteAccessTfaRequest,
931
+ output: DeleteAccessTfaResponse,
932
+ errors: [],
933
+ protocol: ProxmoxProtocol,
934
+ retry: Retry.Retry,
935
+ }));
936
+ /** Delete user. (root-privileged endpoint) */
937
+ export const deleteAccessUser = /*@__PURE__*/ API.make(() => ({
938
+ input: DeleteAccessUserRequest,
939
+ output: DeleteAccessUserResponse,
940
+ errors: [],
941
+ protocol: ProxmoxProtocol,
942
+ retry: Retry.Retry,
943
+ }));
944
+ /** Remove API token for a specific user. (root-privileged endpoint) */
945
+ export const deleteAccessUserToken = /*@__PURE__*/ API.make(() => ({
946
+ input: DeleteAccessUserTokenRequest,
947
+ output: DeleteAccessUserTokenResponse,
948
+ errors: [],
949
+ protocol: ProxmoxProtocol,
950
+ retry: Retry.Retry,
951
+ }));
952
+ /** Get auth server configuration. */
953
+ export const getAccessDomain = /*@__PURE__*/ API.make(() => ({
954
+ input: GetAccessDomainRequest,
955
+ output: GetAccessDomainResponse,
956
+ errors: [],
957
+ protocol: ProxmoxProtocol,
958
+ retry: Retry.Retry,
959
+ }));
960
+ /** Get group configuration. */
961
+ export const getAccessGroup = /*@__PURE__*/ API.make(() => ({
962
+ input: GetAccessGroupRequest,
963
+ output: GetAccessGroupResponse,
964
+ errors: [],
965
+ protocol: ProxmoxProtocol,
966
+ retry: Retry.Retry,
967
+ }));
968
+ /** Retrieve effective permissions of given user/token. */
969
+ export const getAccessPermissions = /*@__PURE__*/ API.make(() => ({
970
+ input: GetAccessPermissionsRequest,
971
+ output: GetAccessPermissionsResponse,
972
+ errors: [],
973
+ protocol: ProxmoxProtocol,
974
+ retry: Retry.Retry,
975
+ }));
976
+ /** Get role configuration. */
977
+ export const getAccessRole = /*@__PURE__*/ API.make(() => ({
978
+ input: GetAccessRoleRequest,
979
+ output: GetAccessRoleResponse,
980
+ errors: [],
981
+ protocol: ProxmoxProtocol,
982
+ retry: Retry.Retry,
983
+ }));
984
+ /** List TFA configurations of users. (root-privileged endpoint) */
985
+ export const getAccessTfa = /*@__PURE__*/ API.make(() => ({
986
+ input: GetAccessTfaRequest,
987
+ output: GetAccessTfaResponse,
988
+ errors: [],
989
+ protocol: ProxmoxProtocol,
990
+ retry: Retry.Retry,
991
+ }));
992
+ /** Fetch a requested TFA entry if present. (root-privileged endpoint) */
993
+ export const getAccessTfa2 = /*@__PURE__*/ API.make(() => ({
994
+ input: GetAccessTfa2Request,
995
+ output: GetAccessTfa2Response,
996
+ errors: [],
997
+ protocol: ProxmoxProtocol,
998
+ retry: Retry.Retry,
999
+ }));
1000
+ /** Dummy. Useful for formatters which want to provide a login page. */
1001
+ export const getAccessTicket = /*@__PURE__*/ API.make(() => ({
1002
+ input: GetAccessTicketRequest,
1003
+ output: GetAccessTicketResponse,
1004
+ errors: [],
1005
+ protocol: ProxmoxProtocol,
1006
+ retry: Retry.Retry,
1007
+ }));
1008
+ /** Get user configuration. */
1009
+ export const getAccessUser = /*@__PURE__*/ API.make(() => ({
1010
+ input: GetAccessUserRequest,
1011
+ output: GetAccessUserResponse,
1012
+ errors: [],
1013
+ protocol: ProxmoxProtocol,
1014
+ retry: Retry.Retry,
1015
+ }));
1016
+ /** Get user TFA types (Personal and Realm). (root-privileged endpoint) */
1017
+ export const getAccessUserTfa = /*@__PURE__*/ API.make(() => ({
1018
+ input: GetAccessUserTfaRequest,
1019
+ output: GetAccessUserTfaResponse,
1020
+ errors: [],
1021
+ protocol: ProxmoxProtocol,
1022
+ retry: Retry.Retry,
1023
+ }));
1024
+ /** Get specific API token information. */
1025
+ export const getAccessUserToken = /*@__PURE__*/ API.make(() => ({
1026
+ input: GetAccessUserTokenRequest,
1027
+ output: GetAccessUserTokenResponse,
1028
+ errors: [],
1029
+ protocol: ProxmoxProtocol,
1030
+ retry: Retry.Retry,
1031
+ }));
1032
+ /** Directory index. */
1033
+ export const listAccess = /*@__PURE__*/ API.make(() => ({
1034
+ input: ListAccessRequest,
1035
+ output: ListAccessResponse,
1036
+ errors: [],
1037
+ protocol: ProxmoxProtocol,
1038
+ retry: Retry.Retry,
1039
+ }));
1040
+ /** Get Access Control List (ACLs). */
1041
+ export const listAccessAcl = /*@__PURE__*/ API.make(() => ({
1042
+ input: ListAccessAclRequest,
1043
+ output: ListAccessAclResponse,
1044
+ errors: [],
1045
+ protocol: ProxmoxProtocol,
1046
+ retry: Retry.Retry,
1047
+ }));
1048
+ /** Authentication domain index. */
1049
+ export const listAccessDomains = /*@__PURE__*/ API.make(() => ({
1050
+ input: ListAccessDomainsRequest,
1051
+ output: ListAccessDomainsResponse,
1052
+ errors: [],
1053
+ protocol: ProxmoxProtocol,
1054
+ retry: Retry.Retry,
1055
+ }));
1056
+ /** Group index. */
1057
+ export const listAccessGroups = /*@__PURE__*/ API.make(() => ({
1058
+ input: ListAccessGroupsRequest,
1059
+ output: ListAccessGroupsResponse,
1060
+ errors: [],
1061
+ protocol: ProxmoxProtocol,
1062
+ retry: Retry.Retry,
1063
+ }));
1064
+ /** Directory index. */
1065
+ export const listAccessOpenid = /*@__PURE__*/ API.make(() => ({
1066
+ input: ListAccessOpenidRequest,
1067
+ output: ListAccessOpenidResponse,
1068
+ errors: [],
1069
+ protocol: ProxmoxProtocol,
1070
+ retry: Retry.Retry,
1071
+ }));
1072
+ /** Role index. */
1073
+ export const listAccessRoles = /*@__PURE__*/ API.make(() => ({
1074
+ input: ListAccessRolesRequest,
1075
+ output: ListAccessRolesResponse,
1076
+ errors: [],
1077
+ protocol: ProxmoxProtocol,
1078
+ retry: Retry.Retry,
1079
+ }));
1080
+ /** List TFA configurations of users. (root-privileged endpoint) */
1081
+ export const listAccessTfa = /*@__PURE__*/ API.make(() => ({
1082
+ input: ListAccessTfaRequest,
1083
+ output: ListAccessTfaResponse,
1084
+ errors: [],
1085
+ protocol: ProxmoxProtocol,
1086
+ retry: Retry.Retry,
1087
+ }));
1088
+ /** User index. (root-privileged endpoint) */
1089
+ export const listAccessUsers = /*@__PURE__*/ API.make(() => ({
1090
+ input: ListAccessUsersRequest,
1091
+ output: ListAccessUsersResponse,
1092
+ errors: [],
1093
+ protocol: ProxmoxProtocol,
1094
+ retry: Retry.Retry,
1095
+ }));
1096
+ /** Get user API tokens. */
1097
+ export const listAccessUserToken = /*@__PURE__*/ API.make(() => ({
1098
+ input: ListAccessUserTokenRequest,
1099
+ output: ListAccessUserTokenResponse,
1100
+ errors: [],
1101
+ protocol: ProxmoxProtocol,
1102
+ retry: Retry.Retry,
1103
+ }));
1104
+ /** Verify OpenID authorization code and create a ticket. (root-privileged endpoint) */
1105
+ export const loginAccessOpenid = /*@__PURE__*/ API.make(() => ({
1106
+ input: LoginAccessOpenidRequest,
1107
+ output: LoginAccessOpenidResponse,
1108
+ errors: [],
1109
+ protocol: ProxmoxProtocol,
1110
+ retry: Retry.Retry,
1111
+ }));
1112
+ /** Update Access Control List (add or remove permissions). (root-privileged endpoint) */
1113
+ export const putAccessAcl = /*@__PURE__*/ API.make(() => ({
1114
+ input: PutAccessAclRequest,
1115
+ output: PutAccessAclResponse,
1116
+ errors: [],
1117
+ protocol: ProxmoxProtocol,
1118
+ retry: Retry.Retry,
1119
+ }));
1120
+ /** Update authentication server settings. (root-privileged endpoint) */
1121
+ export const putAccessDomain = /*@__PURE__*/ API.make(() => ({
1122
+ input: PutAccessDomainRequest,
1123
+ output: PutAccessDomainResponse,
1124
+ errors: [],
1125
+ protocol: ProxmoxProtocol,
1126
+ retry: Retry.Retry,
1127
+ }));
1128
+ /** Update group data. (root-privileged endpoint) */
1129
+ export const putAccessGroup = /*@__PURE__*/ API.make(() => ({
1130
+ input: PutAccessGroupRequest,
1131
+ output: PutAccessGroupResponse,
1132
+ errors: [],
1133
+ protocol: ProxmoxProtocol,
1134
+ retry: Retry.Retry,
1135
+ }));
1136
+ /** Change user password. (root-privileged endpoint) */
1137
+ export const putAccessPassword = /*@__PURE__*/ API.make(() => ({
1138
+ input: PutAccessPasswordRequest,
1139
+ output: PutAccessPasswordResponse,
1140
+ errors: [],
1141
+ protocol: ProxmoxProtocol,
1142
+ retry: Retry.Retry,
1143
+ }));
1144
+ /** Update an existing role. (root-privileged endpoint) */
1145
+ export const putAccessRole = /*@__PURE__*/ API.make(() => ({
1146
+ input: PutAccessRoleRequest,
1147
+ output: PutAccessRoleResponse,
1148
+ errors: [],
1149
+ protocol: ProxmoxProtocol,
1150
+ retry: Retry.Retry,
1151
+ }));
1152
+ /** Add a TFA entry for a user. (root-privileged endpoint) */
1153
+ export const putAccessTfa = /*@__PURE__*/ API.make(() => ({
1154
+ input: PutAccessTfaRequest,
1155
+ output: PutAccessTfaResponse,
1156
+ errors: [],
1157
+ protocol: ProxmoxProtocol,
1158
+ retry: Retry.Retry,
1159
+ }));
1160
+ /** Update user configuration. (root-privileged endpoint) */
1161
+ export const putAccessUser = /*@__PURE__*/ API.make(() => ({
1162
+ input: PutAccessUserRequest,
1163
+ output: PutAccessUserResponse,
1164
+ errors: [],
1165
+ protocol: ProxmoxProtocol,
1166
+ retry: Retry.Retry,
1167
+ }));
1168
+ /** Update API token for a specific user. NOTE: when 'regenerate' is set, the returned token value needs to be stored as it cannot be retrieved afterwards! (root-privileged endpoint) */
1169
+ export const putAccessUserToken = /*@__PURE__*/ API.make(() => ({
1170
+ input: PutAccessUserTokenRequest,
1171
+ output: PutAccessUserTokenResponse,
1172
+ errors: [],
1173
+ protocol: ProxmoxProtocol,
1174
+ retry: Retry.Retry,
1175
+ }));
1176
+ /** Unlock a user's TFA authentication. (root-privileged endpoint) */
1177
+ export const putAccessUserUnlockTfa = /*@__PURE__*/ API.make(() => ({
1178
+ input: PutAccessUserUnlockTfaRequest,
1179
+ output: PutAccessUserUnlockTfaResponse,
1180
+ errors: [],
1181
+ protocol: ProxmoxProtocol,
1182
+ retry: Retry.Retry,
1183
+ }));
1184
+ /** Syncs users and/or groups from the configured LDAP to user.cfg. NOTE: Synced groups will have the name 'name-$realm', so make sure those groups do not exist to prevent overwriting. (root-privileged endpoint) */
1185
+ export const syncAccessDomain = /*@__PURE__*/ API.make(() => ({
1186
+ input: SyncAccessDomainRequest,
1187
+ output: SyncAccessDomainResponse,
1188
+ errors: [],
1189
+ protocol: ProxmoxProtocol,
1190
+ retry: Retry.Retry,
1191
+ }));
1192
+ /** Add a TFA entry for a user. (root-privileged endpoint) */
1193
+ export const updateAccessTfa = /*@__PURE__*/ API.make(() => ({
1194
+ input: UpdateAccessTfaRequest,
1195
+ output: UpdateAccessTfaResponse,
1196
+ errors: [],
1197
+ protocol: ProxmoxProtocol,
1198
+ retry: Retry.Retry,
1199
+ }));
1200
+ /** Generate a new API token for a specific user. NOTE: returns API token value, which needs to be stored as it cannot be retrieved afterwards! (root-privileged endpoint) */
1201
+ export const updateAccessUserToken = /*@__PURE__*/ API.make(() => ({
1202
+ input: UpdateAccessUserTokenRequest,
1203
+ output: UpdateAccessUserTokenResponse,
1204
+ errors: [],
1205
+ protocol: ProxmoxProtocol,
1206
+ retry: Retry.Retry,
1207
+ }));
1208
+ //# sourceMappingURL=access.js.map