@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,2722 @@
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.ts";
5
+ import {
6
+ ProxmoxProtocol,
7
+ type ProxmoxOpError,
8
+ type ProxmoxOpContext,
9
+ } from "../protocol.ts";
10
+ import * as Retry from "../retry.ts";
11
+
12
+ export type { ProxmoxOpError, ProxmoxOpContext };
13
+
14
+ export type CreateAccessDomainRequestMode = "ldap" | "ldaps" | "ldap+starttls";
15
+ export const CreateAccessDomainRequestMode = S.String;
16
+
17
+ export type CreateAccessDomainRequestSslversion =
18
+ | "tlsv1"
19
+ | "tlsv1_1"
20
+ | "tlsv1_2"
21
+ | "tlsv1_3";
22
+ export const CreateAccessDomainRequestSslversion = S.String;
23
+
24
+ export type CreateAccessDomainRequestType =
25
+ | "ad"
26
+ | "ldap"
27
+ | "openid"
28
+ | "pam"
29
+ | "pve";
30
+ export const CreateAccessDomainRequestType = S.String;
31
+
32
+ export interface CreateAccessDomainRequest {
33
+ /** Specifies the Authentication Context Class Reference values that theAuthorization Server is being requested to use for the Auth Request. */
34
+ acr_values?: string;
35
+ /** A list of audiences that the OpenID Issuer may include that are accepted in addition to 'client-id'. */
36
+ audiences?: string;
37
+ /** Automatically create users if they do not exist. */
38
+ autocreate?: string;
39
+ /** LDAP base domain name */
40
+ base_dn?: string;
41
+ /** LDAP bind domain name */
42
+ bind_dn?: string;
43
+ /** Path to the CA certificate store */
44
+ capath?: string;
45
+ /** username is case-sensitive */
46
+ case_sensitive?: string;
47
+ /** Path to the client certificate */
48
+ cert?: string;
49
+ /** Path to the client certificate key */
50
+ certkey?: string;
51
+ /** Check bind connection to the server. */
52
+ check_connection?: string;
53
+ /** OpenID Client ID */
54
+ client_id?: string;
55
+ /** OpenID Client Key */
56
+ client_key?: string;
57
+ /** Description. */
58
+ comment?: string;
59
+ /** Use this as default realm */
60
+ default?: string;
61
+ /** AD domain name */
62
+ domain?: string;
63
+ /** LDAP filter for user sync. */
64
+ filter?: string;
65
+ /** The objectclasses for groups. */
66
+ group_classes?: string;
67
+ /** LDAP base domain name for group sync. If not set, the base_dn will be used. */
68
+ group_dn?: string;
69
+ /** LDAP filter for group sync. */
70
+ group_filter?: string;
71
+ /** LDAP attribute representing a groups name. If not set or found, the first value of the DN will be used as name. */
72
+ group_name_attr?: string;
73
+ /** Automatically create groups if they do not exist. */
74
+ groups_autocreate?: string;
75
+ /** OpenID claim used to retrieve groups with. */
76
+ groups_claim?: string;
77
+ /** All groups will be overwritten for the user on login. */
78
+ groups_overwrite?: string;
79
+ /** OpenID Issuer Url */
80
+ issuer_url?: string;
81
+ /** LDAP protocol mode. */
82
+ mode?: CreateAccessDomainRequestMode | (string & {});
83
+ /** LDAP bind password. Will be stored in '/etc/pve/priv/realm/<REALM>.pw'. */
84
+ password?: string;
85
+ /** Server port. */
86
+ port?: string;
87
+ /** Specifies whether the Authorization Server prompts the End-User for reauthentication and consent. */
88
+ prompt?: string;
89
+ /** Enables querying the userinfo endpoint for claims values. */
90
+ query_userinfo?: string;
91
+ /** Authentication domain ID */
92
+ realm: string;
93
+ /** Specifies the scopes (user details) that should be authorized and returned, for example 'email' or 'profile'. */
94
+ scopes?: string;
95
+ /** Use secure LDAPS protocol. DEPRECATED: use 'mode' instead. */
96
+ secure?: string;
97
+ /** Server IP address (or DNS name) */
98
+ server1?: string;
99
+ /** Fallback Server IP address (or DNS name) */
100
+ server2?: string;
101
+ /** LDAPS TLS/SSL version. It's not recommended to use version older than 1.2! */
102
+ sslversion?: CreateAccessDomainRequestSslversion | (string & {});
103
+ /** The default options for behavior of synchronizations. */
104
+ sync_defaults_options?: string;
105
+ /** Comma separated list of key=value pairs for specifying which LDAP attributes map to which PVE user field. For example, to map the LDAP attribute 'mail' to PVEs 'email', write 'email=mail'. By default, each PVE user field is represented by an LDAP attribute of the same name. */
106
+ sync_attributes?: string;
107
+ /** Use Two-factor authentication. */
108
+ tfa?: string;
109
+ /** Realm type. */
110
+ type: CreateAccessDomainRequestType | (string & {});
111
+ /** LDAP user attribute name */
112
+ user_attr?: string;
113
+ /** The objectclasses for users. */
114
+ user_classes?: string;
115
+ /** OpenID claim used to generate the unique username. */
116
+ username_claim?: string;
117
+ /** Verify the server's SSL certificate */
118
+ verify?: string;
119
+ }
120
+ export const CreateAccessDomainRequest = /*@__PURE__*/ S.suspend(() =>
121
+ S.Struct({
122
+ acr_values: S.optional(S.String.pipe(T.Body("acr-values"))),
123
+ audiences: S.optional(S.String),
124
+ autocreate: S.optional(S.String),
125
+ base_dn: S.optional(S.String),
126
+ bind_dn: S.optional(S.String),
127
+ capath: S.optional(S.String),
128
+ case_sensitive: S.optional(S.String.pipe(T.Body("case-sensitive"))),
129
+ cert: S.optional(S.String),
130
+ certkey: S.optional(S.String),
131
+ check_connection: S.optional(S.String.pipe(T.Body("check-connection"))),
132
+ client_id: S.optional(S.String.pipe(T.Body("client-id"))),
133
+ client_key: S.optional(S.String.pipe(T.Body("client-key"))),
134
+ comment: S.optional(S.String),
135
+ default: S.optional(S.String),
136
+ domain: S.optional(S.String),
137
+ filter: S.optional(S.String),
138
+ group_classes: S.optional(S.String),
139
+ group_dn: S.optional(S.String),
140
+ group_filter: S.optional(S.String),
141
+ group_name_attr: S.optional(S.String),
142
+ groups_autocreate: S.optional(S.String.pipe(T.Body("groups-autocreate"))),
143
+ groups_claim: S.optional(S.String.pipe(T.Body("groups-claim"))),
144
+ groups_overwrite: S.optional(S.String.pipe(T.Body("groups-overwrite"))),
145
+ issuer_url: S.optional(S.String.pipe(T.Body("issuer-url"))),
146
+ mode: S.optional(CreateAccessDomainRequestMode),
147
+ password: S.optional(S.String),
148
+ port: S.optional(S.String),
149
+ prompt: S.optional(S.String),
150
+ query_userinfo: S.optional(S.String.pipe(T.Body("query-userinfo"))),
151
+ realm: S.String,
152
+ scopes: S.optional(S.String),
153
+ secure: S.optional(S.String),
154
+ server1: S.optional(S.String),
155
+ server2: S.optional(S.String),
156
+ sslversion: S.optional(CreateAccessDomainRequestSslversion),
157
+ sync_defaults_options: S.optional(
158
+ S.String.pipe(T.Body("sync-defaults-options")),
159
+ ),
160
+ sync_attributes: S.optional(S.String),
161
+ tfa: S.optional(S.String),
162
+ type: CreateAccessDomainRequestType,
163
+ user_attr: S.optional(S.String),
164
+ user_classes: S.optional(S.String),
165
+ username_claim: S.optional(S.String.pipe(T.Body("username-claim"))),
166
+ verify: S.optional(S.String),
167
+ }).pipe(
168
+ T.Http({
169
+ method: "POST",
170
+ uri: "/access/domains",
171
+ code: 200,
172
+ contentType: "form-urlencoded",
173
+ }),
174
+ ),
175
+ ).annotate({
176
+ identifier: "CreateAccessDomainRequest",
177
+ }) as any as S.Schema<CreateAccessDomainRequest>;
178
+
179
+ export interface CreateAccessDomainResponse {}
180
+ export const CreateAccessDomainResponse = /*@__PURE__*/ S.suspend(() =>
181
+ S.Struct({}),
182
+ ).annotate({
183
+ identifier: "CreateAccessDomainResponse",
184
+ }) as any as S.Schema<CreateAccessDomainResponse>;
185
+
186
+ export interface CreateAccessGroupRequest {
187
+ comment?: string;
188
+ groupid: string;
189
+ }
190
+ export const CreateAccessGroupRequest = /*@__PURE__*/ S.suspend(() =>
191
+ S.Struct({
192
+ comment: S.optional(S.String),
193
+ groupid: S.String,
194
+ }).pipe(
195
+ T.Http({
196
+ method: "POST",
197
+ uri: "/access/groups",
198
+ code: 200,
199
+ contentType: "form-urlencoded",
200
+ }),
201
+ ),
202
+ ).annotate({
203
+ identifier: "CreateAccessGroupRequest",
204
+ }) as any as S.Schema<CreateAccessGroupRequest>;
205
+
206
+ export interface CreateAccessGroupResponse {}
207
+ export const CreateAccessGroupResponse = /*@__PURE__*/ S.suspend(() =>
208
+ S.Struct({}),
209
+ ).annotate({
210
+ identifier: "CreateAccessGroupResponse",
211
+ }) as any as S.Schema<CreateAccessGroupResponse>;
212
+
213
+ export interface CreateAccessOpenidAuthUrlRequest {
214
+ /** Authentication domain ID */
215
+ realm: string;
216
+ /** Redirection Url. The client should set this to the used server url (location.origin). */
217
+ redirect_url: string;
218
+ }
219
+ export const CreateAccessOpenidAuthUrlRequest = /*@__PURE__*/ S.suspend(() =>
220
+ S.Struct({
221
+ realm: S.String,
222
+ redirect_url: S.String.pipe(T.Body("redirect-url")),
223
+ }).pipe(
224
+ T.Http({
225
+ method: "POST",
226
+ uri: "/access/openid/auth-url",
227
+ code: 200,
228
+ contentType: "form-urlencoded",
229
+ }),
230
+ ),
231
+ ).annotate({
232
+ identifier: "CreateAccessOpenidAuthUrlRequest",
233
+ }) as any as S.Schema<CreateAccessOpenidAuthUrlRequest>;
234
+
235
+ export type CreateAccessOpenidAuthUrlResponse = string;
236
+ export const CreateAccessOpenidAuthUrlResponse = /*@__PURE__*/ S.suspend(() =>
237
+ S.String.pipe(T.RawResponseRoot()),
238
+ ).annotate({
239
+ identifier: "CreateAccessOpenidAuthUrlResponse",
240
+ }) as any as S.Schema<CreateAccessOpenidAuthUrlResponse>;
241
+
242
+ export interface CreateAccessRoleRequest {
243
+ privs?: string;
244
+ roleid: string;
245
+ }
246
+ export const CreateAccessRoleRequest = /*@__PURE__*/ S.suspend(() =>
247
+ S.Struct({
248
+ privs: S.optional(S.String),
249
+ roleid: S.String,
250
+ }).pipe(
251
+ T.Http({
252
+ method: "POST",
253
+ uri: "/access/roles",
254
+ code: 200,
255
+ contentType: "form-urlencoded",
256
+ }),
257
+ ),
258
+ ).annotate({
259
+ identifier: "CreateAccessRoleRequest",
260
+ }) as any as S.Schema<CreateAccessRoleRequest>;
261
+
262
+ export interface CreateAccessRoleResponse {}
263
+ export const CreateAccessRoleResponse = /*@__PURE__*/ S.suspend(() =>
264
+ S.Struct({}),
265
+ ).annotate({
266
+ identifier: "CreateAccessRoleResponse",
267
+ }) as any as S.Schema<CreateAccessRoleResponse>;
268
+
269
+ export interface CreateAccessTicketRequest {
270
+ /** This parameter is now ignored and assumed to be 1. */
271
+ new_format?: string;
272
+ /** One-time password for Two-factor authentication. */
273
+ otp?: string;
274
+ /** The secret password. This can also be a valid ticket. */
275
+ password: string;
276
+ /** Verify ticket, and check if user have access 'privs' on 'path' */
277
+ path?: string;
278
+ /** Verify ticket, and check if user have access 'privs' on 'path' */
279
+ privs?: string;
280
+ /** You can optionally pass the realm using this parameter. Normally the realm is simply added to the username <username>@<realm>. */
281
+ realm?: string;
282
+ /** The signed TFA challenge string the user wants to respond to. */
283
+ tfa_challenge?: string;
284
+ /** User name */
285
+ username: string;
286
+ }
287
+ export const CreateAccessTicketRequest = /*@__PURE__*/ S.suspend(() =>
288
+ S.Struct({
289
+ new_format: S.optional(S.String.pipe(T.Body("new-format"))),
290
+ otp: S.optional(S.String),
291
+ password: S.String,
292
+ path: S.optional(S.String),
293
+ privs: S.optional(S.String),
294
+ realm: S.optional(S.String),
295
+ tfa_challenge: S.optional(S.String.pipe(T.Body("tfa-challenge"))),
296
+ username: S.String,
297
+ }).pipe(
298
+ T.Http({
299
+ method: "POST",
300
+ uri: "/access/ticket",
301
+ code: 200,
302
+ contentType: "form-urlencoded",
303
+ }),
304
+ ),
305
+ ).annotate({
306
+ identifier: "CreateAccessTicketRequest",
307
+ }) as any as S.Schema<CreateAccessTicketRequest>;
308
+
309
+ export interface CreateAccessTicketResponse {
310
+ CSRFPreventionToken?: string;
311
+ clustername?: string;
312
+ ticket?: string;
313
+ username: string;
314
+ }
315
+ export const CreateAccessTicketResponse = /*@__PURE__*/ S.suspend(() =>
316
+ S.Struct({
317
+ CSRFPreventionToken: S.optional(S.String),
318
+ clustername: S.optional(S.String),
319
+ ticket: S.optional(S.String),
320
+ username: S.String,
321
+ }),
322
+ ).annotate({
323
+ identifier: "CreateAccessTicketResponse",
324
+ }) as any as S.Schema<CreateAccessTicketResponse>;
325
+
326
+ export interface CreateAccessUserRequest {
327
+ comment?: string;
328
+ email?: string;
329
+ /** Enable the account (default). You can set this to '0' to disable the account */
330
+ enable?: string;
331
+ /** Account expiration date (seconds since epoch). '0' means no expiration date. */
332
+ expire?: string;
333
+ firstname?: string;
334
+ groups?: string;
335
+ /** Keys for two factor auth (yubico). */
336
+ keys?: string;
337
+ lastname?: string;
338
+ /** Initial password. */
339
+ password?: string;
340
+ /** Full User ID, in the `name@realm` format. */
341
+ userid: string;
342
+ }
343
+ export const CreateAccessUserRequest = /*@__PURE__*/ S.suspend(() =>
344
+ S.Struct({
345
+ comment: S.optional(S.String),
346
+ email: S.optional(S.String),
347
+ enable: S.optional(S.String),
348
+ expire: S.optional(S.String),
349
+ firstname: S.optional(S.String),
350
+ groups: S.optional(S.String),
351
+ keys: S.optional(S.String),
352
+ lastname: S.optional(S.String),
353
+ password: S.optional(S.String),
354
+ userid: S.String,
355
+ }).pipe(
356
+ T.Http({
357
+ method: "POST",
358
+ uri: "/access/users",
359
+ code: 200,
360
+ contentType: "form-urlencoded",
361
+ }),
362
+ ),
363
+ ).annotate({
364
+ identifier: "CreateAccessUserRequest",
365
+ }) as any as S.Schema<CreateAccessUserRequest>;
366
+
367
+ export interface CreateAccessUserResponse {}
368
+ export const CreateAccessUserResponse = /*@__PURE__*/ S.suspend(() =>
369
+ S.Struct({}),
370
+ ).annotate({
371
+ identifier: "CreateAccessUserResponse",
372
+ }) as any as S.Schema<CreateAccessUserResponse>;
373
+
374
+ export interface CreateAccessVncticketRequest {
375
+ /** UserId or token */
376
+ authid: string;
377
+ /** Verify ticket, and check if user have access 'privs' on 'path' */
378
+ path: string;
379
+ /** Verify that the ticket is valid for this port. */
380
+ port?: string;
381
+ /** Verify ticket, and check if user have access 'privs' on 'path' */
382
+ privs: string;
383
+ /** The VNC ticket. */
384
+ vncticket: string;
385
+ }
386
+ export const CreateAccessVncticketRequest = /*@__PURE__*/ S.suspend(() =>
387
+ S.Struct({
388
+ authid: S.String,
389
+ path: S.String,
390
+ port: S.optional(S.String),
391
+ privs: S.String,
392
+ vncticket: S.String,
393
+ }).pipe(
394
+ T.Http({
395
+ method: "POST",
396
+ uri: "/access/vncticket",
397
+ code: 200,
398
+ contentType: "form-urlencoded",
399
+ }),
400
+ ),
401
+ ).annotate({
402
+ identifier: "CreateAccessVncticketRequest",
403
+ }) as any as S.Schema<CreateAccessVncticketRequest>;
404
+
405
+ export interface CreateAccessVncticketResponse {}
406
+ export const CreateAccessVncticketResponse = /*@__PURE__*/ S.suspend(() =>
407
+ S.Struct({}),
408
+ ).annotate({
409
+ identifier: "CreateAccessVncticketResponse",
410
+ }) as any as S.Schema<CreateAccessVncticketResponse>;
411
+
412
+ export interface DeleteAccessDomainRequest {
413
+ realm: string;
414
+ }
415
+ export const DeleteAccessDomainRequest = /*@__PURE__*/ S.suspend(() =>
416
+ S.Struct({
417
+ realm: S.String.pipe(T.Label()),
418
+ }).pipe(
419
+ T.Http({ method: "DELETE", uri: "/access/domains/{realm}", code: 200 }),
420
+ ),
421
+ ).annotate({
422
+ identifier: "DeleteAccessDomainRequest",
423
+ }) as any as S.Schema<DeleteAccessDomainRequest>;
424
+
425
+ export interface DeleteAccessDomainResponse {}
426
+ export const DeleteAccessDomainResponse = /*@__PURE__*/ S.suspend(() =>
427
+ S.Struct({}),
428
+ ).annotate({
429
+ identifier: "DeleteAccessDomainResponse",
430
+ }) as any as S.Schema<DeleteAccessDomainResponse>;
431
+
432
+ export interface DeleteAccessGroupRequest {
433
+ groupid: string;
434
+ }
435
+ export const DeleteAccessGroupRequest = /*@__PURE__*/ S.suspend(() =>
436
+ S.Struct({
437
+ groupid: S.String.pipe(T.Label()),
438
+ }).pipe(
439
+ T.Http({ method: "DELETE", uri: "/access/groups/{groupid}", code: 200 }),
440
+ ),
441
+ ).annotate({
442
+ identifier: "DeleteAccessGroupRequest",
443
+ }) as any as S.Schema<DeleteAccessGroupRequest>;
444
+
445
+ export interface DeleteAccessGroupResponse {}
446
+ export const DeleteAccessGroupResponse = /*@__PURE__*/ S.suspend(() =>
447
+ S.Struct({}),
448
+ ).annotate({
449
+ identifier: "DeleteAccessGroupResponse",
450
+ }) as any as S.Schema<DeleteAccessGroupResponse>;
451
+
452
+ export interface DeleteAccessRoleRequest {
453
+ roleid: string;
454
+ }
455
+ export const DeleteAccessRoleRequest = /*@__PURE__*/ S.suspend(() =>
456
+ S.Struct({
457
+ roleid: S.String.pipe(T.Label()),
458
+ }).pipe(
459
+ T.Http({ method: "DELETE", uri: "/access/roles/{roleid}", code: 200 }),
460
+ ),
461
+ ).annotate({
462
+ identifier: "DeleteAccessRoleRequest",
463
+ }) as any as S.Schema<DeleteAccessRoleRequest>;
464
+
465
+ export interface DeleteAccessRoleResponse {}
466
+ export const DeleteAccessRoleResponse = /*@__PURE__*/ S.suspend(() =>
467
+ S.Struct({}),
468
+ ).annotate({
469
+ identifier: "DeleteAccessRoleResponse",
470
+ }) as any as S.Schema<DeleteAccessRoleResponse>;
471
+
472
+ export interface DeleteAccessTfaRequest {
473
+ userid: string;
474
+ id: string;
475
+ /** The current password of the user performing the change. */
476
+ password?: string;
477
+ }
478
+ export const DeleteAccessTfaRequest = /*@__PURE__*/ S.suspend(() =>
479
+ S.Struct({
480
+ userid: S.String.pipe(T.Label()),
481
+ id: S.String.pipe(T.Label()),
482
+ password: S.optional(S.String),
483
+ }).pipe(
484
+ T.Http({
485
+ method: "DELETE",
486
+ uri: "/access/tfa/{userid}/{id}",
487
+ code: 200,
488
+ contentType: "form-urlencoded",
489
+ }),
490
+ ),
491
+ ).annotate({
492
+ identifier: "DeleteAccessTfaRequest",
493
+ }) as any as S.Schema<DeleteAccessTfaRequest>;
494
+
495
+ export interface DeleteAccessTfaResponse {}
496
+ export const DeleteAccessTfaResponse = /*@__PURE__*/ S.suspend(() =>
497
+ S.Struct({}),
498
+ ).annotate({
499
+ identifier: "DeleteAccessTfaResponse",
500
+ }) as any as S.Schema<DeleteAccessTfaResponse>;
501
+
502
+ export interface DeleteAccessUserRequest {
503
+ userid: string;
504
+ }
505
+ export const DeleteAccessUserRequest = /*@__PURE__*/ S.suspend(() =>
506
+ S.Struct({
507
+ userid: S.String.pipe(T.Label()),
508
+ }).pipe(
509
+ T.Http({ method: "DELETE", uri: "/access/users/{userid}", code: 200 }),
510
+ ),
511
+ ).annotate({
512
+ identifier: "DeleteAccessUserRequest",
513
+ }) as any as S.Schema<DeleteAccessUserRequest>;
514
+
515
+ export interface DeleteAccessUserResponse {}
516
+ export const DeleteAccessUserResponse = /*@__PURE__*/ S.suspend(() =>
517
+ S.Struct({}),
518
+ ).annotate({
519
+ identifier: "DeleteAccessUserResponse",
520
+ }) as any as S.Schema<DeleteAccessUserResponse>;
521
+
522
+ export interface DeleteAccessUserTokenRequest {
523
+ userid: string;
524
+ tokenid: string;
525
+ }
526
+ export const DeleteAccessUserTokenRequest = /*@__PURE__*/ S.suspend(() =>
527
+ S.Struct({
528
+ userid: S.String.pipe(T.Label()),
529
+ tokenid: S.String.pipe(T.Label()),
530
+ }).pipe(
531
+ T.Http({
532
+ method: "DELETE",
533
+ uri: "/access/users/{userid}/token/{tokenid}",
534
+ code: 200,
535
+ }),
536
+ ),
537
+ ).annotate({
538
+ identifier: "DeleteAccessUserTokenRequest",
539
+ }) as any as S.Schema<DeleteAccessUserTokenRequest>;
540
+
541
+ export interface DeleteAccessUserTokenResponse {}
542
+ export const DeleteAccessUserTokenResponse = /*@__PURE__*/ S.suspend(() =>
543
+ S.Struct({}),
544
+ ).annotate({
545
+ identifier: "DeleteAccessUserTokenResponse",
546
+ }) as any as S.Schema<DeleteAccessUserTokenResponse>;
547
+
548
+ export interface GetAccessDomainRequest {
549
+ realm: string;
550
+ }
551
+ export const GetAccessDomainRequest = /*@__PURE__*/ S.suspend(() =>
552
+ S.Struct({
553
+ realm: S.String.pipe(T.Label()),
554
+ }).pipe(T.Http({ method: "GET", uri: "/access/domains/{realm}", code: 200 })),
555
+ ).annotate({
556
+ identifier: "GetAccessDomainRequest",
557
+ }) as any as S.Schema<GetAccessDomainRequest>;
558
+
559
+ export type GetAccessDomainResponse = unknown;
560
+ export const GetAccessDomainResponse = /*@__PURE__*/ S.suspend(() =>
561
+ S.Unknown.pipe(T.RawResponseRoot()),
562
+ ).annotate({
563
+ identifier: "GetAccessDomainResponse",
564
+ }) as any as S.Schema<GetAccessDomainResponse>;
565
+
566
+ export interface GetAccessGroupRequest {
567
+ groupid: string;
568
+ }
569
+ export const GetAccessGroupRequest = /*@__PURE__*/ S.suspend(() =>
570
+ S.Struct({
571
+ groupid: S.String.pipe(T.Label()),
572
+ }).pipe(
573
+ T.Http({ method: "GET", uri: "/access/groups/{groupid}", code: 200 }),
574
+ ),
575
+ ).annotate({
576
+ identifier: "GetAccessGroupRequest",
577
+ }) as any as S.Schema<GetAccessGroupRequest>;
578
+
579
+ export type GetAccessGroupResponseMembersList = Array<string>;
580
+ export const GetAccessGroupResponseMembersList = /*@__PURE__*/ S.Array(
581
+ S.String,
582
+ ) as any as S.Schema<GetAccessGroupResponseMembersList>;
583
+
584
+ export interface GetAccessGroupResponse {
585
+ comment?: string;
586
+ members: GetAccessGroupResponseMembersList;
587
+ }
588
+ export const GetAccessGroupResponse = /*@__PURE__*/ S.suspend(() =>
589
+ S.Struct({
590
+ comment: S.optional(S.String),
591
+ members: GetAccessGroupResponseMembersList,
592
+ }),
593
+ ).annotate({
594
+ identifier: "GetAccessGroupResponse",
595
+ }) as any as S.Schema<GetAccessGroupResponse>;
596
+
597
+ export interface GetAccessPermissionsRequest {
598
+ /** Only dump this specific path, not the whole tree. */
599
+ path?: string;
600
+ /** User ID or full API token ID */
601
+ userid?: string;
602
+ }
603
+ export const GetAccessPermissionsRequest = /*@__PURE__*/ S.suspend(() =>
604
+ S.Struct({
605
+ path: S.optional(S.String.pipe(T.Query())),
606
+ userid: S.optional(S.String.pipe(T.Query())),
607
+ }).pipe(T.Http({ method: "GET", uri: "/access/permissions", code: 200 })),
608
+ ).annotate({
609
+ identifier: "GetAccessPermissionsRequest",
610
+ }) as any as S.Schema<GetAccessPermissionsRequest>;
611
+
612
+ export type GetAccessPermissionsResponse = unknown;
613
+ export const GetAccessPermissionsResponse = /*@__PURE__*/ S.suspend(() =>
614
+ S.Unknown.pipe(T.RawResponseRoot()),
615
+ ).annotate({
616
+ identifier: "GetAccessPermissionsResponse",
617
+ }) as any as S.Schema<GetAccessPermissionsResponse>;
618
+
619
+ export interface GetAccessRoleRequest {
620
+ roleid: string;
621
+ }
622
+ export const GetAccessRoleRequest = /*@__PURE__*/ S.suspend(() =>
623
+ S.Struct({
624
+ roleid: S.String.pipe(T.Label()),
625
+ }).pipe(T.Http({ method: "GET", uri: "/access/roles/{roleid}", code: 200 })),
626
+ ).annotate({
627
+ identifier: "GetAccessRoleRequest",
628
+ }) as any as S.Schema<GetAccessRoleRequest>;
629
+
630
+ export interface GetAccessRoleResponse {
631
+ Datastore_Allocate?: unknown;
632
+ Datastore_AllocateSpace?: unknown;
633
+ Datastore_AllocateTemplate?: unknown;
634
+ Datastore_Audit?: unknown;
635
+ Group_Allocate?: unknown;
636
+ Mapping_Audit?: unknown;
637
+ Mapping_Modify?: unknown;
638
+ Mapping_Use?: unknown;
639
+ Permissions_Modify?: unknown;
640
+ Pool_Allocate?: unknown;
641
+ Pool_Audit?: unknown;
642
+ Realm_Allocate?: unknown;
643
+ Realm_AllocateUser?: unknown;
644
+ SDN_Allocate?: unknown;
645
+ SDN_Audit?: unknown;
646
+ SDN_Use?: unknown;
647
+ Sys_AccessNetwork?: unknown;
648
+ Sys_Audit?: unknown;
649
+ Sys_Console?: unknown;
650
+ Sys_Incoming?: unknown;
651
+ Sys_Modify?: unknown;
652
+ Sys_PowerMgmt?: unknown;
653
+ Sys_Syslog?: unknown;
654
+ User_Modify?: unknown;
655
+ VM_Allocate?: unknown;
656
+ VM_Audit?: unknown;
657
+ VM_Backup?: unknown;
658
+ VM_Clone?: unknown;
659
+ VM_Config_CDROM?: unknown;
660
+ VM_Config_CPU?: unknown;
661
+ VM_Config_Cloudinit?: unknown;
662
+ VM_Config_Disk?: unknown;
663
+ VM_Config_HWType?: unknown;
664
+ VM_Config_Memory?: unknown;
665
+ VM_Config_Network?: unknown;
666
+ VM_Config_Options?: unknown;
667
+ VM_Console?: unknown;
668
+ VM_GuestAgent_Audit?: unknown;
669
+ VM_GuestAgent_FileRead?: unknown;
670
+ VM_GuestAgent_FileSystemMgmt?: unknown;
671
+ VM_GuestAgent_FileWrite?: unknown;
672
+ VM_GuestAgent_Unrestricted?: unknown;
673
+ VM_Migrate?: unknown;
674
+ VM_PowerMgmt?: unknown;
675
+ VM_Replicate?: unknown;
676
+ VM_Snapshot?: unknown;
677
+ VM_Snapshot_Rollback?: unknown;
678
+ }
679
+ export const GetAccessRoleResponse = /*@__PURE__*/ S.suspend(() =>
680
+ S.Struct({
681
+ Datastore_Allocate: S.optional(
682
+ S.Unknown.pipe(T.Body("Datastore.Allocate")),
683
+ ),
684
+ Datastore_AllocateSpace: S.optional(
685
+ S.Unknown.pipe(T.Body("Datastore.AllocateSpace")),
686
+ ),
687
+ Datastore_AllocateTemplate: S.optional(
688
+ S.Unknown.pipe(T.Body("Datastore.AllocateTemplate")),
689
+ ),
690
+ Datastore_Audit: S.optional(S.Unknown.pipe(T.Body("Datastore.Audit"))),
691
+ Group_Allocate: S.optional(S.Unknown.pipe(T.Body("Group.Allocate"))),
692
+ Mapping_Audit: S.optional(S.Unknown.pipe(T.Body("Mapping.Audit"))),
693
+ Mapping_Modify: S.optional(S.Unknown.pipe(T.Body("Mapping.Modify"))),
694
+ Mapping_Use: S.optional(S.Unknown.pipe(T.Body("Mapping.Use"))),
695
+ Permissions_Modify: S.optional(
696
+ S.Unknown.pipe(T.Body("Permissions.Modify")),
697
+ ),
698
+ Pool_Allocate: S.optional(S.Unknown.pipe(T.Body("Pool.Allocate"))),
699
+ Pool_Audit: S.optional(S.Unknown.pipe(T.Body("Pool.Audit"))),
700
+ Realm_Allocate: S.optional(S.Unknown.pipe(T.Body("Realm.Allocate"))),
701
+ Realm_AllocateUser: S.optional(
702
+ S.Unknown.pipe(T.Body("Realm.AllocateUser")),
703
+ ),
704
+ SDN_Allocate: S.optional(S.Unknown.pipe(T.Body("SDN.Allocate"))),
705
+ SDN_Audit: S.optional(S.Unknown.pipe(T.Body("SDN.Audit"))),
706
+ SDN_Use: S.optional(S.Unknown.pipe(T.Body("SDN.Use"))),
707
+ Sys_AccessNetwork: S.optional(S.Unknown.pipe(T.Body("Sys.AccessNetwork"))),
708
+ Sys_Audit: S.optional(S.Unknown.pipe(T.Body("Sys.Audit"))),
709
+ Sys_Console: S.optional(S.Unknown.pipe(T.Body("Sys.Console"))),
710
+ Sys_Incoming: S.optional(S.Unknown.pipe(T.Body("Sys.Incoming"))),
711
+ Sys_Modify: S.optional(S.Unknown.pipe(T.Body("Sys.Modify"))),
712
+ Sys_PowerMgmt: S.optional(S.Unknown.pipe(T.Body("Sys.PowerMgmt"))),
713
+ Sys_Syslog: S.optional(S.Unknown.pipe(T.Body("Sys.Syslog"))),
714
+ User_Modify: S.optional(S.Unknown.pipe(T.Body("User.Modify"))),
715
+ VM_Allocate: S.optional(S.Unknown.pipe(T.Body("VM.Allocate"))),
716
+ VM_Audit: S.optional(S.Unknown.pipe(T.Body("VM.Audit"))),
717
+ VM_Backup: S.optional(S.Unknown.pipe(T.Body("VM.Backup"))),
718
+ VM_Clone: S.optional(S.Unknown.pipe(T.Body("VM.Clone"))),
719
+ VM_Config_CDROM: S.optional(S.Unknown.pipe(T.Body("VM.Config.CDROM"))),
720
+ VM_Config_CPU: S.optional(S.Unknown.pipe(T.Body("VM.Config.CPU"))),
721
+ VM_Config_Cloudinit: S.optional(
722
+ S.Unknown.pipe(T.Body("VM.Config.Cloudinit")),
723
+ ),
724
+ VM_Config_Disk: S.optional(S.Unknown.pipe(T.Body("VM.Config.Disk"))),
725
+ VM_Config_HWType: S.optional(S.Unknown.pipe(T.Body("VM.Config.HWType"))),
726
+ VM_Config_Memory: S.optional(S.Unknown.pipe(T.Body("VM.Config.Memory"))),
727
+ VM_Config_Network: S.optional(S.Unknown.pipe(T.Body("VM.Config.Network"))),
728
+ VM_Config_Options: S.optional(S.Unknown.pipe(T.Body("VM.Config.Options"))),
729
+ VM_Console: S.optional(S.Unknown.pipe(T.Body("VM.Console"))),
730
+ VM_GuestAgent_Audit: S.optional(
731
+ S.Unknown.pipe(T.Body("VM.GuestAgent.Audit")),
732
+ ),
733
+ VM_GuestAgent_FileRead: S.optional(
734
+ S.Unknown.pipe(T.Body("VM.GuestAgent.FileRead")),
735
+ ),
736
+ VM_GuestAgent_FileSystemMgmt: S.optional(
737
+ S.Unknown.pipe(T.Body("VM.GuestAgent.FileSystemMgmt")),
738
+ ),
739
+ VM_GuestAgent_FileWrite: S.optional(
740
+ S.Unknown.pipe(T.Body("VM.GuestAgent.FileWrite")),
741
+ ),
742
+ VM_GuestAgent_Unrestricted: S.optional(
743
+ S.Unknown.pipe(T.Body("VM.GuestAgent.Unrestricted")),
744
+ ),
745
+ VM_Migrate: S.optional(S.Unknown.pipe(T.Body("VM.Migrate"))),
746
+ VM_PowerMgmt: S.optional(S.Unknown.pipe(T.Body("VM.PowerMgmt"))),
747
+ VM_Replicate: S.optional(S.Unknown.pipe(T.Body("VM.Replicate"))),
748
+ VM_Snapshot: S.optional(S.Unknown.pipe(T.Body("VM.Snapshot"))),
749
+ VM_Snapshot_Rollback: S.optional(
750
+ S.Unknown.pipe(T.Body("VM.Snapshot.Rollback")),
751
+ ),
752
+ }),
753
+ ).annotate({
754
+ identifier: "GetAccessRoleResponse",
755
+ }) as any as S.Schema<GetAccessRoleResponse>;
756
+
757
+ export interface GetAccessTfaRequest {
758
+ userid: string;
759
+ }
760
+ export const GetAccessTfaRequest = /*@__PURE__*/ S.suspend(() =>
761
+ S.Struct({
762
+ userid: S.String.pipe(T.Label()),
763
+ }).pipe(T.Http({ method: "GET", uri: "/access/tfa/{userid}", code: 200 })),
764
+ ).annotate({
765
+ identifier: "GetAccessTfaRequest",
766
+ }) as any as S.Schema<GetAccessTfaRequest>;
767
+
768
+ export type GetAccessTfaResponseBodyItemType =
769
+ | "totp"
770
+ | "u2f"
771
+ | "webauthn"
772
+ | "recovery"
773
+ | "yubico";
774
+ export const GetAccessTfaResponseBodyItemType = S.String;
775
+
776
+ export interface GetAccessTfaResponseBodyItem {
777
+ created: number;
778
+ description: string;
779
+ enable?: unknown;
780
+ id: string;
781
+ type: GetAccessTfaResponseBodyItemType;
782
+ }
783
+ export const GetAccessTfaResponseBodyItem = /*@__PURE__*/ S.suspend(() =>
784
+ S.Struct({
785
+ created: S.Number,
786
+ description: S.String,
787
+ enable: S.optional(S.Unknown),
788
+ id: S.String,
789
+ type: GetAccessTfaResponseBodyItemType,
790
+ }),
791
+ ).annotate({
792
+ identifier: "GetAccessTfaResponseBodyItem",
793
+ }) as any as S.Schema<GetAccessTfaResponseBodyItem>;
794
+
795
+ export type GetAccessTfaResponseBodyList = Array<GetAccessTfaResponseBodyItem>;
796
+ export const GetAccessTfaResponseBodyList = /*@__PURE__*/ S.Array(
797
+ GetAccessTfaResponseBodyItem,
798
+ ) as any as S.Schema<GetAccessTfaResponseBodyList>;
799
+
800
+ export type GetAccessTfaResponse = GetAccessTfaResponseBodyList;
801
+ export const GetAccessTfaResponse = /*@__PURE__*/ S.suspend(() =>
802
+ GetAccessTfaResponseBodyList.pipe(T.RawResponseRoot()),
803
+ ).annotate({
804
+ identifier: "GetAccessTfaResponse",
805
+ }) as any as S.Schema<GetAccessTfaResponse>;
806
+
807
+ export interface GetAccessTfa2Request {
808
+ userid: string;
809
+ id: string;
810
+ }
811
+ export const GetAccessTfa2Request = /*@__PURE__*/ S.suspend(() =>
812
+ S.Struct({
813
+ userid: S.String.pipe(T.Label()),
814
+ id: S.String.pipe(T.Label()),
815
+ }).pipe(
816
+ T.Http({ method: "GET", uri: "/access/tfa/{userid}/{id}", code: 200 }),
817
+ ),
818
+ ).annotate({
819
+ identifier: "GetAccessTfa2Request",
820
+ }) as any as S.Schema<GetAccessTfa2Request>;
821
+
822
+ export type GetAccessTfa2ResponseType =
823
+ | "totp"
824
+ | "u2f"
825
+ | "webauthn"
826
+ | "recovery"
827
+ | "yubico";
828
+ export const GetAccessTfa2ResponseType = S.String;
829
+
830
+ export interface GetAccessTfa2Response {
831
+ created: number;
832
+ description: string;
833
+ enable?: unknown;
834
+ id: string;
835
+ type: GetAccessTfa2ResponseType;
836
+ }
837
+ export const GetAccessTfa2Response = /*@__PURE__*/ S.suspend(() =>
838
+ S.Struct({
839
+ created: S.Number,
840
+ description: S.String,
841
+ enable: S.optional(S.Unknown),
842
+ id: S.String,
843
+ type: GetAccessTfa2ResponseType,
844
+ }),
845
+ ).annotate({
846
+ identifier: "GetAccessTfa2Response",
847
+ }) as any as S.Schema<GetAccessTfa2Response>;
848
+
849
+ export interface GetAccessTicketRequest {}
850
+ export const GetAccessTicketRequest = /*@__PURE__*/ S.suspend(() =>
851
+ S.Struct({}).pipe(
852
+ T.Http({ method: "GET", uri: "/access/ticket", code: 200 }),
853
+ ),
854
+ ).annotate({
855
+ identifier: "GetAccessTicketRequest",
856
+ }) as any as S.Schema<GetAccessTicketRequest>;
857
+
858
+ export interface GetAccessTicketResponse {}
859
+ export const GetAccessTicketResponse = /*@__PURE__*/ S.suspend(() =>
860
+ S.Struct({}),
861
+ ).annotate({
862
+ identifier: "GetAccessTicketResponse",
863
+ }) as any as S.Schema<GetAccessTicketResponse>;
864
+
865
+ export interface GetAccessUserRequest {
866
+ userid: string;
867
+ }
868
+ export const GetAccessUserRequest = /*@__PURE__*/ S.suspend(() =>
869
+ S.Struct({
870
+ userid: S.String.pipe(T.Label()),
871
+ }).pipe(T.Http({ method: "GET", uri: "/access/users/{userid}", code: 200 })),
872
+ ).annotate({
873
+ identifier: "GetAccessUserRequest",
874
+ }) as any as S.Schema<GetAccessUserRequest>;
875
+
876
+ export type GetAccessUserResponseGroupsList = Array<string>;
877
+ export const GetAccessUserResponseGroupsList = /*@__PURE__*/ S.Array(
878
+ S.String,
879
+ ) as any as S.Schema<GetAccessUserResponseGroupsList>;
880
+
881
+ export interface GetAccessUserResponse {
882
+ comment?: string;
883
+ email?: string;
884
+ enable?: unknown;
885
+ expire?: number;
886
+ firstname?: string;
887
+ groups?: GetAccessUserResponseGroupsList;
888
+ keys?: string;
889
+ lastname?: string;
890
+ tokens?: unknown;
891
+ }
892
+ export const GetAccessUserResponse = /*@__PURE__*/ S.suspend(() =>
893
+ S.Struct({
894
+ comment: S.optional(S.String),
895
+ email: S.optional(S.String),
896
+ enable: S.optional(S.Unknown),
897
+ expire: S.optional(S.Number),
898
+ firstname: S.optional(S.String),
899
+ groups: S.optional(GetAccessUserResponseGroupsList),
900
+ keys: S.optional(S.String),
901
+ lastname: S.optional(S.String),
902
+ tokens: S.optional(S.Unknown),
903
+ }),
904
+ ).annotate({
905
+ identifier: "GetAccessUserResponse",
906
+ }) as any as S.Schema<GetAccessUserResponse>;
907
+
908
+ export interface GetAccessUserTfaRequest {
909
+ userid: string;
910
+ /** Request all entries as an array. */
911
+ multiple?: string;
912
+ }
913
+ export const GetAccessUserTfaRequest = /*@__PURE__*/ S.suspend(() =>
914
+ S.Struct({
915
+ userid: S.String.pipe(T.Label()),
916
+ multiple: S.optional(S.String.pipe(T.Query())),
917
+ }).pipe(
918
+ T.Http({ method: "GET", uri: "/access/users/{userid}/tfa", code: 200 }),
919
+ ),
920
+ ).annotate({
921
+ identifier: "GetAccessUserTfaRequest",
922
+ }) as any as S.Schema<GetAccessUserTfaRequest>;
923
+
924
+ export type GetAccessUserTfaResponseRealm = "oath" | "yubico";
925
+ export const GetAccessUserTfaResponseRealm = S.String;
926
+
927
+ export type GetAccessUserTfaResponseTypesItem =
928
+ | "totp"
929
+ | "u2f"
930
+ | "yubico"
931
+ | "webauthn"
932
+ | "recovedry";
933
+ export const GetAccessUserTfaResponseTypesItem = S.String;
934
+
935
+ export type GetAccessUserTfaResponseTypesList =
936
+ Array<GetAccessUserTfaResponseTypesItem>;
937
+ export const GetAccessUserTfaResponseTypesList = /*@__PURE__*/ S.Array(
938
+ GetAccessUserTfaResponseTypesItem,
939
+ ) as any as S.Schema<GetAccessUserTfaResponseTypesList>;
940
+
941
+ export type GetAccessUserTfaResponseUser = "oath" | "u2f";
942
+ export const GetAccessUserTfaResponseUser = S.String;
943
+
944
+ export interface GetAccessUserTfaResponse {
945
+ realm?: GetAccessUserTfaResponseRealm;
946
+ types?: GetAccessUserTfaResponseTypesList;
947
+ user?: GetAccessUserTfaResponseUser;
948
+ }
949
+ export const GetAccessUserTfaResponse = /*@__PURE__*/ S.suspend(() =>
950
+ S.Struct({
951
+ realm: S.optional(GetAccessUserTfaResponseRealm),
952
+ types: S.optional(GetAccessUserTfaResponseTypesList),
953
+ user: S.optional(GetAccessUserTfaResponseUser),
954
+ }),
955
+ ).annotate({
956
+ identifier: "GetAccessUserTfaResponse",
957
+ }) as any as S.Schema<GetAccessUserTfaResponse>;
958
+
959
+ export interface GetAccessUserTokenRequest {
960
+ userid: string;
961
+ tokenid: string;
962
+ }
963
+ export const GetAccessUserTokenRequest = /*@__PURE__*/ S.suspend(() =>
964
+ S.Struct({
965
+ userid: S.String.pipe(T.Label()),
966
+ tokenid: S.String.pipe(T.Label()),
967
+ }).pipe(
968
+ T.Http({
969
+ method: "GET",
970
+ uri: "/access/users/{userid}/token/{tokenid}",
971
+ code: 200,
972
+ }),
973
+ ),
974
+ ).annotate({
975
+ identifier: "GetAccessUserTokenRequest",
976
+ }) as any as S.Schema<GetAccessUserTokenRequest>;
977
+
978
+ export interface GetAccessUserTokenResponse {
979
+ comment?: string;
980
+ expire?: number;
981
+ privsep?: unknown;
982
+ }
983
+ export const GetAccessUserTokenResponse = /*@__PURE__*/ S.suspend(() =>
984
+ S.Struct({
985
+ comment: S.optional(S.String),
986
+ expire: S.optional(S.Number),
987
+ privsep: S.optional(S.Unknown),
988
+ }),
989
+ ).annotate({
990
+ identifier: "GetAccessUserTokenResponse",
991
+ }) as any as S.Schema<GetAccessUserTokenResponse>;
992
+
993
+ export interface ListAccessRequest {}
994
+ export const ListAccessRequest = /*@__PURE__*/ S.suspend(() =>
995
+ S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access", code: 200 })),
996
+ ).annotate({
997
+ identifier: "ListAccessRequest",
998
+ }) as any as S.Schema<ListAccessRequest>;
999
+
1000
+ export interface ListAccessResponseBodyItem {
1001
+ subdir: string;
1002
+ }
1003
+ export const ListAccessResponseBodyItem = /*@__PURE__*/ S.suspend(() =>
1004
+ S.Struct({
1005
+ subdir: S.String,
1006
+ }),
1007
+ ).annotate({
1008
+ identifier: "ListAccessResponseBodyItem",
1009
+ }) as any as S.Schema<ListAccessResponseBodyItem>;
1010
+
1011
+ export type ListAccessResponseBodyList = Array<ListAccessResponseBodyItem>;
1012
+ export const ListAccessResponseBodyList = /*@__PURE__*/ S.Array(
1013
+ ListAccessResponseBodyItem,
1014
+ ) as any as S.Schema<ListAccessResponseBodyList>;
1015
+
1016
+ export type ListAccessResponse = ListAccessResponseBodyList;
1017
+ export const ListAccessResponse = /*@__PURE__*/ S.suspend(() =>
1018
+ ListAccessResponseBodyList.pipe(T.RawResponseRoot()),
1019
+ ).annotate({
1020
+ identifier: "ListAccessResponse",
1021
+ }) as any as S.Schema<ListAccessResponse>;
1022
+
1023
+ export interface ListAccessAclRequest {}
1024
+ export const ListAccessAclRequest = /*@__PURE__*/ S.suspend(() =>
1025
+ S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access/acl", code: 200 })),
1026
+ ).annotate({
1027
+ identifier: "ListAccessAclRequest",
1028
+ }) as any as S.Schema<ListAccessAclRequest>;
1029
+
1030
+ export type ListAccessAclResponseBodyItemType = "user" | "group" | "token";
1031
+ export const ListAccessAclResponseBodyItemType = S.String;
1032
+
1033
+ export interface ListAccessAclResponseBodyItem {
1034
+ path: string;
1035
+ propagate?: unknown;
1036
+ roleid: string;
1037
+ type: ListAccessAclResponseBodyItemType;
1038
+ ugid: string;
1039
+ }
1040
+ export const ListAccessAclResponseBodyItem = /*@__PURE__*/ S.suspend(() =>
1041
+ S.Struct({
1042
+ path: S.String,
1043
+ propagate: S.optional(S.Unknown),
1044
+ roleid: S.String,
1045
+ type: ListAccessAclResponseBodyItemType,
1046
+ ugid: S.String,
1047
+ }),
1048
+ ).annotate({
1049
+ identifier: "ListAccessAclResponseBodyItem",
1050
+ }) as any as S.Schema<ListAccessAclResponseBodyItem>;
1051
+
1052
+ export type ListAccessAclResponseBodyList =
1053
+ Array<ListAccessAclResponseBodyItem>;
1054
+ export const ListAccessAclResponseBodyList = /*@__PURE__*/ S.Array(
1055
+ ListAccessAclResponseBodyItem,
1056
+ ) as any as S.Schema<ListAccessAclResponseBodyList>;
1057
+
1058
+ export type ListAccessAclResponse = ListAccessAclResponseBodyList;
1059
+ export const ListAccessAclResponse = /*@__PURE__*/ S.suspend(() =>
1060
+ ListAccessAclResponseBodyList.pipe(T.RawResponseRoot()),
1061
+ ).annotate({
1062
+ identifier: "ListAccessAclResponse",
1063
+ }) as any as S.Schema<ListAccessAclResponse>;
1064
+
1065
+ export interface ListAccessDomainsRequest {}
1066
+ export const ListAccessDomainsRequest = /*@__PURE__*/ S.suspend(() =>
1067
+ S.Struct({}).pipe(
1068
+ T.Http({ method: "GET", uri: "/access/domains", code: 200 }),
1069
+ ),
1070
+ ).annotate({
1071
+ identifier: "ListAccessDomainsRequest",
1072
+ }) as any as S.Schema<ListAccessDomainsRequest>;
1073
+
1074
+ export type ListAccessDomainsResponseBodyItemTfa = "yubico" | "oath";
1075
+ export const ListAccessDomainsResponseBodyItemTfa = S.String;
1076
+
1077
+ export interface ListAccessDomainsResponseBodyItem {
1078
+ comment?: string;
1079
+ realm: string;
1080
+ tfa?: ListAccessDomainsResponseBodyItemTfa;
1081
+ type: string;
1082
+ }
1083
+ export const ListAccessDomainsResponseBodyItem = /*@__PURE__*/ S.suspend(() =>
1084
+ S.Struct({
1085
+ comment: S.optional(S.String),
1086
+ realm: S.String,
1087
+ tfa: S.optional(ListAccessDomainsResponseBodyItemTfa),
1088
+ type: S.String,
1089
+ }),
1090
+ ).annotate({
1091
+ identifier: "ListAccessDomainsResponseBodyItem",
1092
+ }) as any as S.Schema<ListAccessDomainsResponseBodyItem>;
1093
+
1094
+ export type ListAccessDomainsResponseBodyList =
1095
+ Array<ListAccessDomainsResponseBodyItem>;
1096
+ export const ListAccessDomainsResponseBodyList = /*@__PURE__*/ S.Array(
1097
+ ListAccessDomainsResponseBodyItem,
1098
+ ) as any as S.Schema<ListAccessDomainsResponseBodyList>;
1099
+
1100
+ export type ListAccessDomainsResponse = ListAccessDomainsResponseBodyList;
1101
+ export const ListAccessDomainsResponse = /*@__PURE__*/ S.suspend(() =>
1102
+ ListAccessDomainsResponseBodyList.pipe(T.RawResponseRoot()),
1103
+ ).annotate({
1104
+ identifier: "ListAccessDomainsResponse",
1105
+ }) as any as S.Schema<ListAccessDomainsResponse>;
1106
+
1107
+ export interface ListAccessGroupsRequest {}
1108
+ export const ListAccessGroupsRequest = /*@__PURE__*/ S.suspend(() =>
1109
+ S.Struct({}).pipe(
1110
+ T.Http({ method: "GET", uri: "/access/groups", code: 200 }),
1111
+ ),
1112
+ ).annotate({
1113
+ identifier: "ListAccessGroupsRequest",
1114
+ }) as any as S.Schema<ListAccessGroupsRequest>;
1115
+
1116
+ export interface ListAccessGroupsResponseBodyItem {
1117
+ comment?: string;
1118
+ groupid: string;
1119
+ users?: string;
1120
+ }
1121
+ export const ListAccessGroupsResponseBodyItem = /*@__PURE__*/ S.suspend(() =>
1122
+ S.Struct({
1123
+ comment: S.optional(S.String),
1124
+ groupid: S.String,
1125
+ users: S.optional(S.String),
1126
+ }),
1127
+ ).annotate({
1128
+ identifier: "ListAccessGroupsResponseBodyItem",
1129
+ }) as any as S.Schema<ListAccessGroupsResponseBodyItem>;
1130
+
1131
+ export type ListAccessGroupsResponseBodyList =
1132
+ Array<ListAccessGroupsResponseBodyItem>;
1133
+ export const ListAccessGroupsResponseBodyList = /*@__PURE__*/ S.Array(
1134
+ ListAccessGroupsResponseBodyItem,
1135
+ ) as any as S.Schema<ListAccessGroupsResponseBodyList>;
1136
+
1137
+ export type ListAccessGroupsResponse = ListAccessGroupsResponseBodyList;
1138
+ export const ListAccessGroupsResponse = /*@__PURE__*/ S.suspend(() =>
1139
+ ListAccessGroupsResponseBodyList.pipe(T.RawResponseRoot()),
1140
+ ).annotate({
1141
+ identifier: "ListAccessGroupsResponse",
1142
+ }) as any as S.Schema<ListAccessGroupsResponse>;
1143
+
1144
+ export interface ListAccessOpenidRequest {}
1145
+ export const ListAccessOpenidRequest = /*@__PURE__*/ S.suspend(() =>
1146
+ S.Struct({}).pipe(
1147
+ T.Http({ method: "GET", uri: "/access/openid", code: 200 }),
1148
+ ),
1149
+ ).annotate({
1150
+ identifier: "ListAccessOpenidRequest",
1151
+ }) as any as S.Schema<ListAccessOpenidRequest>;
1152
+
1153
+ export type ListAccessOpenidResponseBodyItem = ListAccessResponseBodyItem;
1154
+ export const ListAccessOpenidResponseBodyItem = ListAccessResponseBodyItem;
1155
+
1156
+ export type ListAccessOpenidResponseBodyList =
1157
+ Array<ListAccessResponseBodyItem>;
1158
+ export const ListAccessOpenidResponseBodyList = /*@__PURE__*/ S.Array(
1159
+ ListAccessResponseBodyItem,
1160
+ ) as any as S.Schema<ListAccessOpenidResponseBodyList>;
1161
+
1162
+ export type ListAccessOpenidResponse = ListAccessOpenidResponseBodyList;
1163
+ export const ListAccessOpenidResponse = /*@__PURE__*/ S.suspend(() =>
1164
+ ListAccessOpenidResponseBodyList.pipe(T.RawResponseRoot()),
1165
+ ).annotate({
1166
+ identifier: "ListAccessOpenidResponse",
1167
+ }) as any as S.Schema<ListAccessOpenidResponse>;
1168
+
1169
+ export interface ListAccessRolesRequest {}
1170
+ export const ListAccessRolesRequest = /*@__PURE__*/ S.suspend(() =>
1171
+ S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access/roles", code: 200 })),
1172
+ ).annotate({
1173
+ identifier: "ListAccessRolesRequest",
1174
+ }) as any as S.Schema<ListAccessRolesRequest>;
1175
+
1176
+ export interface ListAccessRolesResponseBodyItem {
1177
+ privs?: string;
1178
+ roleid: string;
1179
+ special?: unknown;
1180
+ }
1181
+ export const ListAccessRolesResponseBodyItem = /*@__PURE__*/ S.suspend(() =>
1182
+ S.Struct({
1183
+ privs: S.optional(S.String),
1184
+ roleid: S.String,
1185
+ special: S.optional(S.Unknown),
1186
+ }),
1187
+ ).annotate({
1188
+ identifier: "ListAccessRolesResponseBodyItem",
1189
+ }) as any as S.Schema<ListAccessRolesResponseBodyItem>;
1190
+
1191
+ export type ListAccessRolesResponseBodyList =
1192
+ Array<ListAccessRolesResponseBodyItem>;
1193
+ export const ListAccessRolesResponseBodyList = /*@__PURE__*/ S.Array(
1194
+ ListAccessRolesResponseBodyItem,
1195
+ ) as any as S.Schema<ListAccessRolesResponseBodyList>;
1196
+
1197
+ export type ListAccessRolesResponse = ListAccessRolesResponseBodyList;
1198
+ export const ListAccessRolesResponse = /*@__PURE__*/ S.suspend(() =>
1199
+ ListAccessRolesResponseBodyList.pipe(T.RawResponseRoot()),
1200
+ ).annotate({
1201
+ identifier: "ListAccessRolesResponse",
1202
+ }) as any as S.Schema<ListAccessRolesResponse>;
1203
+
1204
+ export interface ListAccessTfaRequest {}
1205
+ export const ListAccessTfaRequest = /*@__PURE__*/ S.suspend(() =>
1206
+ S.Struct({}).pipe(T.Http({ method: "GET", uri: "/access/tfa", code: 200 })),
1207
+ ).annotate({
1208
+ identifier: "ListAccessTfaRequest",
1209
+ }) as any as S.Schema<ListAccessTfaRequest>;
1210
+
1211
+ export type ListAccessTfaResponseBodyItemEntriesItemType =
1212
+ | "totp"
1213
+ | "u2f"
1214
+ | "webauthn"
1215
+ | "recovery"
1216
+ | "yubico";
1217
+ export const ListAccessTfaResponseBodyItemEntriesItemType = S.String;
1218
+
1219
+ export interface ListAccessTfaResponseBodyItemEntriesItem {
1220
+ created: number;
1221
+ description: string;
1222
+ enable?: unknown;
1223
+ id: string;
1224
+ type: ListAccessTfaResponseBodyItemEntriesItemType;
1225
+ }
1226
+ export const ListAccessTfaResponseBodyItemEntriesItem = /*@__PURE__*/ S.suspend(
1227
+ () =>
1228
+ S.Struct({
1229
+ created: S.Number,
1230
+ description: S.String,
1231
+ enable: S.optional(S.Unknown),
1232
+ id: S.String,
1233
+ type: ListAccessTfaResponseBodyItemEntriesItemType,
1234
+ }),
1235
+ ).annotate({
1236
+ identifier: "ListAccessTfaResponseBodyItemEntriesItem",
1237
+ }) as any as S.Schema<ListAccessTfaResponseBodyItemEntriesItem>;
1238
+
1239
+ export type ListAccessTfaResponseBodyItemEntriesList =
1240
+ Array<ListAccessTfaResponseBodyItemEntriesItem>;
1241
+ export const ListAccessTfaResponseBodyItemEntriesList = /*@__PURE__*/ S.Array(
1242
+ ListAccessTfaResponseBodyItemEntriesItem,
1243
+ ) as any as S.Schema<ListAccessTfaResponseBodyItemEntriesList>;
1244
+
1245
+ export interface ListAccessTfaResponseBodyItem {
1246
+ entries: ListAccessTfaResponseBodyItemEntriesList;
1247
+ tfa_locked_until?: number;
1248
+ totp_locked?: unknown;
1249
+ userid: string;
1250
+ }
1251
+ export const ListAccessTfaResponseBodyItem = /*@__PURE__*/ S.suspend(() =>
1252
+ S.Struct({
1253
+ entries: ListAccessTfaResponseBodyItemEntriesList,
1254
+ tfa_locked_until: S.optional(S.Number.pipe(T.Body("tfa-locked-until"))),
1255
+ totp_locked: S.optional(S.Unknown.pipe(T.Body("totp-locked"))),
1256
+ userid: S.String,
1257
+ }),
1258
+ ).annotate({
1259
+ identifier: "ListAccessTfaResponseBodyItem",
1260
+ }) as any as S.Schema<ListAccessTfaResponseBodyItem>;
1261
+
1262
+ export type ListAccessTfaResponseBodyList =
1263
+ Array<ListAccessTfaResponseBodyItem>;
1264
+ export const ListAccessTfaResponseBodyList = /*@__PURE__*/ S.Array(
1265
+ ListAccessTfaResponseBodyItem,
1266
+ ) as any as S.Schema<ListAccessTfaResponseBodyList>;
1267
+
1268
+ export type ListAccessTfaResponse = ListAccessTfaResponseBodyList;
1269
+ export const ListAccessTfaResponse = /*@__PURE__*/ S.suspend(() =>
1270
+ ListAccessTfaResponseBodyList.pipe(T.RawResponseRoot()),
1271
+ ).annotate({
1272
+ identifier: "ListAccessTfaResponse",
1273
+ }) as any as S.Schema<ListAccessTfaResponse>;
1274
+
1275
+ export interface ListAccessUsersRequest {
1276
+ /** Optional filter for enable property. */
1277
+ enabled?: string;
1278
+ /** Include group and token information. */
1279
+ full?: string;
1280
+ }
1281
+ export const ListAccessUsersRequest = /*@__PURE__*/ S.suspend(() =>
1282
+ S.Struct({
1283
+ enabled: S.optional(S.String.pipe(T.Query())),
1284
+ full: S.optional(S.String.pipe(T.Query())),
1285
+ }).pipe(T.Http({ method: "GET", uri: "/access/users", code: 200 })),
1286
+ ).annotate({
1287
+ identifier: "ListAccessUsersRequest",
1288
+ }) as any as S.Schema<ListAccessUsersRequest>;
1289
+
1290
+ export interface ListAccessUsersResponseBodyItemTokensItem {
1291
+ comment?: string;
1292
+ expire?: number;
1293
+ privsep?: unknown;
1294
+ tokenid: string;
1295
+ }
1296
+ export const ListAccessUsersResponseBodyItemTokensItem =
1297
+ /*@__PURE__*/ S.suspend(() =>
1298
+ S.Struct({
1299
+ comment: S.optional(S.String),
1300
+ expire: S.optional(S.Number),
1301
+ privsep: S.optional(S.Unknown),
1302
+ tokenid: S.String,
1303
+ }),
1304
+ ).annotate({
1305
+ identifier: "ListAccessUsersResponseBodyItemTokensItem",
1306
+ }) as any as S.Schema<ListAccessUsersResponseBodyItemTokensItem>;
1307
+
1308
+ export type ListAccessUsersResponseBodyItemTokensList =
1309
+ Array<ListAccessUsersResponseBodyItemTokensItem>;
1310
+ export const ListAccessUsersResponseBodyItemTokensList = /*@__PURE__*/ S.Array(
1311
+ ListAccessUsersResponseBodyItemTokensItem,
1312
+ ) as any as S.Schema<ListAccessUsersResponseBodyItemTokensList>;
1313
+
1314
+ export interface ListAccessUsersResponseBodyItem {
1315
+ comment?: string;
1316
+ email?: string;
1317
+ enable?: unknown;
1318
+ expire?: number;
1319
+ firstname?: string;
1320
+ groups?: string;
1321
+ keys?: string;
1322
+ lastname?: string;
1323
+ realm_type?: string;
1324
+ tfa_locked_until?: number;
1325
+ tokens?: ListAccessUsersResponseBodyItemTokensList;
1326
+ totp_locked?: unknown;
1327
+ userid: string;
1328
+ }
1329
+ export const ListAccessUsersResponseBodyItem = /*@__PURE__*/ S.suspend(() =>
1330
+ S.Struct({
1331
+ comment: S.optional(S.String),
1332
+ email: S.optional(S.String),
1333
+ enable: S.optional(S.Unknown),
1334
+ expire: S.optional(S.Number),
1335
+ firstname: S.optional(S.String),
1336
+ groups: S.optional(S.String),
1337
+ keys: S.optional(S.String),
1338
+ lastname: S.optional(S.String),
1339
+ realm_type: S.optional(S.String.pipe(T.Body("realm-type"))),
1340
+ tfa_locked_until: S.optional(S.Number.pipe(T.Body("tfa-locked-until"))),
1341
+ tokens: S.optional(ListAccessUsersResponseBodyItemTokensList),
1342
+ totp_locked: S.optional(S.Unknown.pipe(T.Body("totp-locked"))),
1343
+ userid: S.String,
1344
+ }),
1345
+ ).annotate({
1346
+ identifier: "ListAccessUsersResponseBodyItem",
1347
+ }) as any as S.Schema<ListAccessUsersResponseBodyItem>;
1348
+
1349
+ export type ListAccessUsersResponseBodyList =
1350
+ Array<ListAccessUsersResponseBodyItem>;
1351
+ export const ListAccessUsersResponseBodyList = /*@__PURE__*/ S.Array(
1352
+ ListAccessUsersResponseBodyItem,
1353
+ ) as any as S.Schema<ListAccessUsersResponseBodyList>;
1354
+
1355
+ export type ListAccessUsersResponse = ListAccessUsersResponseBodyList;
1356
+ export const ListAccessUsersResponse = /*@__PURE__*/ S.suspend(() =>
1357
+ ListAccessUsersResponseBodyList.pipe(T.RawResponseRoot()),
1358
+ ).annotate({
1359
+ identifier: "ListAccessUsersResponse",
1360
+ }) as any as S.Schema<ListAccessUsersResponse>;
1361
+
1362
+ export interface ListAccessUserTokenRequest {
1363
+ userid: string;
1364
+ }
1365
+ export const ListAccessUserTokenRequest = /*@__PURE__*/ S.suspend(() =>
1366
+ S.Struct({
1367
+ userid: S.String.pipe(T.Label()),
1368
+ }).pipe(
1369
+ T.Http({ method: "GET", uri: "/access/users/{userid}/token", code: 200 }),
1370
+ ),
1371
+ ).annotate({
1372
+ identifier: "ListAccessUserTokenRequest",
1373
+ }) as any as S.Schema<ListAccessUserTokenRequest>;
1374
+
1375
+ export type ListAccessUserTokenResponseBodyItem =
1376
+ ListAccessUsersResponseBodyItemTokensItem;
1377
+ export const ListAccessUserTokenResponseBodyItem =
1378
+ ListAccessUsersResponseBodyItemTokensItem;
1379
+
1380
+ export type ListAccessUserTokenResponseBodyList =
1381
+ Array<ListAccessUsersResponseBodyItemTokensItem>;
1382
+ export const ListAccessUserTokenResponseBodyList = /*@__PURE__*/ S.Array(
1383
+ ListAccessUsersResponseBodyItemTokensItem,
1384
+ ) as any as S.Schema<ListAccessUserTokenResponseBodyList>;
1385
+
1386
+ export type ListAccessUserTokenResponse = ListAccessUserTokenResponseBodyList;
1387
+ export const ListAccessUserTokenResponse = /*@__PURE__*/ S.suspend(() =>
1388
+ ListAccessUserTokenResponseBodyList.pipe(T.RawResponseRoot()),
1389
+ ).annotate({
1390
+ identifier: "ListAccessUserTokenResponse",
1391
+ }) as any as S.Schema<ListAccessUserTokenResponse>;
1392
+
1393
+ export interface LoginAccessOpenidRequest {
1394
+ /** OpenId authorization code. */
1395
+ code: string;
1396
+ /** Redirection Url. The client should set this to the used server url (location.origin). */
1397
+ redirect_url: string;
1398
+ /** OpenId state. */
1399
+ state: string;
1400
+ }
1401
+ export const LoginAccessOpenidRequest = /*@__PURE__*/ S.suspend(() =>
1402
+ S.Struct({
1403
+ code: S.String,
1404
+ redirect_url: S.String.pipe(T.Body("redirect-url")),
1405
+ state: S.String,
1406
+ }).pipe(
1407
+ T.Http({
1408
+ method: "POST",
1409
+ uri: "/access/openid/login",
1410
+ code: 200,
1411
+ contentType: "form-urlencoded",
1412
+ }),
1413
+ ),
1414
+ ).annotate({
1415
+ identifier: "LoginAccessOpenidRequest",
1416
+ }) as any as S.Schema<LoginAccessOpenidRequest>;
1417
+
1418
+ export type LoginAccessOpenidResponse = unknown;
1419
+ export const LoginAccessOpenidResponse = /*@__PURE__*/ S.suspend(() =>
1420
+ S.Unknown.pipe(T.RawResponseRoot()),
1421
+ ).annotate({
1422
+ identifier: "LoginAccessOpenidResponse",
1423
+ }) as any as S.Schema<LoginAccessOpenidResponse>;
1424
+
1425
+ export interface PutAccessAclRequest {
1426
+ /** Remove permissions (instead of adding it). */
1427
+ delete?: string;
1428
+ /** List of groups. */
1429
+ groups?: string;
1430
+ /** Access control path */
1431
+ path: string;
1432
+ /** Allow to propagate (inherit) permissions. */
1433
+ propagate?: string;
1434
+ /** List of roles. */
1435
+ roles: string;
1436
+ /** List of API tokens. */
1437
+ tokens?: string;
1438
+ /** List of users. */
1439
+ users?: string;
1440
+ }
1441
+ export const PutAccessAclRequest = /*@__PURE__*/ S.suspend(() =>
1442
+ S.Struct({
1443
+ delete: S.optional(S.String),
1444
+ groups: S.optional(S.String),
1445
+ path: S.String,
1446
+ propagate: S.optional(S.String),
1447
+ roles: S.String,
1448
+ tokens: S.optional(S.String),
1449
+ users: S.optional(S.String),
1450
+ }).pipe(
1451
+ T.Http({
1452
+ method: "PUT",
1453
+ uri: "/access/acl",
1454
+ code: 200,
1455
+ contentType: "form-urlencoded",
1456
+ }),
1457
+ ),
1458
+ ).annotate({
1459
+ identifier: "PutAccessAclRequest",
1460
+ }) as any as S.Schema<PutAccessAclRequest>;
1461
+
1462
+ export interface PutAccessAclResponse {}
1463
+ export const PutAccessAclResponse = /*@__PURE__*/ S.suspend(() =>
1464
+ S.Struct({}),
1465
+ ).annotate({
1466
+ identifier: "PutAccessAclResponse",
1467
+ }) as any as S.Schema<PutAccessAclResponse>;
1468
+
1469
+ export type PutAccessDomainRequestMode = "ldap" | "ldaps" | "ldap+starttls";
1470
+ export const PutAccessDomainRequestMode = S.String;
1471
+
1472
+ export type PutAccessDomainRequestSslversion =
1473
+ | "tlsv1"
1474
+ | "tlsv1_1"
1475
+ | "tlsv1_2"
1476
+ | "tlsv1_3";
1477
+ export const PutAccessDomainRequestSslversion = S.String;
1478
+
1479
+ export interface PutAccessDomainRequest {
1480
+ realm: string;
1481
+ /** Specifies the Authentication Context Class Reference values that theAuthorization Server is being requested to use for the Auth Request. */
1482
+ acr_values?: string;
1483
+ /** A list of audiences that the OpenID Issuer may include that are accepted in addition to 'client-id'. */
1484
+ audiences?: string;
1485
+ /** Automatically create users if they do not exist. */
1486
+ autocreate?: string;
1487
+ /** LDAP base domain name */
1488
+ base_dn?: string;
1489
+ /** LDAP bind domain name */
1490
+ bind_dn?: string;
1491
+ /** Path to the CA certificate store */
1492
+ capath?: string;
1493
+ /** username is case-sensitive */
1494
+ case_sensitive?: string;
1495
+ /** Path to the client certificate */
1496
+ cert?: string;
1497
+ /** Path to the client certificate key */
1498
+ certkey?: string;
1499
+ /** Check bind connection to the server. */
1500
+ check_connection?: string;
1501
+ /** OpenID Client ID */
1502
+ client_id?: string;
1503
+ /** OpenID Client Key */
1504
+ client_key?: string;
1505
+ /** Description. */
1506
+ comment?: string;
1507
+ /** Use this as default realm */
1508
+ default?: string;
1509
+ /** A list of settings you want to delete. */
1510
+ delete?: string;
1511
+ /** Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. */
1512
+ digest?: string;
1513
+ /** AD domain name */
1514
+ domain?: string;
1515
+ /** LDAP filter for user sync. */
1516
+ filter?: string;
1517
+ /** The objectclasses for groups. */
1518
+ group_classes?: string;
1519
+ /** LDAP base domain name for group sync. If not set, the base_dn will be used. */
1520
+ group_dn?: string;
1521
+ /** LDAP filter for group sync. */
1522
+ group_filter?: string;
1523
+ /** LDAP attribute representing a groups name. If not set or found, the first value of the DN will be used as name. */
1524
+ group_name_attr?: string;
1525
+ /** Automatically create groups if they do not exist. */
1526
+ groups_autocreate?: string;
1527
+ /** OpenID claim used to retrieve groups with. */
1528
+ groups_claim?: string;
1529
+ /** All groups will be overwritten for the user on login. */
1530
+ groups_overwrite?: string;
1531
+ /** OpenID Issuer Url */
1532
+ issuer_url?: string;
1533
+ /** LDAP protocol mode. */
1534
+ mode?: PutAccessDomainRequestMode | (string & {});
1535
+ /** LDAP bind password. Will be stored in '/etc/pve/priv/realm/<REALM>.pw'. */
1536
+ password?: string;
1537
+ /** Server port. */
1538
+ port?: string;
1539
+ /** Specifies whether the Authorization Server prompts the End-User for reauthentication and consent. */
1540
+ prompt?: string;
1541
+ /** Enables querying the userinfo endpoint for claims values. */
1542
+ query_userinfo?: string;
1543
+ /** Specifies the scopes (user details) that should be authorized and returned, for example 'email' or 'profile'. */
1544
+ scopes?: string;
1545
+ /** Use secure LDAPS protocol. DEPRECATED: use 'mode' instead. */
1546
+ secure?: string;
1547
+ /** Server IP address (or DNS name) */
1548
+ server1?: string;
1549
+ /** Fallback Server IP address (or DNS name) */
1550
+ server2?: string;
1551
+ /** LDAPS TLS/SSL version. It's not recommended to use version older than 1.2! */
1552
+ sslversion?: PutAccessDomainRequestSslversion | (string & {});
1553
+ /** The default options for behavior of synchronizations. */
1554
+ sync_defaults_options?: string;
1555
+ /** Comma separated list of key=value pairs for specifying which LDAP attributes map to which PVE user field. For example, to map the LDAP attribute 'mail' to PVEs 'email', write 'email=mail'. By default, each PVE user field is represented by an LDAP attribute of the same name. */
1556
+ sync_attributes?: string;
1557
+ /** Use Two-factor authentication. */
1558
+ tfa?: string;
1559
+ /** LDAP user attribute name */
1560
+ user_attr?: string;
1561
+ /** The objectclasses for users. */
1562
+ user_classes?: string;
1563
+ /** Verify the server's SSL certificate */
1564
+ verify?: string;
1565
+ }
1566
+ export const PutAccessDomainRequest = /*@__PURE__*/ S.suspend(() =>
1567
+ S.Struct({
1568
+ realm: S.String.pipe(T.Label()),
1569
+ acr_values: S.optional(S.String.pipe(T.Body("acr-values"))),
1570
+ audiences: S.optional(S.String),
1571
+ autocreate: S.optional(S.String),
1572
+ base_dn: S.optional(S.String),
1573
+ bind_dn: S.optional(S.String),
1574
+ capath: S.optional(S.String),
1575
+ case_sensitive: S.optional(S.String.pipe(T.Body("case-sensitive"))),
1576
+ cert: S.optional(S.String),
1577
+ certkey: S.optional(S.String),
1578
+ check_connection: S.optional(S.String.pipe(T.Body("check-connection"))),
1579
+ client_id: S.optional(S.String.pipe(T.Body("client-id"))),
1580
+ client_key: S.optional(S.String.pipe(T.Body("client-key"))),
1581
+ comment: S.optional(S.String),
1582
+ default: S.optional(S.String),
1583
+ delete: S.optional(S.String),
1584
+ digest: S.optional(S.String),
1585
+ domain: S.optional(S.String),
1586
+ filter: S.optional(S.String),
1587
+ group_classes: S.optional(S.String),
1588
+ group_dn: S.optional(S.String),
1589
+ group_filter: S.optional(S.String),
1590
+ group_name_attr: S.optional(S.String),
1591
+ groups_autocreate: S.optional(S.String.pipe(T.Body("groups-autocreate"))),
1592
+ groups_claim: S.optional(S.String.pipe(T.Body("groups-claim"))),
1593
+ groups_overwrite: S.optional(S.String.pipe(T.Body("groups-overwrite"))),
1594
+ issuer_url: S.optional(S.String.pipe(T.Body("issuer-url"))),
1595
+ mode: S.optional(PutAccessDomainRequestMode),
1596
+ password: S.optional(S.String),
1597
+ port: S.optional(S.String),
1598
+ prompt: S.optional(S.String),
1599
+ query_userinfo: S.optional(S.String.pipe(T.Body("query-userinfo"))),
1600
+ scopes: S.optional(S.String),
1601
+ secure: S.optional(S.String),
1602
+ server1: S.optional(S.String),
1603
+ server2: S.optional(S.String),
1604
+ sslversion: S.optional(PutAccessDomainRequestSslversion),
1605
+ sync_defaults_options: S.optional(
1606
+ S.String.pipe(T.Body("sync-defaults-options")),
1607
+ ),
1608
+ sync_attributes: S.optional(S.String),
1609
+ tfa: S.optional(S.String),
1610
+ user_attr: S.optional(S.String),
1611
+ user_classes: S.optional(S.String),
1612
+ verify: S.optional(S.String),
1613
+ }).pipe(
1614
+ T.Http({
1615
+ method: "PUT",
1616
+ uri: "/access/domains/{realm}",
1617
+ code: 200,
1618
+ contentType: "form-urlencoded",
1619
+ }),
1620
+ ),
1621
+ ).annotate({
1622
+ identifier: "PutAccessDomainRequest",
1623
+ }) as any as S.Schema<PutAccessDomainRequest>;
1624
+
1625
+ export interface PutAccessDomainResponse {}
1626
+ export const PutAccessDomainResponse = /*@__PURE__*/ S.suspend(() =>
1627
+ S.Struct({}),
1628
+ ).annotate({
1629
+ identifier: "PutAccessDomainResponse",
1630
+ }) as any as S.Schema<PutAccessDomainResponse>;
1631
+
1632
+ export interface PutAccessGroupRequest {
1633
+ groupid: string;
1634
+ comment?: string;
1635
+ }
1636
+ export const PutAccessGroupRequest = /*@__PURE__*/ S.suspend(() =>
1637
+ S.Struct({
1638
+ groupid: S.String.pipe(T.Label()),
1639
+ comment: S.optional(S.String),
1640
+ }).pipe(
1641
+ T.Http({
1642
+ method: "PUT",
1643
+ uri: "/access/groups/{groupid}",
1644
+ code: 200,
1645
+ contentType: "form-urlencoded",
1646
+ }),
1647
+ ),
1648
+ ).annotate({
1649
+ identifier: "PutAccessGroupRequest",
1650
+ }) as any as S.Schema<PutAccessGroupRequest>;
1651
+
1652
+ export interface PutAccessGroupResponse {}
1653
+ export const PutAccessGroupResponse = /*@__PURE__*/ S.suspend(() =>
1654
+ S.Struct({}),
1655
+ ).annotate({
1656
+ identifier: "PutAccessGroupResponse",
1657
+ }) as any as S.Schema<PutAccessGroupResponse>;
1658
+
1659
+ export interface PutAccessPasswordRequest {
1660
+ /** The current password of the user performing the change. */
1661
+ confirmation_password?: string;
1662
+ /** The new password. */
1663
+ password: string;
1664
+ /** Full User ID, in the `name@realm` format. */
1665
+ userid: string;
1666
+ }
1667
+ export const PutAccessPasswordRequest = /*@__PURE__*/ S.suspend(() =>
1668
+ S.Struct({
1669
+ confirmation_password: S.optional(
1670
+ S.String.pipe(T.Body("confirmation-password")),
1671
+ ),
1672
+ password: S.String,
1673
+ userid: S.String,
1674
+ }).pipe(
1675
+ T.Http({
1676
+ method: "PUT",
1677
+ uri: "/access/password",
1678
+ code: 200,
1679
+ contentType: "form-urlencoded",
1680
+ }),
1681
+ ),
1682
+ ).annotate({
1683
+ identifier: "PutAccessPasswordRequest",
1684
+ }) as any as S.Schema<PutAccessPasswordRequest>;
1685
+
1686
+ export interface PutAccessPasswordResponse {}
1687
+ export const PutAccessPasswordResponse = /*@__PURE__*/ S.suspend(() =>
1688
+ S.Struct({}),
1689
+ ).annotate({
1690
+ identifier: "PutAccessPasswordResponse",
1691
+ }) as any as S.Schema<PutAccessPasswordResponse>;
1692
+
1693
+ export interface PutAccessRoleRequest {
1694
+ roleid: string;
1695
+ append?: string;
1696
+ privs?: string;
1697
+ }
1698
+ export const PutAccessRoleRequest = /*@__PURE__*/ S.suspend(() =>
1699
+ S.Struct({
1700
+ roleid: S.String.pipe(T.Label()),
1701
+ append: S.optional(S.String),
1702
+ privs: S.optional(S.String),
1703
+ }).pipe(
1704
+ T.Http({
1705
+ method: "PUT",
1706
+ uri: "/access/roles/{roleid}",
1707
+ code: 200,
1708
+ contentType: "form-urlencoded",
1709
+ }),
1710
+ ),
1711
+ ).annotate({
1712
+ identifier: "PutAccessRoleRequest",
1713
+ }) as any as S.Schema<PutAccessRoleRequest>;
1714
+
1715
+ export interface PutAccessRoleResponse {}
1716
+ export const PutAccessRoleResponse = /*@__PURE__*/ S.suspend(() =>
1717
+ S.Struct({}),
1718
+ ).annotate({
1719
+ identifier: "PutAccessRoleResponse",
1720
+ }) as any as S.Schema<PutAccessRoleResponse>;
1721
+
1722
+ export interface PutAccessTfaRequest {
1723
+ userid: string;
1724
+ id: string;
1725
+ /** A description to distinguish multiple entries from one another */
1726
+ description?: string;
1727
+ /** Whether the entry should be enabled for login. */
1728
+ enable?: string;
1729
+ /** The current password of the user performing the change. */
1730
+ password?: string;
1731
+ }
1732
+ export const PutAccessTfaRequest = /*@__PURE__*/ S.suspend(() =>
1733
+ S.Struct({
1734
+ userid: S.String.pipe(T.Label()),
1735
+ id: S.String.pipe(T.Label()),
1736
+ description: S.optional(S.String),
1737
+ enable: S.optional(S.String),
1738
+ password: S.optional(S.String),
1739
+ }).pipe(
1740
+ T.Http({
1741
+ method: "PUT",
1742
+ uri: "/access/tfa/{userid}/{id}",
1743
+ code: 200,
1744
+ contentType: "form-urlencoded",
1745
+ }),
1746
+ ),
1747
+ ).annotate({
1748
+ identifier: "PutAccessTfaRequest",
1749
+ }) as any as S.Schema<PutAccessTfaRequest>;
1750
+
1751
+ export interface PutAccessTfaResponse {}
1752
+ export const PutAccessTfaResponse = /*@__PURE__*/ S.suspend(() =>
1753
+ S.Struct({}),
1754
+ ).annotate({
1755
+ identifier: "PutAccessTfaResponse",
1756
+ }) as any as S.Schema<PutAccessTfaResponse>;
1757
+
1758
+ export interface PutAccessUserRequest {
1759
+ userid: string;
1760
+ append?: string;
1761
+ comment?: string;
1762
+ email?: string;
1763
+ /** Enable the account (default). You can set this to '0' to disable the account */
1764
+ enable?: string;
1765
+ /** Account expiration date (seconds since epoch). '0' means no expiration date. */
1766
+ expire?: string;
1767
+ firstname?: string;
1768
+ groups?: string;
1769
+ /** Keys for two factor auth (yubico). */
1770
+ keys?: string;
1771
+ lastname?: string;
1772
+ }
1773
+ export const PutAccessUserRequest = /*@__PURE__*/ S.suspend(() =>
1774
+ S.Struct({
1775
+ userid: S.String.pipe(T.Label()),
1776
+ append: S.optional(S.String),
1777
+ comment: S.optional(S.String),
1778
+ email: S.optional(S.String),
1779
+ enable: S.optional(S.String),
1780
+ expire: S.optional(S.String),
1781
+ firstname: S.optional(S.String),
1782
+ groups: S.optional(S.String),
1783
+ keys: S.optional(S.String),
1784
+ lastname: S.optional(S.String),
1785
+ }).pipe(
1786
+ T.Http({
1787
+ method: "PUT",
1788
+ uri: "/access/users/{userid}",
1789
+ code: 200,
1790
+ contentType: "form-urlencoded",
1791
+ }),
1792
+ ),
1793
+ ).annotate({
1794
+ identifier: "PutAccessUserRequest",
1795
+ }) as any as S.Schema<PutAccessUserRequest>;
1796
+
1797
+ export interface PutAccessUserResponse {}
1798
+ export const PutAccessUserResponse = /*@__PURE__*/ S.suspend(() =>
1799
+ S.Struct({}),
1800
+ ).annotate({
1801
+ identifier: "PutAccessUserResponse",
1802
+ }) as any as S.Schema<PutAccessUserResponse>;
1803
+
1804
+ export interface PutAccessUserTokenRequest {
1805
+ userid: string;
1806
+ tokenid: string;
1807
+ comment?: string;
1808
+ /** A list of settings you want to delete. */
1809
+ delete?: string;
1810
+ /** API token expiration date (seconds since epoch). '0' means no expiration date. */
1811
+ expire?: string;
1812
+ /** Restrict API token privileges with separate ACLs (default), or give full privileges of corresponding user. */
1813
+ privsep?: string;
1814
+ /** Regenerate the token's secret value. All users of the previous secret will lose access after this operation. */
1815
+ regenerate?: string;
1816
+ }
1817
+ export const PutAccessUserTokenRequest = /*@__PURE__*/ S.suspend(() =>
1818
+ S.Struct({
1819
+ userid: S.String.pipe(T.Label()),
1820
+ tokenid: S.String.pipe(T.Label()),
1821
+ comment: S.optional(S.String),
1822
+ delete: S.optional(S.String),
1823
+ expire: S.optional(S.String),
1824
+ privsep: S.optional(S.String),
1825
+ regenerate: S.optional(S.String),
1826
+ }).pipe(
1827
+ T.Http({
1828
+ method: "PUT",
1829
+ uri: "/access/users/{userid}/token/{tokenid}",
1830
+ code: 200,
1831
+ contentType: "form-urlencoded",
1832
+ }),
1833
+ ),
1834
+ ).annotate({
1835
+ identifier: "PutAccessUserTokenRequest",
1836
+ }) as any as S.Schema<PutAccessUserTokenRequest>;
1837
+
1838
+ export interface PutAccessUserTokenResponse {
1839
+ comment?: string;
1840
+ expire?: number;
1841
+ full_tokenid?: string;
1842
+ privsep?: unknown;
1843
+ value?: string;
1844
+ }
1845
+ export const PutAccessUserTokenResponse = /*@__PURE__*/ S.suspend(() =>
1846
+ S.Struct({
1847
+ comment: S.optional(S.String),
1848
+ expire: S.optional(S.Number),
1849
+ full_tokenid: S.optional(S.String.pipe(T.Body("full-tokenid"))),
1850
+ privsep: S.optional(S.Unknown),
1851
+ value: S.optional(S.String),
1852
+ }),
1853
+ ).annotate({
1854
+ identifier: "PutAccessUserTokenResponse",
1855
+ }) as any as S.Schema<PutAccessUserTokenResponse>;
1856
+
1857
+ export interface PutAccessUserUnlockTfaRequest {
1858
+ userid: string;
1859
+ }
1860
+ export const PutAccessUserUnlockTfaRequest = /*@__PURE__*/ S.suspend(() =>
1861
+ S.Struct({
1862
+ userid: S.String.pipe(T.Label()),
1863
+ }).pipe(
1864
+ T.Http({
1865
+ method: "PUT",
1866
+ uri: "/access/users/{userid}/unlock-tfa",
1867
+ code: 200,
1868
+ }),
1869
+ ),
1870
+ ).annotate({
1871
+ identifier: "PutAccessUserUnlockTfaRequest",
1872
+ }) as any as S.Schema<PutAccessUserUnlockTfaRequest>;
1873
+
1874
+ export type PutAccessUserUnlockTfaResponse = unknown;
1875
+ export const PutAccessUserUnlockTfaResponse = /*@__PURE__*/ S.suspend(() =>
1876
+ S.Unknown.pipe(T.RawResponseRoot()),
1877
+ ).annotate({
1878
+ identifier: "PutAccessUserUnlockTfaResponse",
1879
+ }) as any as S.Schema<PutAccessUserUnlockTfaResponse>;
1880
+
1881
+ export type SyncAccessDomainRequestScope = "users" | "groups" | "both";
1882
+ export const SyncAccessDomainRequestScope = S.String;
1883
+
1884
+ export interface SyncAccessDomainRequest {
1885
+ realm: string;
1886
+ /** If set, does not write anything. */
1887
+ dry_run?: string;
1888
+ /** Enable newly synced users immediately. */
1889
+ enable_new: string;
1890
+ /** DEPRECATED: use 'remove-vanished' instead. If set, uses the LDAP Directory as source of truth, deleting users or groups not returned from the sync and removing all locally modified properties of synced users. If not set, only syncs information which is present in the synced data, and does not delete or modify anything else. */
1891
+ full: string;
1892
+ /** DEPRECATED: use 'remove-vanished' instead. Remove ACLs for users or groups which were removed from the config during a sync. */
1893
+ purge: string;
1894
+ /** A semicolon-separated list of things to remove when they or the user vanishes during a sync. The following values are possible: 'entry' removes the user/group when not returned from the sync. 'properties' removes the set properties on existing user/group that do not appear in the source (even custom ones). 'acl' removes acls when the user/group is not returned from the sync. Instead of a list it also can be 'none' (the default). */
1895
+ remove_vanished: string;
1896
+ /** Select what to sync. */
1897
+ scope: SyncAccessDomainRequestScope | (string & {});
1898
+ }
1899
+ export const SyncAccessDomainRequest = /*@__PURE__*/ S.suspend(() =>
1900
+ S.Struct({
1901
+ realm: S.String.pipe(T.Label()),
1902
+ dry_run: S.optional(S.String.pipe(T.Body("dry-run"))),
1903
+ enable_new: S.String.pipe(T.Body("enable-new")),
1904
+ full: S.String,
1905
+ purge: S.String,
1906
+ remove_vanished: S.String.pipe(T.Body("remove-vanished")),
1907
+ scope: SyncAccessDomainRequestScope,
1908
+ }).pipe(
1909
+ T.Http({
1910
+ method: "POST",
1911
+ uri: "/access/domains/{realm}/sync",
1912
+ code: 200,
1913
+ contentType: "form-urlencoded",
1914
+ }),
1915
+ ),
1916
+ ).annotate({
1917
+ identifier: "SyncAccessDomainRequest",
1918
+ }) as any as S.Schema<SyncAccessDomainRequest>;
1919
+
1920
+ export type SyncAccessDomainResponse = string;
1921
+ export const SyncAccessDomainResponse = /*@__PURE__*/ S.suspend(() =>
1922
+ S.String.pipe(T.RawResponseRoot()),
1923
+ ).annotate({
1924
+ identifier: "SyncAccessDomainResponse",
1925
+ }) as any as S.Schema<SyncAccessDomainResponse>;
1926
+
1927
+ export type UpdateAccessTfaRequestType =
1928
+ | "totp"
1929
+ | "u2f"
1930
+ | "webauthn"
1931
+ | "recovery"
1932
+ | "yubico";
1933
+ export const UpdateAccessTfaRequestType = S.String;
1934
+
1935
+ export interface UpdateAccessTfaRequest {
1936
+ userid: string;
1937
+ /** When responding to a u2f challenge: the original challenge string */
1938
+ challenge?: string;
1939
+ /** A description to distinguish multiple entries from one another */
1940
+ description?: string;
1941
+ /** The current password of the user performing the change. */
1942
+ password?: string;
1943
+ /** A totp URI. */
1944
+ totp?: string;
1945
+ /** TFA Entry Type. */
1946
+ type: UpdateAccessTfaRequestType | (string & {});
1947
+ /** The current value for the provided totp URI, or a Webauthn/U2F challenge response */
1948
+ value?: string;
1949
+ }
1950
+ export const UpdateAccessTfaRequest = /*@__PURE__*/ S.suspend(() =>
1951
+ S.Struct({
1952
+ userid: S.String.pipe(T.Label()),
1953
+ challenge: S.optional(S.String),
1954
+ description: S.optional(S.String),
1955
+ password: S.optional(S.String),
1956
+ totp: S.optional(S.String),
1957
+ type: UpdateAccessTfaRequestType,
1958
+ value: S.optional(S.String),
1959
+ }).pipe(
1960
+ T.Http({
1961
+ method: "POST",
1962
+ uri: "/access/tfa/{userid}",
1963
+ code: 200,
1964
+ contentType: "form-urlencoded",
1965
+ }),
1966
+ ),
1967
+ ).annotate({
1968
+ identifier: "UpdateAccessTfaRequest",
1969
+ }) as any as S.Schema<UpdateAccessTfaRequest>;
1970
+
1971
+ export type UpdateAccessTfaResponseRecoveryList = Array<string>;
1972
+ export const UpdateAccessTfaResponseRecoveryList = /*@__PURE__*/ S.Array(
1973
+ S.String,
1974
+ ) as any as S.Schema<UpdateAccessTfaResponseRecoveryList>;
1975
+
1976
+ export interface UpdateAccessTfaResponse {
1977
+ challenge?: string;
1978
+ id: string;
1979
+ recovery?: UpdateAccessTfaResponseRecoveryList;
1980
+ }
1981
+ export const UpdateAccessTfaResponse = /*@__PURE__*/ S.suspend(() =>
1982
+ S.Struct({
1983
+ challenge: S.optional(S.String),
1984
+ id: S.String,
1985
+ recovery: S.optional(UpdateAccessTfaResponseRecoveryList),
1986
+ }),
1987
+ ).annotate({
1988
+ identifier: "UpdateAccessTfaResponse",
1989
+ }) as any as S.Schema<UpdateAccessTfaResponse>;
1990
+
1991
+ export interface UpdateAccessUserTokenRequest {
1992
+ userid: string;
1993
+ tokenid: string;
1994
+ comment?: string;
1995
+ /** API token expiration date (seconds since epoch). '0' means no expiration date. */
1996
+ expire?: string;
1997
+ /** Restrict API token privileges with separate ACLs (default), or give full privileges of corresponding user. */
1998
+ privsep?: string;
1999
+ }
2000
+ export const UpdateAccessUserTokenRequest = /*@__PURE__*/ S.suspend(() =>
2001
+ S.Struct({
2002
+ userid: S.String.pipe(T.Label()),
2003
+ tokenid: S.String.pipe(T.Label()),
2004
+ comment: S.optional(S.String),
2005
+ expire: S.optional(S.String),
2006
+ privsep: S.optional(S.String),
2007
+ }).pipe(
2008
+ T.Http({
2009
+ method: "POST",
2010
+ uri: "/access/users/{userid}/token/{tokenid}",
2011
+ code: 200,
2012
+ contentType: "form-urlencoded",
2013
+ }),
2014
+ ),
2015
+ ).annotate({
2016
+ identifier: "UpdateAccessUserTokenRequest",
2017
+ }) as any as S.Schema<UpdateAccessUserTokenRequest>;
2018
+
2019
+ export interface UpdateAccessUserTokenResponseInfo {
2020
+ comment?: string;
2021
+ expire?: number;
2022
+ privsep?: unknown;
2023
+ }
2024
+ export const UpdateAccessUserTokenResponseInfo = /*@__PURE__*/ S.suspend(() =>
2025
+ S.Struct({
2026
+ comment: S.optional(S.String),
2027
+ expire: S.optional(S.Number),
2028
+ privsep: S.optional(S.Unknown),
2029
+ }),
2030
+ ).annotate({
2031
+ identifier: "UpdateAccessUserTokenResponseInfo",
2032
+ }) as any as S.Schema<UpdateAccessUserTokenResponseInfo>;
2033
+
2034
+ export interface UpdateAccessUserTokenResponse {
2035
+ full_tokenid?: string;
2036
+ info: UpdateAccessUserTokenResponseInfo;
2037
+ value: string;
2038
+ }
2039
+ export const UpdateAccessUserTokenResponse = /*@__PURE__*/ S.suspend(() =>
2040
+ S.Struct({
2041
+ full_tokenid: S.optional(S.String.pipe(T.Body("full-tokenid"))),
2042
+ info: UpdateAccessUserTokenResponseInfo,
2043
+ value: S.String,
2044
+ }),
2045
+ ).annotate({
2046
+ identifier: "UpdateAccessUserTokenResponse",
2047
+ }) as any as S.Schema<UpdateAccessUserTokenResponse>;
2048
+
2049
+ export type CreateAccessDomainError = ProxmoxOpError;
2050
+ /** Add an authentication server. (root-privileged endpoint) */
2051
+ export const createAccessDomain: API.OperationMethod<
2052
+ CreateAccessDomainRequest,
2053
+ CreateAccessDomainResponse,
2054
+ CreateAccessDomainError,
2055
+ ProxmoxOpContext
2056
+ > = /*@__PURE__*/ API.make(() => ({
2057
+ input: CreateAccessDomainRequest,
2058
+ output: CreateAccessDomainResponse,
2059
+ errors: [],
2060
+ protocol: ProxmoxProtocol,
2061
+ retry: Retry.Retry,
2062
+ }));
2063
+
2064
+ export type CreateAccessGroupError = ProxmoxOpError;
2065
+ /** Create new group. (root-privileged endpoint) */
2066
+ export const createAccessGroup: API.OperationMethod<
2067
+ CreateAccessGroupRequest,
2068
+ CreateAccessGroupResponse,
2069
+ CreateAccessGroupError,
2070
+ ProxmoxOpContext
2071
+ > = /*@__PURE__*/ API.make(() => ({
2072
+ input: CreateAccessGroupRequest,
2073
+ output: CreateAccessGroupResponse,
2074
+ errors: [],
2075
+ protocol: ProxmoxProtocol,
2076
+ retry: Retry.Retry,
2077
+ }));
2078
+
2079
+ export type CreateAccessOpenidAuthUrlError = ProxmoxOpError;
2080
+ /** Get the OpenId Authorization Url for the specified realm. (root-privileged endpoint) */
2081
+ export const createAccessOpenidAuthUrl: API.OperationMethod<
2082
+ CreateAccessOpenidAuthUrlRequest,
2083
+ CreateAccessOpenidAuthUrlResponse,
2084
+ CreateAccessOpenidAuthUrlError,
2085
+ ProxmoxOpContext
2086
+ > = /*@__PURE__*/ API.make(() => ({
2087
+ input: CreateAccessOpenidAuthUrlRequest,
2088
+ output: CreateAccessOpenidAuthUrlResponse,
2089
+ errors: [],
2090
+ protocol: ProxmoxProtocol,
2091
+ retry: Retry.Retry,
2092
+ }));
2093
+
2094
+ export type CreateAccessRoleError = ProxmoxOpError;
2095
+ /** Create new role. (root-privileged endpoint) */
2096
+ export const createAccessRole: API.OperationMethod<
2097
+ CreateAccessRoleRequest,
2098
+ CreateAccessRoleResponse,
2099
+ CreateAccessRoleError,
2100
+ ProxmoxOpContext
2101
+ > = /*@__PURE__*/ API.make(() => ({
2102
+ input: CreateAccessRoleRequest,
2103
+ output: CreateAccessRoleResponse,
2104
+ errors: [],
2105
+ protocol: ProxmoxProtocol,
2106
+ retry: Retry.Retry,
2107
+ }));
2108
+
2109
+ export type CreateAccessTicketError = ProxmoxOpError;
2110
+ /** Create or verify authentication ticket. (root-privileged endpoint) */
2111
+ export const createAccessTicket: API.OperationMethod<
2112
+ CreateAccessTicketRequest,
2113
+ CreateAccessTicketResponse,
2114
+ CreateAccessTicketError,
2115
+ ProxmoxOpContext
2116
+ > = /*@__PURE__*/ API.make(() => ({
2117
+ input: CreateAccessTicketRequest,
2118
+ output: CreateAccessTicketResponse,
2119
+ errors: [],
2120
+ protocol: ProxmoxProtocol,
2121
+ retry: Retry.Retry,
2122
+ }));
2123
+
2124
+ export type CreateAccessUserError = ProxmoxOpError;
2125
+ /** Create new user. (root-privileged endpoint) */
2126
+ export const createAccessUser: API.OperationMethod<
2127
+ CreateAccessUserRequest,
2128
+ CreateAccessUserResponse,
2129
+ CreateAccessUserError,
2130
+ ProxmoxOpContext
2131
+ > = /*@__PURE__*/ API.make(() => ({
2132
+ input: CreateAccessUserRequest,
2133
+ output: CreateAccessUserResponse,
2134
+ errors: [],
2135
+ protocol: ProxmoxProtocol,
2136
+ retry: Retry.Retry,
2137
+ }));
2138
+
2139
+ export type CreateAccessVncticketError = ProxmoxOpError;
2140
+ /** verify VNC authentication ticket. (root-privileged endpoint) */
2141
+ export const createAccessVncticket: API.OperationMethod<
2142
+ CreateAccessVncticketRequest,
2143
+ CreateAccessVncticketResponse,
2144
+ CreateAccessVncticketError,
2145
+ ProxmoxOpContext
2146
+ > = /*@__PURE__*/ API.make(() => ({
2147
+ input: CreateAccessVncticketRequest,
2148
+ output: CreateAccessVncticketResponse,
2149
+ errors: [],
2150
+ protocol: ProxmoxProtocol,
2151
+ retry: Retry.Retry,
2152
+ }));
2153
+
2154
+ export type DeleteAccessDomainError = ProxmoxOpError;
2155
+ /** Delete an authentication server. (root-privileged endpoint) */
2156
+ export const deleteAccessDomain: API.OperationMethod<
2157
+ DeleteAccessDomainRequest,
2158
+ DeleteAccessDomainResponse,
2159
+ DeleteAccessDomainError,
2160
+ ProxmoxOpContext
2161
+ > = /*@__PURE__*/ API.make(() => ({
2162
+ input: DeleteAccessDomainRequest,
2163
+ output: DeleteAccessDomainResponse,
2164
+ errors: [],
2165
+ protocol: ProxmoxProtocol,
2166
+ retry: Retry.Retry,
2167
+ }));
2168
+
2169
+ export type DeleteAccessGroupError = ProxmoxOpError;
2170
+ /** Delete group. (root-privileged endpoint) */
2171
+ export const deleteAccessGroup: API.OperationMethod<
2172
+ DeleteAccessGroupRequest,
2173
+ DeleteAccessGroupResponse,
2174
+ DeleteAccessGroupError,
2175
+ ProxmoxOpContext
2176
+ > = /*@__PURE__*/ API.make(() => ({
2177
+ input: DeleteAccessGroupRequest,
2178
+ output: DeleteAccessGroupResponse,
2179
+ errors: [],
2180
+ protocol: ProxmoxProtocol,
2181
+ retry: Retry.Retry,
2182
+ }));
2183
+
2184
+ export type DeleteAccessRoleError = ProxmoxOpError;
2185
+ /** Delete role. (root-privileged endpoint) */
2186
+ export const deleteAccessRole: API.OperationMethod<
2187
+ DeleteAccessRoleRequest,
2188
+ DeleteAccessRoleResponse,
2189
+ DeleteAccessRoleError,
2190
+ ProxmoxOpContext
2191
+ > = /*@__PURE__*/ API.make(() => ({
2192
+ input: DeleteAccessRoleRequest,
2193
+ output: DeleteAccessRoleResponse,
2194
+ errors: [],
2195
+ protocol: ProxmoxProtocol,
2196
+ retry: Retry.Retry,
2197
+ }));
2198
+
2199
+ export type DeleteAccessTfaError = ProxmoxOpError;
2200
+ /** Delete a TFA entry by ID. (root-privileged endpoint) */
2201
+ export const deleteAccessTfa: API.OperationMethod<
2202
+ DeleteAccessTfaRequest,
2203
+ DeleteAccessTfaResponse,
2204
+ DeleteAccessTfaError,
2205
+ ProxmoxOpContext
2206
+ > = /*@__PURE__*/ API.make(() => ({
2207
+ input: DeleteAccessTfaRequest,
2208
+ output: DeleteAccessTfaResponse,
2209
+ errors: [],
2210
+ protocol: ProxmoxProtocol,
2211
+ retry: Retry.Retry,
2212
+ }));
2213
+
2214
+ export type DeleteAccessUserError = ProxmoxOpError;
2215
+ /** Delete user. (root-privileged endpoint) */
2216
+ export const deleteAccessUser: API.OperationMethod<
2217
+ DeleteAccessUserRequest,
2218
+ DeleteAccessUserResponse,
2219
+ DeleteAccessUserError,
2220
+ ProxmoxOpContext
2221
+ > = /*@__PURE__*/ API.make(() => ({
2222
+ input: DeleteAccessUserRequest,
2223
+ output: DeleteAccessUserResponse,
2224
+ errors: [],
2225
+ protocol: ProxmoxProtocol,
2226
+ retry: Retry.Retry,
2227
+ }));
2228
+
2229
+ export type DeleteAccessUserTokenError = ProxmoxOpError;
2230
+ /** Remove API token for a specific user. (root-privileged endpoint) */
2231
+ export const deleteAccessUserToken: API.OperationMethod<
2232
+ DeleteAccessUserTokenRequest,
2233
+ DeleteAccessUserTokenResponse,
2234
+ DeleteAccessUserTokenError,
2235
+ ProxmoxOpContext
2236
+ > = /*@__PURE__*/ API.make(() => ({
2237
+ input: DeleteAccessUserTokenRequest,
2238
+ output: DeleteAccessUserTokenResponse,
2239
+ errors: [],
2240
+ protocol: ProxmoxProtocol,
2241
+ retry: Retry.Retry,
2242
+ }));
2243
+
2244
+ export type GetAccessDomainError = ProxmoxOpError;
2245
+ /** Get auth server configuration. */
2246
+ export const getAccessDomain: API.OperationMethod<
2247
+ GetAccessDomainRequest,
2248
+ GetAccessDomainResponse,
2249
+ GetAccessDomainError,
2250
+ ProxmoxOpContext
2251
+ > = /*@__PURE__*/ API.make(() => ({
2252
+ input: GetAccessDomainRequest,
2253
+ output: GetAccessDomainResponse,
2254
+ errors: [],
2255
+ protocol: ProxmoxProtocol,
2256
+ retry: Retry.Retry,
2257
+ }));
2258
+
2259
+ export type GetAccessGroupError = ProxmoxOpError;
2260
+ /** Get group configuration. */
2261
+ export const getAccessGroup: API.OperationMethod<
2262
+ GetAccessGroupRequest,
2263
+ GetAccessGroupResponse,
2264
+ GetAccessGroupError,
2265
+ ProxmoxOpContext
2266
+ > = /*@__PURE__*/ API.make(() => ({
2267
+ input: GetAccessGroupRequest,
2268
+ output: GetAccessGroupResponse,
2269
+ errors: [],
2270
+ protocol: ProxmoxProtocol,
2271
+ retry: Retry.Retry,
2272
+ }));
2273
+
2274
+ export type GetAccessPermissionsError = ProxmoxOpError;
2275
+ /** Retrieve effective permissions of given user/token. */
2276
+ export const getAccessPermissions: API.OperationMethod<
2277
+ GetAccessPermissionsRequest,
2278
+ GetAccessPermissionsResponse,
2279
+ GetAccessPermissionsError,
2280
+ ProxmoxOpContext
2281
+ > = /*@__PURE__*/ API.make(() => ({
2282
+ input: GetAccessPermissionsRequest,
2283
+ output: GetAccessPermissionsResponse,
2284
+ errors: [],
2285
+ protocol: ProxmoxProtocol,
2286
+ retry: Retry.Retry,
2287
+ }));
2288
+
2289
+ export type GetAccessRoleError = ProxmoxOpError;
2290
+ /** Get role configuration. */
2291
+ export const getAccessRole: API.OperationMethod<
2292
+ GetAccessRoleRequest,
2293
+ GetAccessRoleResponse,
2294
+ GetAccessRoleError,
2295
+ ProxmoxOpContext
2296
+ > = /*@__PURE__*/ API.make(() => ({
2297
+ input: GetAccessRoleRequest,
2298
+ output: GetAccessRoleResponse,
2299
+ errors: [],
2300
+ protocol: ProxmoxProtocol,
2301
+ retry: Retry.Retry,
2302
+ }));
2303
+
2304
+ export type GetAccessTfaError = ProxmoxOpError;
2305
+ /** List TFA configurations of users. (root-privileged endpoint) */
2306
+ export const getAccessTfa: API.OperationMethod<
2307
+ GetAccessTfaRequest,
2308
+ GetAccessTfaResponse,
2309
+ GetAccessTfaError,
2310
+ ProxmoxOpContext
2311
+ > = /*@__PURE__*/ API.make(() => ({
2312
+ input: GetAccessTfaRequest,
2313
+ output: GetAccessTfaResponse,
2314
+ errors: [],
2315
+ protocol: ProxmoxProtocol,
2316
+ retry: Retry.Retry,
2317
+ }));
2318
+
2319
+ export type GetAccessTfa2Error = ProxmoxOpError;
2320
+ /** Fetch a requested TFA entry if present. (root-privileged endpoint) */
2321
+ export const getAccessTfa2: API.OperationMethod<
2322
+ GetAccessTfa2Request,
2323
+ GetAccessTfa2Response,
2324
+ GetAccessTfa2Error,
2325
+ ProxmoxOpContext
2326
+ > = /*@__PURE__*/ API.make(() => ({
2327
+ input: GetAccessTfa2Request,
2328
+ output: GetAccessTfa2Response,
2329
+ errors: [],
2330
+ protocol: ProxmoxProtocol,
2331
+ retry: Retry.Retry,
2332
+ }));
2333
+
2334
+ export type GetAccessTicketError = ProxmoxOpError;
2335
+ /** Dummy. Useful for formatters which want to provide a login page. */
2336
+ export const getAccessTicket: API.OperationMethod<
2337
+ GetAccessTicketRequest,
2338
+ GetAccessTicketResponse,
2339
+ GetAccessTicketError,
2340
+ ProxmoxOpContext
2341
+ > = /*@__PURE__*/ API.make(() => ({
2342
+ input: GetAccessTicketRequest,
2343
+ output: GetAccessTicketResponse,
2344
+ errors: [],
2345
+ protocol: ProxmoxProtocol,
2346
+ retry: Retry.Retry,
2347
+ }));
2348
+
2349
+ export type GetAccessUserError = ProxmoxOpError;
2350
+ /** Get user configuration. */
2351
+ export const getAccessUser: API.OperationMethod<
2352
+ GetAccessUserRequest,
2353
+ GetAccessUserResponse,
2354
+ GetAccessUserError,
2355
+ ProxmoxOpContext
2356
+ > = /*@__PURE__*/ API.make(() => ({
2357
+ input: GetAccessUserRequest,
2358
+ output: GetAccessUserResponse,
2359
+ errors: [],
2360
+ protocol: ProxmoxProtocol,
2361
+ retry: Retry.Retry,
2362
+ }));
2363
+
2364
+ export type GetAccessUserTfaError = ProxmoxOpError;
2365
+ /** Get user TFA types (Personal and Realm). (root-privileged endpoint) */
2366
+ export const getAccessUserTfa: API.OperationMethod<
2367
+ GetAccessUserTfaRequest,
2368
+ GetAccessUserTfaResponse,
2369
+ GetAccessUserTfaError,
2370
+ ProxmoxOpContext
2371
+ > = /*@__PURE__*/ API.make(() => ({
2372
+ input: GetAccessUserTfaRequest,
2373
+ output: GetAccessUserTfaResponse,
2374
+ errors: [],
2375
+ protocol: ProxmoxProtocol,
2376
+ retry: Retry.Retry,
2377
+ }));
2378
+
2379
+ export type GetAccessUserTokenError = ProxmoxOpError;
2380
+ /** Get specific API token information. */
2381
+ export const getAccessUserToken: API.OperationMethod<
2382
+ GetAccessUserTokenRequest,
2383
+ GetAccessUserTokenResponse,
2384
+ GetAccessUserTokenError,
2385
+ ProxmoxOpContext
2386
+ > = /*@__PURE__*/ API.make(() => ({
2387
+ input: GetAccessUserTokenRequest,
2388
+ output: GetAccessUserTokenResponse,
2389
+ errors: [],
2390
+ protocol: ProxmoxProtocol,
2391
+ retry: Retry.Retry,
2392
+ }));
2393
+
2394
+ export type ListAccessError = ProxmoxOpError;
2395
+ /** Directory index. */
2396
+ export const listAccess: API.OperationMethod<
2397
+ ListAccessRequest,
2398
+ ListAccessResponse,
2399
+ ListAccessError,
2400
+ ProxmoxOpContext
2401
+ > = /*@__PURE__*/ API.make(() => ({
2402
+ input: ListAccessRequest,
2403
+ output: ListAccessResponse,
2404
+ errors: [],
2405
+ protocol: ProxmoxProtocol,
2406
+ retry: Retry.Retry,
2407
+ }));
2408
+
2409
+ export type ListAccessAclError = ProxmoxOpError;
2410
+ /** Get Access Control List (ACLs). */
2411
+ export const listAccessAcl: API.OperationMethod<
2412
+ ListAccessAclRequest,
2413
+ ListAccessAclResponse,
2414
+ ListAccessAclError,
2415
+ ProxmoxOpContext
2416
+ > = /*@__PURE__*/ API.make(() => ({
2417
+ input: ListAccessAclRequest,
2418
+ output: ListAccessAclResponse,
2419
+ errors: [],
2420
+ protocol: ProxmoxProtocol,
2421
+ retry: Retry.Retry,
2422
+ }));
2423
+
2424
+ export type ListAccessDomainsError = ProxmoxOpError;
2425
+ /** Authentication domain index. */
2426
+ export const listAccessDomains: API.OperationMethod<
2427
+ ListAccessDomainsRequest,
2428
+ ListAccessDomainsResponse,
2429
+ ListAccessDomainsError,
2430
+ ProxmoxOpContext
2431
+ > = /*@__PURE__*/ API.make(() => ({
2432
+ input: ListAccessDomainsRequest,
2433
+ output: ListAccessDomainsResponse,
2434
+ errors: [],
2435
+ protocol: ProxmoxProtocol,
2436
+ retry: Retry.Retry,
2437
+ }));
2438
+
2439
+ export type ListAccessGroupsError = ProxmoxOpError;
2440
+ /** Group index. */
2441
+ export const listAccessGroups: API.OperationMethod<
2442
+ ListAccessGroupsRequest,
2443
+ ListAccessGroupsResponse,
2444
+ ListAccessGroupsError,
2445
+ ProxmoxOpContext
2446
+ > = /*@__PURE__*/ API.make(() => ({
2447
+ input: ListAccessGroupsRequest,
2448
+ output: ListAccessGroupsResponse,
2449
+ errors: [],
2450
+ protocol: ProxmoxProtocol,
2451
+ retry: Retry.Retry,
2452
+ }));
2453
+
2454
+ export type ListAccessOpenidError = ProxmoxOpError;
2455
+ /** Directory index. */
2456
+ export const listAccessOpenid: API.OperationMethod<
2457
+ ListAccessOpenidRequest,
2458
+ ListAccessOpenidResponse,
2459
+ ListAccessOpenidError,
2460
+ ProxmoxOpContext
2461
+ > = /*@__PURE__*/ API.make(() => ({
2462
+ input: ListAccessOpenidRequest,
2463
+ output: ListAccessOpenidResponse,
2464
+ errors: [],
2465
+ protocol: ProxmoxProtocol,
2466
+ retry: Retry.Retry,
2467
+ }));
2468
+
2469
+ export type ListAccessRolesError = ProxmoxOpError;
2470
+ /** Role index. */
2471
+ export const listAccessRoles: API.OperationMethod<
2472
+ ListAccessRolesRequest,
2473
+ ListAccessRolesResponse,
2474
+ ListAccessRolesError,
2475
+ ProxmoxOpContext
2476
+ > = /*@__PURE__*/ API.make(() => ({
2477
+ input: ListAccessRolesRequest,
2478
+ output: ListAccessRolesResponse,
2479
+ errors: [],
2480
+ protocol: ProxmoxProtocol,
2481
+ retry: Retry.Retry,
2482
+ }));
2483
+
2484
+ export type ListAccessTfaError = ProxmoxOpError;
2485
+ /** List TFA configurations of users. (root-privileged endpoint) */
2486
+ export const listAccessTfa: API.OperationMethod<
2487
+ ListAccessTfaRequest,
2488
+ ListAccessTfaResponse,
2489
+ ListAccessTfaError,
2490
+ ProxmoxOpContext
2491
+ > = /*@__PURE__*/ API.make(() => ({
2492
+ input: ListAccessTfaRequest,
2493
+ output: ListAccessTfaResponse,
2494
+ errors: [],
2495
+ protocol: ProxmoxProtocol,
2496
+ retry: Retry.Retry,
2497
+ }));
2498
+
2499
+ export type ListAccessUsersError = ProxmoxOpError;
2500
+ /** User index. (root-privileged endpoint) */
2501
+ export const listAccessUsers: API.OperationMethod<
2502
+ ListAccessUsersRequest,
2503
+ ListAccessUsersResponse,
2504
+ ListAccessUsersError,
2505
+ ProxmoxOpContext
2506
+ > = /*@__PURE__*/ API.make(() => ({
2507
+ input: ListAccessUsersRequest,
2508
+ output: ListAccessUsersResponse,
2509
+ errors: [],
2510
+ protocol: ProxmoxProtocol,
2511
+ retry: Retry.Retry,
2512
+ }));
2513
+
2514
+ export type ListAccessUserTokenError = ProxmoxOpError;
2515
+ /** Get user API tokens. */
2516
+ export const listAccessUserToken: API.OperationMethod<
2517
+ ListAccessUserTokenRequest,
2518
+ ListAccessUserTokenResponse,
2519
+ ListAccessUserTokenError,
2520
+ ProxmoxOpContext
2521
+ > = /*@__PURE__*/ API.make(() => ({
2522
+ input: ListAccessUserTokenRequest,
2523
+ output: ListAccessUserTokenResponse,
2524
+ errors: [],
2525
+ protocol: ProxmoxProtocol,
2526
+ retry: Retry.Retry,
2527
+ }));
2528
+
2529
+ export type LoginAccessOpenidError = ProxmoxOpError;
2530
+ /** Verify OpenID authorization code and create a ticket. (root-privileged endpoint) */
2531
+ export const loginAccessOpenid: API.OperationMethod<
2532
+ LoginAccessOpenidRequest,
2533
+ LoginAccessOpenidResponse,
2534
+ LoginAccessOpenidError,
2535
+ ProxmoxOpContext
2536
+ > = /*@__PURE__*/ API.make(() => ({
2537
+ input: LoginAccessOpenidRequest,
2538
+ output: LoginAccessOpenidResponse,
2539
+ errors: [],
2540
+ protocol: ProxmoxProtocol,
2541
+ retry: Retry.Retry,
2542
+ }));
2543
+
2544
+ export type PutAccessAclError = ProxmoxOpError;
2545
+ /** Update Access Control List (add or remove permissions). (root-privileged endpoint) */
2546
+ export const putAccessAcl: API.OperationMethod<
2547
+ PutAccessAclRequest,
2548
+ PutAccessAclResponse,
2549
+ PutAccessAclError,
2550
+ ProxmoxOpContext
2551
+ > = /*@__PURE__*/ API.make(() => ({
2552
+ input: PutAccessAclRequest,
2553
+ output: PutAccessAclResponse,
2554
+ errors: [],
2555
+ protocol: ProxmoxProtocol,
2556
+ retry: Retry.Retry,
2557
+ }));
2558
+
2559
+ export type PutAccessDomainError = ProxmoxOpError;
2560
+ /** Update authentication server settings. (root-privileged endpoint) */
2561
+ export const putAccessDomain: API.OperationMethod<
2562
+ PutAccessDomainRequest,
2563
+ PutAccessDomainResponse,
2564
+ PutAccessDomainError,
2565
+ ProxmoxOpContext
2566
+ > = /*@__PURE__*/ API.make(() => ({
2567
+ input: PutAccessDomainRequest,
2568
+ output: PutAccessDomainResponse,
2569
+ errors: [],
2570
+ protocol: ProxmoxProtocol,
2571
+ retry: Retry.Retry,
2572
+ }));
2573
+
2574
+ export type PutAccessGroupError = ProxmoxOpError;
2575
+ /** Update group data. (root-privileged endpoint) */
2576
+ export const putAccessGroup: API.OperationMethod<
2577
+ PutAccessGroupRequest,
2578
+ PutAccessGroupResponse,
2579
+ PutAccessGroupError,
2580
+ ProxmoxOpContext
2581
+ > = /*@__PURE__*/ API.make(() => ({
2582
+ input: PutAccessGroupRequest,
2583
+ output: PutAccessGroupResponse,
2584
+ errors: [],
2585
+ protocol: ProxmoxProtocol,
2586
+ retry: Retry.Retry,
2587
+ }));
2588
+
2589
+ export type PutAccessPasswordError = ProxmoxOpError;
2590
+ /** Change user password. (root-privileged endpoint) */
2591
+ export const putAccessPassword: API.OperationMethod<
2592
+ PutAccessPasswordRequest,
2593
+ PutAccessPasswordResponse,
2594
+ PutAccessPasswordError,
2595
+ ProxmoxOpContext
2596
+ > = /*@__PURE__*/ API.make(() => ({
2597
+ input: PutAccessPasswordRequest,
2598
+ output: PutAccessPasswordResponse,
2599
+ errors: [],
2600
+ protocol: ProxmoxProtocol,
2601
+ retry: Retry.Retry,
2602
+ }));
2603
+
2604
+ export type PutAccessRoleError = ProxmoxOpError;
2605
+ /** Update an existing role. (root-privileged endpoint) */
2606
+ export const putAccessRole: API.OperationMethod<
2607
+ PutAccessRoleRequest,
2608
+ PutAccessRoleResponse,
2609
+ PutAccessRoleError,
2610
+ ProxmoxOpContext
2611
+ > = /*@__PURE__*/ API.make(() => ({
2612
+ input: PutAccessRoleRequest,
2613
+ output: PutAccessRoleResponse,
2614
+ errors: [],
2615
+ protocol: ProxmoxProtocol,
2616
+ retry: Retry.Retry,
2617
+ }));
2618
+
2619
+ export type PutAccessTfaError = ProxmoxOpError;
2620
+ /** Add a TFA entry for a user. (root-privileged endpoint) */
2621
+ export const putAccessTfa: API.OperationMethod<
2622
+ PutAccessTfaRequest,
2623
+ PutAccessTfaResponse,
2624
+ PutAccessTfaError,
2625
+ ProxmoxOpContext
2626
+ > = /*@__PURE__*/ API.make(() => ({
2627
+ input: PutAccessTfaRequest,
2628
+ output: PutAccessTfaResponse,
2629
+ errors: [],
2630
+ protocol: ProxmoxProtocol,
2631
+ retry: Retry.Retry,
2632
+ }));
2633
+
2634
+ export type PutAccessUserError = ProxmoxOpError;
2635
+ /** Update user configuration. (root-privileged endpoint) */
2636
+ export const putAccessUser: API.OperationMethod<
2637
+ PutAccessUserRequest,
2638
+ PutAccessUserResponse,
2639
+ PutAccessUserError,
2640
+ ProxmoxOpContext
2641
+ > = /*@__PURE__*/ API.make(() => ({
2642
+ input: PutAccessUserRequest,
2643
+ output: PutAccessUserResponse,
2644
+ errors: [],
2645
+ protocol: ProxmoxProtocol,
2646
+ retry: Retry.Retry,
2647
+ }));
2648
+
2649
+ export type PutAccessUserTokenError = ProxmoxOpError;
2650
+ /** 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) */
2651
+ export const putAccessUserToken: API.OperationMethod<
2652
+ PutAccessUserTokenRequest,
2653
+ PutAccessUserTokenResponse,
2654
+ PutAccessUserTokenError,
2655
+ ProxmoxOpContext
2656
+ > = /*@__PURE__*/ API.make(() => ({
2657
+ input: PutAccessUserTokenRequest,
2658
+ output: PutAccessUserTokenResponse,
2659
+ errors: [],
2660
+ protocol: ProxmoxProtocol,
2661
+ retry: Retry.Retry,
2662
+ }));
2663
+
2664
+ export type PutAccessUserUnlockTfaError = ProxmoxOpError;
2665
+ /** Unlock a user's TFA authentication. (root-privileged endpoint) */
2666
+ export const putAccessUserUnlockTfa: API.OperationMethod<
2667
+ PutAccessUserUnlockTfaRequest,
2668
+ PutAccessUserUnlockTfaResponse,
2669
+ PutAccessUserUnlockTfaError,
2670
+ ProxmoxOpContext
2671
+ > = /*@__PURE__*/ API.make(() => ({
2672
+ input: PutAccessUserUnlockTfaRequest,
2673
+ output: PutAccessUserUnlockTfaResponse,
2674
+ errors: [],
2675
+ protocol: ProxmoxProtocol,
2676
+ retry: Retry.Retry,
2677
+ }));
2678
+
2679
+ export type SyncAccessDomainError = ProxmoxOpError;
2680
+ /** 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) */
2681
+ export const syncAccessDomain: API.OperationMethod<
2682
+ SyncAccessDomainRequest,
2683
+ SyncAccessDomainResponse,
2684
+ SyncAccessDomainError,
2685
+ ProxmoxOpContext
2686
+ > = /*@__PURE__*/ API.make(() => ({
2687
+ input: SyncAccessDomainRequest,
2688
+ output: SyncAccessDomainResponse,
2689
+ errors: [],
2690
+ protocol: ProxmoxProtocol,
2691
+ retry: Retry.Retry,
2692
+ }));
2693
+
2694
+ export type UpdateAccessTfaError = ProxmoxOpError;
2695
+ /** Add a TFA entry for a user. (root-privileged endpoint) */
2696
+ export const updateAccessTfa: API.OperationMethod<
2697
+ UpdateAccessTfaRequest,
2698
+ UpdateAccessTfaResponse,
2699
+ UpdateAccessTfaError,
2700
+ ProxmoxOpContext
2701
+ > = /*@__PURE__*/ API.make(() => ({
2702
+ input: UpdateAccessTfaRequest,
2703
+ output: UpdateAccessTfaResponse,
2704
+ errors: [],
2705
+ protocol: ProxmoxProtocol,
2706
+ retry: Retry.Retry,
2707
+ }));
2708
+
2709
+ export type UpdateAccessUserTokenError = ProxmoxOpError;
2710
+ /** 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) */
2711
+ export const updateAccessUserToken: API.OperationMethod<
2712
+ UpdateAccessUserTokenRequest,
2713
+ UpdateAccessUserTokenResponse,
2714
+ UpdateAccessUserTokenError,
2715
+ ProxmoxOpContext
2716
+ > = /*@__PURE__*/ API.make(() => ({
2717
+ input: UpdateAccessUserTokenRequest,
2718
+ output: UpdateAccessUserTokenResponse,
2719
+ errors: [],
2720
+ protocol: ProxmoxProtocol,
2721
+ retry: Retry.Retry,
2722
+ }));