]> git.proxmox.com Git - pve-docs.git/blame - api-viewer/apidata.js
Fix path to block device when creating a file system on a thin volume
[pve-docs.git] / api-viewer / apidata.js
CommitLineData
56122987
DM
1var pveapi = [
2 {
56122987 3 "children" : [
32d876b5
DM
4 {
5 "children" : [
6 {
7 "info" : {
8 "GET" : {
9 "description" : "Corosync node list.",
10 "method" : "GET",
11 "name" : "nodes",
12 "parameters" : {
13 "additionalProperties" : 0
14 },
15 "returns" : {
16 "items" : {
17 "properties" : {
18 "node" : {
19 "type" : "string"
20 }
21 },
22 "type" : "object"
23 },
24 "links" : [
25 {
26 "href" : "{node}",
27 "rel" : "child"
28 }
29 ],
30 "type" : "array"
31 }
32 }
33 },
34 "leaf" : 1,
35 "path" : "/cluster/config/nodes",
36 "text" : "nodes"
37 },
38 {
39 "info" : {
40 "GET" : {
41 "description" : "Get corosync totem protocol settings.",
42 "method" : "GET",
43 "name" : "totem",
44 "parameters" : {
45 "additionalProperties" : 0
46 },
47 "returns" : {
48 "properties" : {},
49 "type" : "object"
50 }
51 }
52 },
53 "leaf" : 1,
54 "path" : "/cluster/config/totem",
55 "text" : "totem"
56 }
57 ],
58 "info" : {
59 "GET" : {
60 "description" : "Directory index.",
61 "method" : "GET",
62 "name" : "index",
63 "parameters" : {
64 "additionalProperties" : 0
65 },
66 "returns" : {
67 "items" : {
68 "properties" : {},
69 "type" : "object"
70 },
71 "links" : [
72 {
73 "href" : "{name}",
74 "rel" : "child"
75 }
76 ],
77 "type" : "array"
78 }
79 }
80 },
81 "leaf" : 0,
82 "path" : "/cluster/config",
83 "text" : "config"
84 },
56122987 85 {
56122987
DM
86 "children" : [
87 {
56122987
DM
88 "children" : [
89 {
44660702
DM
90 "children" : [
91 {
92 "info" : {
93 "DELETE" : {
94 "description" : "Delete rule.",
95 "method" : "DELETE",
96 "name" : "delete_rule",
97 "parameters" : {
98 "additionalProperties" : 0,
99 "properties" : {
100 "digest" : {
101 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
102 "maxLength" : 40,
103 "optional" : 1,
013dc89f
DM
104 "type" : "string",
105 "typetext" : "<string>"
44660702
DM
106 },
107 "group" : {
108 "description" : "Security Group name.",
4bd7df8b 109 "maxLength" : 18,
44660702
DM
110 "minLength" : 2,
111 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
112 "type" : "string"
113 },
114 "pos" : {
115 "description" : "Update rule at position <pos>.",
116 "minimum" : 0,
117 "optional" : 1,
4bd7df8b 118 "type" : "integer",
013dc89f 119 "typetext" : "<integer> (0 - N)"
44660702
DM
120 }
121 }
122 },
123 "permissions" : {
124 "check" : [
125 "perm",
126 "/",
127 [
128 "Sys.Modify"
129 ]
130 ]
131 },
132 "protected" : 1,
133 "proxyto" : null,
134 "returns" : {
135 "type" : "null"
7aacca6f
DM
136 }
137 },
44660702
DM
138 "GET" : {
139 "description" : "Get single rule data.",
140 "method" : "GET",
141 "name" : "get_rule",
142 "parameters" : {
143 "additionalProperties" : 0,
144 "properties" : {
145 "group" : {
146 "description" : "Security Group name.",
4bd7df8b 147 "maxLength" : 18,
44660702
DM
148 "minLength" : 2,
149 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
150 "type" : "string"
151 },
152 "pos" : {
153 "description" : "Update rule at position <pos>.",
154 "minimum" : 0,
155 "optional" : 1,
4bd7df8b 156 "type" : "integer",
013dc89f 157 "typetext" : "<integer> (0 - N)"
44660702 158 }
7aacca6f 159 }
56122987 160 },
44660702
DM
161 "permissions" : {
162 "check" : [
163 "perm",
164 "/",
165 [
166 "Sys.Audit"
167 ]
168 ]
169 },
170 "proxyto" : null,
171 "returns" : {
172 "properties" : {
173 "pos" : {
174 "type" : "integer"
175 }
176 },
177 "type" : "object"
56122987 178 }
44660702 179 },
7aacca6f 180 "PUT" : {
44660702
DM
181 "description" : "Modify rule data.",
182 "method" : "PUT",
183 "name" : "update_rule",
7aacca6f
DM
184 "parameters" : {
185 "additionalProperties" : 0,
186 "properties" : {
44660702
DM
187 "action" : {
188 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
7aacca6f 189 "maxLength" : 20,
44660702 190 "minLength" : 2,
7aacca6f 191 "optional" : 1,
44660702 192 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
7aacca6f
DM
193 "type" : "string"
194 },
44660702 195 "comment" : {
e94f0d56 196 "description" : "Descriptive comment.",
7aacca6f 197 "optional" : 1,
013dc89f
DM
198 "type" : "string",
199 "typetext" : "<string>"
7aacca6f 200 },
44660702
DM
201 "delete" : {
202 "description" : "A list of settings you want to delete.",
203 "format" : "pve-configid-list",
7aacca6f 204 "optional" : 1,
013dc89f
DM
205 "type" : "string",
206 "typetext" : "<string>"
7aacca6f 207 },
44660702
DM
208 "dest" : {
209 "description" : "Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
210 "format" : "pve-fw-addr-spec",
7aacca6f 211 "optional" : 1,
013dc89f
DM
212 "type" : "string",
213 "typetext" : "<string>"
7aacca6f
DM
214 },
215 "digest" : {
216 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702 217 "maxLength" : 40,
7aacca6f 218 "optional" : 1,
013dc89f
DM
219 "type" : "string",
220 "typetext" : "<string>"
7aacca6f 221 },
44660702
DM
222 "dport" : {
223 "description" : "Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
224 "format" : "pve-fw-dport-spec",
7aacca6f 225 "optional" : 1,
013dc89f
DM
226 "type" : "string",
227 "typetext" : "<string>"
7aacca6f 228 },
44660702 229 "enable" : {
e94f0d56 230 "description" : "Flag to enable/disable a rule.",
44660702 231 "minimum" : 0,
7aacca6f 232 "optional" : 1,
4bd7df8b 233 "type" : "integer",
013dc89f 234 "typetext" : "<integer> (0 - N)"
7aacca6f 235 },
44660702
DM
236 "group" : {
237 "description" : "Security Group name.",
4bd7df8b 238 "maxLength" : 18,
44660702
DM
239 "minLength" : 2,
240 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
241 "type" : "string"
242 },
243 "iface" : {
244 "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.",
245 "format" : "pve-iface",
246 "maxLength" : 20,
247 "minLength" : 2,
7aacca6f 248 "optional" : 1,
013dc89f
DM
249 "type" : "string",
250 "typetext" : "<string>"
7aacca6f 251 },
44660702 252 "macro" : {
e94f0d56 253 "description" : "Use predefined standard macro.",
44660702
DM
254 "maxLength" : 128,
255 "optional" : 1,
013dc89f
DM
256 "type" : "string",
257 "typetext" : "<string>"
7aacca6f
DM
258 },
259 "moveto" : {
260 "description" : "Move rule to new position <moveto>. Other arguments are ignored.",
44660702 261 "minimum" : 0,
7aacca6f 262 "optional" : 1,
4bd7df8b 263 "type" : "integer",
013dc89f 264 "typetext" : "<integer> (0 - N)"
7aacca6f 265 },
44660702
DM
266 "pos" : {
267 "description" : "Update rule at position <pos>.",
268 "minimum" : 0,
269 "optional" : 1,
4bd7df8b 270 "type" : "integer",
013dc89f 271 "typetext" : "<integer> (0 - N)"
7aacca6f 272 },
44660702
DM
273 "proto" : {
274 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
275 "format" : "pve-fw-protocol-spec",
7aacca6f 276 "optional" : 1,
013dc89f
DM
277 "type" : "string",
278 "typetext" : "<string>"
44660702
DM
279 },
280 "source" : {
281 "description" : "Restrict packet source address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
282 "format" : "pve-fw-addr-spec",
283 "optional" : 1,
013dc89f
DM
284 "type" : "string",
285 "typetext" : "<string>"
44660702
DM
286 },
287 "sport" : {
288 "description" : "Restrict TCP/UDP source port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
289 "format" : "pve-fw-sport-spec",
290 "optional" : 1,
013dc89f
DM
291 "type" : "string",
292 "typetext" : "<string>"
7aacca6f
DM
293 },
294 "type" : {
e94f0d56 295 "description" : "Rule type.",
7aacca6f
DM
296 "enum" : [
297 "in",
298 "out",
299 "group"
300 ],
301 "optional" : 1,
302 "type" : "string"
303 }
304 }
305 },
7aacca6f
DM
306 "permissions" : {
307 "check" : [
308 "perm",
309 "/",
310 [
311 "Sys.Modify"
312 ]
313 ]
314 },
44660702 315 "protected" : 1,
7aacca6f
DM
316 "proxyto" : null,
317 "returns" : {
318 "type" : "null"
319 }
7aacca6f
DM
320 }
321 },
44660702 322 "leaf" : 1,
7aacca6f 323 "path" : "/cluster/firewall/groups/{group}/{pos}",
44660702 324 "text" : "{pos}"
7aacca6f
DM
325 }
326 ],
44660702
DM
327 "info" : {
328 "DELETE" : {
329 "description" : "Delete security group.",
330 "method" : "DELETE",
331 "name" : "delete_security_group",
332 "parameters" : {
333 "additionalProperties" : 0,
334 "properties" : {
335 "group" : {
336 "description" : "Security Group name.",
4bd7df8b 337 "maxLength" : 18,
44660702
DM
338 "minLength" : 2,
339 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
340 "type" : "string"
341 }
56122987 342 }
7aacca6f 343 },
44660702
DM
344 "permissions" : {
345 "check" : [
346 "perm",
347 "/",
348 [
349 "Sys.Modify"
350 ]
7aacca6f 351 ]
56122987 352 },
44660702
DM
353 "protected" : 1,
354 "returns" : {
355 "type" : "null"
56122987 356 }
7aacca6f 357 },
7aacca6f 358 "GET" : {
44660702 359 "description" : "List rules.",
7aacca6f 360 "method" : "GET",
44660702
DM
361 "name" : "get_rules",
362 "parameters" : {
363 "additionalProperties" : 0,
7aacca6f 364 "properties" : {
44660702
DM
365 "group" : {
366 "description" : "Security Group name.",
4bd7df8b 367 "maxLength" : 18,
44660702
DM
368 "minLength" : 2,
369 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
370 "type" : "string"
7aacca6f 371 }
44660702 372 }
7aacca6f
DM
373 },
374 "permissions" : {
375 "check" : [
376 "perm",
377 "/",
378 [
379 "Sys.Audit"
380 ]
381 ]
382 },
44660702
DM
383 "proxyto" : null,
384 "returns" : {
385 "items" : {
386 "properties" : {
387 "pos" : {
388 "type" : "integer"
389 }
390 },
391 "type" : "object"
392 },
393 "links" : [
394 {
395 "href" : "{pos}",
396 "rel" : "child"
397 }
398 ],
399 "type" : "array"
400 }
401 },
402 "POST" : {
403 "description" : "Create new rule.",
404 "method" : "POST",
405 "name" : "create_rule",
7aacca6f
DM
406 "parameters" : {
407 "additionalProperties" : 0,
408 "properties" : {
44660702
DM
409 "action" : {
410 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
411 "maxLength" : 20,
56122987 412 "minLength" : 2,
44660702
DM
413 "optional" : 0,
414 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
7aacca6f 415 "type" : "string"
56122987 416 },
44660702 417 "comment" : {
e94f0d56 418 "description" : "Descriptive comment.",
56122987 419 "optional" : 1,
013dc89f
DM
420 "type" : "string",
421 "typetext" : "<string>"
56122987 422 },
44660702
DM
423 "dest" : {
424 "description" : "Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
56122987
DM
425 "format" : "pve-fw-addr-spec",
426 "optional" : 1,
013dc89f
DM
427 "type" : "string",
428 "typetext" : "<string>"
56122987 429 },
44660702
DM
430 "digest" : {
431 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
432 "maxLength" : 40,
7aacca6f 433 "optional" : 1,
013dc89f
DM
434 "type" : "string",
435 "typetext" : "<string>"
56122987 436 },
44660702
DM
437 "dport" : {
438 "description" : "Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
439 "format" : "pve-fw-dport-spec",
56122987 440 "optional" : 1,
013dc89f
DM
441 "type" : "string",
442 "typetext" : "<string>"
56122987 443 },
7aacca6f 444 "enable" : {
e94f0d56 445 "description" : "Flag to enable/disable a rule.",
44660702 446 "minimum" : 0,
7aacca6f 447 "optional" : 1,
4bd7df8b 448 "type" : "integer",
013dc89f 449 "typetext" : "<integer> (0 - N)"
56122987 450 },
44660702
DM
451 "group" : {
452 "description" : "Security Group name.",
4bd7df8b 453 "maxLength" : 18,
44660702 454 "minLength" : 2,
7aacca6f 455 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702
DM
456 "type" : "string"
457 },
458 "iface" : {
459 "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.",
460 "format" : "pve-iface",
461 "maxLength" : 20,
7aacca6f 462 "minLength" : 2,
44660702 463 "optional" : 1,
013dc89f
DM
464 "type" : "string",
465 "typetext" : "<string>"
56122987 466 },
7aacca6f 467 "macro" : {
e94f0d56 468 "description" : "Use predefined standard macro.",
44660702 469 "maxLength" : 128,
7aacca6f 470 "optional" : 1,
013dc89f
DM
471 "type" : "string",
472 "typetext" : "<string>"
7aacca6f
DM
473 },
474 "pos" : {
475 "description" : "Update rule at position <pos>.",
44660702 476 "minimum" : 0,
56122987 477 "optional" : 1,
4bd7df8b 478 "type" : "integer",
013dc89f 479 "typetext" : "<integer> (0 - N)"
7aacca6f
DM
480 },
481 "proto" : {
482 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
44660702 483 "format" : "pve-fw-protocol-spec",
7aacca6f 484 "optional" : 1,
013dc89f
DM
485 "type" : "string",
486 "typetext" : "<string>"
44660702
DM
487 },
488 "source" : {
489 "description" : "Restrict packet source address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
490 "format" : "pve-fw-addr-spec",
491 "optional" : 1,
013dc89f
DM
492 "type" : "string",
493 "typetext" : "<string>"
44660702
DM
494 },
495 "sport" : {
496 "description" : "Restrict TCP/UDP source port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
497 "format" : "pve-fw-sport-spec",
498 "optional" : 1,
013dc89f
DM
499 "type" : "string",
500 "typetext" : "<string>"
44660702
DM
501 },
502 "type" : {
e94f0d56 503 "description" : "Rule type.",
44660702
DM
504 "enum" : [
505 "in",
506 "out",
507 "group"
508 ],
509 "optional" : 0,
510 "type" : "string"
56122987 511 }
44660702 512 }
56122987 513 },
56122987
DM
514 "permissions" : {
515 "check" : [
516 "perm",
517 "/",
518 [
519 "Sys.Modify"
520 ]
521 ]
522 },
44660702
DM
523 "protected" : 1,
524 "proxyto" : null,
56122987
DM
525 "returns" : {
526 "type" : "null"
7aacca6f 527 }
44660702
DM
528 }
529 },
530 "leaf" : 0,
531 "path" : "/cluster/firewall/groups/{group}",
532 "text" : "{group}"
533 }
534 ],
535 "info" : {
536 "GET" : {
537 "description" : "List security groups.",
538 "method" : "GET",
539 "name" : "list_security_groups",
540 "parameters" : {
541 "additionalProperties" : 0
542 },
543 "permissions" : {
544 "user" : "all"
545 },
546 "returns" : {
547 "items" : {
548 "properties" : {
549 "comment" : {
550 "optional" : 1,
551 "type" : "string"
552 },
553 "digest" : {
554 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
555 "maxLength" : 40,
556 "optional" : 0,
557 "type" : "string"
558 },
559 "group" : {
560 "description" : "Security Group name.",
4bd7df8b 561 "maxLength" : 18,
44660702
DM
562 "minLength" : 2,
563 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
564 "type" : "string"
565 }
566 },
567 "type" : "object"
56122987 568 },
44660702
DM
569 "links" : [
570 {
571 "href" : "{group}",
572 "rel" : "child"
573 }
574 ],
575 "type" : "array"
576 }
577 },
578 "POST" : {
579 "description" : "Create new security group.",
580 "method" : "POST",
581 "name" : "create_security_group",
582 "parameters" : {
583 "additionalProperties" : 0,
584 "properties" : {
585 "comment" : {
586 "optional" : 1,
013dc89f
DM
587 "type" : "string",
588 "typetext" : "<string>"
44660702
DM
589 },
590 "digest" : {
591 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
592 "maxLength" : 40,
593 "optional" : 1,
013dc89f
DM
594 "type" : "string",
595 "typetext" : "<string>"
44660702
DM
596 },
597 "group" : {
598 "description" : "Security Group name.",
4bd7df8b 599 "maxLength" : 18,
44660702
DM
600 "minLength" : 2,
601 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
602 "type" : "string"
603 },
604 "rename" : {
605 "description" : "Rename/update an existing security group. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing group.",
4bd7df8b 606 "maxLength" : 18,
44660702
DM
607 "minLength" : 2,
608 "optional" : 1,
609 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
610 "type" : "string"
611 }
612 }
613 },
614 "permissions" : {
615 "check" : [
616 "perm",
617 "/",
618 [
619 "Sys.Modify"
620 ]
621 ]
622 },
623 "protected" : 1,
624 "returns" : {
625 "type" : "null"
626 }
627 }
628 },
629 "leaf" : 0,
630 "path" : "/cluster/firewall/groups",
631 "text" : "groups"
632 },
633 {
634 "children" : [
635 {
636 "info" : {
7aacca6f 637 "DELETE" : {
44660702
DM
638 "description" : "Delete rule.",
639 "method" : "DELETE",
640 "name" : "delete_rule",
641 "parameters" : {
642 "additionalProperties" : 0,
643 "properties" : {
644 "digest" : {
645 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
646 "maxLength" : 40,
647 "optional" : 1,
013dc89f
DM
648 "type" : "string",
649 "typetext" : "<string>"
44660702
DM
650 },
651 "pos" : {
652 "description" : "Update rule at position <pos>.",
653 "minimum" : 0,
654 "optional" : 1,
4bd7df8b 655 "type" : "integer",
013dc89f 656 "typetext" : "<integer> (0 - N)"
44660702
DM
657 }
658 }
659 },
56122987
DM
660 "permissions" : {
661 "check" : [
662 "perm",
663 "/",
664 [
7aacca6f 665 "Sys.Modify"
56122987
DM
666 ]
667 ]
668 },
44660702 669 "protected" : 1,
56122987
DM
670 "proxyto" : null,
671 "returns" : {
7aacca6f 672 "type" : "null"
44660702
DM
673 }
674 },
675 "GET" : {
676 "description" : "Get single rule data.",
677 "method" : "GET",
678 "name" : "get_rule",
56122987
DM
679 "parameters" : {
680 "additionalProperties" : 0,
681 "properties" : {
682 "pos" : {
7aacca6f 683 "description" : "Update rule at position <pos>.",
44660702 684 "minimum" : 0,
56122987 685 "optional" : 1,
4bd7df8b 686 "type" : "integer",
013dc89f 687 "typetext" : "<integer> (0 - N)"
7aacca6f
DM
688 }
689 }
690 },
7aacca6f
DM
691 "permissions" : {
692 "check" : [
693 "perm",
694 "/",
695 [
696 "Sys.Audit"
697 ]
698 ]
56122987 699 },
44660702
DM
700 "proxyto" : null,
701 "returns" : {
7aacca6f 702 "properties" : {
44660702
DM
703 "pos" : {
704 "type" : "integer"
7aacca6f 705 }
44660702
DM
706 },
707 "type" : "object"
708 }
56122987 709 },
44660702
DM
710 "PUT" : {
711 "description" : "Modify rule data.",
712 "method" : "PUT",
713 "name" : "update_rule",
7aacca6f
DM
714 "parameters" : {
715 "additionalProperties" : 0,
716 "properties" : {
44660702
DM
717 "action" : {
718 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
719 "maxLength" : 20,
720 "minLength" : 2,
721 "optional" : 1,
722 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
723 "type" : "string"
7aacca6f 724 },
44660702 725 "comment" : {
e94f0d56 726 "description" : "Descriptive comment.",
44660702 727 "optional" : 1,
013dc89f
DM
728 "type" : "string",
729 "typetext" : "<string>"
7aacca6f 730 },
44660702
DM
731 "delete" : {
732 "description" : "A list of settings you want to delete.",
733 "format" : "pve-configid-list",
734 "optional" : 1,
013dc89f
DM
735 "type" : "string",
736 "typetext" : "<string>"
44660702
DM
737 },
738 "dest" : {
739 "description" : "Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
740 "format" : "pve-fw-addr-spec",
741 "optional" : 1,
013dc89f
DM
742 "type" : "string",
743 "typetext" : "<string>"
44660702
DM
744 },
745 "digest" : {
746 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
747 "maxLength" : 40,
748 "optional" : 1,
013dc89f
DM
749 "type" : "string",
750 "typetext" : "<string>"
44660702
DM
751 },
752 "dport" : {
753 "description" : "Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
754 "format" : "pve-fw-dport-spec",
755 "optional" : 1,
013dc89f
DM
756 "type" : "string",
757 "typetext" : "<string>"
44660702
DM
758 },
759 "enable" : {
e94f0d56 760 "description" : "Flag to enable/disable a rule.",
44660702
DM
761 "minimum" : 0,
762 "optional" : 1,
4bd7df8b 763 "type" : "integer",
013dc89f 764 "typetext" : "<integer> (0 - N)"
44660702
DM
765 },
766 "iface" : {
767 "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.",
768 "format" : "pve-iface",
769 "maxLength" : 20,
7aacca6f 770 "minLength" : 2,
44660702 771 "optional" : 1,
013dc89f
DM
772 "type" : "string",
773 "typetext" : "<string>"
7aacca6f 774 },
44660702 775 "macro" : {
e94f0d56 776 "description" : "Use predefined standard macro.",
44660702
DM
777 "maxLength" : 128,
778 "optional" : 1,
013dc89f
DM
779 "type" : "string",
780 "typetext" : "<string>"
44660702
DM
781 },
782 "moveto" : {
783 "description" : "Move rule to new position <moveto>. Other arguments are ignored.",
784 "minimum" : 0,
785 "optional" : 1,
4bd7df8b 786 "type" : "integer",
013dc89f 787 "typetext" : "<integer> (0 - N)"
44660702
DM
788 },
789 "pos" : {
790 "description" : "Update rule at position <pos>.",
791 "minimum" : 0,
792 "optional" : 1,
4bd7df8b 793 "type" : "integer",
013dc89f 794 "typetext" : "<integer> (0 - N)"
44660702
DM
795 },
796 "proto" : {
797 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
798 "format" : "pve-fw-protocol-spec",
799 "optional" : 1,
013dc89f
DM
800 "type" : "string",
801 "typetext" : "<string>"
44660702
DM
802 },
803 "source" : {
804 "description" : "Restrict packet source address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
805 "format" : "pve-fw-addr-spec",
806 "optional" : 1,
013dc89f
DM
807 "type" : "string",
808 "typetext" : "<string>"
44660702
DM
809 },
810 "sport" : {
811 "description" : "Restrict TCP/UDP source port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
812 "format" : "pve-fw-sport-spec",
813 "optional" : 1,
013dc89f
DM
814 "type" : "string",
815 "typetext" : "<string>"
44660702
DM
816 },
817 "type" : {
e94f0d56 818 "description" : "Rule type.",
44660702
DM
819 "enum" : [
820 "in",
821 "out",
822 "group"
823 ],
824 "optional" : 1,
825 "type" : "string"
7aacca6f 826 }
56122987
DM
827 }
828 },
7aacca6f
DM
829 "permissions" : {
830 "check" : [
831 "perm",
832 "/",
833 [
834 "Sys.Modify"
835 ]
836 ]
837 },
44660702
DM
838 "protected" : 1,
839 "proxyto" : null,
840 "returns" : {
841 "type" : "null"
842 }
7aacca6f 843 }
56122987 844 },
44660702
DM
845 "leaf" : 1,
846 "path" : "/cluster/firewall/rules/{pos}",
847 "text" : "{pos}"
7aacca6f
DM
848 }
849 ],
7aacca6f 850 "info" : {
44660702
DM
851 "GET" : {
852 "description" : "List rules.",
853 "method" : "GET",
854 "name" : "get_rules",
7aacca6f 855 "parameters" : {
44660702 856 "additionalProperties" : 0
7aacca6f
DM
857 },
858 "permissions" : {
859 "check" : [
860 "perm",
861 "/",
862 [
44660702 863 "Sys.Audit"
7aacca6f
DM
864 ]
865 ]
866 },
44660702 867 "proxyto" : null,
7aacca6f 868 "returns" : {
7aacca6f
DM
869 "items" : {
870 "properties" : {
44660702
DM
871 "pos" : {
872 "type" : "integer"
7aacca6f
DM
873 }
874 },
875 "type" : "object"
56122987 876 },
7aacca6f
DM
877 "links" : [
878 {
44660702 879 "href" : "{pos}",
7aacca6f
DM
880 "rel" : "child"
881 }
44660702
DM
882 ],
883 "type" : "array"
7aacca6f 884 }
44660702 885 },
7aacca6f 886 "POST" : {
44660702 887 "description" : "Create new rule.",
7aacca6f 888 "method" : "POST",
44660702 889 "name" : "create_rule",
7aacca6f
DM
890 "parameters" : {
891 "additionalProperties" : 0,
892 "properties" : {
44660702
DM
893 "action" : {
894 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
895 "maxLength" : 20,
7aacca6f 896 "minLength" : 2,
44660702
DM
897 "optional" : 0,
898 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
899 "type" : "string"
7aacca6f
DM
900 },
901 "comment" : {
e94f0d56 902 "description" : "Descriptive comment.",
7aacca6f 903 "optional" : 1,
013dc89f
DM
904 "type" : "string",
905 "typetext" : "<string>"
44660702
DM
906 },
907 "dest" : {
908 "description" : "Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
909 "format" : "pve-fw-addr-spec",
910 "optional" : 1,
013dc89f
DM
911 "type" : "string",
912 "typetext" : "<string>"
44660702
DM
913 },
914 "digest" : {
915 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
916 "maxLength" : 40,
917 "optional" : 1,
013dc89f
DM
918 "type" : "string",
919 "typetext" : "<string>"
44660702
DM
920 },
921 "dport" : {
922 "description" : "Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
923 "format" : "pve-fw-dport-spec",
924 "optional" : 1,
013dc89f
DM
925 "type" : "string",
926 "typetext" : "<string>"
44660702
DM
927 },
928 "enable" : {
e94f0d56 929 "description" : "Flag to enable/disable a rule.",
44660702
DM
930 "minimum" : 0,
931 "optional" : 1,
4bd7df8b 932 "type" : "integer",
013dc89f 933 "typetext" : "<integer> (0 - N)"
44660702
DM
934 },
935 "iface" : {
936 "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.",
937 "format" : "pve-iface",
938 "maxLength" : 20,
939 "minLength" : 2,
940 "optional" : 1,
013dc89f
DM
941 "type" : "string",
942 "typetext" : "<string>"
44660702
DM
943 },
944 "macro" : {
e94f0d56 945 "description" : "Use predefined standard macro.",
44660702
DM
946 "maxLength" : 128,
947 "optional" : 1,
013dc89f
DM
948 "type" : "string",
949 "typetext" : "<string>"
44660702
DM
950 },
951 "pos" : {
952 "description" : "Update rule at position <pos>.",
953 "minimum" : 0,
954 "optional" : 1,
4bd7df8b 955 "type" : "integer",
013dc89f 956 "typetext" : "<integer> (0 - N)"
44660702
DM
957 },
958 "proto" : {
959 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
960 "format" : "pve-fw-protocol-spec",
961 "optional" : 1,
013dc89f
DM
962 "type" : "string",
963 "typetext" : "<string>"
44660702
DM
964 },
965 "source" : {
966 "description" : "Restrict packet source address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
967 "format" : "pve-fw-addr-spec",
968 "optional" : 1,
013dc89f
DM
969 "type" : "string",
970 "typetext" : "<string>"
44660702
DM
971 },
972 "sport" : {
973 "description" : "Restrict TCP/UDP source port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
974 "format" : "pve-fw-sport-spec",
975 "optional" : 1,
013dc89f
DM
976 "type" : "string",
977 "typetext" : "<string>"
44660702
DM
978 },
979 "type" : {
e94f0d56 980 "description" : "Rule type.",
44660702
DM
981 "enum" : [
982 "in",
983 "out",
984 "group"
985 ],
986 "optional" : 0,
987 "type" : "string"
7aacca6f
DM
988 }
989 }
990 },
991 "permissions" : {
992 "check" : [
993 "perm",
994 "/",
995 [
996 "Sys.Modify"
997 ]
998 ]
999 },
44660702
DM
1000 "protected" : 1,
1001 "proxyto" : null,
7aacca6f 1002 "returns" : {
44660702
DM
1003 "type" : "null"
1004 }
1005 }
1006 },
1007 "leaf" : 0,
1008 "path" : "/cluster/firewall/rules",
1009 "text" : "rules"
1010 },
1011 {
1012 "children" : [
1013 {
1014 "children" : [
1015 {
1016 "info" : {
1017 "DELETE" : {
1018 "description" : "Remove IP or Network from IPSet.",
1019 "method" : "DELETE",
1020 "name" : "remove_ip",
1021 "parameters" : {
1022 "additionalProperties" : 0,
1023 "properties" : {
1024 "cidr" : {
1025 "description" : "Network/IP specification in CIDR format.",
1026 "format" : "IPorCIDRorAlias",
013dc89f
DM
1027 "type" : "string",
1028 "typetext" : "<string>"
44660702
DM
1029 },
1030 "digest" : {
1031 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1032 "maxLength" : 40,
1033 "optional" : 1,
013dc89f
DM
1034 "type" : "string",
1035 "typetext" : "<string>"
44660702
DM
1036 },
1037 "name" : {
1038 "description" : "IP set name.",
1039 "maxLength" : 64,
1040 "minLength" : 2,
1041 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1042 "type" : "string"
1043 }
1044 }
1045 },
1046 "permissions" : {
1047 "check" : [
1048 "perm",
1049 "/",
1050 [
1051 "Sys.Modify"
1052 ]
1053 ]
1054 },
1055 "protected" : 1,
1056 "returns" : {
1057 "type" : "null"
1058 }
7aacca6f 1059 },
44660702
DM
1060 "GET" : {
1061 "description" : "Read IP or Network settings from IPSet.",
1062 "method" : "GET",
1063 "name" : "read_ip",
1064 "parameters" : {
1065 "additionalProperties" : 0,
1066 "properties" : {
1067 "cidr" : {
1068 "description" : "Network/IP specification in CIDR format.",
1069 "format" : "IPorCIDRorAlias",
013dc89f
DM
1070 "type" : "string",
1071 "typetext" : "<string>"
44660702
DM
1072 },
1073 "name" : {
1074 "description" : "IP set name.",
1075 "maxLength" : 64,
1076 "minLength" : 2,
1077 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1078 "type" : "string"
1079 }
1080 }
1081 },
1082 "permissions" : {
1083 "check" : [
1084 "perm",
1085 "/",
1086 [
1087 "Sys.Audit"
1088 ]
1089 ]
1090 },
1091 "protected" : 1,
1092 "returns" : {
1093 "type" : "object"
1094 }
7aacca6f 1095 },
44660702
DM
1096 "PUT" : {
1097 "description" : "Update IP or Network settings",
1098 "method" : "PUT",
1099 "name" : "update_ip",
1100 "parameters" : {
1101 "additionalProperties" : 0,
1102 "properties" : {
1103 "cidr" : {
1104 "description" : "Network/IP specification in CIDR format.",
1105 "format" : "IPorCIDRorAlias",
013dc89f
DM
1106 "type" : "string",
1107 "typetext" : "<string>"
44660702
DM
1108 },
1109 "comment" : {
1110 "optional" : 1,
013dc89f
DM
1111 "type" : "string",
1112 "typetext" : "<string>"
44660702
DM
1113 },
1114 "digest" : {
1115 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1116 "maxLength" : 40,
1117 "optional" : 1,
013dc89f
DM
1118 "type" : "string",
1119 "typetext" : "<string>"
44660702
DM
1120 },
1121 "name" : {
1122 "description" : "IP set name.",
1123 "maxLength" : 64,
1124 "minLength" : 2,
1125 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1126 "type" : "string"
1127 },
1128 "nomatch" : {
1129 "optional" : 1,
013dc89f
DM
1130 "type" : "boolean",
1131 "typetext" : "<boolean>"
44660702
DM
1132 }
1133 }
1134 },
1135 "permissions" : {
1136 "check" : [
1137 "perm",
1138 "/",
1139 [
1140 "Sys.Modify"
1141 ]
1142 ]
1143 },
1144 "protected" : 1,
1145 "returns" : {
1146 "type" : "null"
1147 }
7aacca6f
DM
1148 }
1149 },
44660702
DM
1150 "leaf" : 1,
1151 "path" : "/cluster/firewall/ipset/{name}/{cidr}",
1152 "text" : "{cidr}"
7aacca6f 1153 }
44660702 1154 ],
7aacca6f
DM
1155 "info" : {
1156 "DELETE" : {
44660702
DM
1157 "description" : "Delete IPSet",
1158 "method" : "DELETE",
1159 "name" : "delete_ipset",
56122987 1160 "parameters" : {
44660702 1161 "additionalProperties" : 0,
56122987
DM
1162 "properties" : {
1163 "name" : {
44660702 1164 "description" : "IP set name.",
56122987 1165 "maxLength" : 64,
44660702 1166 "minLength" : 2,
56122987 1167 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 1168 "type" : "string"
56122987 1169 }
44660702 1170 }
7aacca6f 1171 },
56122987
DM
1172 "permissions" : {
1173 "check" : [
1174 "perm",
1175 "/",
1176 [
1177 "Sys.Modify"
1178 ]
1179 ]
1180 },
7aacca6f
DM
1181 "protected" : 1,
1182 "returns" : {
1183 "type" : "null"
44660702 1184 }
7aacca6f 1185 },
44660702
DM
1186 "GET" : {
1187 "description" : "List IPSet content",
1188 "method" : "GET",
1189 "name" : "get_ipset",
56122987
DM
1190 "parameters" : {
1191 "additionalProperties" : 0,
1192 "properties" : {
7aacca6f 1193 "name" : {
44660702 1194 "description" : "IP set name.",
7aacca6f 1195 "maxLength" : 64,
7aacca6f 1196 "minLength" : 2,
44660702 1197 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
56122987 1198 "type" : "string"
56122987 1199 }
7aacca6f 1200 }
56122987 1201 },
56122987
DM
1202 "permissions" : {
1203 "check" : [
1204 "perm",
1205 "/",
1206 [
44660702 1207 "Sys.Audit"
56122987
DM
1208 ]
1209 ]
44660702
DM
1210 },
1211 "returns" : {
1212 "items" : {
1213 "properties" : {
1214 "cidr" : {
1215 "type" : "string"
1216 },
1217 "comment" : {
1218 "optional" : 1,
1219 "type" : "string"
1220 },
1221 "digest" : {
1222 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1223 "maxLength" : 40,
1224 "optional" : 0,
1225 "type" : "string"
1226 },
1227 "nomatch" : {
1228 "optional" : 1,
1229 "type" : "boolean"
1230 }
1231 },
1232 "type" : "object"
1233 },
1234 "links" : [
1235 {
1236 "href" : "{cidr}",
1237 "rel" : "child"
1238 }
1239 ],
1240 "type" : "array"
7aacca6f
DM
1241 }
1242 },
44660702
DM
1243 "POST" : {
1244 "description" : "Add IP or Network to IPSet.",
1245 "method" : "POST",
1246 "name" : "create_ip",
56122987
DM
1247 "parameters" : {
1248 "additionalProperties" : 0,
1249 "properties" : {
44660702
DM
1250 "cidr" : {
1251 "description" : "Network/IP specification in CIDR format.",
1252 "format" : "IPorCIDRorAlias",
013dc89f
DM
1253 "type" : "string",
1254 "typetext" : "<string>"
44660702
DM
1255 },
1256 "comment" : {
1257 "optional" : 1,
013dc89f
DM
1258 "type" : "string",
1259 "typetext" : "<string>"
44660702
DM
1260 },
1261 "name" : {
1262 "description" : "IP set name.",
1263 "maxLength" : 64,
1264 "minLength" : 2,
1265 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1266 "type" : "string"
1267 },
1268 "nomatch" : {
1269 "optional" : 1,
013dc89f
DM
1270 "type" : "boolean",
1271 "typetext" : "<boolean>"
56122987
DM
1272 }
1273 }
1274 },
56122987
DM
1275 "permissions" : {
1276 "check" : [
1277 "perm",
1278 "/",
1279 [
44660702 1280 "Sys.Modify"
56122987
DM
1281 ]
1282 ]
1283 },
44660702 1284 "protected" : 1,
56122987 1285 "returns" : {
44660702
DM
1286 "type" : "null"
1287 }
56122987
DM
1288 }
1289 },
44660702
DM
1290 "leaf" : 0,
1291 "path" : "/cluster/firewall/ipset/{name}",
1292 "text" : "{name}"
56122987
DM
1293 }
1294 ],
56122987 1295 "info" : {
44660702
DM
1296 "GET" : {
1297 "description" : "List IPSets",
1298 "method" : "GET",
1299 "name" : "ipset_index",
56122987 1300 "parameters" : {
7aacca6f 1301 "additionalProperties" : 0
56122987 1302 },
56122987
DM
1303 "permissions" : {
1304 "check" : [
1305 "perm",
1306 "/",
1307 [
7aacca6f 1308 "Sys.Audit"
56122987
DM
1309 ]
1310 ]
1311 },
56122987
DM
1312 "returns" : {
1313 "items" : {
1314 "properties" : {
44660702
DM
1315 "comment" : {
1316 "optional" : 1,
1317 "type" : "string"
56122987 1318 },
44660702
DM
1319 "digest" : {
1320 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1321 "maxLength" : 40,
1322 "optional" : 0,
1323 "type" : "string"
1324 },
1325 "name" : {
1326 "description" : "IP set name.",
1327 "maxLength" : 64,
1328 "minLength" : 2,
1329 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
7aacca6f 1330 "type" : "string"
56122987
DM
1331 }
1332 },
1333 "type" : "object"
44660702
DM
1334 },
1335 "links" : [
1336 {
1337 "href" : "{name}",
1338 "rel" : "child"
1339 }
1340 ],
1341 "type" : "array"
56122987 1342 }
44660702
DM
1343 },
1344 "POST" : {
1345 "description" : "Create new IPSet",
1346 "method" : "POST",
1347 "name" : "create_ipset",
7aacca6f
DM
1348 "parameters" : {
1349 "additionalProperties" : 0,
1350 "properties" : {
44660702
DM
1351 "comment" : {
1352 "optional" : 1,
013dc89f
DM
1353 "type" : "string",
1354 "typetext" : "<string>"
44660702
DM
1355 },
1356 "digest" : {
1357 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1358 "maxLength" : 40,
1359 "optional" : 1,
013dc89f
DM
1360 "type" : "string",
1361 "typetext" : "<string>"
44660702
DM
1362 },
1363 "name" : {
1364 "description" : "IP set name.",
1365 "maxLength" : 64,
1366 "minLength" : 2,
1367 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1368 "type" : "string"
1369 },
1370 "rename" : {
1371 "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.",
1372 "maxLength" : 64,
1373 "minLength" : 2,
1374 "optional" : 1,
1375 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1376 "type" : "string"
7aacca6f
DM
1377 }
1378 }
1379 },
56122987
DM
1380 "permissions" : {
1381 "check" : [
1382 "perm",
1383 "/",
1384 [
44660702 1385 "Sys.Modify"
56122987
DM
1386 ]
1387 ]
1388 },
44660702 1389 "protected" : 1,
56122987 1390 "returns" : {
44660702
DM
1391 "type" : "null"
1392 }
56122987 1393 }
7aacca6f 1394 },
44660702
DM
1395 "leaf" : 0,
1396 "path" : "/cluster/firewall/ipset",
1397 "text" : "ipset"
1398 },
56122987 1399 {
44660702
DM
1400 "children" : [
1401 {
1402 "info" : {
1403 "DELETE" : {
1404 "description" : "Remove IP or Network alias.",
1405 "method" : "DELETE",
1406 "name" : "remove_alias",
1407 "parameters" : {
1408 "additionalProperties" : 0,
1409 "properties" : {
1410 "digest" : {
1411 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1412 "maxLength" : 40,
1413 "optional" : 1,
013dc89f
DM
1414 "type" : "string",
1415 "typetext" : "<string>"
44660702
DM
1416 },
1417 "name" : {
1418 "description" : "Alias name.",
1419 "maxLength" : 64,
1420 "minLength" : 2,
1421 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1422 "type" : "string"
1423 }
1424 }
1425 },
1426 "permissions" : {
1427 "check" : [
1428 "perm",
1429 "/",
1430 [
1431 "Sys.Modify"
1432 ]
1433 ]
1434 },
1435 "protected" : 1,
1436 "returns" : {
1437 "type" : "null"
1438 }
1439 },
1440 "GET" : {
1441 "description" : "Read alias.",
1442 "method" : "GET",
1443 "name" : "read_alias",
1444 "parameters" : {
1445 "additionalProperties" : 0,
1446 "properties" : {
1447 "name" : {
1448 "description" : "Alias name.",
1449 "maxLength" : 64,
1450 "minLength" : 2,
1451 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1452 "type" : "string"
1453 }
1454 }
1455 },
1456 "permissions" : {
1457 "check" : [
1458 "perm",
1459 "/",
1460 [
1461 "Sys.Audit"
1462 ]
1463 ]
1464 },
1465 "returns" : {
1466 "type" : "object"
1467 }
1468 },
1469 "PUT" : {
1470 "description" : "Update IP or Network alias.",
1471 "method" : "PUT",
1472 "name" : "update_alias",
1473 "parameters" : {
1474 "additionalProperties" : 0,
1475 "properties" : {
1476 "cidr" : {
1477 "description" : "Network/IP specification in CIDR format.",
1478 "format" : "IPorCIDR",
013dc89f
DM
1479 "type" : "string",
1480 "typetext" : "<string>"
44660702
DM
1481 },
1482 "comment" : {
1483 "optional" : 1,
013dc89f
DM
1484 "type" : "string",
1485 "typetext" : "<string>"
44660702
DM
1486 },
1487 "digest" : {
1488 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1489 "maxLength" : 40,
1490 "optional" : 1,
013dc89f
DM
1491 "type" : "string",
1492 "typetext" : "<string>"
44660702
DM
1493 },
1494 "name" : {
1495 "description" : "Alias name.",
1496 "maxLength" : 64,
1497 "minLength" : 2,
1498 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1499 "type" : "string"
1500 },
1501 "rename" : {
1502 "description" : "Rename an existing alias.",
1503 "maxLength" : 64,
1504 "minLength" : 2,
1505 "optional" : 1,
1506 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1507 "type" : "string"
1508 }
1509 }
1510 },
1511 "permissions" : {
1512 "check" : [
1513 "perm",
1514 "/",
1515 [
1516 "Sys.Modify"
1517 ]
1518 ]
1519 },
1520 "protected" : 1,
1521 "returns" : {
1522 "type" : "null"
1523 }
1524 }
1525 },
1526 "leaf" : 1,
1527 "path" : "/cluster/firewall/aliases/{name}",
1528 "text" : "{name}"
1529 }
1530 ],
1531 "info" : {
1532 "GET" : {
1533 "description" : "List aliases",
1534 "method" : "GET",
1535 "name" : "get_aliases",
1536 "parameters" : {
1537 "additionalProperties" : 0
1538 },
1539 "permissions" : {
1540 "check" : [
1541 "perm",
1542 "/",
1543 [
1544 "Sys.Audit"
1545 ]
1546 ]
1547 },
1548 "returns" : {
1549 "items" : {
1550 "properties" : {
1551 "cidr" : {
1552 "type" : "string"
1553 },
1554 "comment" : {
1555 "optional" : 1,
1556 "type" : "string"
1557 },
1558 "digest" : {
1559 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1560 "maxLength" : 40,
1561 "optional" : 0,
1562 "type" : "string"
1563 },
1564 "name" : {
1565 "type" : "string"
1566 }
1567 },
1568 "type" : "object"
1569 },
1570 "links" : [
1571 {
1572 "href" : "{name}",
1573 "rel" : "child"
1574 }
1575 ],
1576 "type" : "array"
1577 }
1578 },
1579 "POST" : {
1580 "description" : "Create IP or Network Alias.",
1581 "method" : "POST",
1582 "name" : "create_alias",
56122987
DM
1583 "parameters" : {
1584 "additionalProperties" : 0,
1585 "properties" : {
44660702
DM
1586 "cidr" : {
1587 "description" : "Network/IP specification in CIDR format.",
1588 "format" : "IPorCIDR",
013dc89f
DM
1589 "type" : "string",
1590 "typetext" : "<string>"
44660702
DM
1591 },
1592 "comment" : {
1593 "optional" : 1,
013dc89f
DM
1594 "type" : "string",
1595 "typetext" : "<string>"
44660702
DM
1596 },
1597 "name" : {
1598 "description" : "Alias name.",
1599 "maxLength" : 64,
1600 "minLength" : 2,
1601 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1602 "type" : "string"
56122987
DM
1603 }
1604 }
1605 },
56122987
DM
1606 "permissions" : {
1607 "check" : [
1608 "perm",
1609 "/",
1610 [
1611 "Sys.Modify"
1612 ]
1613 ]
1614 },
44660702 1615 "protected" : 1,
56122987
DM
1616 "returns" : {
1617 "type" : "null"
1618 }
44660702
DM
1619 }
1620 },
1621 "leaf" : 0,
1622 "path" : "/cluster/firewall/aliases",
1623 "text" : "aliases"
1624 },
1625 {
1626 "info" : {
1627 "GET" : {
1628 "description" : "Get Firewall options.",
1629 "method" : "GET",
1630 "name" : "get_options",
1631 "parameters" : {
1632 "additionalProperties" : 0
7aacca6f 1633 },
56122987
DM
1634 "permissions" : {
1635 "check" : [
1636 "perm",
1637 "/",
1638 [
44660702 1639 "Sys.Audit"
56122987
DM
1640 ]
1641 ]
1642 },
44660702 1643 "returns" : {
56122987 1644 "properties" : {
44660702
DM
1645 "enable" : {
1646 "description" : "Enable or disable the firewall cluster wide.",
1647 "minimum" : 0,
56122987 1648 "optional" : 1,
7aacca6f 1649 "type" : "integer"
56122987 1650 },
44660702
DM
1651 "policy_in" : {
1652 "description" : "Input policy.",
1653 "enum" : [
1654 "ACCEPT",
1655 "REJECT",
1656 "DROP"
1657 ],
56122987 1658 "optional" : 1,
44660702 1659 "type" : "string"
7aacca6f 1660 },
44660702
DM
1661 "policy_out" : {
1662 "description" : "Output policy.",
1663 "enum" : [
1664 "ACCEPT",
1665 "REJECT",
1666 "DROP"
1667 ],
7aacca6f 1668 "optional" : 1,
44660702
DM
1669 "type" : "string"
1670 }
1671 },
1672 "type" : "object"
1673 }
1674 },
1675 "PUT" : {
1676 "description" : "Set Firewall options.",
1677 "method" : "PUT",
1678 "name" : "set_options",
1679 "parameters" : {
1680 "additionalProperties" : 0,
1681 "properties" : {
1682 "delete" : {
1683 "description" : "A list of settings you want to delete.",
1684 "format" : "pve-configid-list",
56122987 1685 "optional" : 1,
013dc89f
DM
1686 "type" : "string",
1687 "typetext" : "<string>"
56122987 1688 },
44660702
DM
1689 "digest" : {
1690 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1691 "maxLength" : 40,
56122987 1692 "optional" : 1,
013dc89f
DM
1693 "type" : "string",
1694 "typetext" : "<string>"
56122987 1695 },
44660702
DM
1696 "enable" : {
1697 "description" : "Enable or disable the firewall cluster wide.",
7aacca6f 1698 "minimum" : 0,
56122987 1699 "optional" : 1,
4bd7df8b 1700 "type" : "integer",
013dc89f 1701 "typetext" : "<integer> (0 - N)"
56122987 1702 },
44660702
DM
1703 "policy_in" : {
1704 "description" : "Input policy.",
56122987 1705 "enum" : [
44660702
DM
1706 "ACCEPT",
1707 "REJECT",
1708 "DROP"
56122987 1709 ],
56122987 1710 "optional" : 1,
44660702 1711 "type" : "string"
56122987 1712 },
44660702
DM
1713 "policy_out" : {
1714 "description" : "Output policy.",
56122987 1715 "enum" : [
44660702
DM
1716 "ACCEPT",
1717 "REJECT",
1718 "DROP"
56122987 1719 ],
7aacca6f 1720 "optional" : 1,
44660702 1721 "type" : "string"
56122987 1722 }
44660702
DM
1723 }
1724 },
1725 "permissions" : {
1726 "check" : [
1727 "perm",
1728 "/",
1729 [
1730 "Sys.Modify"
1731 ]
1732 ]
7aacca6f
DM
1733 },
1734 "protected" : 1,
44660702
DM
1735 "returns" : {
1736 "type" : "null"
1737 }
1738 }
1739 },
1740 "leaf" : 1,
1741 "path" : "/cluster/firewall/options",
1742 "text" : "options"
1743 },
1744 {
1745 "info" : {
7aacca6f 1746 "GET" : {
44660702 1747 "description" : "List available macros",
7aacca6f 1748 "method" : "GET",
44660702
DM
1749 "name" : "get_macros",
1750 "parameters" : {
1751 "additionalProperties" : 0
7aacca6f 1752 },
44660702
DM
1753 "permissions" : {
1754 "user" : "all"
1755 },
1756 "returns" : {
1757 "items" : {
1758 "properties" : {
1759 "descr" : {
1760 "description" : "More verbose description (if available).",
1761 "type" : "string"
1762 },
1763 "macro" : {
1764 "description" : "Macro name.",
1765 "type" : "string"
1766 }
1767 },
1768 "type" : "object"
1769 },
1770 "type" : "array"
1771 }
1772 }
1773 },
1774 "leaf" : 1,
1775 "path" : "/cluster/firewall/macros",
1776 "text" : "macros"
1777 },
1778 {
1779 "info" : {
1780 "GET" : {
1781 "description" : "Lists possible IPSet/Alias reference which are allowed in source/dest properties.",
1782 "method" : "GET",
1783 "name" : "refs",
7aacca6f 1784 "parameters" : {
44660702 1785 "additionalProperties" : 0,
7aacca6f 1786 "properties" : {
44660702
DM
1787 "type" : {
1788 "description" : "Only list references of specified type.",
1789 "enum" : [
1790 "alias",
1791 "ipset"
1792 ],
1793 "optional" : 1,
1794 "type" : "string"
7aacca6f 1795 }
44660702 1796 }
7aacca6f
DM
1797 },
1798 "permissions" : {
1799 "check" : [
1800 "perm",
1801 "/",
1802 [
1803 "Sys.Audit"
1804 ]
1805 ]
1806 },
44660702
DM
1807 "returns" : {
1808 "items" : {
1809 "properties" : {
1810 "comment" : {
1811 "optional" : 1,
1812 "type" : "string"
1813 },
1814 "name" : {
1815 "type" : "string"
1816 },
1817 "ref" : {
1818 "type" : "string"
1819 },
1820 "type" : {
1821 "enum" : [
1822 "alias",
1823 "ipset"
1824 ],
1825 "type" : "string"
1826 }
1827 },
1828 "type" : "object"
1829 },
1830 "type" : "array"
1831 }
56122987
DM
1832 }
1833 },
7aacca6f 1834 "leaf" : 1,
44660702
DM
1835 "path" : "/cluster/firewall/refs",
1836 "text" : "refs"
56122987
DM
1837 }
1838 ],
56122987 1839 "info" : {
44660702
DM
1840 "GET" : {
1841 "description" : "Directory index.",
1842 "method" : "GET",
1843 "name" : "index",
56122987 1844 "parameters" : {
56122987
DM
1845 "additionalProperties" : 0
1846 },
44660702
DM
1847 "permissions" : {
1848 "user" : "all"
1849 },
56122987 1850 "returns" : {
44660702
DM
1851 "items" : {
1852 "properties" : {},
1853 "type" : "object"
1854 },
7aacca6f
DM
1855 "links" : [
1856 {
44660702
DM
1857 "href" : "{name}",
1858 "rel" : "child"
7aacca6f
DM
1859 }
1860 ],
7aacca6f 1861 "type" : "array"
7aacca6f 1862 }
56122987
DM
1863 }
1864 },
44660702
DM
1865 "leaf" : 0,
1866 "path" : "/cluster/firewall",
1867 "text" : "firewall"
7aacca6f
DM
1868 },
1869 {
56122987
DM
1870 "children" : [
1871 {
56122987 1872 "info" : {
44660702
DM
1873 "DELETE" : {
1874 "description" : "Delete vzdump backup job definition.",
1875 "method" : "DELETE",
1876 "name" : "delete_job",
1877 "parameters" : {
1878 "additionalProperties" : 0,
1879 "properties" : {
1880 "id" : {
1881 "description" : "The job ID.",
1882 "maxLength" : 50,
013dc89f
DM
1883 "type" : "string",
1884 "typetext" : "<string>"
44660702
DM
1885 }
1886 }
1887 },
1888 "permissions" : {
1889 "check" : [
1890 "perm",
1891 "/",
1892 [
1893 "Sys.Modify"
1894 ]
1895 ]
1896 },
1897 "protected" : 1,
56122987
DM
1898 "returns" : {
1899 "type" : "null"
44660702
DM
1900 }
1901 },
1902 "GET" : {
1903 "description" : "Read vzdump backup job definition.",
1904 "method" : "GET",
1905 "name" : "read_job",
1906 "parameters" : {
1907 "additionalProperties" : 0,
1908 "properties" : {
1909 "id" : {
1910 "description" : "The job ID.",
1911 "maxLength" : 50,
013dc89f
DM
1912 "type" : "string",
1913 "typetext" : "<string>"
44660702
DM
1914 }
1915 }
56122987 1916 },
7aacca6f
DM
1917 "permissions" : {
1918 "check" : [
1919 "perm",
1920 "/",
1921 [
44660702 1922 "Sys.Audit"
7aacca6f
DM
1923 ]
1924 ]
1925 },
44660702
DM
1926 "returns" : {
1927 "type" : "object"
1928 }
1929 },
1930 "PUT" : {
1931 "description" : "Update vzdump backup job definition.",
1932 "method" : "PUT",
1933 "name" : "update_job",
56122987 1934 "parameters" : {
44660702 1935 "additionalProperties" : 0,
56122987 1936 "properties" : {
44660702
DM
1937 "all" : {
1938 "default" : 0,
1939 "description" : "Backup all known guest systems on this host.",
7aacca6f 1940 "optional" : 1,
013dc89f
DM
1941 "type" : "boolean",
1942 "typetext" : "<boolean>"
7aacca6f 1943 },
44660702
DM
1944 "bwlimit" : {
1945 "default" : 0,
1946 "description" : "Limit I/O bandwidth (KBytes per second).",
1947 "minimum" : 0,
1948 "optional" : 1,
4bd7df8b 1949 "type" : "integer",
013dc89f 1950 "typetext" : "<integer> (0 - N)"
44660702
DM
1951 },
1952 "compress" : {
1953 "default" : "0",
1954 "description" : "Compress dump file.",
7aacca6f 1955 "enum" : [
44660702
DM
1956 "0",
1957 "1",
1958 "gzip",
1959 "lzo"
7aacca6f 1960 ],
44660702
DM
1961 "optional" : 1,
1962 "type" : "string"
7aacca6f 1963 },
44660702
DM
1964 "delete" : {
1965 "description" : "A list of settings you want to delete.",
1966 "format" : "pve-configid-list",
7aacca6f 1967 "optional" : 1,
013dc89f
DM
1968 "type" : "string",
1969 "typetext" : "<string>"
56122987 1970 },
44660702
DM
1971 "dow" : {
1972 "description" : "Day of week selection.",
1973 "format" : "pve-day-of-week-list",
7aacca6f 1974 "optional" : 1,
013dc89f
DM
1975 "type" : "string",
1976 "typetext" : "<string>"
56122987 1977 },
44660702
DM
1978 "dumpdir" : {
1979 "description" : "Store resulting files to specified directory.",
56122987 1980 "optional" : 1,
013dc89f
DM
1981 "type" : "string",
1982 "typetext" : "<string>"
56122987 1983 },
44660702
DM
1984 "enabled" : {
1985 "default" : "1",
1986 "description" : "Enable or disable the job.",
1987 "optional" : 1,
013dc89f
DM
1988 "type" : "boolean",
1989 "typetext" : "<boolean>"
44660702
DM
1990 },
1991 "exclude" : {
1992 "description" : "Exclude specified guest systems (assumes --all)",
1993 "format" : "pve-vmid-list",
1994 "optional" : 1,
013dc89f
DM
1995 "type" : "string",
1996 "typetext" : "<string>"
44660702
DM
1997 },
1998 "exclude-path" : {
1999 "description" : "Exclude certain files/directories (shell globs).",
2000 "format" : "string-alist",
2001 "optional" : 1,
013dc89f
DM
2002 "type" : "string",
2003 "typetext" : "<string>"
44660702
DM
2004 },
2005 "id" : {
2006 "description" : "The job ID.",
2007 "maxLength" : 50,
013dc89f
DM
2008 "type" : "string",
2009 "typetext" : "<string>"
44660702
DM
2010 },
2011 "ionice" : {
2012 "default" : 7,
2013 "description" : "Set CFQ ionice priority.",
2014 "maximum" : 8,
2015 "minimum" : 0,
2016 "optional" : 1,
4bd7df8b 2017 "type" : "integer",
013dc89f 2018 "typetext" : "<integer> (0 - 8)"
44660702
DM
2019 },
2020 "lockwait" : {
2021 "default" : 180,
2022 "description" : "Maximal time to wait for the global lock (minutes).",
2023 "minimum" : 0,
2024 "optional" : 1,
4bd7df8b 2025 "type" : "integer",
013dc89f 2026 "typetext" : "<integer> (0 - N)"
44660702
DM
2027 },
2028 "mailnotification" : {
2029 "default" : "always",
2030 "description" : "Specify when to send an email",
56122987 2031 "enum" : [
44660702
DM
2032 "always",
2033 "failure"
56122987 2034 ],
44660702
DM
2035 "optional" : 1,
2036 "type" : "string"
2037 },
2038 "mailto" : {
2039 "description" : "Comma-separated list of email addresses that should receive email notifications.",
2040 "format" : "string-list",
2041 "optional" : 1,
013dc89f
DM
2042 "type" : "string",
2043 "typetext" : "<string>"
44660702
DM
2044 },
2045 "maxfiles" : {
2046 "default" : 1,
2047 "description" : "Maximal number of backup files per guest system.",
2048 "minimum" : 1,
2049 "optional" : 1,
4bd7df8b 2050 "type" : "integer",
013dc89f 2051 "typetext" : "<integer> (1 - N)"
44660702
DM
2052 },
2053 "mode" : {
2054 "default" : "snapshot",
2055 "description" : "Backup mode.",
2056 "enum" : [
2057 "snapshot",
2058 "suspend",
2059 "stop"
2060 ],
2061 "optional" : 1,
2062 "type" : "string"
2063 },
2064 "node" : {
2065 "description" : "Only run if executed on this node.",
2066 "format" : "pve-node",
2067 "optional" : 1,
013dc89f
DM
2068 "type" : "string",
2069 "typetext" : "<string>"
44660702
DM
2070 },
2071 "pigz" : {
2072 "default" : 0,
2073 "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count.",
2074 "optional" : 1,
013dc89f
DM
2075 "type" : "integer",
2076 "typetext" : "<integer>"
44660702
DM
2077 },
2078 "quiet" : {
2079 "default" : 0,
2080 "description" : "Be quiet.",
2081 "optional" : 1,
013dc89f
DM
2082 "type" : "boolean",
2083 "typetext" : "<boolean>"
44660702
DM
2084 },
2085 "remove" : {
2086 "default" : 1,
2087 "description" : "Remove old backup files if there are more than 'maxfiles' backup files.",
2088 "optional" : 1,
013dc89f
DM
2089 "type" : "boolean",
2090 "typetext" : "<boolean>"
44660702
DM
2091 },
2092 "script" : {
2093 "description" : "Use specified hook script.",
2094 "optional" : 1,
013dc89f
DM
2095 "type" : "string",
2096 "typetext" : "<string>"
44660702
DM
2097 },
2098 "size" : {
2099 "default" : 1024,
2100 "description" : "Unused, will be removed in a future release.",
2101 "minimum" : 500,
2102 "optional" : 1,
4bd7df8b 2103 "type" : "integer",
013dc89f 2104 "typetext" : "<integer> (500 - N)"
44660702
DM
2105 },
2106 "starttime" : {
2107 "description" : "Job Start time.",
2108 "pattern" : "\\d{1,2}:\\d{1,2}",
56122987 2109 "type" : "string",
44660702 2110 "typetext" : "HH:MM"
7aacca6f 2111 },
44660702
DM
2112 "stdexcludes" : {
2113 "default" : 1,
2114 "description" : "Exclude temporary files and logs.",
2115 "optional" : 1,
013dc89f
DM
2116 "type" : "boolean",
2117 "typetext" : "<boolean>"
44660702
DM
2118 },
2119 "stop" : {
2120 "default" : 0,
2121 "description" : "Stop runnig backup jobs on this host.",
2122 "optional" : 1,
013dc89f
DM
2123 "type" : "boolean",
2124 "typetext" : "<boolean>"
44660702
DM
2125 },
2126 "stopwait" : {
2127 "default" : 10,
2128 "description" : "Maximal time to wait until a guest system is stopped (minutes).",
2129 "minimum" : 0,
2130 "optional" : 1,
4bd7df8b 2131 "type" : "integer",
013dc89f 2132 "typetext" : "<integer> (0 - N)"
44660702
DM
2133 },
2134 "storage" : {
2135 "description" : "Store resulting file to this storage.",
2136 "format" : "pve-storage-id",
2137 "optional" : 1,
013dc89f
DM
2138 "type" : "string",
2139 "typetext" : "<string>"
56122987 2140 },
44660702
DM
2141 "tmpdir" : {
2142 "description" : "Store temporary files to specified directory.",
2143 "optional" : 1,
013dc89f
DM
2144 "type" : "string",
2145 "typetext" : "<string>"
44660702
DM
2146 },
2147 "vmid" : {
2148 "description" : "The ID of the guest system you want to backup.",
2149 "format" : "pve-vmid-list",
2150 "optional" : 1,
013dc89f
DM
2151 "type" : "string",
2152 "typetext" : "<string>"
56122987 2153 }
44660702 2154 }
56122987
DM
2155 },
2156 "permissions" : {
2157 "check" : [
2158 "perm",
2159 "/",
2160 [
44660702 2161 "Sys.Modify"
56122987
DM
2162 ]
2163 ]
2164 },
44660702
DM
2165 "protected" : 1,
2166 "returns" : {
2167 "type" : "null"
7aacca6f 2168 }
56122987
DM
2169 }
2170 },
44660702
DM
2171 "leaf" : 1,
2172 "path" : "/cluster/backup/{id}",
2173 "text" : "{id}"
2174 }
2175 ],
2176 "info" : {
2177 "GET" : {
2178 "description" : "List vzdump backup schedule.",
2179 "method" : "GET",
2180 "name" : "index",
2181 "parameters" : {
2182 "additionalProperties" : 0
2183 },
2184 "permissions" : {
2185 "check" : [
2186 "perm",
2187 "/",
2188 [
2189 "Sys.Audit"
2190 ]
2191 ]
2192 },
2193 "returns" : {
2194 "items" : {
2195 "properties" : {
2196 "id" : {
2197 "type" : "string"
2198 }
2199 },
2200 "type" : "object"
2201 },
2202 "links" : [
2203 {
2204 "href" : "{id}",
2205 "rel" : "child"
2206 }
2207 ],
2208 "type" : "array"
2209 }
2210 },
2211 "POST" : {
2212 "description" : "Create new vzdump backup job.",
2213 "method" : "POST",
2214 "name" : "create_job",
2215 "parameters" : {
2216 "additionalProperties" : 0,
2217 "properties" : {
2218 "all" : {
2219 "default" : 0,
2220 "description" : "Backup all known guest systems on this host.",
2221 "optional" : 1,
013dc89f
DM
2222 "type" : "boolean",
2223 "typetext" : "<boolean>"
44660702
DM
2224 },
2225 "bwlimit" : {
2226 "default" : 0,
2227 "description" : "Limit I/O bandwidth (KBytes per second).",
2228 "minimum" : 0,
2229 "optional" : 1,
4bd7df8b 2230 "type" : "integer",
013dc89f 2231 "typetext" : "<integer> (0 - N)"
44660702
DM
2232 },
2233 "compress" : {
2234 "default" : "0",
2235 "description" : "Compress dump file.",
2236 "enum" : [
2237 "0",
2238 "1",
2239 "gzip",
2240 "lzo"
2241 ],
2242 "optional" : 1,
2243 "type" : "string"
2244 },
2245 "dow" : {
2246 "default" : "mon,tue,wed,thu,fri,sat,sun",
2247 "description" : "Day of week selection.",
2248 "format" : "pve-day-of-week-list",
2249 "optional" : 1,
013dc89f
DM
2250 "type" : "string",
2251 "typetext" : "<string>"
44660702
DM
2252 },
2253 "dumpdir" : {
2254 "description" : "Store resulting files to specified directory.",
2255 "optional" : 1,
013dc89f
DM
2256 "type" : "string",
2257 "typetext" : "<string>"
44660702
DM
2258 },
2259 "enabled" : {
2260 "default" : "1",
2261 "description" : "Enable or disable the job.",
2262 "optional" : 1,
013dc89f
DM
2263 "type" : "boolean",
2264 "typetext" : "<boolean>"
44660702
DM
2265 },
2266 "exclude" : {
2267 "description" : "Exclude specified guest systems (assumes --all)",
2268 "format" : "pve-vmid-list",
2269 "optional" : 1,
013dc89f
DM
2270 "type" : "string",
2271 "typetext" : "<string>"
44660702
DM
2272 },
2273 "exclude-path" : {
2274 "description" : "Exclude certain files/directories (shell globs).",
2275 "format" : "string-alist",
2276 "optional" : 1,
013dc89f
DM
2277 "type" : "string",
2278 "typetext" : "<string>"
44660702
DM
2279 },
2280 "ionice" : {
2281 "default" : 7,
2282 "description" : "Set CFQ ionice priority.",
2283 "maximum" : 8,
2284 "minimum" : 0,
2285 "optional" : 1,
4bd7df8b 2286 "type" : "integer",
013dc89f 2287 "typetext" : "<integer> (0 - 8)"
44660702
DM
2288 },
2289 "lockwait" : {
2290 "default" : 180,
2291 "description" : "Maximal time to wait for the global lock (minutes).",
2292 "minimum" : 0,
2293 "optional" : 1,
4bd7df8b 2294 "type" : "integer",
013dc89f 2295 "typetext" : "<integer> (0 - N)"
44660702
DM
2296 },
2297 "mailnotification" : {
2298 "default" : "always",
2299 "description" : "Specify when to send an email",
2300 "enum" : [
2301 "always",
2302 "failure"
2303 ],
2304 "optional" : 1,
2305 "type" : "string"
2306 },
2307 "mailto" : {
2308 "description" : "Comma-separated list of email addresses that should receive email notifications.",
2309 "format" : "string-list",
2310 "optional" : 1,
013dc89f
DM
2311 "type" : "string",
2312 "typetext" : "<string>"
44660702
DM
2313 },
2314 "maxfiles" : {
2315 "default" : 1,
2316 "description" : "Maximal number of backup files per guest system.",
2317 "minimum" : 1,
2318 "optional" : 1,
4bd7df8b 2319 "type" : "integer",
013dc89f 2320 "typetext" : "<integer> (1 - N)"
44660702
DM
2321 },
2322 "mode" : {
2323 "default" : "snapshot",
2324 "description" : "Backup mode.",
2325 "enum" : [
2326 "snapshot",
2327 "suspend",
2328 "stop"
2329 ],
2330 "optional" : 1,
2331 "type" : "string"
2332 },
2333 "node" : {
2334 "description" : "Only run if executed on this node.",
2335 "format" : "pve-node",
2336 "optional" : 1,
013dc89f
DM
2337 "type" : "string",
2338 "typetext" : "<string>"
44660702
DM
2339 },
2340 "pigz" : {
2341 "default" : 0,
2342 "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count.",
2343 "optional" : 1,
013dc89f
DM
2344 "type" : "integer",
2345 "typetext" : "<integer>"
44660702
DM
2346 },
2347 "quiet" : {
2348 "default" : 0,
2349 "description" : "Be quiet.",
2350 "optional" : 1,
013dc89f
DM
2351 "type" : "boolean",
2352 "typetext" : "<boolean>"
44660702
DM
2353 },
2354 "remove" : {
2355 "default" : 1,
2356 "description" : "Remove old backup files if there are more than 'maxfiles' backup files.",
2357 "optional" : 1,
013dc89f
DM
2358 "type" : "boolean",
2359 "typetext" : "<boolean>"
44660702
DM
2360 },
2361 "script" : {
2362 "description" : "Use specified hook script.",
2363 "optional" : 1,
013dc89f
DM
2364 "type" : "string",
2365 "typetext" : "<string>"
44660702
DM
2366 },
2367 "size" : {
2368 "default" : 1024,
2369 "description" : "Unused, will be removed in a future release.",
2370 "minimum" : 500,
2371 "optional" : 1,
4bd7df8b 2372 "type" : "integer",
013dc89f 2373 "typetext" : "<integer> (500 - N)"
44660702
DM
2374 },
2375 "starttime" : {
2376 "description" : "Job Start time.",
2377 "pattern" : "\\d{1,2}:\\d{1,2}",
2378 "type" : "string",
2379 "typetext" : "HH:MM"
2380 },
2381 "stdexcludes" : {
2382 "default" : 1,
2383 "description" : "Exclude temporary files and logs.",
2384 "optional" : 1,
013dc89f
DM
2385 "type" : "boolean",
2386 "typetext" : "<boolean>"
44660702
DM
2387 },
2388 "stop" : {
2389 "default" : 0,
2390 "description" : "Stop runnig backup jobs on this host.",
2391 "optional" : 1,
013dc89f
DM
2392 "type" : "boolean",
2393 "typetext" : "<boolean>"
44660702
DM
2394 },
2395 "stopwait" : {
2396 "default" : 10,
2397 "description" : "Maximal time to wait until a guest system is stopped (minutes).",
2398 "minimum" : 0,
2399 "optional" : 1,
4bd7df8b 2400 "type" : "integer",
013dc89f 2401 "typetext" : "<integer> (0 - N)"
44660702
DM
2402 },
2403 "storage" : {
2404 "description" : "Store resulting file to this storage.",
2405 "format" : "pve-storage-id",
2406 "optional" : 1,
013dc89f
DM
2407 "type" : "string",
2408 "typetext" : "<string>"
44660702
DM
2409 },
2410 "tmpdir" : {
2411 "description" : "Store temporary files to specified directory.",
2412 "optional" : 1,
013dc89f
DM
2413 "type" : "string",
2414 "typetext" : "<string>"
44660702
DM
2415 },
2416 "vmid" : {
2417 "description" : "The ID of the guest system you want to backup.",
2418 "format" : "pve-vmid-list",
2419 "optional" : 1,
013dc89f
DM
2420 "type" : "string",
2421 "typetext" : "<string>"
44660702
DM
2422 }
2423 }
2424 },
2425 "permissions" : {
2426 "check" : [
2427 "perm",
2428 "/",
2429 [
2430 "Sys.Modify"
2431 ]
de0983cb
DM
2432 ],
2433 "description" : "The 'tmpdir', 'dumpdir' and 'script' parameters are additionally restricted to the 'root@pam' user."
44660702
DM
2434 },
2435 "protected" : 1,
2436 "returns" : {
2437 "type" : "null"
2438 }
2439 }
2440 },
2441 "leaf" : 0,
2442 "path" : "/cluster/backup",
2443 "text" : "backup"
2444 },
2445 {
2446 "children" : [
2447 {
2448 "children" : [
2449 {
2450 "children" : [
56122987 2451 {
56122987
DM
2452 "info" : {
2453 "POST" : {
44660702
DM
2454 "description" : "Request resource migration (online) to another node.",
2455 "method" : "POST",
2456 "name" : "migrate",
56122987 2457 "parameters" : {
7aacca6f 2458 "additionalProperties" : 0,
56122987
DM
2459 "properties" : {
2460 "node" : {
7aacca6f 2461 "description" : "The cluster node name.",
44660702 2462 "format" : "pve-node",
013dc89f
DM
2463 "type" : "string",
2464 "typetext" : "<string>"
56122987
DM
2465 },
2466 "sid" : {
44660702 2467 "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).",
56122987 2468 "format" : "pve-ha-resource-or-vm-id",
7aacca6f 2469 "type" : "string",
44660702 2470 "typetext" : "<type>:<name>"
56122987 2471 }
7aacca6f 2472 }
56122987 2473 },
56122987
DM
2474 "permissions" : {
2475 "check" : [
2476 "perm",
2477 "/",
2478 [
2479 "Sys.Console"
2480 ]
2481 ]
2482 },
7aacca6f 2483 "protected" : 1,
7aacca6f
DM
2484 "returns" : {
2485 "type" : "null"
44660702 2486 }
56122987 2487 }
44660702
DM
2488 },
2489 "leaf" : 1,
2490 "path" : "/cluster/ha/resources/{sid}/migrate",
2491 "text" : "migrate"
2492 },
2493 {
2494 "info" : {
2495 "POST" : {
2496 "description" : "Request resource relocatzion to another node. This stops the service on the old node, and restarts it on the target node.",
2497 "method" : "POST",
2498 "name" : "relocate",
2499 "parameters" : {
2500 "additionalProperties" : 0,
2501 "properties" : {
2502 "node" : {
2503 "description" : "The cluster node name.",
2504 "format" : "pve-node",
013dc89f
DM
2505 "type" : "string",
2506 "typetext" : "<string>"
44660702
DM
2507 },
2508 "sid" : {
2509 "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).",
2510 "format" : "pve-ha-resource-or-vm-id",
2511 "type" : "string",
2512 "typetext" : "<type>:<name>"
2513 }
2514 }
2515 },
2516 "permissions" : {
2517 "check" : [
2518 "perm",
2519 "/",
2520 [
2521 "Sys.Console"
2522 ]
2523 ]
2524 },
2525 "protected" : 1,
2526 "returns" : {
2527 "type" : "null"
2528 }
2529 }
2530 },
2531 "leaf" : 1,
2532 "path" : "/cluster/ha/resources/{sid}/relocate",
2533 "text" : "relocate"
2534 }
2535 ],
2536 "info" : {
2537 "DELETE" : {
2538 "description" : "Delete resource configuration.",
2539 "method" : "DELETE",
2540 "name" : "delete",
7aacca6f 2541 "parameters" : {
44660702 2542 "additionalProperties" : 0,
7aacca6f
DM
2543 "properties" : {
2544 "sid" : {
2545 "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).",
44660702 2546 "format" : "pve-ha-resource-or-vm-id",
7aacca6f 2547 "type" : "string",
44660702
DM
2548 "typetext" : "<type>:<name>"
2549 }
2550 }
2551 },
2552 "permissions" : {
2553 "check" : [
2554 "perm",
2555 "/",
2556 [
2557 "Sys.Console"
2558 ]
2559 ]
2560 },
2561 "protected" : 1,
2562 "returns" : {
2563 "type" : "null"
2564 }
2565 },
2566 "GET" : {
2567 "description" : "Read resource configuration.",
2568 "method" : "GET",
2569 "name" : "read",
2570 "parameters" : {
2571 "additionalProperties" : 0,
2572 "properties" : {
2573 "sid" : {
2574 "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).",
7aacca6f 2575 "format" : "pve-ha-resource-or-vm-id",
44660702 2576 "type" : "string",
7aacca6f
DM
2577 "typetext" : "<type>:<name>"
2578 }
44660702 2579 }
7aacca6f
DM
2580 },
2581 "permissions" : {
2582 "check" : [
2583 "perm",
2584 "/",
2585 [
2586 "Sys.Audit"
2587 ]
2588 ]
2589 },
44660702 2590 "returns" : {}
7aacca6f 2591 },
56122987 2592 "PUT" : {
44660702 2593 "description" : "Update resource configuration.",
7aacca6f 2594 "method" : "PUT",
44660702 2595 "name" : "update",
56122987
DM
2596 "parameters" : {
2597 "additionalProperties" : 0,
2598 "properties" : {
44660702
DM
2599 "comment" : {
2600 "description" : "Description.",
2601 "maxLength" : 4096,
56122987 2602 "optional" : 1,
013dc89f
DM
2603 "type" : "string",
2604 "typetext" : "<string>"
56122987 2605 },
7aacca6f
DM
2606 "delete" : {
2607 "description" : "A list of settings you want to delete.",
7aacca6f 2608 "format" : "pve-configid-list",
44660702
DM
2609 "maxLength" : 4096,
2610 "optional" : 1,
013dc89f
DM
2611 "type" : "string",
2612 "typetext" : "<string>"
56122987 2613 },
44660702
DM
2614 "digest" : {
2615 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
2616 "maxLength" : 40,
2617 "optional" : 1,
013dc89f
DM
2618 "type" : "string",
2619 "typetext" : "<string>"
56122987 2620 },
44660702
DM
2621 "group" : {
2622 "description" : "The HA group identifier.",
2623 "format" : "pve-configid",
7aacca6f 2624 "optional" : 1,
013dc89f
DM
2625 "type" : "string",
2626 "typetext" : "<string>"
56122987
DM
2627 },
2628 "max_relocate" : {
7aacca6f 2629 "default" : 1,
56122987 2630 "description" : "Maximal number of service relocate tries when a service failes to start.",
44660702
DM
2631 "minimum" : 0,
2632 "optional" : 1,
4bd7df8b 2633 "type" : "integer",
013dc89f 2634 "typetext" : "<integer> (0 - N)"
7aacca6f 2635 },
44660702
DM
2636 "max_restart" : {
2637 "default" : 1,
2638 "description" : "Maximal number of tries to restart the service on a node after its start failed.",
2639 "minimum" : 0,
7aacca6f 2640 "optional" : 1,
4bd7df8b 2641 "type" : "integer",
013dc89f 2642 "typetext" : "<integer> (0 - N)"
44660702
DM
2643 },
2644 "sid" : {
2645 "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).",
2646 "format" : "pve-ha-resource-or-vm-id",
2647 "type" : "string",
2648 "typetext" : "<type>:<name>"
7aacca6f
DM
2649 },
2650 "state" : {
f13c1238
DM
2651 "default" : "started",
2652 "description" : "Requested resource state.",
7aacca6f 2653 "enum" : [
f13c1238
DM
2654 "started",
2655 "stopped",
7aacca6f
DM
2656 "enabled",
2657 "disabled"
2658 ],
7aacca6f 2659 "optional" : 1,
f13c1238
DM
2660 "type" : "string",
2661 "verbose_description" : "Requested resource state. The CRM reads this state and acts accordingly.\nPlease note that `enabled` is just an alias for `started`.\n\n`started`;;\n\nThe CRM tries to start the resource. Service state is\nset to `started` after successful start. On node failures, or when start\nfails, it tries to recover the resource. If everything fails, service\nstate it set to `error`.\n\n`stopped`;;\n\nThe CRM tries to keep the resource in `stopped` state, but it\nstill tries to relocate the resources on node failures.\n\n`disabled`;;\n\nThe CRM tries to put the resource in `stopped` state, but does not try\nto relocate the resources on node failures. The main purpose of this\nstate is error recovery, because it is the only way to move a resource out\nof the `error` state.\n\n"
56122987 2662 }
44660702
DM
2663 },
2664 "type" : "object"
56122987 2665 },
56122987
DM
2666 "permissions" : {
2667 "check" : [
2668 "perm",
2669 "/",
2670 [
2671 "Sys.Console"
2672 ]
2673 ]
2674 },
7aacca6f 2675 "protected" : 1,
56122987
DM
2676 "returns" : {
2677 "type" : "null"
2678 }
2679 }
2680 },
44660702 2681 "leaf" : 0,
7aacca6f 2682 "path" : "/cluster/ha/resources/{sid}",
44660702 2683 "text" : "{sid}"
56122987
DM
2684 }
2685 ],
7aacca6f
DM
2686 "info" : {
2687 "GET" : {
44660702
DM
2688 "description" : "List HA resources.",
2689 "method" : "GET",
2690 "name" : "index",
7aacca6f 2691 "parameters" : {
44660702
DM
2692 "additionalProperties" : 0,
2693 "properties" : {
2694 "type" : {
2695 "description" : "Only list resources of specific type",
2696 "enum" : [
2697 "ct",
2698 "vm"
2699 ],
2700 "optional" : 1,
2701 "type" : "string"
2702 }
2703 }
7aacca6f 2704 },
7aacca6f
DM
2705 "permissions" : {
2706 "check" : [
2707 "perm",
2708 "/",
2709 [
2710 "Sys.Audit"
2711 ]
2712 ]
2713 },
7aacca6f 2714 "returns" : {
7aacca6f 2715 "items" : {
7aacca6f 2716 "properties" : {
44660702 2717 "sid" : {
7aacca6f
DM
2718 "type" : "string"
2719 }
44660702
DM
2720 },
2721 "type" : "object"
7aacca6f
DM
2722 },
2723 "links" : [
2724 {
44660702 2725 "href" : "{sid}",
7aacca6f
DM
2726 "rel" : "child"
2727 }
44660702
DM
2728 ],
2729 "type" : "array"
7aacca6f
DM
2730 }
2731 },
2732 "POST" : {
44660702 2733 "description" : "Create a new HA resource.",
7aacca6f 2734 "method" : "POST",
44660702 2735 "name" : "create",
7aacca6f 2736 "parameters" : {
44660702 2737 "additionalProperties" : 0,
7aacca6f
DM
2738 "properties" : {
2739 "comment" : {
7aacca6f 2740 "description" : "Description.",
44660702 2741 "maxLength" : 4096,
7aacca6f 2742 "optional" : 1,
013dc89f
DM
2743 "type" : "string",
2744 "typetext" : "<string>"
7aacca6f 2745 },
44660702
DM
2746 "group" : {
2747 "description" : "The HA group identifier.",
2748 "format" : "pve-configid",
7aacca6f 2749 "optional" : 1,
013dc89f
DM
2750 "type" : "string",
2751 "typetext" : "<string>"
7aacca6f 2752 },
44660702
DM
2753 "max_relocate" : {
2754 "default" : 1,
2755 "description" : "Maximal number of service relocate tries when a service failes to start.",
2756 "minimum" : 0,
7aacca6f 2757 "optional" : 1,
4bd7df8b 2758 "type" : "integer",
013dc89f 2759 "typetext" : "<integer> (0 - N)"
7aacca6f 2760 },
44660702
DM
2761 "max_restart" : {
2762 "default" : 1,
2763 "description" : "Maximal number of tries to restart the service on a node after its start failed.",
2764 "minimum" : 0,
2765 "optional" : 1,
4bd7df8b 2766 "type" : "integer",
013dc89f 2767 "typetext" : "<integer> (0 - N)"
44660702
DM
2768 },
2769 "sid" : {
2770 "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).",
2771 "format" : "pve-ha-resource-or-vm-id",
2772 "type" : "string",
2773 "typetext" : "<type>:<name>"
2774 },
2775 "state" : {
f13c1238
DM
2776 "default" : "started",
2777 "description" : "Requested resource state.",
7aacca6f 2778 "enum" : [
f13c1238
DM
2779 "started",
2780 "stopped",
44660702
DM
2781 "enabled",
2782 "disabled"
7aacca6f 2783 ],
7aacca6f 2784 "optional" : 1,
f13c1238
DM
2785 "type" : "string",
2786 "verbose_description" : "Requested resource state. The CRM reads this state and acts accordingly.\nPlease note that `enabled` is just an alias for `started`.\n\n`started`;;\n\nThe CRM tries to start the resource. Service state is\nset to `started` after successful start. On node failures, or when start\nfails, it tries to recover the resource. If everything fails, service\nstate it set to `error`.\n\n`stopped`;;\n\nThe CRM tries to keep the resource in `stopped` state, but it\nstill tries to relocate the resources on node failures.\n\n`disabled`;;\n\nThe CRM tries to put the resource in `stopped` state, but does not try\nto relocate the resources on node failures. The main purpose of this\nstate is error recovery, because it is the only way to move a resource out\nof the `error` state.\n\n"
7aacca6f 2787 },
44660702
DM
2788 "type" : {
2789 "description" : "Resource type.",
2790 "enum" : [
2791 "ct",
2792 "vm"
2793 ],
2794 "optional" : 1,
2795 "type" : "string"
2796 }
7aacca6f 2797 },
44660702 2798 "type" : "object"
7aacca6f
DM
2799 },
2800 "permissions" : {
2801 "check" : [
2802 "perm",
2803 "/",
2804 [
2805 "Sys.Console"
2806 ]
2807 ]
2808 },
44660702
DM
2809 "protected" : 1,
2810 "returns" : {
2811 "type" : "null"
2812 }
7aacca6f
DM
2813 }
2814 },
44660702
DM
2815 "leaf" : 0,
2816 "path" : "/cluster/ha/resources",
2817 "text" : "resources"
2818 },
2819 {
56122987
DM
2820 "children" : [
2821 {
56122987 2822 "info" : {
44660702
DM
2823 "DELETE" : {
2824 "description" : "Delete ha group configuration.",
2825 "method" : "DELETE",
2826 "name" : "delete",
56122987 2827 "parameters" : {
7aacca6f 2828 "additionalProperties" : 0,
56122987 2829 "properties" : {
7aacca6f
DM
2830 "group" : {
2831 "description" : "The HA group identifier.",
44660702 2832 "format" : "pve-configid",
013dc89f
DM
2833 "type" : "string",
2834 "typetext" : "<string>"
56122987 2835 }
7aacca6f 2836 }
56122987 2837 },
56122987
DM
2838 "permissions" : {
2839 "check" : [
2840 "perm",
2841 "/",
2842 [
7aacca6f 2843 "Sys.Console"
56122987
DM
2844 ]
2845 ]
2846 },
44660702 2847 "protected" : 1,
7aacca6f
DM
2848 "returns" : {
2849 "type" : "null"
56122987
DM
2850 }
2851 },
44660702
DM
2852 "GET" : {
2853 "description" : "Read ha group configuration.",
2854 "method" : "GET",
2855 "name" : "read",
56122987 2856 "parameters" : {
44660702 2857 "additionalProperties" : 0,
56122987
DM
2858 "properties" : {
2859 "group" : {
2860 "description" : "The HA group identifier.",
44660702 2861 "format" : "pve-configid",
013dc89f
DM
2862 "type" : "string",
2863 "typetext" : "<string>"
56122987 2864 }
44660702 2865 }
56122987 2866 },
56122987
DM
2867 "permissions" : {
2868 "check" : [
2869 "perm",
2870 "/",
2871 [
44660702 2872 "Sys.Audit"
56122987
DM
2873 ]
2874 ]
2875 },
44660702 2876 "returns" : {}
7aacca6f 2877 },
44660702
DM
2878 "PUT" : {
2879 "description" : "Update ha group configuration.",
2880 "method" : "PUT",
2881 "name" : "update",
7aacca6f 2882 "parameters" : {
44660702 2883 "additionalProperties" : 0,
7aacca6f 2884 "properties" : {
44660702
DM
2885 "comment" : {
2886 "description" : "Description.",
2887 "maxLength" : 4096,
2888 "optional" : 1,
013dc89f
DM
2889 "type" : "string",
2890 "typetext" : "<string>"
44660702
DM
2891 },
2892 "delete" : {
2893 "description" : "A list of settings you want to delete.",
2894 "format" : "pve-configid-list",
2895 "maxLength" : 4096,
2896 "optional" : 1,
013dc89f
DM
2897 "type" : "string",
2898 "typetext" : "<string>"
44660702
DM
2899 },
2900 "digest" : {
2901 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
2902 "maxLength" : 40,
2903 "optional" : 1,
013dc89f
DM
2904 "type" : "string",
2905 "typetext" : "<string>"
44660702 2906 },
7aacca6f
DM
2907 "group" : {
2908 "description" : "The HA group identifier.",
44660702 2909 "format" : "pve-configid",
013dc89f
DM
2910 "type" : "string",
2911 "typetext" : "<string>"
44660702
DM
2912 },
2913 "nodes" : {
f13c1238 2914 "description" : "List of cluster node names with optional priority.",
44660702
DM
2915 "format" : "pve-ha-group-node-list",
2916 "optional" : 1,
7aacca6f 2917 "type" : "string",
f13c1238
DM
2918 "typetext" : "<node>[:<pri>]{,<node>[:<pri>]}*",
2919 "verbose_description" : "List of cluster node members, where a priority can be given to each node. A resource bound to a group will run on the available nodes with the highest priority. If there are more nodes in the highest priority class, the services will get distributed to those nodes. The priorities have a relative meaning only."
44660702
DM
2920 },
2921 "nofailback" : {
2922 "default" : 0,
2923 "description" : "The CRM tries to run services on the node with the highest priority. If a node with higher priority comes online, the CRM migrates the service to that node. Enabling nofailback prevents that behavior.",
2924 "optional" : 1,
013dc89f
DM
2925 "type" : "boolean",
2926 "typetext" : "<boolean>"
44660702
DM
2927 },
2928 "restricted" : {
2929 "default" : 0,
c4808e75 2930 "description" : "Resources bound to restricted groups may only run on nodes defined by the group.",
44660702 2931 "optional" : 1,
013dc89f 2932 "type" : "boolean",
c4808e75
DM
2933 "typetext" : "<boolean>",
2934 "verbose_description" : "Resources bound to restricted groups may only run on nodes defined by the group. The resource will be placed in the stopped state if no group node member is online. Resources on unrestricted groups may run on any cluster node if all group members are offline, but they will migrate back as soon as a group member comes online. One can implement a 'preferred node' behavior using an unrestricted group with only one member."
7aacca6f
DM
2935 }
2936 },
44660702 2937 "type" : "object"
7aacca6f 2938 },
7aacca6f
DM
2939 "permissions" : {
2940 "check" : [
2941 "perm",
2942 "/",
2943 [
44660702 2944 "Sys.Console"
7aacca6f
DM
2945 ]
2946 ]
2947 },
44660702
DM
2948 "protected" : 1,
2949 "returns" : {
2950 "type" : "null"
2951 }
56122987
DM
2952 }
2953 },
2954 "leaf" : 1,
44660702
DM
2955 "path" : "/cluster/ha/groups/{group}",
2956 "text" : "{group}"
56122987 2957 }
44660702
DM
2958 ],
2959 "info" : {
2960 "GET" : {
2961 "description" : "Get HA groups.",
2962 "method" : "GET",
2963 "name" : "index",
2964 "parameters" : {
2965 "additionalProperties" : 0
2966 },
2967 "permissions" : {
2968 "check" : [
2969 "perm",
2970 "/",
2971 [
2972 "Sys.Audit"
2973 ]
2974 ]
2975 },
2976 "returns" : {
2977 "items" : {
2978 "properties" : {
2979 "group" : {
2980 "type" : "string"
2981 }
2982 },
2983 "type" : "object"
2984 },
2985 "links" : [
2986 {
2987 "href" : "{group}",
2988 "rel" : "child"
2989 }
2990 ],
2991 "type" : "array"
2992 }
2993 },
2994 "POST" : {
2995 "description" : "Create a new HA group.",
2996 "method" : "POST",
2997 "name" : "create",
2998 "parameters" : {
2999 "additionalProperties" : 0,
3000 "properties" : {
3001 "comment" : {
3002 "description" : "Description.",
3003 "maxLength" : 4096,
3004 "optional" : 1,
013dc89f
DM
3005 "type" : "string",
3006 "typetext" : "<string>"
44660702
DM
3007 },
3008 "group" : {
3009 "description" : "The HA group identifier.",
3010 "format" : "pve-configid",
013dc89f
DM
3011 "type" : "string",
3012 "typetext" : "<string>"
44660702
DM
3013 },
3014 "nodes" : {
f13c1238 3015 "description" : "List of cluster node names with optional priority.",
44660702
DM
3016 "format" : "pve-ha-group-node-list",
3017 "optional" : 0,
3018 "type" : "string",
f13c1238
DM
3019 "typetext" : "<node>[:<pri>]{,<node>[:<pri>]}*",
3020 "verbose_description" : "List of cluster node members, where a priority can be given to each node. A resource bound to a group will run on the available nodes with the highest priority. If there are more nodes in the highest priority class, the services will get distributed to those nodes. The priorities have a relative meaning only."
44660702
DM
3021 },
3022 "nofailback" : {
3023 "default" : 0,
3024 "description" : "The CRM tries to run services on the node with the highest priority. If a node with higher priority comes online, the CRM migrates the service to that node. Enabling nofailback prevents that behavior.",
3025 "optional" : 1,
013dc89f
DM
3026 "type" : "boolean",
3027 "typetext" : "<boolean>"
44660702
DM
3028 },
3029 "restricted" : {
3030 "default" : 0,
c4808e75 3031 "description" : "Resources bound to restricted groups may only run on nodes defined by the group.",
44660702 3032 "optional" : 1,
013dc89f 3033 "type" : "boolean",
c4808e75
DM
3034 "typetext" : "<boolean>",
3035 "verbose_description" : "Resources bound to restricted groups may only run on nodes defined by the group. The resource will be placed in the stopped state if no group node member is online. Resources on unrestricted groups may run on any cluster node if all group members are offline, but they will migrate back as soon as a group member comes online. One can implement a 'preferred node' behavior using an unrestricted group with only one member."
44660702
DM
3036 },
3037 "type" : {
3038 "description" : "Group type.",
3039 "enum" : [
3040 "group"
3041 ],
3042 "optional" : 1,
3043 "type" : "string"
3044 }
3045 },
3046 "type" : "object"
3047 },
3048 "permissions" : {
3049 "check" : [
3050 "perm",
3051 "/",
3052 [
3053 "Sys.Console"
3054 ]
3055 ]
3056 },
3057 "protected" : 1,
3058 "returns" : {
3059 "type" : "null"
3060 }
3061 }
3062 },
3063 "leaf" : 0,
3064 "path" : "/cluster/ha/groups",
3065 "text" : "groups"
7aacca6f
DM
3066 },
3067 {
7aacca6f
DM
3068 "children" : [
3069 {
3070 "info" : {
3071 "GET" : {
56122987 3072 "description" : "Get HA manger status.",
44660702 3073 "method" : "GET",
7aacca6f 3074 "name" : "status",
44660702
DM
3075 "parameters" : {
3076 "additionalProperties" : 0
3077 },
56122987
DM
3078 "permissions" : {
3079 "check" : [
3080 "perm",
3081 "/",
3082 [
3083 "Sys.Audit"
3084 ]
3085 ]
7aacca6f 3086 },
44660702
DM
3087 "returns" : {
3088 "type" : "array"
56122987
DM
3089 }
3090 }
7aacca6f 3091 },
7aacca6f 3092 "leaf" : 1,
44660702
DM
3093 "path" : "/cluster/ha/status/current",
3094 "text" : "current"
56122987
DM
3095 },
3096 {
3097 "info" : {
3098 "GET" : {
7aacca6f 3099 "description" : "Get full HA manger status, including LRM status.",
44660702
DM
3100 "method" : "GET",
3101 "name" : "manager_status",
7aacca6f
DM
3102 "parameters" : {
3103 "additionalProperties" : 0
3104 },
56122987
DM
3105 "permissions" : {
3106 "check" : [
3107 "perm",
3108 "/",
3109 [
3110 "Sys.Audit"
3111 ]
3112 ]
44660702
DM
3113 },
3114 "returns" : {
3115 "type" : "object"
7aacca6f 3116 }
56122987
DM
3117 }
3118 },
56122987 3119 "leaf" : 1,
44660702
DM
3120 "path" : "/cluster/ha/status/manager_status",
3121 "text" : "manager_status"
56122987
DM
3122 }
3123 ],
56122987
DM
3124 "info" : {
3125 "GET" : {
44660702 3126 "description" : "Directory index.",
7aacca6f 3127 "method" : "GET",
44660702
DM
3128 "name" : "index",
3129 "parameters" : {
3130 "additionalProperties" : 0
3131 },
3132 "permissions" : {
3133 "user" : "all"
3134 },
56122987 3135 "returns" : {
56122987
DM
3136 "items" : {
3137 "properties" : {},
3138 "type" : "object"
3139 },
3140 "links" : [
3141 {
44660702
DM
3142 "href" : "{name}",
3143 "rel" : "child"
56122987 3144 }
7aacca6f
DM
3145 ],
3146 "type" : "array"
44660702 3147 }
56122987 3148 }
7aacca6f 3149 },
44660702 3150 "leaf" : 0,
7aacca6f 3151 "path" : "/cluster/ha/status",
44660702 3152 "text" : "status"
56122987
DM
3153 }
3154 ],
56122987
DM
3155 "info" : {
3156 "GET" : {
7aacca6f 3157 "description" : "Directory index.",
44660702
DM
3158 "method" : "GET",
3159 "name" : "index",
3160 "parameters" : {
3161 "additionalProperties" : 0
3162 },
7aacca6f
DM
3163 "permissions" : {
3164 "check" : [
3165 "perm",
3166 "/",
3167 [
3168 "Sys.Audit"
3169 ]
3170 ]
3171 },
56122987 3172 "returns" : {
56122987 3173 "items" : {
7aacca6f
DM
3174 "properties" : {
3175 "id" : {
3176 "type" : "string"
3177 }
44660702
DM
3178 },
3179 "type" : "object"
7aacca6f
DM
3180 },
3181 "links" : [
3182 {
3183 "href" : "{id}",
3184 "rel" : "child"
3185 }
44660702
DM
3186 ],
3187 "type" : "array"
7aacca6f
DM
3188 }
3189 }
44660702
DM
3190 },
3191 "leaf" : 0,
3192 "path" : "/cluster/ha",
3193 "text" : "ha"
7aacca6f
DM
3194 },
3195 {
7aacca6f
DM
3196 "info" : {
3197 "GET" : {
3198 "description" : "Read cluster log",
44660702
DM
3199 "method" : "GET",
3200 "name" : "log",
56122987 3201 "parameters" : {
7aacca6f 3202 "additionalProperties" : 0,
56122987
DM
3203 "properties" : {
3204 "max" : {
7aacca6f 3205 "description" : "Maximum number of entries.",
44660702
DM
3206 "minimum" : 1,
3207 "optional" : 1,
4bd7df8b 3208 "type" : "integer",
013dc89f 3209 "typetext" : "<integer> (1 - N)"
56122987 3210 }
7aacca6f 3211 }
56122987 3212 },
44660702
DM
3213 "permissions" : {
3214 "user" : "all"
3215 },
7aacca6f 3216 "returns" : {
7aacca6f 3217 "items" : {
44660702
DM
3218 "properties" : {},
3219 "type" : "object"
3220 },
3221 "type" : "array"
7aacca6f 3222 }
56122987 3223 }
44660702
DM
3224 },
3225 "leaf" : 1,
3226 "path" : "/cluster/log",
3227 "text" : "log"
56122987
DM
3228 },
3229 {
56122987
DM
3230 "info" : {
3231 "GET" : {
44660702 3232 "description" : "Resources index (cluster wide).",
7aacca6f 3233 "method" : "GET",
7aacca6f 3234 "name" : "resources",
56122987
DM
3235 "parameters" : {
3236 "additionalProperties" : 0,
3237 "properties" : {
3238 "type" : {
3239 "enum" : [
3240 "vm",
3241 "storage",
3242 "node"
44660702
DM
3243 ],
3244 "optional" : 1,
3245 "type" : "string"
56122987
DM
3246 }
3247 }
3248 },
44660702
DM
3249 "permissions" : {
3250 "user" : "all"
3251 },
3252 "returns" : {
3253 "items" : {
3254 "properties" : {},
3255 "type" : "object"
3256 },
3257 "type" : "array"
3258 }
56122987
DM
3259 }
3260 },
7aacca6f 3261 "leaf" : 1,
44660702
DM
3262 "path" : "/cluster/resources",
3263 "text" : "resources"
56122987
DM
3264 },
3265 {
56122987
DM
3266 "info" : {
3267 "GET" : {
7aacca6f 3268 "description" : "List recent tasks (cluster wide).",
44660702 3269 "method" : "GET",
7aacca6f 3270 "name" : "tasks",
56122987
DM
3271 "parameters" : {
3272 "additionalProperties" : 0
3273 },
44660702
DM
3274 "permissions" : {
3275 "user" : "all"
3276 },
56122987
DM
3277 "returns" : {
3278 "items" : {
3279 "properties" : {
3280 "upid" : {
3281 "type" : "string"
3282 }
44660702
DM
3283 },
3284 "type" : "object"
3285 },
3286 "type" : "array"
7aacca6f 3287 }
56122987
DM
3288 }
3289 },
7aacca6f 3290 "leaf" : 1,
44660702
DM
3291 "path" : "/cluster/tasks",
3292 "text" : "tasks"
56122987
DM
3293 },
3294 {
56122987 3295 "info" : {
7aacca6f 3296 "GET" : {
44660702
DM
3297 "description" : "Get datacenter options.",
3298 "method" : "GET",
3299 "name" : "get_options",
56122987 3300 "parameters" : {
7aacca6f
DM
3301 "additionalProperties" : 0
3302 },
3303 "permissions" : {
3304 "check" : [
3305 "perm",
3306 "/",
3307 [
3308 "Sys.Audit"
3309 ]
3310 ]
3311 },
7aacca6f 3312 "returns" : {
44660702
DM
3313 "properties" : {},
3314 "type" : "object"
7aacca6f
DM
3315 }
3316 },
3317 "PUT" : {
44660702
DM
3318 "description" : "Set datacenter options.",
3319 "method" : "PUT",
7aacca6f
DM
3320 "name" : "set_options",
3321 "parameters" : {
3322 "additionalProperties" : 0,
3323 "properties" : {
56122987 3324 "console" : {
56122987 3325 "description" : "Select the default Console viewer. You can either use the builtin java applet (VNC), an external virt-viewer comtatible application (SPICE), or an HTML5 based viewer (noVNC).",
56122987
DM
3326 "enum" : [
3327 "applet",
3328 "vv",
3329 "html5"
44660702
DM
3330 ],
3331 "optional" : 1,
3332 "type" : "string"
56122987 3333 },
7aacca6f 3334 "delete" : {
7aacca6f 3335 "description" : "A list of settings you want to delete.",
44660702 3336 "format" : "pve-configid-list",
7aacca6f 3337 "optional" : 1,
013dc89f
DM
3338 "type" : "string",
3339 "typetext" : "<string>"
7aacca6f 3340 },
44660702
DM
3341 "email_from" : {
3342 "description" : "Specify email address to send notification from (default is root@$hostname)",
3343 "format" : "email-opt",
7aacca6f 3344 "optional" : 1,
013dc89f
DM
3345 "type" : "string",
3346 "typetext" : "<string>"
44660702
DM
3347 },
3348 "fencing" : {
3349 "default" : "watchdog",
3350 "description" : "Set the fencing mode of the HA cluster. Hardware mode needs a valid configuration of fence devices in /etc/pve/ha/fence.cfg. With both all two modes are used.\n\nWARNING: 'hardware' and 'both' are EXPERIMENTAL & WIP",
7aacca6f 3351 "enum" : [
44660702
DM
3352 "watchdog",
3353 "hardware",
3354 "both"
7aacca6f 3355 ],
44660702
DM
3356 "optional" : 1,
3357 "type" : "string"
3358 },
3359 "http_proxy" : {
3360 "description" : "Specify external http proxy which is used for downloads (example: 'http://username:password@host:port/')",
3361 "optional" : 1,
3362 "pattern" : "http://.*",
3363 "type" : "string"
7aacca6f 3364 },
56122987 3365 "keyboard" : {
44660702 3366 "description" : "Default keybord layout for vnc server.",
56122987 3367 "enum" : [
44660702
DM
3368 "de",
3369 "de-ch",
7aacca6f 3370 "da",
56122987 3371 "en-gb",
44660702
DM
3372 "en-us",
3373 "es",
3374 "fi",
3375 "fr",
3376 "fr-be",
3377 "fr-ca",
3378 "fr-ch",
3379 "hu",
7aacca6f 3380 "is",
44660702
DM
3381 "it",
3382 "ja",
3383 "lt",
56122987 3384 "mk",
7aacca6f 3385 "nl",
56122987 3386 "no",
44660702 3387 "pl",
7aacca6f 3388 "pt",
44660702
DM
3389 "pt-br",
3390 "sv",
3391 "sl",
3392 "tr"
56122987 3393 ],
56122987
DM
3394 "optional" : 1,
3395 "type" : "string"
3396 },
44660702
DM
3397 "language" : {
3398 "description" : "Default GUI language.",
3399 "enum" : [
3400 "en",
3401 "de"
3402 ],
56122987 3403 "optional" : 1,
44660702 3404 "type" : "string"
56122987 3405 },
4bd7df8b
DM
3406 "mac_prefix" : {
3407 "description" : "Prefix for autogenerated MAC addresses.",
3408 "optional" : 1,
3409 "pattern" : "(?^i:[a-f0-9]{2}(?::[a-f0-9]{2}){0,2}:?)",
3410 "type" : "string"
3411 },
44660702
DM
3412 "max_workers" : {
3413 "description" : "Defines how many workers (per node) are maximal started on actions like 'stopall VMs' or task from the ha-manager.",
3414 "minimum" : 1,
56122987 3415 "optional" : 1,
4bd7df8b 3416 "type" : "integer",
013dc89f 3417 "typetext" : "<integer> (1 - N)"
56122987 3418 },
de0983cb
DM
3419 "migration" : {
3420 "description" : "For cluster wide migration settings.",
3421 "format" : {
3422 "network" : {
3423 "description" : "CIDR of the (sub) network that is used for migration.",
3424 "format" : "CIDR",
3425 "format_description" : "CIDR",
3426 "optional" : 1,
3427 "type" : "string"
3428 },
3429 "type" : {
3430 "default" : "secure",
3431 "default_key" : 1,
3432 "description" : "Migration traffic is encrypted using an SSH tunnel by default. On secure, completely private networks this can be disabled to increase performance.",
3433 "enum" : [
3434 "secure",
3435 "insecure"
3436 ],
3437 "type" : "string"
3438 }
3439 },
3440 "optional" : 1,
3441 "type" : "string",
3442 "typetext" : "[type=]<secure|insecure> [,network=<CIDR>]"
3443 },
7aacca6f 3444 "migration_unsecure" : {
de0983cb 3445 "description" : "Migration is secure using SSH tunnel by default. For secure private networks you can disable it to speed up migration. Deprecated, use the 'migration' property instead!",
56122987 3446 "optional" : 1,
013dc89f
DM
3447 "type" : "boolean",
3448 "typetext" : "<boolean>"
56122987
DM
3449 }
3450 }
3451 },
44660702
DM
3452 "permissions" : {
3453 "check" : [
3454 "perm",
3455 "/",
3456 [
3457 "Sys.Modify"
3458 ]
3459 ]
3460 },
56122987 3461 "protected" : 1,
7aacca6f
DM
3462 "returns" : {
3463 "type" : "null"
44660702 3464 }
7aacca6f
DM
3465 }
3466 },
44660702
DM
3467 "leaf" : 1,
3468 "path" : "/cluster/options",
7aacca6f
DM
3469 "text" : "options"
3470 },
3471 {
7aacca6f 3472 "info" : {
56122987 3473 "GET" : {
44660702
DM
3474 "description" : "Get cluster status informations.",
3475 "method" : "GET",
3476 "name" : "get_status",
56122987
DM
3477 "parameters" : {
3478 "additionalProperties" : 0
3479 },
56122987
DM
3480 "permissions" : {
3481 "check" : [
3482 "perm",
3483 "/",
3484 [
3485 "Sys.Audit"
3486 ]
3487 ]
3488 },
7aacca6f 3489 "protected" : 1,
56122987 3490 "returns" : {
56122987 3491 "items" : {
56122987
DM
3492 "properties" : {
3493 "type" : {
3494 "type" : "string"
3495 }
44660702
DM
3496 },
3497 "type" : "object"
7aacca6f
DM
3498 },
3499 "type" : "array"
56122987
DM
3500 }
3501 }
3502 },
44660702 3503 "leaf" : 1,
7aacca6f 3504 "path" : "/cluster/status",
44660702 3505 "text" : "status"
56122987
DM
3506 },
3507 {
56122987
DM
3508 "info" : {
3509 "GET" : {
56122987 3510 "description" : "Get next free VMID. If you pass an VMID it will raise an error if the ID is already used.",
44660702
DM
3511 "method" : "GET",
3512 "name" : "nextid",
56122987 3513 "parameters" : {
44660702 3514 "additionalProperties" : 0,
56122987
DM
3515 "properties" : {
3516 "vmid" : {
44660702 3517 "description" : "The (unique) ID of the VM.",
56122987 3518 "format" : "pve-vmid",
7aacca6f 3519 "minimum" : 1,
7aacca6f 3520 "optional" : 1,
4bd7df8b 3521 "type" : "integer",
013dc89f 3522 "typetext" : "<integer> (1 - N)"
56122987 3523 }
44660702 3524 }
56122987 3525 },
7aacca6f
DM
3526 "permissions" : {
3527 "user" : "all"
44660702
DM
3528 },
3529 "returns" : {
3530 "description" : "The next free VMID.",
3531 "type" : "integer"
7aacca6f 3532 }
56122987
DM
3533 }
3534 },
7aacca6f 3535 "leaf" : 1,
44660702
DM
3536 "path" : "/cluster/nextid",
3537 "text" : "nextid"
56122987
DM
3538 }
3539 ],
44660702
DM
3540 "info" : {
3541 "GET" : {
3542 "description" : "Cluster index.",
3543 "method" : "GET",
3544 "name" : "index",
3545 "parameters" : {
3546 "additionalProperties" : 0
3547 },
3548 "permissions" : {
3549 "user" : "all"
3550 },
3551 "returns" : {
3552 "items" : {
3553 "properties" : {},
3554 "type" : "object"
3555 },
3556 "links" : [
3557 {
3558 "href" : "{name}",
3559 "rel" : "child"
3560 }
3561 ],
3562 "type" : "array"
3563 }
3564 }
3565 },
3566 "leaf" : 0,
3567 "path" : "/cluster",
7aacca6f 3568 "text" : "cluster"
56122987
DM
3569 },
3570 {
56122987
DM
3571 "children" : [
3572 {
7aacca6f
DM
3573 "children" : [
3574 {
3575 "children" : [
3576 {
56122987
DM
3577 "children" : [
3578 {
56122987
DM
3579 "children" : [
3580 {
3581 "children" : [
3582 {
56122987
DM
3583 "info" : {
3584 "DELETE" : {
44660702 3585 "description" : "Delete rule.",
7aacca6f 3586 "method" : "DELETE",
44660702 3587 "name" : "delete_rule",
56122987 3588 "parameters" : {
44660702 3589 "additionalProperties" : 0,
56122987 3590 "properties" : {
44660702
DM
3591 "digest" : {
3592 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
3593 "maxLength" : 40,
3594 "optional" : 1,
013dc89f
DM
3595 "type" : "string",
3596 "typetext" : "<string>"
44660702 3597 },
56122987 3598 "node" : {
7aacca6f 3599 "description" : "The cluster node name.",
44660702 3600 "format" : "pve-node",
013dc89f
DM
3601 "type" : "string",
3602 "typetext" : "<string>"
7aacca6f 3603 },
56122987 3604 "pos" : {
7aacca6f 3605 "description" : "Update rule at position <pos>.",
44660702 3606 "minimum" : 0,
56122987 3607 "optional" : 1,
4bd7df8b 3608 "type" : "integer",
013dc89f 3609 "typetext" : "<integer> (0 - N)"
44660702
DM
3610 },
3611 "vmid" : {
3612 "description" : "The (unique) ID of the VM.",
3613 "format" : "pve-vmid",
3614 "minimum" : 1,
4bd7df8b 3615 "type" : "integer",
013dc89f 3616 "typetext" : "<integer> (1 - N)"
56122987 3617 }
44660702 3618 }
7aacca6f 3619 },
56122987
DM
3620 "permissions" : {
3621 "check" : [
3622 "perm",
3623 "/vms/{vmid}",
3624 [
3625 "VM.Config.Network"
3626 ]
3627 ]
3628 },
44660702
DM
3629 "protected" : 1,
3630 "proxyto" : null,
56122987
DM
3631 "returns" : {
3632 "type" : "null"
44660702
DM
3633 }
3634 },
3635 "GET" : {
3636 "description" : "Get single rule data.",
3637 "method" : "GET",
3638 "name" : "get_rule",
3639 "parameters" : {
3640 "additionalProperties" : 0,
3641 "properties" : {
3642 "node" : {
3643 "description" : "The cluster node name.",
3644 "format" : "pve-node",
013dc89f
DM
3645 "type" : "string",
3646 "typetext" : "<string>"
44660702
DM
3647 },
3648 "pos" : {
3649 "description" : "Update rule at position <pos>.",
3650 "minimum" : 0,
3651 "optional" : 1,
4bd7df8b 3652 "type" : "integer",
013dc89f 3653 "typetext" : "<integer> (0 - N)"
44660702
DM
3654 },
3655 "vmid" : {
3656 "description" : "The (unique) ID of the VM.",
3657 "format" : "pve-vmid",
3658 "minimum" : 1,
4bd7df8b 3659 "type" : "integer",
013dc89f 3660 "typetext" : "<integer> (1 - N)"
44660702
DM
3661 }
3662 }
56122987 3663 },
56122987
DM
3664 "permissions" : {
3665 "check" : [
3666 "perm",
3667 "/vms/{vmid}",
3668 [
44660702 3669 "VM.Audit"
56122987
DM
3670 ]
3671 ]
3672 },
56122987 3673 "proxyto" : null,
44660702
DM
3674 "returns" : {
3675 "properties" : {
3676 "pos" : {
3677 "type" : "integer"
3678 }
3679 },
3680 "type" : "object"
3681 }
3682 },
3683 "PUT" : {
7aacca6f
DM
3684 "description" : "Modify rule data.",
3685 "method" : "PUT",
44660702 3686 "name" : "update_rule",
56122987 3687 "parameters" : {
44660702 3688 "additionalProperties" : 0,
56122987 3689 "properties" : {
44660702
DM
3690 "action" : {
3691 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
3692 "maxLength" : 20,
3693 "minLength" : 2,
56122987 3694 "optional" : 1,
44660702 3695 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
7aacca6f
DM
3696 "type" : "string"
3697 },
7aacca6f 3698 "comment" : {
e94f0d56 3699 "description" : "Descriptive comment.",
7aacca6f 3700 "optional" : 1,
013dc89f
DM
3701 "type" : "string",
3702 "typetext" : "<string>"
7aacca6f
DM
3703 },
3704 "delete" : {
7aacca6f 3705 "description" : "A list of settings you want to delete.",
44660702
DM
3706 "format" : "pve-configid-list",
3707 "optional" : 1,
013dc89f
DM
3708 "type" : "string",
3709 "typetext" : "<string>"
7aacca6f
DM
3710 },
3711 "dest" : {
44660702 3712 "description" : "Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
7aacca6f 3713 "format" : "pve-fw-addr-spec",
56122987 3714 "optional" : 1,
013dc89f
DM
3715 "type" : "string",
3716 "typetext" : "<string>"
56122987 3717 },
7aacca6f 3718 "digest" : {
44660702 3719 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
7aacca6f 3720 "maxLength" : 40,
56122987 3721 "optional" : 1,
013dc89f
DM
3722 "type" : "string",
3723 "typetext" : "<string>"
44660702
DM
3724 },
3725 "dport" : {
3726 "description" : "Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
3727 "format" : "pve-fw-dport-spec",
3728 "optional" : 1,
013dc89f
DM
3729 "type" : "string",
3730 "typetext" : "<string>"
56122987 3731 },
7aacca6f 3732 "enable" : {
e94f0d56 3733 "description" : "Flag to enable/disable a rule.",
44660702 3734 "minimum" : 0,
56122987 3735 "optional" : 1,
4bd7df8b 3736 "type" : "integer",
013dc89f 3737 "typetext" : "<integer> (0 - N)"
7aacca6f 3738 },
44660702
DM
3739 "iface" : {
3740 "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.",
3741 "format" : "pve-iface",
3742 "maxLength" : 20,
7aacca6f 3743 "minLength" : 2,
56122987 3744 "optional" : 1,
013dc89f
DM
3745 "type" : "string",
3746 "typetext" : "<string>"
56122987 3747 },
44660702 3748 "macro" : {
e94f0d56 3749 "description" : "Use predefined standard macro.",
44660702 3750 "maxLength" : 128,
56122987 3751 "optional" : 1,
013dc89f
DM
3752 "type" : "string",
3753 "typetext" : "<string>"
56122987 3754 },
44660702
DM
3755 "moveto" : {
3756 "description" : "Move rule to new position <moveto>. Other arguments are ignored.",
3757 "minimum" : 0,
56122987 3758 "optional" : 1,
4bd7df8b 3759 "type" : "integer",
013dc89f 3760 "typetext" : "<integer> (0 - N)"
56122987 3761 },
44660702
DM
3762 "node" : {
3763 "description" : "The cluster node name.",
3764 "format" : "pve-node",
013dc89f
DM
3765 "type" : "string",
3766 "typetext" : "<string>"
44660702
DM
3767 },
3768 "pos" : {
3769 "description" : "Update rule at position <pos>.",
3770 "minimum" : 0,
3771 "optional" : 1,
4bd7df8b 3772 "type" : "integer",
013dc89f 3773 "typetext" : "<integer> (0 - N)"
56122987 3774 },
44660702
DM
3775 "proto" : {
3776 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
3777 "format" : "pve-fw-protocol-spec",
3778 "optional" : 1,
013dc89f
DM
3779 "type" : "string",
3780 "typetext" : "<string>"
7aacca6f 3781 },
44660702
DM
3782 "source" : {
3783 "description" : "Restrict packet source address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
3784 "format" : "pve-fw-addr-spec",
56122987 3785 "optional" : 1,
013dc89f
DM
3786 "type" : "string",
3787 "typetext" : "<string>"
56122987
DM
3788 },
3789 "sport" : {
3790 "description" : "Restrict TCP/UDP source port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
44660702
DM
3791 "format" : "pve-fw-sport-spec",
3792 "optional" : 1,
013dc89f
DM
3793 "type" : "string",
3794 "typetext" : "<string>"
44660702
DM
3795 },
3796 "type" : {
e94f0d56 3797 "description" : "Rule type.",
44660702
DM
3798 "enum" : [
3799 "in",
3800 "out",
3801 "group"
3802 ],
56122987 3803 "optional" : 1,
56122987 3804 "type" : "string"
44660702
DM
3805 },
3806 "vmid" : {
3807 "description" : "The (unique) ID of the VM.",
3808 "format" : "pve-vmid",
3809 "minimum" : 1,
4bd7df8b 3810 "type" : "integer",
013dc89f 3811 "typetext" : "<integer> (1 - N)"
56122987 3812 }
44660702 3813 }
56122987 3814 },
56122987
DM
3815 "permissions" : {
3816 "check" : [
3817 "perm",
3818 "/vms/{vmid}",
3819 [
44660702 3820 "VM.Config.Network"
56122987
DM
3821 ]
3822 ]
7aacca6f 3823 },
44660702 3824 "protected" : 1,
7aacca6f 3825 "proxyto" : null,
7aacca6f 3826 "returns" : {
44660702
DM
3827 "type" : "null"
3828 }
56122987 3829 }
7aacca6f 3830 },
44660702 3831 "leaf" : 1,
7aacca6f 3832 "path" : "/nodes/{node}/qemu/{vmid}/firewall/rules/{pos}",
44660702 3833 "text" : "{pos}"
56122987
DM
3834 }
3835 ],
56122987 3836 "info" : {
44660702
DM
3837 "GET" : {
3838 "description" : "List rules.",
3839 "method" : "GET",
3840 "name" : "get_rules",
3841 "parameters" : {
3842 "additionalProperties" : 0,
3843 "properties" : {
3844 "node" : {
3845 "description" : "The cluster node name.",
3846 "format" : "pve-node",
013dc89f
DM
3847 "type" : "string",
3848 "typetext" : "<string>"
44660702
DM
3849 },
3850 "vmid" : {
3851 "description" : "The (unique) ID of the VM.",
3852 "format" : "pve-vmid",
3853 "minimum" : 1,
4bd7df8b 3854 "type" : "integer",
013dc89f 3855 "typetext" : "<integer> (1 - N)"
44660702
DM
3856 }
3857 }
56122987 3858 },
56122987
DM
3859 "permissions" : {
3860 "check" : [
3861 "perm",
3862 "/vms/{vmid}",
3863 [
44660702 3864 "VM.Audit"
56122987
DM
3865 ]
3866 ]
7aacca6f 3867 },
44660702
DM
3868 "proxyto" : null,
3869 "returns" : {
3870 "items" : {
3871 "properties" : {
3872 "pos" : {
3873 "type" : "integer"
3874 }
3875 },
3876 "type" : "object"
3877 },
3878 "links" : [
3879 {
3880 "href" : "{pos}",
3881 "rel" : "child"
3882 }
3883 ],
3884 "type" : "array"
3885 }
3886 },
3887 "POST" : {
3888 "description" : "Create new rule.",
7aacca6f 3889 "method" : "POST",
44660702 3890 "name" : "create_rule",
56122987 3891 "parameters" : {
44660702 3892 "additionalProperties" : 0,
56122987 3893 "properties" : {
44660702
DM
3894 "action" : {
3895 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
3896 "maxLength" : 20,
3897 "minLength" : 2,
3898 "optional" : 0,
3899 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
3900 "type" : "string"
56122987 3901 },
44660702 3902 "comment" : {
e94f0d56 3903 "description" : "Descriptive comment.",
56122987 3904 "optional" : 1,
013dc89f
DM
3905 "type" : "string",
3906 "typetext" : "<string>"
56122987 3907 },
44660702
DM
3908 "dest" : {
3909 "description" : "Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
3910 "format" : "pve-fw-addr-spec",
3911 "optional" : 1,
013dc89f
DM
3912 "type" : "string",
3913 "typetext" : "<string>"
56122987 3914 },
44660702
DM
3915 "digest" : {
3916 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
3917 "maxLength" : 40,
56122987 3918 "optional" : 1,
013dc89f
DM
3919 "type" : "string",
3920 "typetext" : "<string>"
56122987 3921 },
7aacca6f
DM
3922 "dport" : {
3923 "description" : "Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
44660702 3924 "format" : "pve-fw-dport-spec",
7aacca6f 3925 "optional" : 1,
013dc89f
DM
3926 "type" : "string",
3927 "typetext" : "<string>"
56122987
DM
3928 },
3929 "enable" : {
e94f0d56 3930 "description" : "Flag to enable/disable a rule.",
56122987 3931 "minimum" : 0,
44660702 3932 "optional" : 1,
4bd7df8b 3933 "type" : "integer",
013dc89f 3934 "typetext" : "<integer> (0 - N)"
56122987 3935 },
44660702
DM
3936 "iface" : {
3937 "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.",
3938 "format" : "pve-iface",
3939 "maxLength" : 20,
7aacca6f 3940 "minLength" : 2,
44660702 3941 "optional" : 1,
013dc89f
DM
3942 "type" : "string",
3943 "typetext" : "<string>"
56122987 3944 },
44660702 3945 "macro" : {
e94f0d56 3946 "description" : "Use predefined standard macro.",
44660702 3947 "maxLength" : 128,
56122987 3948 "optional" : 1,
013dc89f
DM
3949 "type" : "string",
3950 "typetext" : "<string>"
7aacca6f 3951 },
44660702
DM
3952 "node" : {
3953 "description" : "The cluster node name.",
3954 "format" : "pve-node",
013dc89f
DM
3955 "type" : "string",
3956 "typetext" : "<string>"
44660702
DM
3957 },
3958 "pos" : {
3959 "description" : "Update rule at position <pos>.",
3960 "minimum" : 0,
3961 "optional" : 1,
4bd7df8b 3962 "type" : "integer",
013dc89f 3963 "typetext" : "<integer> (0 - N)"
44660702
DM
3964 },
3965 "proto" : {
3966 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
3967 "format" : "pve-fw-protocol-spec",
7aacca6f 3968 "optional" : 1,
013dc89f
DM
3969 "type" : "string",
3970 "typetext" : "<string>"
7aacca6f
DM
3971 },
3972 "source" : {
3973 "description" : "Restrict packet source address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
44660702 3974 "format" : "pve-fw-addr-spec",
7aacca6f 3975 "optional" : 1,
013dc89f
DM
3976 "type" : "string",
3977 "typetext" : "<string>"
7aacca6f 3978 },
44660702
DM
3979 "sport" : {
3980 "description" : "Restrict TCP/UDP source port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
3981 "format" : "pve-fw-sport-spec",
7aacca6f 3982 "optional" : 1,
013dc89f
DM
3983 "type" : "string",
3984 "typetext" : "<string>"
7aacca6f 3985 },
44660702 3986 "type" : {
e94f0d56 3987 "description" : "Rule type.",
44660702
DM
3988 "enum" : [
3989 "in",
3990 "out",
3991 "group"
3992 ],
3993 "optional" : 0,
3994 "type" : "string"
7aacca6f 3995 },
7aacca6f 3996 "vmid" : {
44660702 3997 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
3998 "format" : "pve-vmid",
3999 "minimum" : 1,
4bd7df8b 4000 "type" : "integer",
013dc89f 4001 "typetext" : "<integer> (1 - N)"
7aacca6f
DM
4002 }
4003 }
4004 },
56122987
DM
4005 "permissions" : {
4006 "check" : [
4007 "perm",
4008 "/vms/{vmid}",
4009 [
44660702 4010 "VM.Config.Network"
56122987
DM
4011 ]
4012 ]
4013 },
44660702
DM
4014 "protected" : 1,
4015 "proxyto" : null,
56122987 4016 "returns" : {
44660702
DM
4017 "type" : "null"
4018 }
56122987
DM
4019 }
4020 },
44660702 4021 "leaf" : 0,
7aacca6f 4022 "path" : "/nodes/{node}/qemu/{vmid}/firewall/rules",
44660702 4023 "text" : "rules"
56122987
DM
4024 },
4025 {
4026 "children" : [
4027 {
56122987 4028 "info" : {
44660702
DM
4029 "DELETE" : {
4030 "description" : "Remove IP or Network alias.",
4031 "method" : "DELETE",
4032 "name" : "remove_alias",
56122987 4033 "parameters" : {
44660702 4034 "additionalProperties" : 0,
56122987 4035 "properties" : {
44660702
DM
4036 "digest" : {
4037 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
4038 "maxLength" : 40,
4039 "optional" : 1,
013dc89f
DM
4040 "type" : "string",
4041 "typetext" : "<string>"
56122987
DM
4042 },
4043 "name" : {
56122987 4044 "description" : "Alias name.",
44660702 4045 "maxLength" : 64,
7aacca6f 4046 "minLength" : 2,
44660702 4047 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
56122987
DM
4048 "type" : "string"
4049 },
7aacca6f 4050 "node" : {
44660702 4051 "description" : "The cluster node name.",
7aacca6f 4052 "format" : "pve-node",
013dc89f
DM
4053 "type" : "string",
4054 "typetext" : "<string>"
44660702
DM
4055 },
4056 "vmid" : {
4057 "description" : "The (unique) ID of the VM.",
4058 "format" : "pve-vmid",
4059 "minimum" : 1,
4bd7df8b 4060 "type" : "integer",
013dc89f 4061 "typetext" : "<integer> (1 - N)"
56122987 4062 }
44660702 4063 }
56122987 4064 },
7aacca6f
DM
4065 "permissions" : {
4066 "check" : [
4067 "perm",
4068 "/vms/{vmid}",
4069 [
4070 "VM.Config.Network"
4071 ]
4072 ]
56122987 4073 },
44660702
DM
4074 "protected" : 1,
4075 "returns" : {
4076 "type" : "null"
4077 }
4078 },
4079 "GET" : {
4080 "description" : "Read alias.",
4081 "method" : "GET",
4082 "name" : "read_alias",
56122987 4083 "parameters" : {
44660702 4084 "additionalProperties" : 0,
56122987 4085 "properties" : {
56122987 4086 "name" : {
7aacca6f 4087 "description" : "Alias name.",
44660702 4088 "maxLength" : 64,
56122987 4089 "minLength" : 2,
44660702 4090 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
56122987 4091 "type" : "string"
7aacca6f
DM
4092 },
4093 "node" : {
4094 "description" : "The cluster node name.",
44660702 4095 "format" : "pve-node",
013dc89f
DM
4096 "type" : "string",
4097 "typetext" : "<string>"
44660702
DM
4098 },
4099 "vmid" : {
4100 "description" : "The (unique) ID of the VM.",
4101 "format" : "pve-vmid",
4102 "minimum" : 1,
4bd7df8b 4103 "type" : "integer",
013dc89f 4104 "typetext" : "<integer> (1 - N)"
56122987 4105 }
44660702 4106 }
56122987 4107 },
44660702
DM
4108 "permissions" : {
4109 "check" : [
4110 "perm",
4111 "/vms/{vmid}",
4112 [
4113 "VM.Audit"
4114 ]
4115 ]
56122987 4116 },
44660702
DM
4117 "returns" : {
4118 "type" : "object"
4119 }
7aacca6f 4120 },
44660702
DM
4121 "PUT" : {
4122 "description" : "Update IP or Network alias.",
4123 "method" : "PUT",
4124 "name" : "update_alias",
56122987
DM
4125 "parameters" : {
4126 "additionalProperties" : 0,
4127 "properties" : {
44660702
DM
4128 "cidr" : {
4129 "description" : "Network/IP specification in CIDR format.",
4130 "format" : "IPorCIDR",
013dc89f
DM
4131 "type" : "string",
4132 "typetext" : "<string>"
44660702
DM
4133 },
4134 "comment" : {
4135 "optional" : 1,
013dc89f
DM
4136 "type" : "string",
4137 "typetext" : "<string>"
56122987
DM
4138 },
4139 "digest" : {
44660702 4140 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
56122987
DM
4141 "maxLength" : 40,
4142 "optional" : 1,
013dc89f
DM
4143 "type" : "string",
4144 "typetext" : "<string>"
56122987 4145 },
7aacca6f 4146 "name" : {
44660702 4147 "description" : "Alias name.",
56122987
DM
4148 "maxLength" : 64,
4149 "minLength" : 2,
4150 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 4151 "type" : "string"
7aacca6f
DM
4152 },
4153 "node" : {
7aacca6f 4154 "description" : "The cluster node name.",
44660702 4155 "format" : "pve-node",
013dc89f
DM
4156 "type" : "string",
4157 "typetext" : "<string>"
44660702
DM
4158 },
4159 "rename" : {
4160 "description" : "Rename an existing alias.",
4161 "maxLength" : 64,
4162 "minLength" : 2,
4163 "optional" : 1,
4164 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4165 "type" : "string"
4166 },
4167 "vmid" : {
4168 "description" : "The (unique) ID of the VM.",
4169 "format" : "pve-vmid",
4170 "minimum" : 1,
4bd7df8b 4171 "type" : "integer",
013dc89f 4172 "typetext" : "<integer> (1 - N)"
56122987
DM
4173 }
4174 }
4175 },
7aacca6f
DM
4176 "permissions" : {
4177 "check" : [
4178 "perm",
4179 "/vms/{vmid}",
4180 [
4181 "VM.Config.Network"
4182 ]
4183 ]
4184 },
4185 "protected" : 1,
7aacca6f
DM
4186 "returns" : {
4187 "type" : "null"
44660702 4188 }
56122987
DM
4189 }
4190 },
44660702 4191 "leaf" : 1,
7aacca6f 4192 "path" : "/nodes/{node}/qemu/{vmid}/firewall/aliases/{name}",
44660702 4193 "text" : "{name}"
56122987
DM
4194 }
4195 ],
4196 "info" : {
44660702
DM
4197 "GET" : {
4198 "description" : "List aliases",
4199 "method" : "GET",
4200 "name" : "get_aliases",
56122987 4201 "parameters" : {
44660702 4202 "additionalProperties" : 0,
56122987 4203 "properties" : {
7aacca6f 4204 "node" : {
7aacca6f 4205 "description" : "The cluster node name.",
44660702 4206 "format" : "pve-node",
013dc89f
DM
4207 "type" : "string",
4208 "typetext" : "<string>"
56122987 4209 },
44660702
DM
4210 "vmid" : {
4211 "description" : "The (unique) ID of the VM.",
4212 "format" : "pve-vmid",
4213 "minimum" : 1,
4bd7df8b 4214 "type" : "integer",
013dc89f 4215 "typetext" : "<integer> (1 - N)"
56122987 4216 }
44660702 4217 }
56122987 4218 },
56122987
DM
4219 "permissions" : {
4220 "check" : [
4221 "perm",
4222 "/vms/{vmid}",
4223 [
44660702 4224 "VM.Audit"
56122987
DM
4225 ]
4226 ]
4227 },
56122987
DM
4228 "returns" : {
4229 "items" : {
4230 "properties" : {
44660702 4231 "cidr" : {
56122987
DM
4232 "type" : "string"
4233 },
44660702
DM
4234 "comment" : {
4235 "optional" : 1,
7aacca6f 4236 "type" : "string"
56122987
DM
4237 },
4238 "digest" : {
56122987 4239 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702 4240 "maxLength" : 40,
56122987
DM
4241 "optional" : 0,
4242 "type" : "string"
4243 },
44660702 4244 "name" : {
56122987
DM
4245 "type" : "string"
4246 }
44660702
DM
4247 },
4248 "type" : "object"
56122987 4249 },
56122987
DM
4250 "links" : [
4251 {
4252 "href" : "{name}",
4253 "rel" : "child"
4254 }
44660702
DM
4255 ],
4256 "type" : "array"
4257 }
4258 },
4259 "POST" : {
4260 "description" : "Create IP or Network Alias.",
4261 "method" : "POST",
4262 "name" : "create_alias",
56122987 4263 "parameters" : {
7aacca6f 4264 "additionalProperties" : 0,
56122987 4265 "properties" : {
44660702
DM
4266 "cidr" : {
4267 "description" : "Network/IP specification in CIDR format.",
4268 "format" : "IPorCIDR",
013dc89f
DM
4269 "type" : "string",
4270 "typetext" : "<string>"
44660702
DM
4271 },
4272 "comment" : {
4273 "optional" : 1,
013dc89f
DM
4274 "type" : "string",
4275 "typetext" : "<string>"
44660702
DM
4276 },
4277 "name" : {
4278 "description" : "Alias name.",
4279 "maxLength" : 64,
4280 "minLength" : 2,
4281 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4282 "type" : "string"
56122987
DM
4283 },
4284 "node" : {
7aacca6f 4285 "description" : "The cluster node name.",
44660702 4286 "format" : "pve-node",
013dc89f
DM
4287 "type" : "string",
4288 "typetext" : "<string>"
44660702
DM
4289 },
4290 "vmid" : {
4291 "description" : "The (unique) ID of the VM.",
4292 "format" : "pve-vmid",
4293 "minimum" : 1,
4bd7df8b 4294 "type" : "integer",
013dc89f 4295 "typetext" : "<integer> (1 - N)"
56122987 4296 }
7aacca6f 4297 }
56122987 4298 },
44660702
DM
4299 "permissions" : {
4300 "check" : [
4301 "perm",
4302 "/vms/{vmid}",
4303 [
4304 "VM.Config.Network"
4305 ]
4306 ]
4307 },
4308 "protected" : 1,
4309 "returns" : {
4310 "type" : "null"
4311 }
56122987 4312 }
44660702
DM
4313 },
4314 "leaf" : 0,
4315 "path" : "/nodes/{node}/qemu/{vmid}/firewall/aliases",
4316 "text" : "aliases"
56122987
DM
4317 },
4318 {
56122987
DM
4319 "children" : [
4320 {
7aacca6f
DM
4321 "children" : [
4322 {
4323 "info" : {
4324 "DELETE" : {
44660702 4325 "description" : "Remove IP or Network from IPSet.",
7aacca6f 4326 "method" : "DELETE",
44660702 4327 "name" : "remove_ip",
7aacca6f 4328 "parameters" : {
44660702 4329 "additionalProperties" : 0,
7aacca6f 4330 "properties" : {
44660702
DM
4331 "cidr" : {
4332 "description" : "Network/IP specification in CIDR format.",
4333 "format" : "IPorCIDRorAlias",
013dc89f
DM
4334 "type" : "string",
4335 "typetext" : "<string>"
44660702
DM
4336 },
4337 "digest" : {
4338 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
4339 "maxLength" : 40,
4340 "optional" : 1,
013dc89f
DM
4341 "type" : "string",
4342 "typetext" : "<string>"
44660702 4343 },
7aacca6f 4344 "name" : {
7aacca6f 4345 "description" : "IP set name.",
44660702
DM
4346 "maxLength" : 64,
4347 "minLength" : 2,
7aacca6f 4348 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 4349 "type" : "string"
7aacca6f
DM
4350 },
4351 "node" : {
4352 "description" : "The cluster node name.",
44660702 4353 "format" : "pve-node",
013dc89f
DM
4354 "type" : "string",
4355 "typetext" : "<string>"
7aacca6f
DM
4356 },
4357 "vmid" : {
44660702 4358 "description" : "The (unique) ID of the VM.",
7aacca6f 4359 "format" : "pve-vmid",
44660702 4360 "minimum" : 1,
4bd7df8b 4361 "type" : "integer",
013dc89f 4362 "typetext" : "<integer> (1 - N)"
7aacca6f 4363 }
44660702 4364 }
7aacca6f 4365 },
7aacca6f
DM
4366 "permissions" : {
4367 "check" : [
4368 "perm",
4369 "/vms/{vmid}",
4370 [
4371 "VM.Config.Network"
4372 ]
4373 ]
4374 },
4375 "protected" : 1,
44660702
DM
4376 "returns" : {
4377 "type" : "null"
4378 }
56122987 4379 },
44660702
DM
4380 "GET" : {
4381 "description" : "Read IP or Network settings from IPSet.",
4382 "method" : "GET",
4383 "name" : "read_ip",
7aacca6f 4384 "parameters" : {
44660702 4385 "additionalProperties" : 0,
7aacca6f 4386 "properties" : {
7aacca6f 4387 "cidr" : {
44660702 4388 "description" : "Network/IP specification in CIDR format.",
7aacca6f 4389 "format" : "IPorCIDRorAlias",
013dc89f
DM
4390 "type" : "string",
4391 "typetext" : "<string>"
7aacca6f
DM
4392 },
4393 "name" : {
7aacca6f 4394 "description" : "IP set name.",
44660702 4395 "maxLength" : 64,
7aacca6f 4396 "minLength" : 2,
44660702
DM
4397 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4398 "type" : "string"
7aacca6f 4399 },
44660702
DM
4400 "node" : {
4401 "description" : "The cluster node name.",
4402 "format" : "pve-node",
013dc89f
DM
4403 "type" : "string",
4404 "typetext" : "<string>"
7aacca6f 4405 },
44660702
DM
4406 "vmid" : {
4407 "description" : "The (unique) ID of the VM.",
4408 "format" : "pve-vmid",
4409 "minimum" : 1,
4bd7df8b 4410 "type" : "integer",
013dc89f 4411 "typetext" : "<integer> (1 - N)"
7aacca6f 4412 }
44660702 4413 }
7aacca6f 4414 },
44660702
DM
4415 "permissions" : {
4416 "check" : [
4417 "perm",
4418 "/vms/{vmid}",
4419 [
4420 "VM.Audit"
4421 ]
4422 ]
4423 },
4424 "protected" : 1,
7aacca6f 4425 "returns" : {
44660702 4426 "type" : "object"
7aacca6f 4427 }
56122987 4428 },
44660702
DM
4429 "PUT" : {
4430 "description" : "Update IP or Network settings",
4431 "method" : "PUT",
4432 "name" : "update_ip",
7aacca6f
DM
4433 "parameters" : {
4434 "additionalProperties" : 0,
4435 "properties" : {
44660702
DM
4436 "cidr" : {
4437 "description" : "Network/IP specification in CIDR format.",
4438 "format" : "IPorCIDRorAlias",
013dc89f
DM
4439 "type" : "string",
4440 "typetext" : "<string>"
44660702
DM
4441 },
4442 "comment" : {
4443 "optional" : 1,
013dc89f
DM
4444 "type" : "string",
4445 "typetext" : "<string>"
44660702
DM
4446 },
4447 "digest" : {
4448 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
4449 "maxLength" : 40,
4450 "optional" : 1,
013dc89f
DM
4451 "type" : "string",
4452 "typetext" : "<string>"
44660702 4453 },
7aacca6f 4454 "name" : {
7aacca6f 4455 "description" : "IP set name.",
44660702 4456 "maxLength" : 64,
7aacca6f 4457 "minLength" : 2,
44660702
DM
4458 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4459 "type" : "string"
7aacca6f
DM
4460 },
4461 "node" : {
7aacca6f 4462 "description" : "The cluster node name.",
44660702 4463 "format" : "pve-node",
013dc89f
DM
4464 "type" : "string",
4465 "typetext" : "<string>"
7aacca6f 4466 },
44660702
DM
4467 "nomatch" : {
4468 "optional" : 1,
013dc89f
DM
4469 "type" : "boolean",
4470 "typetext" : "<boolean>"
7aacca6f
DM
4471 },
4472 "vmid" : {
4473 "description" : "The (unique) ID of the VM.",
44660702 4474 "format" : "pve-vmid",
7aacca6f 4475 "minimum" : 1,
4bd7df8b 4476 "type" : "integer",
013dc89f 4477 "typetext" : "<integer> (1 - N)"
7aacca6f
DM
4478 }
4479 }
4480 },
4481 "permissions" : {
4482 "check" : [
4483 "perm",
4484 "/vms/{vmid}",
4485 [
44660702 4486 "VM.Config.Network"
7aacca6f
DM
4487 ]
4488 ]
4489 },
7aacca6f 4490 "protected" : 1,
7aacca6f 4491 "returns" : {
44660702 4492 "type" : "null"
7aacca6f 4493 }
56122987 4494 }
7aacca6f 4495 },
7aacca6f 4496 "leaf" : 1,
44660702
DM
4497 "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset/{name}/{cidr}",
4498 "text" : "{cidr}"
7aacca6f 4499 }
44660702
DM
4500 ],
4501 "info" : {
4502 "DELETE" : {
4503 "description" : "Delete IPSet",
4504 "method" : "DELETE",
4505 "name" : "delete_ipset",
4506 "parameters" : {
4507 "additionalProperties" : 0,
4508 "properties" : {
4509 "name" : {
4510 "description" : "IP set name.",
4511 "maxLength" : 64,
4512 "minLength" : 2,
4513 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4514 "type" : "string"
4515 },
4516 "node" : {
4517 "description" : "The cluster node name.",
4518 "format" : "pve-node",
013dc89f
DM
4519 "type" : "string",
4520 "typetext" : "<string>"
44660702
DM
4521 },
4522 "vmid" : {
4523 "description" : "The (unique) ID of the VM.",
4524 "format" : "pve-vmid",
4525 "minimum" : 1,
4bd7df8b 4526 "type" : "integer",
013dc89f 4527 "typetext" : "<integer> (1 - N)"
44660702
DM
4528 }
4529 }
7aacca6f 4530 },
44660702
DM
4531 "permissions" : {
4532 "check" : [
4533 "perm",
4534 "/vms/{vmid}",
4535 [
4536 "VM.Config.Network"
4537 ]
4538 ]
7aacca6f 4539 },
44660702
DM
4540 "protected" : 1,
4541 "returns" : {
4542 "type" : "null"
4543 }
4544 },
4545 "GET" : {
4546 "description" : "List IPSet content",
4547 "method" : "GET",
4548 "name" : "get_ipset",
4549 "parameters" : {
4550 "additionalProperties" : 0,
4551 "properties" : {
4552 "name" : {
4553 "description" : "IP set name.",
4554 "maxLength" : 64,
4555 "minLength" : 2,
4556 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4557 "type" : "string"
4558 },
4559 "node" : {
4560 "description" : "The cluster node name.",
4561 "format" : "pve-node",
013dc89f
DM
4562 "type" : "string",
4563 "typetext" : "<string>"
44660702
DM
4564 },
4565 "vmid" : {
4566 "description" : "The (unique) ID of the VM.",
4567 "format" : "pve-vmid",
4568 "minimum" : 1,
4bd7df8b 4569 "type" : "integer",
013dc89f 4570 "typetext" : "<integer> (1 - N)"
44660702
DM
4571 }
4572 }
7aacca6f 4573 },
44660702
DM
4574 "permissions" : {
4575 "check" : [
4576 "perm",
4577 "/vms/{vmid}",
4578 [
4579 "VM.Audit"
4580 ]
4581 ]
7aacca6f 4582 },
44660702
DM
4583 "returns" : {
4584 "items" : {
4585 "properties" : {
4586 "cidr" : {
4587 "type" : "string"
4588 },
4589 "comment" : {
4590 "optional" : 1,
4591 "type" : "string"
4592 },
4593 "digest" : {
4594 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
4595 "maxLength" : 40,
4596 "optional" : 0,
4597 "type" : "string"
4598 },
4599 "nomatch" : {
4600 "optional" : 1,
4601 "type" : "boolean"
4602 }
4603 },
4604 "type" : "object"
4605 },
4606 "links" : [
4607 {
4608 "href" : "{cidr}",
4609 "rel" : "child"
4610 }
4611 ],
4612 "type" : "array"
56122987
DM
4613 }
4614 },
44660702
DM
4615 "POST" : {
4616 "description" : "Add IP or Network to IPSet.",
4617 "method" : "POST",
4618 "name" : "create_ip",
4619 "parameters" : {
4620 "additionalProperties" : 0,
4621 "properties" : {
4622 "cidr" : {
4623 "description" : "Network/IP specification in CIDR format.",
4624 "format" : "IPorCIDRorAlias",
013dc89f
DM
4625 "type" : "string",
4626 "typetext" : "<string>"
44660702
DM
4627 },
4628 "comment" : {
4629 "optional" : 1,
013dc89f
DM
4630 "type" : "string",
4631 "typetext" : "<string>"
44660702
DM
4632 },
4633 "name" : {
4634 "description" : "IP set name.",
4635 "maxLength" : 64,
4636 "minLength" : 2,
4637 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4638 "type" : "string"
4639 },
4640 "node" : {
4641 "description" : "The cluster node name.",
4642 "format" : "pve-node",
013dc89f
DM
4643 "type" : "string",
4644 "typetext" : "<string>"
44660702
DM
4645 },
4646 "nomatch" : {
4647 "optional" : 1,
013dc89f
DM
4648 "type" : "boolean",
4649 "typetext" : "<boolean>"
44660702
DM
4650 },
4651 "vmid" : {
4652 "description" : "The (unique) ID of the VM.",
4653 "format" : "pve-vmid",
4654 "minimum" : 1,
4bd7df8b 4655 "type" : "integer",
013dc89f 4656 "typetext" : "<integer> (1 - N)"
44660702
DM
4657 }
4658 }
4659 },
4660 "permissions" : {
4661 "check" : [
4662 "perm",
4663 "/vms/{vmid}",
4664 [
4665 "VM.Config.Network"
4666 ]
4667 ]
4668 },
4669 "protected" : 1,
4670 "returns" : {
4671 "type" : "null"
4672 }
4673 }
4674 },
4675 "leaf" : 0,
4676 "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset/{name}",
4677 "text" : "{name}"
4678 }
4679 ],
4680 "info" : {
4681 "GET" : {
4682 "description" : "List IPSets",
4683 "method" : "GET",
4684 "name" : "ipset_index",
4685 "parameters" : {
4686 "additionalProperties" : 0,
4687 "properties" : {
4688 "node" : {
4689 "description" : "The cluster node name.",
4690 "format" : "pve-node",
013dc89f
DM
4691 "type" : "string",
4692 "typetext" : "<string>"
44660702
DM
4693 },
4694 "vmid" : {
4695 "description" : "The (unique) ID of the VM.",
4696 "format" : "pve-vmid",
4697 "minimum" : 1,
4bd7df8b 4698 "type" : "integer",
013dc89f 4699 "typetext" : "<integer> (1 - N)"
44660702
DM
4700 }
4701 }
56122987
DM
4702 },
4703 "permissions" : {
4704 "check" : [
4705 "perm",
4706 "/vms/{vmid}",
4707 [
44660702 4708 "VM.Audit"
56122987
DM
4709 ]
4710 ]
4711 },
7aacca6f 4712 "returns" : {
7aacca6f
DM
4713 "items" : {
4714 "properties" : {
7aacca6f
DM
4715 "comment" : {
4716 "optional" : 1,
4717 "type" : "string"
4718 },
4719 "digest" : {
7aacca6f 4720 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702
DM
4721 "maxLength" : 40,
4722 "optional" : 0,
4723 "type" : "string"
4724 },
4725 "name" : {
4726 "description" : "IP set name.",
4727 "maxLength" : 64,
4728 "minLength" : 2,
4729 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4730 "type" : "string"
7aacca6f
DM
4731 }
4732 },
4733 "type" : "object"
4734 },
4735 "links" : [
4736 {
44660702
DM
4737 "href" : "{name}",
4738 "rel" : "child"
7aacca6f 4739 }
44660702
DM
4740 ],
4741 "type" : "array"
4742 }
4743 },
4744 "POST" : {
4745 "description" : "Create new IPSet",
4746 "method" : "POST",
4747 "name" : "create_ipset",
56122987
DM
4748 "parameters" : {
4749 "additionalProperties" : 0,
4750 "properties" : {
44660702
DM
4751 "comment" : {
4752 "optional" : 1,
013dc89f
DM
4753 "type" : "string",
4754 "typetext" : "<string>"
56122987 4755 },
44660702
DM
4756 "digest" : {
4757 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
4758 "maxLength" : 40,
4759 "optional" : 1,
013dc89f
DM
4760 "type" : "string",
4761 "typetext" : "<string>"
44660702
DM
4762 },
4763 "name" : {
4764 "description" : "IP set name.",
4765 "maxLength" : 64,
4766 "minLength" : 2,
4767 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4768 "type" : "string"
4769 },
4770 "node" : {
4771 "description" : "The cluster node name.",
4772 "format" : "pve-node",
013dc89f
DM
4773 "type" : "string",
4774 "typetext" : "<string>"
44660702
DM
4775 },
4776 "rename" : {
4777 "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.",
4778 "maxLength" : 64,
4779 "minLength" : 2,
4780 "optional" : 1,
4781 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4782 "type" : "string"
4783 },
4784 "vmid" : {
4785 "description" : "The (unique) ID of the VM.",
4786 "format" : "pve-vmid",
4787 "minimum" : 1,
4bd7df8b 4788 "type" : "integer",
013dc89f 4789 "typetext" : "<integer> (1 - N)"
44660702
DM
4790 }
4791 }
4792 },
7aacca6f
DM
4793 "permissions" : {
4794 "check" : [
4795 "perm",
4796 "/vms/{vmid}",
4797 [
4798 "VM.Config.Network"
4799 ]
4800 ]
4801 },
44660702 4802 "protected" : 1,
56122987 4803 "returns" : {
7aacca6f 4804 "type" : "null"
44660702
DM
4805 }
4806 }
4807 },
4808 "leaf" : 0,
4809 "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset",
4810 "text" : "ipset"
4811 },
4812 {
4813 "info" : {
4814 "GET" : {
4815 "description" : "Get VM firewall options.",
4816 "method" : "GET",
4817 "name" : "get_options",
7aacca6f
DM
4818 "parameters" : {
4819 "additionalProperties" : 0,
56122987 4820 "properties" : {
7aacca6f
DM
4821 "node" : {
4822 "description" : "The cluster node name.",
44660702 4823 "format" : "pve-node",
013dc89f
DM
4824 "type" : "string",
4825 "typetext" : "<string>"
7aacca6f 4826 },
44660702
DM
4827 "vmid" : {
4828 "description" : "The (unique) ID of the VM.",
4829 "format" : "pve-vmid",
4830 "minimum" : 1,
4bd7df8b 4831 "type" : "integer",
013dc89f 4832 "typetext" : "<integer> (1 - N)"
44660702
DM
4833 }
4834 }
4835 },
4836 "permissions" : {
4837 "check" : [
4838 "perm",
4839 "/vms/{vmid}",
4840 [
4841 "VM.Audit"
4842 ]
4843 ]
4844 },
4845 "proxyto" : "node",
4846 "returns" : {
4847 "properties" : {
4848 "dhcp" : {
4849 "description" : "Enable DHCP.",
56122987 4850 "optional" : 1,
44660702 4851 "type" : "boolean"
56122987 4852 },
44660702
DM
4853 "enable" : {
4854 "description" : "Enable/disable firewall rules.",
7aacca6f 4855 "optional" : 1,
44660702 4856 "type" : "boolean"
56122987 4857 },
44660702
DM
4858 "ipfilter" : {
4859 "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net<id> ipset for every interface. Such ipsets implicitly contain sane default restrictions such as restricting IPv6 link local addresses to the one derived from the interface's MAC address. For containers the configured IP addresses will be implicitly added.",
7aacca6f 4860 "optional" : 1,
44660702 4861 "type" : "boolean"
7aacca6f 4862 },
56122987 4863 "log_level_in" : {
7aacca6f 4864 "description" : "Log level for incoming traffic.",
56122987
DM
4865 "enum" : [
4866 "emerg",
4867 "alert",
4868 "crit",
4869 "err",
4870 "warning",
4871 "notice",
4872 "info",
4873 "debug",
4874 "nolog"
4875 ],
56122987
DM
4876 "optional" : 1,
4877 "type" : "string"
4878 },
44660702
DM
4879 "log_level_out" : {
4880 "description" : "Log level for outgoing traffic.",
4881 "enum" : [
4882 "emerg",
4883 "alert",
4884 "crit",
4885 "err",
4886 "warning",
4887 "notice",
4888 "info",
4889 "debug",
4890 "nolog"
4891 ],
4892 "optional" : 1,
4893 "type" : "string"
4894 },
4895 "macfilter" : {
4896 "description" : "Enable/disable MAC address filter.",
56122987 4897 "optional" : 1,
7aacca6f 4898 "type" : "boolean"
56122987
DM
4899 },
4900 "ndp" : {
44660702 4901 "description" : "Enable NDP.",
56122987 4902 "optional" : 1,
44660702 4903 "type" : "boolean"
56122987
DM
4904 },
4905 "policy_in" : {
56122987
DM
4906 "description" : "Input policy.",
4907 "enum" : [
4908 "ACCEPT",
4909 "REJECT",
4910 "DROP"
44660702
DM
4911 ],
4912 "optional" : 1,
4913 "type" : "string"
56122987 4914 },
44660702
DM
4915 "policy_out" : {
4916 "description" : "Output policy.",
4917 "enum" : [
4918 "ACCEPT",
4919 "REJECT",
4920 "DROP"
4921 ],
4922 "optional" : 1,
4923 "type" : "string"
4924 },
4925 "radv" : {
4926 "description" : "Allow sending Router Advertisement.",
4927 "optional" : 1,
4928 "type" : "boolean"
4929 }
4930 },
4931 "type" : "object"
4932 }
4933 },
4934 "PUT" : {
4935 "description" : "Set Firewall options.",
4936 "method" : "PUT",
4937 "name" : "set_options",
4938 "parameters" : {
4939 "additionalProperties" : 0,
4940 "properties" : {
4941 "delete" : {
4942 "description" : "A list of settings you want to delete.",
4943 "format" : "pve-configid-list",
4944 "optional" : 1,
013dc89f
DM
4945 "type" : "string",
4946 "typetext" : "<string>"
44660702
DM
4947 },
4948 "dhcp" : {
4949 "description" : "Enable DHCP.",
7aacca6f 4950 "optional" : 1,
013dc89f
DM
4951 "type" : "boolean",
4952 "typetext" : "<boolean>"
7aacca6f
DM
4953 },
4954 "digest" : {
4955 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702 4956 "maxLength" : 40,
7aacca6f 4957 "optional" : 1,
013dc89f
DM
4958 "type" : "string",
4959 "typetext" : "<string>"
7aacca6f
DM
4960 },
4961 "enable" : {
4962 "description" : "Enable/disable firewall rules.",
56122987 4963 "optional" : 1,
013dc89f
DM
4964 "type" : "boolean",
4965 "typetext" : "<boolean>"
7aacca6f 4966 },
44660702
DM
4967 "ipfilter" : {
4968 "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net<id> ipset for every interface. Such ipsets implicitly contain sane default restrictions such as restricting IPv6 link local addresses to the one derived from the interface's MAC address. For containers the configured IP addresses will be implicitly added.",
4969 "optional" : 1,
013dc89f
DM
4970 "type" : "boolean",
4971 "typetext" : "<boolean>"
44660702
DM
4972 },
4973 "log_level_in" : {
4974 "description" : "Log level for incoming traffic.",
56122987
DM
4975 "enum" : [
4976 "emerg",
4977 "alert",
4978 "crit",
4979 "err",
4980 "warning",
4981 "notice",
4982 "info",
4983 "debug",
4984 "nolog"
7aacca6f 4985 ],
7aacca6f 4986 "optional" : 1,
44660702 4987 "type" : "string"
7aacca6f 4988 },
44660702
DM
4989 "log_level_out" : {
4990 "description" : "Log level for outgoing traffic.",
56122987
DM
4991 "enum" : [
4992 "emerg",
4993 "alert",
4994 "crit",
4995 "err",
4996 "warning",
4997 "notice",
4998 "info",
4999 "debug",
5000 "nolog"
5001 ],
56122987 5002 "optional" : 1,
44660702 5003 "type" : "string"
56122987
DM
5004 },
5005 "macfilter" : {
56122987 5006 "description" : "Enable/disable MAC address filter.",
7aacca6f 5007 "optional" : 1,
013dc89f
DM
5008 "type" : "boolean",
5009 "typetext" : "<boolean>"
56122987 5010 },
44660702
DM
5011 "ndp" : {
5012 "description" : "Enable NDP.",
5013 "optional" : 1,
013dc89f
DM
5014 "type" : "boolean",
5015 "typetext" : "<boolean>"
44660702
DM
5016 },
5017 "node" : {
5018 "description" : "The cluster node name.",
5019 "format" : "pve-node",
013dc89f
DM
5020 "type" : "string",
5021 "typetext" : "<string>"
44660702 5022 },
56122987 5023 "policy_in" : {
44660702 5024 "description" : "Input policy.",
56122987
DM
5025 "enum" : [
5026 "ACCEPT",
5027 "REJECT",
5028 "DROP"
7aacca6f 5029 ],
56122987 5030 "optional" : 1,
7aacca6f 5031 "type" : "string"
56122987 5032 },
44660702
DM
5033 "policy_out" : {
5034 "description" : "Output policy.",
5035 "enum" : [
5036 "ACCEPT",
5037 "REJECT",
5038 "DROP"
5039 ],
56122987 5040 "optional" : 1,
44660702 5041 "type" : "string"
56122987 5042 },
44660702
DM
5043 "radv" : {
5044 "description" : "Allow sending Router Advertisement.",
56122987 5045 "optional" : 1,
013dc89f
DM
5046 "type" : "boolean",
5047 "typetext" : "<boolean>"
7aacca6f
DM
5048 },
5049 "vmid" : {
5050 "description" : "The (unique) ID of the VM.",
44660702 5051 "format" : "pve-vmid",
7aacca6f 5052 "minimum" : 1,
4bd7df8b 5053 "type" : "integer",
013dc89f 5054 "typetext" : "<integer> (1 - N)"
56122987
DM
5055 }
5056 }
5057 },
56122987
DM
5058 "permissions" : {
5059 "check" : [
5060 "perm",
5061 "/vms/{vmid}",
5062 [
44660702 5063 "VM.Config.Network"
56122987
DM
5064 ]
5065 ]
7aacca6f 5066 },
44660702 5067 "protected" : 1,
7aacca6f 5068 "proxyto" : "node",
44660702
DM
5069 "returns" : {
5070 "type" : "null"
5071 }
56122987
DM
5072 }
5073 },
44660702 5074 "leaf" : 1,
7aacca6f 5075 "path" : "/nodes/{node}/qemu/{vmid}/firewall/options",
44660702 5076 "text" : "options"
56122987
DM
5077 },
5078 {
56122987
DM
5079 "info" : {
5080 "GET" : {
44660702
DM
5081 "description" : "Read firewall log",
5082 "method" : "GET",
5083 "name" : "log",
5084 "parameters" : {
5085 "additionalProperties" : 0,
5086 "properties" : {
5087 "limit" : {
5088 "minimum" : 0,
5089 "optional" : 1,
4bd7df8b 5090 "type" : "integer",
013dc89f 5091 "typetext" : "<integer> (0 - N)"
56122987 5092 },
44660702
DM
5093 "node" : {
5094 "description" : "The cluster node name.",
5095 "format" : "pve-node",
013dc89f
DM
5096 "type" : "string",
5097 "typetext" : "<string>"
44660702
DM
5098 },
5099 "start" : {
5100 "minimum" : 0,
5101 "optional" : 1,
4bd7df8b 5102 "type" : "integer",
013dc89f 5103 "typetext" : "<integer> (0 - N)"
44660702
DM
5104 },
5105 "vmid" : {
5106 "description" : "The (unique) ID of the VM.",
5107 "format" : "pve-vmid",
5108 "minimum" : 1,
4bd7df8b 5109 "type" : "integer",
013dc89f 5110 "typetext" : "<integer> (1 - N)"
44660702
DM
5111 }
5112 }
7aacca6f 5113 },
7aacca6f
DM
5114 "permissions" : {
5115 "check" : [
5116 "perm",
5117 "/vms/{vmid}",
5118 [
5119 "VM.Console"
5120 ]
5121 ]
56122987 5122 },
7aacca6f 5123 "protected" : 1,
44660702
DM
5124 "proxyto" : "node",
5125 "returns" : {
5126 "items" : {
5127 "properties" : {
5128 "n" : {
5129 "description" : "Line number",
5130 "type" : "integer"
5131 },
5132 "t" : {
5133 "description" : "Line text",
5134 "type" : "string"
5135 }
56122987 5136 },
44660702 5137 "type" : "object"
7aacca6f 5138 },
44660702 5139 "type" : "array"
7aacca6f
DM
5140 }
5141 }
5142 },
44660702 5143 "leaf" : 1,
7aacca6f 5144 "path" : "/nodes/{node}/qemu/{vmid}/firewall/log",
44660702 5145 "text" : "log"
7aacca6f
DM
5146 },
5147 {
7aacca6f
DM
5148 "info" : {
5149 "GET" : {
5150 "description" : "Lists possible IPSet/Alias reference which are allowed in source/dest properties.",
44660702
DM
5151 "method" : "GET",
5152 "name" : "refs",
56122987 5153 "parameters" : {
44660702 5154 "additionalProperties" : 0,
56122987
DM
5155 "properties" : {
5156 "node" : {
7aacca6f 5157 "description" : "The cluster node name.",
44660702 5158 "format" : "pve-node",
013dc89f
DM
5159 "type" : "string",
5160 "typetext" : "<string>"
56122987
DM
5161 },
5162 "type" : {
56122987
DM
5163 "description" : "Only list references of specified type.",
5164 "enum" : [
5165 "alias",
5166 "ipset"
7aacca6f 5167 ],
44660702
DM
5168 "optional" : 1,
5169 "type" : "string"
5170 },
5171 "vmid" : {
5172 "description" : "The (unique) ID of the VM.",
5173 "format" : "pve-vmid",
5174 "minimum" : 1,
4bd7df8b 5175 "type" : "integer",
013dc89f 5176 "typetext" : "<integer> (1 - N)"
56122987 5177 }
44660702
DM
5178 }
5179 },
5180 "permissions" : {
5181 "check" : [
5182 "perm",
5183 "/vms/{vmid}",
5184 [
5185 "VM.Audit"
5186 ]
5187 ]
56122987
DM
5188 },
5189 "returns" : {
56122987
DM
5190 "items" : {
5191 "properties" : {
44660702
DM
5192 "comment" : {
5193 "optional" : 1,
56122987
DM
5194 "type" : "string"
5195 },
5196 "name" : {
5197 "type" : "string"
5198 },
44660702
DM
5199 "type" : {
5200 "enum" : [
5201 "alias",
5202 "ipset"
5203 ],
7aacca6f 5204 "type" : "string"
56122987
DM
5205 }
5206 },
5207 "type" : "object"
7aacca6f
DM
5208 },
5209 "type" : "array"
5210 }
56122987 5211 }
44660702
DM
5212 },
5213 "leaf" : 1,
5214 "path" : "/nodes/{node}/qemu/{vmid}/firewall/refs",
5215 "text" : "refs"
56122987
DM
5216 }
5217 ],
56122987
DM
5218 "info" : {
5219 "GET" : {
44660702 5220 "description" : "Directory index.",
56122987 5221 "method" : "GET",
44660702 5222 "name" : "index",
56122987 5223 "parameters" : {
44660702 5224 "additionalProperties" : 0,
56122987
DM
5225 "properties" : {
5226 "node" : {
5227 "description" : "The cluster node name.",
44660702 5228 "format" : "pve-node",
013dc89f
DM
5229 "type" : "string",
5230 "typetext" : "<string>"
56122987
DM
5231 },
5232 "vmid" : {
44660702 5233 "description" : "The (unique) ID of the VM.",
56122987
DM
5234 "format" : "pve-vmid",
5235 "minimum" : 1,
4bd7df8b 5236 "type" : "integer",
013dc89f 5237 "typetext" : "<integer> (1 - N)"
56122987 5238 }
44660702 5239 }
56122987 5240 },
56122987
DM
5241 "permissions" : {
5242 "user" : "all"
7aacca6f 5243 },
44660702
DM
5244 "returns" : {
5245 "items" : {
5246 "properties" : {},
5247 "type" : "object"
5248 },
5249 "links" : [
5250 {
5251 "href" : "{name}",
5252 "rel" : "child"
5253 }
5254 ],
5255 "type" : "array"
5256 }
56122987 5257 }
44660702
DM
5258 },
5259 "leaf" : 0,
5260 "path" : "/nodes/{node}/qemu/{vmid}/firewall",
5261 "text" : "firewall"
56122987
DM
5262 },
5263 {
56122987
DM
5264 "info" : {
5265 "GET" : {
44660702
DM
5266 "description" : "Read VM RRD statistics (returns PNG)",
5267 "method" : "GET",
7aacca6f 5268 "name" : "rrd",
56122987
DM
5269 "parameters" : {
5270 "additionalProperties" : 0,
5271 "properties" : {
7aacca6f 5272 "cf" : {
44660702 5273 "description" : "The RRD consolidation function",
7aacca6f
DM
5274 "enum" : [
5275 "AVERAGE",
5276 "MAX"
5277 ],
7aacca6f
DM
5278 "optional" : 1,
5279 "type" : "string"
5280 },
44660702
DM
5281 "ds" : {
5282 "description" : "The list of datasources you want to display.",
5283 "format" : "pve-configid-list",
013dc89f
DM
5284 "type" : "string",
5285 "typetext" : "<string>"
56122987
DM
5286 },
5287 "node" : {
44660702 5288 "description" : "The cluster node name.",
56122987 5289 "format" : "pve-node",
013dc89f
DM
5290 "type" : "string",
5291 "typetext" : "<string>"
56122987
DM
5292 },
5293 "timeframe" : {
44660702 5294 "description" : "Specify the time frame you are interested in.",
56122987
DM
5295 "enum" : [
5296 "hour",
5297 "day",
5298 "week",
5299 "month",
5300 "year"
5301 ],
56122987
DM
5302 "type" : "string"
5303 },
44660702
DM
5304 "vmid" : {
5305 "description" : "The (unique) ID of the VM.",
5306 "format" : "pve-vmid",
5307 "minimum" : 1,
4bd7df8b 5308 "type" : "integer",
013dc89f 5309 "typetext" : "<integer> (1 - N)"
56122987
DM
5310 }
5311 }
5312 },
56122987
DM
5313 "permissions" : {
5314 "check" : [
5315 "perm",
5316 "/vms/{vmid}",
5317 [
5318 "VM.Audit"
5319 ]
5320 ]
5321 },
7aacca6f
DM
5322 "protected" : 1,
5323 "returns" : {
5324 "properties" : {
5325 "filename" : {
5326 "type" : "string"
5327 }
5328 },
5329 "type" : "object"
44660702 5330 }
56122987 5331 }
44660702
DM
5332 },
5333 "leaf" : 1,
5334 "path" : "/nodes/{node}/qemu/{vmid}/rrd",
5335 "text" : "rrd"
56122987
DM
5336 },
5337 {
7aacca6f 5338 "info" : {
56122987 5339 "GET" : {
7aacca6f 5340 "description" : "Read VM RRD statistics",
44660702 5341 "method" : "GET",
56122987 5342 "name" : "rrddata",
56122987 5343 "parameters" : {
44660702 5344 "additionalProperties" : 0,
56122987 5345 "properties" : {
44660702
DM
5346 "cf" : {
5347 "description" : "The RRD consolidation function",
5348 "enum" : [
5349 "AVERAGE",
5350 "MAX"
5351 ],
5352 "optional" : 1,
5353 "type" : "string"
5354 },
56122987 5355 "node" : {
44660702 5356 "description" : "The cluster node name.",
56122987 5357 "format" : "pve-node",
013dc89f
DM
5358 "type" : "string",
5359 "typetext" : "<string>"
56122987
DM
5360 },
5361 "timeframe" : {
44660702 5362 "description" : "Specify the time frame you are interested in.",
56122987
DM
5363 "enum" : [
5364 "hour",
5365 "day",
5366 "week",
5367 "month",
5368 "year"
7aacca6f 5369 ],
44660702 5370 "type" : "string"
7aacca6f
DM
5371 },
5372 "vmid" : {
7aacca6f
DM
5373 "description" : "The (unique) ID of the VM.",
5374 "format" : "pve-vmid",
44660702 5375 "minimum" : 1,
4bd7df8b 5376 "type" : "integer",
013dc89f 5377 "typetext" : "<integer> (1 - N)"
56122987 5378 }
44660702 5379 }
56122987 5380 },
56122987
DM
5381 "permissions" : {
5382 "check" : [
5383 "perm",
5384 "/vms/{vmid}",
5385 [
5386 "VM.Audit"
5387 ]
5388 ]
5389 },
44660702 5390 "protected" : 1,
7aacca6f 5391 "returns" : {
7aacca6f 5392 "items" : {
44660702
DM
5393 "properties" : {},
5394 "type" : "object"
5395 },
5396 "type" : "array"
7aacca6f 5397 }
56122987
DM
5398 }
5399 },
44660702
DM
5400 "leaf" : 1,
5401 "path" : "/nodes/{node}/qemu/{vmid}/rrddata",
56122987
DM
5402 "text" : "rrddata"
5403 },
5404 {
56122987 5405 "info" : {
44660702
DM
5406 "GET" : {
5407 "description" : "Get current virtual machine configuration. This does not include pending configuration changes (see 'pending' API).",
5408 "method" : "GET",
5409 "name" : "vm_config",
5410 "parameters" : {
5411 "additionalProperties" : 0,
5412 "properties" : {
5413 "current" : {
5414 "default" : 0,
5415 "description" : "Get current values (instead of pending values).",
5416 "optional" : 1,
013dc89f
DM
5417 "type" : "boolean",
5418 "typetext" : "<boolean>"
44660702
DM
5419 },
5420 "node" : {
5421 "description" : "The cluster node name.",
5422 "format" : "pve-node",
013dc89f
DM
5423 "type" : "string",
5424 "typetext" : "<string>"
44660702
DM
5425 },
5426 "vmid" : {
5427 "description" : "The (unique) ID of the VM.",
5428 "format" : "pve-vmid",
5429 "minimum" : 1,
4bd7df8b 5430 "type" : "integer",
013dc89f 5431 "typetext" : "<integer> (1 - N)"
44660702
DM
5432 }
5433 }
7aacca6f 5434 },
56122987
DM
5435 "permissions" : {
5436 "check" : [
5437 "perm",
5438 "/vms/{vmid}",
5439 [
44660702
DM
5440 "VM.Audit"
5441 ]
56122987
DM
5442 ]
5443 },
56122987 5444 "proxyto" : "node",
44660702
DM
5445 "returns" : {
5446 "properties" : {
5447 "digest" : {
5448 "description" : "SHA1 digest of configuration file. This can be used to prevent concurrent modifications.",
5449 "type" : "string"
5450 }
5451 },
5452 "type" : "object"
5453 }
5454 },
5455 "POST" : {
7aacca6f
DM
5456 "description" : "Set virtual machine options (asynchrounous API).",
5457 "method" : "POST",
44660702 5458 "name" : "update_vm_async",
56122987 5459 "parameters" : {
44660702 5460 "additionalProperties" : 0,
56122987 5461 "properties" : {
44660702
DM
5462 "acpi" : {
5463 "default" : 1,
5464 "description" : "Enable/disable ACPI.",
5465 "optional" : 1,
013dc89f
DM
5466 "type" : "boolean",
5467 "typetext" : "<boolean>"
44660702
DM
5468 },
5469 "agent" : {
7aacca6f 5470 "default" : 0,
44660702 5471 "description" : "Enable/disable Qemu GuestAgent.",
7aacca6f 5472 "optional" : 1,
013dc89f
DM
5473 "type" : "boolean",
5474 "typetext" : "<boolean>"
7aacca6f 5475 },
44660702 5476 "args" : {
c2993fe5 5477 "description" : "Arbitrary arguments passed to kvm.",
44660702 5478 "optional" : 1,
c2993fe5 5479 "type" : "string",
013dc89f 5480 "typetext" : "<string>",
c2993fe5 5481 "verbose_description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n"
7aacca6f 5482 },
44660702
DM
5483 "autostart" : {
5484 "default" : 0,
5485 "description" : "Automatic restart after crash (currently ignored).",
56122987 5486 "optional" : 1,
013dc89f
DM
5487 "type" : "boolean",
5488 "typetext" : "<boolean>"
56122987 5489 },
44660702
DM
5490 "background_delay" : {
5491 "description" : "Time to wait for the task to finish. We return 'null' if the task finish within that time.",
5492 "maximum" : 30,
5493 "minimum" : 1,
7aacca6f 5494 "optional" : 1,
4bd7df8b 5495 "type" : "integer",
013dc89f 5496 "typetext" : "<integer> (1 - 30)"
56122987 5497 },
44660702
DM
5498 "balloon" : {
5499 "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.",
5500 "minimum" : 0,
7aacca6f 5501 "optional" : 1,
4bd7df8b 5502 "type" : "integer",
013dc89f 5503 "typetext" : "<integer> (0 - N)"
7aacca6f 5504 },
44660702
DM
5505 "bios" : {
5506 "default" : "seabios",
5507 "description" : "Select BIOS implementation.",
5508 "enum" : [
5509 "seabios",
5510 "ovmf"
5511 ],
56122987 5512 "optional" : 1,
44660702 5513 "type" : "string"
7aacca6f 5514 },
44660702
DM
5515 "boot" : {
5516 "default" : "cdn",
5517 "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).",
5518 "optional" : 1,
5519 "pattern" : "[acdn]{1,4}",
5520 "type" : "string"
5521 },
5522 "bootdisk" : {
5523 "description" : "Enable booting from specified disk.",
5524 "format" : "pve-qm-bootdisk",
5525 "optional" : 1,
5526 "pattern" : "(ide|sata|scsi|virtio)\\d+",
5527 "type" : "string"
5528 },
5529 "cdrom" : {
5530 "description" : "This is an alias for option -ide2",
de0983cb 5531 "format" : "pve-qm-ide",
44660702 5532 "optional" : 1,
7aacca6f 5533 "type" : "string",
013dc89f 5534 "typetext" : "<volume>"
44660702
DM
5535 },
5536 "cores" : {
5537 "default" : 1,
5538 "description" : "The number of cores per socket.",
5539 "minimum" : 1,
7aacca6f 5540 "optional" : 1,
4bd7df8b 5541 "type" : "integer",
013dc89f 5542 "typetext" : "<integer> (1 - N)"
7aacca6f 5543 },
44660702
DM
5544 "cpu" : {
5545 "description" : "Emulated CPU type.",
56122987 5546 "format" : {
44660702
DM
5547 "cputype" : {
5548 "default" : "kvm64",
7aacca6f 5549 "default_key" : 1,
44660702 5550 "description" : "Emulated CPU type.",
56122987 5551 "enum" : [
44660702
DM
5552 "486",
5553 "athlon",
f004f5b9
DM
5554 "Broadwell",
5555 "Broadwell-noTSX",
5556 "Conroe",
44660702 5557 "core2duo",
f004f5b9
DM
5558 "coreduo",
5559 "Haswell",
5560 "Haswell-noTSX",
5561 "host",
5562 "IvyBridge",
44660702
DM
5563 "kvm32",
5564 "kvm64",
44660702 5565 "Nehalem",
44660702
DM
5566 "Opteron_G1",
5567 "Opteron_G2",
5568 "Opteron_G3",
5569 "Opteron_G4",
5570 "Opteron_G5",
f004f5b9
DM
5571 "Penryn",
5572 "pentium",
5573 "pentium2",
5574 "pentium3",
5575 "phenom",
5576 "qemu32",
5577 "qemu64",
5578 "SandyBridge",
5579 "Westmere"
56122987 5580 ],
56122987
DM
5581 "type" : "string"
5582 },
44660702
DM
5583 "hidden" : {
5584 "default" : 0,
5585 "description" : "Do not identify as a KVM virtual machine.",
56122987 5586 "optional" : 1,
44660702
DM
5587 "type" : "boolean"
5588 }
5589 },
5590 "optional" : 1,
4bd7df8b 5591 "type" : "string",
013dc89f 5592 "typetext" : "[cputype=]<enum> [,hidden=<1|0>]"
44660702
DM
5593 },
5594 "cpulimit" : {
5595 "default" : 0,
c2993fe5 5596 "description" : "Limit of CPU usage.",
44660702
DM
5597 "maximum" : 128,
5598 "minimum" : 0,
5599 "optional" : 1,
c2993fe5 5600 "type" : "number",
013dc89f 5601 "typetext" : "<number> (0 - 128)",
c2993fe5 5602 "verbose_description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has total of '2' CPU time. Value '0' indicates no CPU limit."
44660702
DM
5603 },
5604 "cpuunits" : {
de0983cb 5605 "default" : 1024,
c2993fe5 5606 "description" : "CPU weight for a VM.",
44660702
DM
5607 "maximum" : 500000,
5608 "minimum" : 0,
5609 "optional" : 1,
c2993fe5 5610 "type" : "integer",
013dc89f 5611 "typetext" : "<integer> (0 - 500000)",
c2993fe5 5612 "verbose_description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0."
44660702
DM
5613 },
5614 "delete" : {
5615 "description" : "A list of settings you want to delete.",
5616 "format" : "pve-configid-list",
5617 "optional" : 1,
013dc89f
DM
5618 "type" : "string",
5619 "typetext" : "<string>"
44660702
DM
5620 },
5621 "description" : {
5622 "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.",
5623 "optional" : 1,
013dc89f
DM
5624 "type" : "string",
5625 "typetext" : "<string>"
44660702
DM
5626 },
5627 "digest" : {
5628 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
5629 "maxLength" : 40,
5630 "optional" : 1,
013dc89f
DM
5631 "type" : "string",
5632 "typetext" : "<string>"
44660702
DM
5633 },
5634 "force" : {
5635 "description" : "Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal.",
5636 "optional" : 1,
5637 "requires" : "delete",
013dc89f
DM
5638 "type" : "boolean",
5639 "typetext" : "<boolean>"
44660702
DM
5640 },
5641 "freeze" : {
5642 "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).",
5643 "optional" : 1,
013dc89f
DM
5644 "type" : "boolean",
5645 "typetext" : "<boolean>"
44660702
DM
5646 },
5647 "hostpci[n]" : {
c2993fe5 5648 "description" : "Map host PCI devices into guest.",
44660702
DM
5649 "format" : "pve-qm-hostpci",
5650 "optional" : 1,
57b78691 5651 "type" : "string",
52e44c50 5652 "typetext" : "[host=]<HOSTPCIID[;HOSTPCIID2...]> [,pcie=<1|0>] [,rombar=<1|0>] [,romfile=<string>] [,x-vga=<1|0>]",
57b78691 5653 "verbose_description" : "Map host PCI devices into guest.\n\nNOTE: This option allows direct access to host hardware. So it is no longer \npossible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
44660702
DM
5654 },
5655 "hotplug" : {
5656 "default" : "network,disk,usb",
5657 "description" : "Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'.",
5658 "format" : "pve-hotplug-features",
5659 "optional" : 1,
013dc89f
DM
5660 "type" : "string",
5661 "typetext" : "<string>"
44660702 5662 },
4bd7df8b
DM
5663 "hugepages" : {
5664 "description" : "Enable/disable hugepages memory.",
5665 "enum" : [
5666 "any",
5667 "2",
5668 "1024"
5669 ],
5670 "optional" : 1,
5671 "type" : "string"
5672 },
44660702
DM
5673 "ide[n]" : {
5674 "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).",
5675 "format" : {
5676 "aio" : {
5677 "description" : "AIO type to use.",
5678 "enum" : [
5679 "native",
5680 "threads"
56122987 5681 ],
56122987 5682 "optional" : 1,
44660702 5683 "type" : "string"
56122987 5684 },
44660702
DM
5685 "backup" : {
5686 "description" : "Whether the drive should be included when making backups.",
56122987 5687 "optional" : 1,
44660702 5688 "type" : "boolean"
56122987 5689 },
7aacca6f 5690 "bps" : {
de0983cb 5691 "description" : "Maximum r/w speed in bytes per second.",
44660702
DM
5692 "format_description" : "bps",
5693 "optional" : 1,
5694 "type" : "integer"
5695 },
de0983cb
DM
5696 "bps_max_length" : {
5697 "description" : "Maximum length of I/O bursts in seconds.",
5698 "format_description" : "seconds",
5699 "minimum" : 1,
5700 "optional" : 1,
5701 "type" : "integer"
5702 },
44660702 5703 "bps_rd" : {
de0983cb 5704 "description" : "Maximum read speed in bytes per second.",
44660702 5705 "format_description" : "bps",
56122987 5706 "optional" : 1,
44660702 5707 "type" : "integer"
56122987 5708 },
de0983cb
DM
5709 "bps_rd_length" : {
5710 "description" : "Maximum length of read I/O bursts in seconds.",
5711 "format_description" : "seconds",
5712 "minimum" : 1,
5713 "optional" : 1,
5714 "type" : "integer"
5715 },
44660702 5716 "bps_wr" : {
de0983cb 5717 "description" : "Maximum write speed in bytes per second.",
44660702
DM
5718 "format_description" : "bps",
5719 "optional" : 1,
5720 "type" : "integer"
5721 },
de0983cb
DM
5722 "bps_wr_length" : {
5723 "description" : "Maximum length of write I/O bursts in seconds.",
5724 "format_description" : "seconds",
5725 "minimum" : 1,
5726 "optional" : 1,
5727 "type" : "integer"
5728 },
44660702
DM
5729 "cache" : {
5730 "description" : "The drive's cache mode",
5731 "enum" : [
5732 "none",
5733 "writethrough",
5734 "writeback",
5735 "unsafe",
5736 "directsync"
5737 ],
44660702
DM
5738 "optional" : 1,
5739 "type" : "string"
5740 },
5741 "cyls" : {
5742 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
5743 "optional" : 1,
5744 "type" : "integer"
5745 },
5746 "detect_zeroes" : {
5747 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
5748 "optional" : 1,
5749 "type" : "boolean"
5750 },
5751 "discard" : {
5752 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
5753 "enum" : [
5754 "ignore",
5755 "on"
5756 ],
56122987 5757 "optional" : 1,
44660702
DM
5758 "type" : "string"
5759 },
5760 "file" : {
5761 "default_key" : 1,
5762 "description" : "The drive's backing volume.",
5763 "format" : "pve-volume-id-or-qm-path",
5764 "format_description" : "volume",
5765 "type" : "string"
56122987 5766 },
7aacca6f 5767 "format" : {
7aacca6f 5768 "description" : "The drive's backing file's data format.",
56122987 5769 "enum" : [
7aacca6f
DM
5770 "raw",
5771 "cow",
5772 "qcow",
5773 "qed",
5774 "qcow2",
5775 "vmdk",
5776 "cloop"
56122987
DM
5777 ],
5778 "optional" : 1,
56122987
DM
5779 "type" : "string"
5780 },
44660702
DM
5781 "heads" : {
5782 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
5783 "optional" : 1,
5784 "type" : "integer"
7aacca6f 5785 },
44660702 5786 "iops" : {
de0983cb 5787 "description" : "Maximum r/w I/O in operations per second.",
44660702 5788 "format_description" : "iops",
56122987 5789 "optional" : 1,
44660702 5790 "type" : "integer"
56122987 5791 },
44660702 5792 "iops_max" : {
de0983cb 5793 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702 5794 "format_description" : "iops",
56122987 5795 "optional" : 1,
44660702 5796 "type" : "integer"
56122987 5797 },
de0983cb
DM
5798 "iops_max_length" : {
5799 "description" : "Maximum length of I/O bursts in seconds.",
5800 "format_description" : "seconds",
5801 "minimum" : 1,
5802 "optional" : 1,
5803 "type" : "integer"
5804 },
44660702 5805 "iops_rd" : {
de0983cb 5806 "description" : "Maximum read I/O in operations per second.",
44660702
DM
5807 "format_description" : "iops",
5808 "optional" : 1,
5809 "type" : "integer"
5810 },
de0983cb
DM
5811 "iops_rd_length" : {
5812 "description" : "Maximum length of read I/O bursts in seconds.",
5813 "format_description" : "seconds",
5814 "minimum" : 1,
5815 "optional" : 1,
5816 "type" : "integer"
5817 },
44660702 5818 "iops_rd_max" : {
de0983cb 5819 "description" : "Maximum unthrottled read I/O pool in operations per second.",
7aacca6f 5820 "format_description" : "iops",
44660702
DM
5821 "optional" : 1,
5822 "type" : "integer"
5823 },
5824 "iops_wr" : {
de0983cb 5825 "description" : "Maximum write I/O in operations per second.",
44660702 5826 "format_description" : "iops",
56122987 5827 "optional" : 1,
7aacca6f 5828 "type" : "integer"
56122987 5829 },
de0983cb
DM
5830 "iops_wr_length" : {
5831 "description" : "Maximum length of write I/O bursts in seconds.",
5832 "format_description" : "seconds",
5833 "minimum" : 1,
5834 "optional" : 1,
5835 "type" : "integer"
5836 },
44660702 5837 "iops_wr_max" : {
de0983cb 5838 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702 5839 "format_description" : "iops",
7aacca6f 5840 "optional" : 1,
44660702 5841 "type" : "integer"
56122987 5842 },
44660702 5843 "mbps" : {
de0983cb 5844 "description" : "Maximum r/w speed in megabytes per second.",
44660702
DM
5845 "format_description" : "mbps",
5846 "optional" : 1,
5847 "type" : "number"
5848 },
5849 "mbps_max" : {
de0983cb 5850 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702
DM
5851 "format_description" : "mbps",
5852 "optional" : 1,
5853 "type" : "number"
5854 },
5855 "mbps_rd" : {
de0983cb 5856 "description" : "Maximum read speed in megabytes per second.",
44660702
DM
5857 "format_description" : "mbps",
5858 "optional" : 1,
5859 "type" : "number"
5860 },
5861 "mbps_rd_max" : {
de0983cb 5862 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702
DM
5863 "format_description" : "mbps",
5864 "optional" : 1,
5865 "type" : "number"
5866 },
5867 "mbps_wr" : {
de0983cb 5868 "description" : "Maximum write speed in megabytes per second.",
44660702
DM
5869 "format_description" : "mbps",
5870 "optional" : 1,
5871 "type" : "number"
5872 },
5873 "mbps_wr_max" : {
de0983cb 5874 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702 5875 "format_description" : "mbps",
56122987 5876 "optional" : 1,
44660702 5877 "type" : "number"
56122987 5878 },
7aacca6f 5879 "media" : {
7aacca6f 5880 "default" : "disk",
7aacca6f
DM
5881 "description" : "The drive's media type.",
5882 "enum" : [
5883 "cdrom",
5884 "disk"
44660702 5885 ],
44660702
DM
5886 "optional" : 1,
5887 "type" : "string"
56122987 5888 },
44660702
DM
5889 "model" : {
5890 "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.",
5891 "format" : "urlencoded",
5892 "format_description" : "model",
5893 "maxLength" : 120,
56122987 5894 "optional" : 1,
44660702 5895 "type" : "string"
56122987 5896 },
44660702
DM
5897 "rerror" : {
5898 "description" : "Read error action.",
5899 "enum" : [
5900 "ignore",
5901 "report",
5902 "stop"
5903 ],
56122987 5904 "optional" : 1,
44660702
DM
5905 "type" : "string"
5906 },
5907 "secs" : {
5908 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
5909 "optional" : 1,
5910 "type" : "integer"
5911 },
5912 "serial" : {
5913 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
5914 "format" : "urlencoded",
5915 "format_description" : "serial",
5916 "maxLength" : 60,
5917 "optional" : 1,
5918 "type" : "string"
5919 },
5920 "size" : {
5921 "description" : "Disk size. This is purely informational and has no effect.",
5922 "format" : "disk-size",
f004f5b9 5923 "format_description" : "DiskSize",
44660702
DM
5924 "optional" : 1,
5925 "type" : "string"
5926 },
5927 "snapshot" : {
5928 "description" : "Whether the drive should be included when making snapshots.",
44660702
DM
5929 "optional" : 1,
5930 "type" : "boolean"
5931 },
5932 "trans" : {
5933 "description" : "Force disk geometry bios translation mode.",
5934 "enum" : [
5935 "none",
5936 "lba",
5937 "auto"
5938 ],
44660702
DM
5939 "optional" : 1,
5940 "type" : "string"
5941 },
5942 "volume" : {
5943 "alias" : "file"
5944 },
5945 "werror" : {
5946 "description" : "Write error action.",
5947 "enum" : [
5948 "enospc",
5949 "ignore",
5950 "report",
5951 "stop"
5952 ],
44660702
DM
5953 "optional" : 1,
5954 "type" : "string"
56122987
DM
5955 }
5956 },
44660702 5957 "optional" : 1,
4bd7df8b 5958 "type" : "string",
013dc89f 5959 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,model=<model>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
56122987 5960 },
44660702
DM
5961 "keyboard" : {
5962 "default" : "en-us",
c2993fe5 5963 "description" : "Keybord layout for vnc server. Default is read from the '/etc/pve/datacenter.conf' configuration file.",
44660702
DM
5964 "enum" : [
5965 "de",
5966 "de-ch",
5967 "da",
5968 "en-gb",
5969 "en-us",
5970 "es",
5971 "fi",
5972 "fr",
5973 "fr-be",
5974 "fr-ca",
5975 "fr-ch",
5976 "hu",
5977 "is",
5978 "it",
5979 "ja",
5980 "lt",
5981 "mk",
5982 "nl",
5983 "no",
5984 "pl",
5985 "pt",
5986 "pt-br",
5987 "sv",
5988 "sl",
5989 "tr"
5990 ],
56122987 5991 "optional" : 1,
44660702
DM
5992 "type" : "string"
5993 },
5994 "kvm" : {
7aacca6f 5995 "default" : 1,
44660702
DM
5996 "description" : "Enable/disable KVM hardware virtualization.",
5997 "optional" : 1,
013dc89f
DM
5998 "type" : "boolean",
5999 "typetext" : "<boolean>"
56122987 6000 },
44660702
DM
6001 "localtime" : {
6002 "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.",
56122987 6003 "optional" : 1,
013dc89f
DM
6004 "type" : "boolean",
6005 "typetext" : "<boolean>"
56122987 6006 },
44660702
DM
6007 "lock" : {
6008 "description" : "Lock/unlock the VM.",
6009 "enum" : [
6010 "migrate",
6011 "backup",
6012 "snapshot",
6013 "rollback"
6014 ],
7aacca6f 6015 "optional" : 1,
44660702
DM
6016 "type" : "string"
6017 },
6018 "machine" : {
6019 "description" : "Specific the Qemu machine type.",
6020 "maxLength" : 40,
6021 "optional" : 1,
6022 "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)",
6023 "type" : "string"
6024 },
6025 "memory" : {
6026 "default" : 512,
6027 "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.",
6028 "minimum" : 16,
6029 "optional" : 1,
4bd7df8b 6030 "type" : "integer",
013dc89f 6031 "typetext" : "<integer> (16 - N)"
44660702
DM
6032 },
6033 "migrate_downtime" : {
6034 "default" : 0.1,
6035 "description" : "Set maximum tolerated downtime (in seconds) for migrations.",
6036 "minimum" : 0,
6037 "optional" : 1,
4bd7df8b 6038 "type" : "number",
013dc89f 6039 "typetext" : "<number> (0 - N)"
44660702
DM
6040 },
6041 "migrate_speed" : {
6042 "default" : 0,
6043 "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.",
6044 "minimum" : 0,
6045 "optional" : 1,
4bd7df8b 6046 "type" : "integer",
013dc89f 6047 "typetext" : "<integer> (0 - N)"
44660702
DM
6048 },
6049 "name" : {
6050 "description" : "Set a name for the VM. Only used on the configuration web interface.",
6051 "format" : "dns-name",
6052 "optional" : 1,
013dc89f
DM
6053 "type" : "string",
6054 "typetext" : "<string>"
44660702
DM
6055 },
6056 "net[n]" : {
c2993fe5 6057 "description" : "Specify network devices.",
f004f5b9
DM
6058 "format" : {
6059 "bridge" : {
c2993fe5 6060 "description" : "Bridge to attach the network device to. The Proxmox VE standard bridge\nis called 'vmbr0'.\n\nIf you do not specify a bridge, we create a kvm user (NATed) network\ndevice, which provides DHCP and DNS services. The following addresses\nare used:\n\n 10.0.2.2 Gateway\n 10.0.2.3 DNS Server\n 10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n",
f004f5b9
DM
6061 "format_description" : "bridge",
6062 "optional" : 1,
6063 "type" : "string"
6064 },
6065 "e1000" : {
6066 "alias" : "macaddr",
6067 "keyAlias" : "model"
6068 },
6069 "e1000-82540em" : {
6070 "alias" : "macaddr",
6071 "keyAlias" : "model"
6072 },
6073 "e1000-82544gc" : {
6074 "alias" : "macaddr",
6075 "keyAlias" : "model"
6076 },
6077 "e1000-82545em" : {
6078 "alias" : "macaddr",
6079 "keyAlias" : "model"
6080 },
6081 "firewall" : {
6082 "description" : "Whether this interface should be protected by the firewall.",
6083 "optional" : 1,
6084 "type" : "boolean"
6085 },
6086 "i82551" : {
6087 "alias" : "macaddr",
6088 "keyAlias" : "model"
6089 },
6090 "i82557b" : {
6091 "alias" : "macaddr",
6092 "keyAlias" : "model"
6093 },
6094 "i82559er" : {
6095 "alias" : "macaddr",
6096 "keyAlias" : "model"
6097 },
6098 "link_down" : {
c2993fe5 6099 "description" : "Whether this interface should be disconnected (like pulling the plug).",
f004f5b9
DM
6100 "optional" : 1,
6101 "type" : "boolean"
6102 },
6103 "macaddr" : {
c2993fe5 6104 "description" : "MAC address. That address must be unique withing your network. This is automatically generated if not specified.",
f004f5b9 6105 "format_description" : "XX:XX:XX:XX:XX:XX",
f004f5b9
DM
6106 "optional" : 1,
6107 "pattern" : "(?^i:[0-9a-f]{2}(?::[0-9a-f]{2}){5})",
6108 "type" : "string"
6109 },
6110 "model" : {
6111 "default_key" : 1,
c2993fe5 6112 "description" : "Network Card Model. The 'virtio' model provides the best performance with very low CPU overhead. If your guest does not support this driver, it is usually best to use 'e1000'.",
f004f5b9
DM
6113 "enum" : [
6114 "rtl8139",
6115 "ne2k_pci",
6116 "e1000",
6117 "pcnet",
6118 "virtio",
6119 "ne2k_isa",
6120 "i82551",
6121 "i82557b",
6122 "i82559er",
6123 "vmxnet3",
6124 "e1000-82540em",
6125 "e1000-82544gc",
6126 "e1000-82545em"
6127 ],
f004f5b9
DM
6128 "type" : "string"
6129 },
6130 "ne2k_isa" : {
6131 "alias" : "macaddr",
6132 "keyAlias" : "model"
6133 },
6134 "ne2k_pci" : {
6135 "alias" : "macaddr",
6136 "keyAlias" : "model"
6137 },
6138 "pcnet" : {
6139 "alias" : "macaddr",
6140 "keyAlias" : "model"
6141 },
6142 "queues" : {
6143 "description" : "Number of packet queues to be used on the device.",
6144 "maximum" : 16,
6145 "minimum" : 0,
6146 "optional" : 1,
6147 "type" : "integer"
6148 },
6149 "rate" : {
c2993fe5 6150 "description" : "Rate limit in mbps (megabytes per second) as floating point number.",
f004f5b9
DM
6151 "minimum" : 0,
6152 "optional" : 1,
6153 "type" : "number"
6154 },
6155 "rtl8139" : {
6156 "alias" : "macaddr",
6157 "keyAlias" : "model"
6158 },
6159 "tag" : {
6160 "description" : "VLAN tag to apply to packets on this interface.",
6161 "maximum" : 4094,
c2993fe5 6162 "minimum" : 1,
f004f5b9
DM
6163 "optional" : 1,
6164 "type" : "integer"
6165 },
6166 "trunks" : {
6167 "description" : "VLAN trunks to pass through this interface.",
6168 "format_description" : "vlanid[;vlanid...]",
6169 "optional" : 1,
6170 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
6171 "type" : "string"
6172 },
6173 "virtio" : {
6174 "alias" : "macaddr",
6175 "keyAlias" : "model"
6176 },
6177 "vmxnet3" : {
6178 "alias" : "macaddr",
6179 "keyAlias" : "model"
6180 }
6181 },
44660702 6182 "optional" : 1,
4bd7df8b 6183 "type" : "string",
013dc89f 6184 "typetext" : "[model=]<enum> [,bridge=<bridge>] [,firewall=<1|0>] [,link_down=<1|0>] [,macaddr=<XX:XX:XX:XX:XX:XX>] [,queues=<integer>] [,rate=<number>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,<model>=<macaddr>]"
44660702
DM
6185 },
6186 "node" : {
6187 "description" : "The cluster node name.",
6188 "format" : "pve-node",
013dc89f
DM
6189 "type" : "string",
6190 "typetext" : "<string>"
44660702
DM
6191 },
6192 "numa" : {
6193 "default" : 0,
6194 "description" : "Enable/disable NUMA.",
6195 "optional" : 1,
013dc89f
DM
6196 "type" : "boolean",
6197 "typetext" : "<boolean>"
44660702
DM
6198 },
6199 "numa[n]" : {
c2993fe5 6200 "description" : "NUMA topology.",
56122987 6201 "format" : {
7aacca6f 6202 "cpus" : {
c2993fe5 6203 "description" : "CPUs accessing this NUMA node.",
44660702
DM
6204 "format_description" : "id[-id];...",
6205 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
6206 "type" : "string"
7aacca6f
DM
6207 },
6208 "hostnodes" : {
c2993fe5 6209 "description" : "Host NUMA nodes to use.",
44660702 6210 "format_description" : "id[-id];...",
7aacca6f 6211 "optional" : 1,
7aacca6f 6212 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
44660702 6213 "type" : "string"
7aacca6f 6214 },
44660702 6215 "memory" : {
c2993fe5 6216 "description" : "Amount of memory this NUMA node provides.",
7aacca6f 6217 "optional" : 1,
44660702
DM
6218 "type" : "number"
6219 },
6220 "policy" : {
c2993fe5 6221 "description" : "NUMA allocation policy.",
7aacca6f
DM
6222 "enum" : [
6223 "preferred",
6224 "bind",
6225 "interleave"
6226 ],
44660702
DM
6227 "optional" : 1,
6228 "type" : "string"
56122987 6229 }
44660702 6230 },
56122987 6231 "optional" : 1,
4bd7df8b
DM
6232 "type" : "string",
6233 "typetext" : "cpus=<id[-id];...> [,hostnodes=<id[-id];...>] [,memory=<number>] [,policy=<preferred|bind|interleave>]"
56122987 6234 },
44660702 6235 "onboot" : {
7aacca6f 6236 "default" : 0,
44660702
DM
6237 "description" : "Specifies whether a VM will be started during system bootup.",
6238 "optional" : 1,
013dc89f
DM
6239 "type" : "boolean",
6240 "typetext" : "<boolean>"
7aacca6f
DM
6241 },
6242 "ostype" : {
c2993fe5 6243 "description" : "Specify guest operating system.",
7aacca6f
DM
6244 "enum" : [
6245 "other",
6246 "wxp",
6247 "w2k",
6248 "w2k3",
6249 "w2k8",
6250 "wvista",
6251 "win7",
6252 "win8",
32d876b5 6253 "win10",
7aacca6f
DM
6254 "l24",
6255 "l26",
6256 "solaris"
6257 ],
7aacca6f 6258 "optional" : 1,
c2993fe5
DM
6259 "type" : "string",
6260 "verbose_description" : "Specify guest operating system. This is used to enable special\noptimization/features for specific operating systems:\n\n[horizontal]\nother;; unspecified OS\nwxp;; Microsoft Windows XP\nw2k;; Microsoft Windows 2000\nw2k3;; Microsoft Windows 2003\nw2k8;; Microsoft Windows 2008\nwvista;; Microsoft Windows Vista\nwin7;; Microsoft Windows 7\nwin8;; Microsoft Windows 8/2012\nl24;; Linux 2.4 Kernel\nl26;; Linux 2.6/3.X Kernel\nsolaris;; Solaris/OpenSolaris/OpenIndiania kernel\n"
56122987 6261 },
44660702 6262 "parallel[n]" : {
c2993fe5 6263 "description" : "Map host parallel devices (n is 0 to 2).",
7aacca6f 6264 "optional" : 1,
44660702 6265 "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+",
c2993fe5
DM
6266 "type" : "string",
6267 "verbose_description" : "Map host parallel devices (n is 0 to 2).\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
7aacca6f
DM
6268 },
6269 "protection" : {
6270 "default" : 0,
c2993fe5 6271 "description" : "Sets the protection flag of the VM. This will disable the remove VM and remove disk operations.",
7aacca6f 6272 "optional" : 1,
013dc89f
DM
6273 "type" : "boolean",
6274 "typetext" : "<boolean>"
7aacca6f 6275 },
44660702
DM
6276 "reboot" : {
6277 "default" : 1,
6278 "description" : "Allow reboot. If set to '0' the VM exit on reboot.",
7aacca6f 6279 "optional" : 1,
013dc89f
DM
6280 "type" : "boolean",
6281 "typetext" : "<boolean>"
7aacca6f 6282 },
44660702
DM
6283 "revert" : {
6284 "description" : "Revert a pending change.",
6285 "format" : "pve-configid-list",
7aacca6f 6286 "optional" : 1,
013dc89f
DM
6287 "type" : "string",
6288 "typetext" : "<string>"
44660702
DM
6289 },
6290 "sata[n]" : {
6291 "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).",
56122987 6292 "format" : {
44660702
DM
6293 "aio" : {
6294 "description" : "AIO type to use.",
7aacca6f 6295 "enum" : [
44660702
DM
6296 "native",
6297 "threads"
7aacca6f 6298 ],
44660702
DM
6299 "optional" : 1,
6300 "type" : "string"
7aacca6f 6301 },
44660702
DM
6302 "backup" : {
6303 "description" : "Whether the drive should be included when making backups.",
56122987 6304 "optional" : 1,
7aacca6f 6305 "type" : "boolean"
44660702
DM
6306 },
6307 "bps" : {
de0983cb 6308 "description" : "Maximum r/w speed in bytes per second.",
44660702 6309 "format_description" : "bps",
7aacca6f 6310 "optional" : 1,
44660702 6311 "type" : "integer"
56122987 6312 },
de0983cb
DM
6313 "bps_max_length" : {
6314 "description" : "Maximum length of I/O bursts in seconds.",
6315 "format_description" : "seconds",
6316 "minimum" : 1,
6317 "optional" : 1,
6318 "type" : "integer"
6319 },
44660702 6320 "bps_rd" : {
de0983cb 6321 "description" : "Maximum read speed in bytes per second.",
44660702 6322 "format_description" : "bps",
56122987 6323 "optional" : 1,
44660702 6324 "type" : "integer"
56122987 6325 },
de0983cb
DM
6326 "bps_rd_length" : {
6327 "description" : "Maximum length of read I/O bursts in seconds.",
6328 "format_description" : "seconds",
6329 "minimum" : 1,
6330 "optional" : 1,
6331 "type" : "integer"
6332 },
44660702 6333 "bps_wr" : {
de0983cb 6334 "description" : "Maximum write speed in bytes per second.",
44660702 6335 "format_description" : "bps",
56122987 6336 "optional" : 1,
44660702 6337 "type" : "integer"
56122987 6338 },
de0983cb
DM
6339 "bps_wr_length" : {
6340 "description" : "Maximum length of write I/O bursts in seconds.",
6341 "format_description" : "seconds",
6342 "minimum" : 1,
6343 "optional" : 1,
6344 "type" : "integer"
6345 },
56122987 6346 "cache" : {
44660702 6347 "description" : "The drive's cache mode",
56122987
DM
6348 "enum" : [
6349 "none",
6350 "writethrough",
6351 "writeback",
6352 "unsafe",
6353 "directsync"
6354 ],
56122987 6355 "optional" : 1,
44660702 6356 "type" : "string"
56122987 6357 },
44660702
DM
6358 "cyls" : {
6359 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
7aacca6f 6360 "optional" : 1,
44660702 6361 "type" : "integer"
7aacca6f
DM
6362 },
6363 "detect_zeroes" : {
6364 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
56122987 6365 "optional" : 1,
44660702 6366 "type" : "boolean"
56122987 6367 },
44660702
DM
6368 "discard" : {
6369 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
6370 "enum" : [
6371 "ignore",
6372 "on"
6373 ],
56122987 6374 "optional" : 1,
44660702 6375 "type" : "string"
7aacca6f 6376 },
44660702
DM
6377 "file" : {
6378 "default_key" : 1,
6379 "description" : "The drive's backing volume.",
6380 "format" : "pve-volume-id-or-qm-path",
6381 "format_description" : "volume",
6382 "type" : "string"
56122987 6383 },
7aacca6f 6384 "format" : {
44660702 6385 "description" : "The drive's backing file's data format.",
7aacca6f
DM
6386 "enum" : [
6387 "raw",
6388 "cow",
6389 "qcow",
6390 "qed",
6391 "qcow2",
6392 "vmdk",
6393 "cloop"
6394 ],
7aacca6f 6395 "optional" : 1,
44660702 6396 "type" : "string"
56122987 6397 },
7aacca6f 6398 "heads" : {
7aacca6f 6399 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 6400 "optional" : 1,
7aacca6f 6401 "type" : "integer"
56122987 6402 },
44660702 6403 "iops" : {
de0983cb 6404 "description" : "Maximum r/w I/O in operations per second.",
44660702 6405 "format_description" : "iops",
56122987 6406 "optional" : 1,
44660702 6407 "type" : "integer"
56122987 6408 },
44660702 6409 "iops_max" : {
de0983cb 6410 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702 6411 "format_description" : "iops",
56122987 6412 "optional" : 1,
44660702 6413 "type" : "integer"
56122987 6414 },
de0983cb
DM
6415 "iops_max_length" : {
6416 "description" : "Maximum length of I/O bursts in seconds.",
6417 "format_description" : "seconds",
6418 "minimum" : 1,
6419 "optional" : 1,
6420 "type" : "integer"
6421 },
44660702 6422 "iops_rd" : {
de0983cb 6423 "description" : "Maximum read I/O in operations per second.",
44660702 6424 "format_description" : "iops",
7aacca6f 6425 "optional" : 1,
44660702 6426 "type" : "integer"
56122987 6427 },
de0983cb
DM
6428 "iops_rd_length" : {
6429 "description" : "Maximum length of read I/O bursts in seconds.",
6430 "format_description" : "seconds",
6431 "minimum" : 1,
6432 "optional" : 1,
6433 "type" : "integer"
6434 },
44660702 6435 "iops_rd_max" : {
de0983cb 6436 "description" : "Maximum unthrottled read I/O pool in operations per second.",
44660702 6437 "format_description" : "iops",
56122987 6438 "optional" : 1,
44660702 6439 "type" : "integer"
7aacca6f 6440 },
44660702 6441 "iops_wr" : {
de0983cb 6442 "description" : "Maximum write I/O in operations per second.",
44660702 6443 "format_description" : "iops",
56122987 6444 "optional" : 1,
44660702 6445 "type" : "integer"
56122987 6446 },
de0983cb
DM
6447 "iops_wr_length" : {
6448 "description" : "Maximum length of write I/O bursts in seconds.",
6449 "format_description" : "seconds",
6450 "minimum" : 1,
6451 "optional" : 1,
6452 "type" : "integer"
6453 },
56122987 6454 "iops_wr_max" : {
de0983cb 6455 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702 6456 "format_description" : "iops",
56122987 6457 "optional" : 1,
44660702 6458 "type" : "integer"
56122987 6459 },
44660702 6460 "mbps" : {
de0983cb 6461 "description" : "Maximum r/w speed in megabytes per second.",
44660702 6462 "format_description" : "mbps",
56122987 6463 "optional" : 1,
44660702 6464 "type" : "number"
56122987 6465 },
44660702 6466 "mbps_max" : {
de0983cb 6467 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702
DM
6468 "format_description" : "mbps",
6469 "optional" : 1,
6470 "type" : "number"
56122987 6471 },
44660702 6472 "mbps_rd" : {
de0983cb 6473 "description" : "Maximum read speed in megabytes per second.",
44660702 6474 "format_description" : "mbps",
56122987 6475 "optional" : 1,
44660702 6476 "type" : "number"
56122987 6477 },
44660702 6478 "mbps_rd_max" : {
de0983cb 6479 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702 6480 "format_description" : "mbps",
56122987 6481 "optional" : 1,
44660702 6482 "type" : "number"
56122987 6483 },
44660702 6484 "mbps_wr" : {
de0983cb 6485 "description" : "Maximum write speed in megabytes per second.",
56122987 6486 "format_description" : "mbps",
44660702
DM
6487 "optional" : 1,
6488 "type" : "number"
56122987 6489 },
44660702 6490 "mbps_wr_max" : {
de0983cb 6491 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702
DM
6492 "format_description" : "mbps",
6493 "optional" : 1,
6494 "type" : "number"
7aacca6f 6495 },
44660702
DM
6496 "media" : {
6497 "default" : "disk",
6498 "description" : "The drive's media type.",
6499 "enum" : [
6500 "cdrom",
6501 "disk"
6502 ],
56122987 6503 "optional" : 1,
44660702
DM
6504 "type" : "string"
6505 },
6506 "rerror" : {
6507 "description" : "Read error action.",
7aacca6f 6508 "enum" : [
44660702
DM
6509 "ignore",
6510 "report",
6511 "stop"
6512 ],
7aacca6f 6513 "optional" : 1,
44660702 6514 "type" : "string"
56122987 6515 },
44660702
DM
6516 "secs" : {
6517 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 6518 "optional" : 1,
44660702 6519 "type" : "integer"
56122987 6520 },
44660702
DM
6521 "serial" : {
6522 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
6523 "format" : "urlencoded",
6524 "format_description" : "serial",
6525 "maxLength" : 60,
56122987 6526 "optional" : 1,
44660702 6527 "type" : "string"
56122987 6528 },
44660702
DM
6529 "size" : {
6530 "description" : "Disk size. This is purely informational and has no effect.",
6531 "format" : "disk-size",
f004f5b9 6532 "format_description" : "DiskSize",
44660702
DM
6533 "optional" : 1,
6534 "type" : "string"
6535 },
6536 "snapshot" : {
6537 "description" : "Whether the drive should be included when making snapshots.",
56122987 6538 "optional" : 1,
44660702
DM
6539 "type" : "boolean"
6540 },
6541 "trans" : {
6542 "description" : "Force disk geometry bios translation mode.",
56122987 6543 "enum" : [
7aacca6f
DM
6544 "none",
6545 "lba",
6546 "auto"
56122987 6547 ],
44660702
DM
6548 "optional" : 1,
6549 "type" : "string"
56122987 6550 },
7aacca6f
DM
6551 "volume" : {
6552 "alias" : "file"
56122987 6553 },
44660702
DM
6554 "werror" : {
6555 "description" : "Write error action.",
6556 "enum" : [
6557 "enospc",
6558 "ignore",
6559 "report",
6560 "stop"
6561 ],
7aacca6f 6562 "optional" : 1,
44660702
DM
6563 "type" : "string"
6564 }
6565 },
6566 "optional" : 1,
4bd7df8b 6567 "type" : "string",
013dc89f 6568 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
44660702
DM
6569 },
6570 "scsi[n]" : {
6571 "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).",
6572 "format" : {
56122987 6573 "aio" : {
56122987
DM
6574 "description" : "AIO type to use.",
6575 "enum" : [
6576 "native",
6577 "threads"
6578 ],
7aacca6f 6579 "optional" : 1,
44660702 6580 "type" : "string"
56122987 6581 },
44660702
DM
6582 "backup" : {
6583 "description" : "Whether the drive should be included when making backups.",
56122987 6584 "optional" : 1,
44660702 6585 "type" : "boolean"
56122987 6586 },
44660702 6587 "bps" : {
de0983cb 6588 "description" : "Maximum r/w speed in bytes per second.",
44660702 6589 "format_description" : "bps",
56122987 6590 "optional" : 1,
44660702 6591 "type" : "integer"
56122987 6592 },
de0983cb
DM
6593 "bps_max_length" : {
6594 "description" : "Maximum length of I/O bursts in seconds.",
6595 "format_description" : "seconds",
6596 "minimum" : 1,
6597 "optional" : 1,
6598 "type" : "integer"
6599 },
44660702 6600 "bps_rd" : {
de0983cb 6601 "description" : "Maximum read speed in bytes per second.",
44660702 6602 "format_description" : "bps",
56122987 6603 "optional" : 1,
44660702 6604 "type" : "integer"
56122987 6605 },
de0983cb
DM
6606 "bps_rd_length" : {
6607 "description" : "Maximum length of read I/O bursts in seconds.",
6608 "format_description" : "seconds",
6609 "minimum" : 1,
6610 "optional" : 1,
6611 "type" : "integer"
6612 },
7aacca6f 6613 "bps_wr" : {
de0983cb 6614 "description" : "Maximum write speed in bytes per second.",
7aacca6f 6615 "format_description" : "bps",
56122987 6616 "optional" : 1,
44660702 6617 "type" : "integer"
56122987 6618 },
de0983cb
DM
6619 "bps_wr_length" : {
6620 "description" : "Maximum length of write I/O bursts in seconds.",
6621 "format_description" : "seconds",
6622 "minimum" : 1,
6623 "optional" : 1,
6624 "type" : "integer"
6625 },
44660702
DM
6626 "cache" : {
6627 "description" : "The drive's cache mode",
7aacca6f 6628 "enum" : [
44660702
DM
6629 "none",
6630 "writethrough",
6631 "writeback",
6632 "unsafe",
6633 "directsync"
7aacca6f 6634 ],
56122987 6635 "optional" : 1,
44660702 6636 "type" : "string"
56122987 6637 },
44660702
DM
6638 "cyls" : {
6639 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
7aacca6f 6640 "optional" : 1,
44660702 6641 "type" : "integer"
56122987 6642 },
44660702
DM
6643 "detect_zeroes" : {
6644 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
56122987 6645 "optional" : 1,
44660702 6646 "type" : "boolean"
56122987 6647 },
44660702
DM
6648 "discard" : {
6649 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
6650 "enum" : [
6651 "ignore",
6652 "on"
6653 ],
7aacca6f 6654 "optional" : 1,
44660702 6655 "type" : "string"
56122987 6656 },
44660702
DM
6657 "file" : {
6658 "default_key" : 1,
6659 "description" : "The drive's backing volume.",
6660 "format" : "pve-volume-id-or-qm-path",
6661 "format_description" : "volume",
6662 "type" : "string"
56122987 6663 },
7aacca6f 6664 "format" : {
44660702 6665 "description" : "The drive's backing file's data format.",
56122987 6666 "enum" : [
7aacca6f
DM
6667 "raw",
6668 "cow",
6669 "qcow",
6670 "qed",
6671 "qcow2",
6672 "vmdk",
6673 "cloop"
6674 ],
44660702
DM
6675 "optional" : 1,
6676 "type" : "string"
56122987 6677 },
44660702
DM
6678 "heads" : {
6679 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 6680 "optional" : 1,
7aacca6f 6681 "type" : "integer"
56122987 6682 },
44660702 6683 "iops" : {
de0983cb 6684 "description" : "Maximum r/w I/O in operations per second.",
7aacca6f 6685 "format_description" : "iops",
44660702
DM
6686 "optional" : 1,
6687 "type" : "integer"
7aacca6f 6688 },
44660702 6689 "iops_max" : {
de0983cb 6690 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702 6691 "format_description" : "iops",
56122987 6692 "optional" : 1,
44660702 6693 "type" : "integer"
7aacca6f 6694 },
de0983cb
DM
6695 "iops_max_length" : {
6696 "description" : "Maximum length of I/O bursts in seconds.",
6697 "format_description" : "seconds",
6698 "minimum" : 1,
6699 "optional" : 1,
6700 "type" : "integer"
6701 },
44660702 6702 "iops_rd" : {
de0983cb 6703 "description" : "Maximum read I/O in operations per second.",
44660702 6704 "format_description" : "iops",
7aacca6f 6705 "optional" : 1,
44660702 6706 "type" : "integer"
56122987 6707 },
de0983cb
DM
6708 "iops_rd_length" : {
6709 "description" : "Maximum length of read I/O bursts in seconds.",
6710 "format_description" : "seconds",
6711 "minimum" : 1,
6712 "optional" : 1,
6713 "type" : "integer"
6714 },
44660702 6715 "iops_rd_max" : {
de0983cb 6716 "description" : "Maximum unthrottled read I/O pool in operations per second.",
44660702
DM
6717 "format_description" : "iops",
6718 "optional" : 1,
6719 "type" : "integer"
6720 },
6721 "iops_wr" : {
de0983cb 6722 "description" : "Maximum write I/O in operations per second.",
44660702 6723 "format_description" : "iops",
56122987 6724 "optional" : 1,
44660702
DM
6725 "type" : "integer"
6726 },
de0983cb
DM
6727 "iops_wr_length" : {
6728 "description" : "Maximum length of write I/O bursts in seconds.",
6729 "format_description" : "seconds",
6730 "minimum" : 1,
6731 "optional" : 1,
6732 "type" : "integer"
6733 },
44660702 6734 "iops_wr_max" : {
de0983cb 6735 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702
DM
6736 "format_description" : "iops",
6737 "optional" : 1,
6738 "type" : "integer"
56122987 6739 },
7aacca6f 6740 "iothread" : {
7aacca6f 6741 "description" : "Whether to use iothreads for this drive",
56122987 6742 "optional" : 1,
56122987
DM
6743 "type" : "boolean"
6744 },
44660702 6745 "mbps" : {
de0983cb 6746 "description" : "Maximum r/w speed in megabytes per second.",
44660702
DM
6747 "format_description" : "mbps",
6748 "optional" : 1,
6749 "type" : "number"
6750 },
6751 "mbps_max" : {
de0983cb 6752 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702
DM
6753 "format_description" : "mbps",
6754 "optional" : 1,
6755 "type" : "number"
6756 },
6757 "mbps_rd" : {
de0983cb 6758 "description" : "Maximum read speed in megabytes per second.",
44660702
DM
6759 "format_description" : "mbps",
6760 "optional" : 1,
6761 "type" : "number"
6762 },
6763 "mbps_rd_max" : {
de0983cb 6764 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702
DM
6765 "format_description" : "mbps",
6766 "optional" : 1,
6767 "type" : "number"
6768 },
6769 "mbps_wr" : {
de0983cb 6770 "description" : "Maximum write speed in megabytes per second.",
44660702
DM
6771 "format_description" : "mbps",
6772 "optional" : 1,
6773 "type" : "number"
6774 },
6775 "mbps_wr_max" : {
de0983cb 6776 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702
DM
6777 "format_description" : "mbps",
6778 "optional" : 1,
6779 "type" : "number"
6780 },
7aacca6f 6781 "media" : {
44660702
DM
6782 "default" : "disk",
6783 "description" : "The drive's media type.",
7aacca6f
DM
6784 "enum" : [
6785 "cdrom",
6786 "disk"
6787 ],
56122987 6788 "optional" : 1,
44660702
DM
6789 "type" : "string"
6790 },
6791 "queues" : {
6792 "description" : "Number of queues.",
44660702
DM
6793 "minimum" : 2,
6794 "optional" : 1,
6795 "type" : "integer"
6796 },
52e44c50
FG
6797 "scsiblock" : {
6798 "default" : 0,
6799 "description" : "whether to use scsi-block for full passthrough of host block device\n\nWARNING: can lead to I/O errors in combination with low memory or high memory fragmentation on host",
6800 "optional" : 1,
6801 "type" : "boolean"
6802 },
44660702
DM
6803 "secs" : {
6804 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
6805 "optional" : 1,
6806 "type" : "integer"
6807 },
6808 "serial" : {
6809 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
6810 "format" : "urlencoded",
6811 "format_description" : "serial",
6812 "maxLength" : 60,
6813 "optional" : 1,
6814 "type" : "string"
6815 },
6816 "size" : {
6817 "description" : "Disk size. This is purely informational and has no effect.",
6818 "format" : "disk-size",
f004f5b9 6819 "format_description" : "DiskSize",
44660702
DM
6820 "optional" : 1,
6821 "type" : "string"
56122987 6822 },
7aacca6f
DM
6823 "snapshot" : {
6824 "description" : "Whether the drive should be included when making snapshots.",
6825 "optional" : 1,
44660702 6826 "type" : "boolean"
7aacca6f 6827 },
44660702
DM
6828 "trans" : {
6829 "description" : "Force disk geometry bios translation mode.",
6830 "enum" : [
6831 "none",
6832 "lba",
6833 "auto"
6834 ],
44660702
DM
6835 "optional" : 1,
6836 "type" : "string"
6837 },
6838 "volume" : {
6839 "alias" : "file"
6840 },
6841 "werror" : {
6842 "description" : "Write error action.",
6843 "enum" : [
6844 "enospc",
6845 "ignore",
6846 "report",
6847 "stop"
6848 ],
56122987 6849 "optional" : 1,
44660702 6850 "type" : "string"
56122987 6851 }
44660702 6852 },
7aacca6f 6853 "optional" : 1,
4bd7df8b 6854 "type" : "string",
52e44c50 6855 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,queues=<integer>] [,scsiblock=<1|0>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
44660702
DM
6856 },
6857 "scsihw" : {
6858 "default" : "lsi",
c2993fe5 6859 "description" : "SCSI controller model",
7aacca6f 6860 "enum" : [
44660702
DM
6861 "lsi",
6862 "lsi53c810",
6863 "virtio-scsi-pci",
6864 "virtio-scsi-single",
6865 "megasas",
6866 "pvscsi"
7aacca6f 6867 ],
44660702
DM
6868 "optional" : 1,
6869 "type" : "string"
56122987 6870 },
44660702 6871 "serial[n]" : {
c2993fe5 6872 "description" : "Create a serial device inside the VM (n is 0 to 3)",
7aacca6f 6873 "optional" : 1,
44660702 6874 "pattern" : "(/dev/.+|socket)",
c2993fe5 6875 "type" : "string",
57b78691 6876 "verbose_description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a\nhost serial device (i.e. /dev/ttyS0), or create a unix socket on the\nhost side (use 'qm terminal' to open a terminal connection).\n\nNOTE: If you pass through a host serial device, it is no longer possible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
7aacca6f 6877 },
44660702
DM
6878 "shares" : {
6879 "default" : 1000,
6880 "description" : "Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning",
6881 "maximum" : 50000,
6882 "minimum" : 0,
56122987 6883 "optional" : 1,
4bd7df8b 6884 "type" : "integer",
013dc89f 6885 "typetext" : "<integer> (0 - 50000)"
56122987 6886 },
44660702
DM
6887 "skiplock" : {
6888 "description" : "Ignore locks - only root is allowed to use this option.",
7aacca6f 6889 "optional" : 1,
013dc89f
DM
6890 "type" : "boolean",
6891 "typetext" : "<boolean>"
56122987 6892 },
44660702
DM
6893 "smbios1" : {
6894 "description" : "Specify SMBIOS type 1 fields.",
6895 "format" : "pve-qm-smbios1",
6896 "maxLength" : 256,
56122987 6897 "optional" : 1,
4bd7df8b
DM
6898 "type" : "string",
6899 "typetext" : "[family=<string>] [,manufacturer=<string>] [,product=<string>] [,serial=<string>] [,sku=<string>] [,uuid=<UUID>] [,version=<string>]"
56122987 6900 },
44660702
DM
6901 "smp" : {
6902 "default" : 1,
6903 "description" : "The number of CPUs. Please use option -sockets instead.",
7aacca6f 6904 "minimum" : 1,
7aacca6f 6905 "optional" : 1,
4bd7df8b 6906 "type" : "integer",
013dc89f 6907 "typetext" : "<integer> (1 - N)"
7aacca6f 6908 },
44660702
DM
6909 "sockets" : {
6910 "default" : 1,
6911 "description" : "The number of CPU sockets.",
6912 "minimum" : 1,
7aacca6f 6913 "optional" : 1,
4bd7df8b 6914 "type" : "integer",
013dc89f 6915 "typetext" : "<integer> (1 - N)"
56122987 6916 },
44660702
DM
6917 "startdate" : {
6918 "default" : "now",
6919 "description" : "Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'.",
7aacca6f 6920 "optional" : 1,
44660702 6921 "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)",
7aacca6f 6922 "type" : "string",
44660702 6923 "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)"
56122987 6924 },
7aacca6f 6925 "startup" : {
7aacca6f 6926 "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.",
44660702 6927 "format" : "pve-startup-order",
56122987 6928 "optional" : 1,
44660702
DM
6929 "type" : "string",
6930 "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] "
56122987 6931 },
44660702 6932 "tablet" : {
7aacca6f 6933 "default" : 1,
c2993fe5 6934 "description" : "Enable/disable the USB tablet device.",
7aacca6f 6935 "optional" : 1,
c2993fe5 6936 "type" : "boolean",
013dc89f 6937 "typetext" : "<boolean>",
c2993fe5 6938 "verbose_description" : "Enable/disable the USB tablet device. This device is usually needed to allow absolute mouse positioning with VNC. Else the mouse runs out of sync with normal VNC clients. If you're running lots of console-only guests on one host, you may consider disabling this to save some context switches. This is turned off by default if you use spice (-vga=qxl)."
56122987 6939 },
44660702
DM
6940 "tdf" : {
6941 "default" : 0,
6942 "description" : "Enable/disable time drift fix.",
7aacca6f 6943 "optional" : 1,
013dc89f
DM
6944 "type" : "boolean",
6945 "typetext" : "<boolean>"
7aacca6f 6946 },
44660702
DM
6947 "template" : {
6948 "default" : 0,
6949 "description" : "Enable/disable Template.",
7aacca6f 6950 "optional" : 1,
013dc89f
DM
6951 "type" : "boolean",
6952 "typetext" : "<boolean>"
7aacca6f 6953 },
44660702 6954 "unused[n]" : {
c2993fe5 6955 "description" : "Reference to unused volumes. This is used internally, and should not be modified manually.",
44660702 6956 "format" : "pve-volume-id",
7aacca6f 6957 "optional" : 1,
013dc89f
DM
6958 "type" : "string",
6959 "typetext" : "<string>"
7aacca6f 6960 },
44660702 6961 "usb[n]" : {
c2993fe5 6962 "description" : "Configure an USB device (n is 0 to 4).",
44660702
DM
6963 "format" : {
6964 "host" : {
6965 "default_key" : 1,
c2993fe5 6966 "description" : "The Host USB device or port or the value 'spice'. HOSTUSBDEVICE syntax is:\n\n 'bus-port(.port)*' (decimal numbers) or\n 'vendor_id:product_id' (hexadeciaml numbers) or\n 'spice'\n\nYou can use the 'lsusb -t' command to list existing usb devices.\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nThe value 'spice' can be used to add a usb redirection devices for spice.\n",
44660702
DM
6967 "format" : "pve-qm-usb-device",
6968 "format_description" : "HOSTUSBDEVICE|spice",
6969 "type" : "string"
6970 },
6971 "usb3" : {
c2993fe5
DM
6972 "default" : 0,
6973 "description" : "Specifies whether if given host option is a USB3 device or port (this does currently not work reliably with spice redirection and is then ignored).",
44660702
DM
6974 "optional" : 1,
6975 "type" : "boolean"
6976 }
6977 },
7aacca6f 6978 "optional" : 1,
4bd7df8b
DM
6979 "type" : "string",
6980 "typetext" : "[host=]<HOSTUSBDEVICE|spice> [,usb3=<1|0>]"
56122987 6981 },
44660702
DM
6982 "vcpus" : {
6983 "default" : 0,
6984 "description" : "Number of hotplugged vcpus.",
6985 "minimum" : 1,
56122987 6986 "optional" : 1,
4bd7df8b 6987 "type" : "integer",
013dc89f 6988 "typetext" : "<integer> (1 - N)"
56122987 6989 },
44660702 6990 "vga" : {
c2993fe5 6991 "description" : "Select the VGA type.",
44660702
DM
6992 "enum" : [
6993 "std",
6994 "cirrus",
6995 "vmware",
6996 "qxl",
6997 "serial0",
6998 "serial1",
6999 "serial2",
7000 "serial3",
7001 "qxl2",
7002 "qxl3",
7003 "qxl4"
7004 ],
56122987 7005 "optional" : 1,
c2993fe5
DM
7006 "type" : "string",
7007 "verbose_description" : "Select the VGA type. If you want to use high resolution modes (>= 1280x1024x16) then you should use the options 'std' or 'vmware'. Default is 'std' for win8/win7/w2k8, and 'cirrus' for other OS types. The 'qxl' option enables the SPICE display sever. For win* OS you can select how many independent displays you want, Linux guests can add displays them self. You can also run without any graphic card, using a serial device as terminal."
56122987 7008 },
44660702
DM
7009 "virtio[n]" : {
7010 "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).",
56122987 7011 "format" : {
44660702
DM
7012 "aio" : {
7013 "description" : "AIO type to use.",
56122987 7014 "enum" : [
44660702
DM
7015 "native",
7016 "threads"
56122987 7017 ],
56122987
DM
7018 "optional" : 1,
7019 "type" : "string"
7020 },
44660702
DM
7021 "backup" : {
7022 "description" : "Whether the drive should be included when making backups.",
44660702
DM
7023 "optional" : 1,
7024 "type" : "boolean"
7aacca6f 7025 },
44660702 7026 "bps" : {
de0983cb 7027 "description" : "Maximum r/w speed in bytes per second.",
44660702
DM
7028 "format_description" : "bps",
7029 "optional" : 1,
7030 "type" : "integer"
56122987 7031 },
de0983cb
DM
7032 "bps_max_length" : {
7033 "description" : "Maximum length of I/O bursts in seconds.",
7034 "format_description" : "seconds",
7035 "minimum" : 1,
7036 "optional" : 1,
7037 "type" : "integer"
7038 },
44660702 7039 "bps_rd" : {
de0983cb 7040 "description" : "Maximum read speed in bytes per second.",
44660702 7041 "format_description" : "bps",
56122987 7042 "optional" : 1,
44660702 7043 "type" : "integer"
56122987 7044 },
de0983cb
DM
7045 "bps_rd_length" : {
7046 "description" : "Maximum length of read I/O bursts in seconds.",
7047 "format_description" : "seconds",
7048 "minimum" : 1,
7049 "optional" : 1,
7050 "type" : "integer"
7051 },
44660702 7052 "bps_wr" : {
de0983cb 7053 "description" : "Maximum write speed in bytes per second.",
44660702 7054 "format_description" : "bps",
56122987 7055 "optional" : 1,
44660702
DM
7056 "type" : "integer"
7057 },
de0983cb
DM
7058 "bps_wr_length" : {
7059 "description" : "Maximum length of write I/O bursts in seconds.",
7060 "format_description" : "seconds",
7061 "minimum" : 1,
7062 "optional" : 1,
7063 "type" : "integer"
7064 },
44660702
DM
7065 "cache" : {
7066 "description" : "The drive's cache mode",
56122987 7067 "enum" : [
44660702
DM
7068 "none",
7069 "writethrough",
7070 "writeback",
7071 "unsafe",
7072 "directsync"
56122987 7073 ],
56122987 7074 "optional" : 1,
44660702 7075 "type" : "string"
56122987 7076 },
44660702
DM
7077 "cyls" : {
7078 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
56122987 7079 "optional" : 1,
44660702 7080 "type" : "integer"
7aacca6f 7081 },
44660702
DM
7082 "detect_zeroes" : {
7083 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
7084 "optional" : 1,
7085 "type" : "boolean"
7aacca6f 7086 },
44660702
DM
7087 "discard" : {
7088 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
7089 "enum" : [
7090 "ignore",
7091 "on"
7092 ],
56122987 7093 "optional" : 1,
44660702 7094 "type" : "string"
56122987
DM
7095 },
7096 "file" : {
7aacca6f 7097 "default_key" : 1,
44660702 7098 "description" : "The drive's backing volume.",
7aacca6f 7099 "format" : "pve-volume-id-or-qm-path",
44660702
DM
7100 "format_description" : "volume",
7101 "type" : "string"
7aacca6f
DM
7102 },
7103 "format" : {
7aacca6f
DM
7104 "description" : "The drive's backing file's data format.",
7105 "enum" : [
7106 "raw",
7107 "cow",
7108 "qcow",
7109 "qed",
7110 "qcow2",
7111 "vmdk",
7112 "cloop"
56122987
DM
7113 ],
7114 "optional" : 1,
56122987
DM
7115 "type" : "string"
7116 },
44660702
DM
7117 "heads" : {
7118 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 7119 "optional" : 1,
44660702 7120 "type" : "integer"
56122987 7121 },
44660702 7122 "iops" : {
de0983cb 7123 "description" : "Maximum r/w I/O in operations per second.",
7aacca6f 7124 "format_description" : "iops",
56122987 7125 "optional" : 1,
44660702 7126 "type" : "integer"
56122987 7127 },
44660702 7128 "iops_max" : {
de0983cb 7129 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702 7130 "format_description" : "iops",
56122987 7131 "optional" : 1,
56122987
DM
7132 "type" : "integer"
7133 },
de0983cb
DM
7134 "iops_max_length" : {
7135 "description" : "Maximum length of I/O bursts in seconds.",
7136 "format_description" : "seconds",
7137 "minimum" : 1,
7138 "optional" : 1,
7139 "type" : "integer"
7140 },
44660702 7141 "iops_rd" : {
de0983cb 7142 "description" : "Maximum read I/O in operations per second.",
44660702 7143 "format_description" : "iops",
56122987 7144 "optional" : 1,
44660702 7145 "type" : "integer"
56122987 7146 },
de0983cb
DM
7147 "iops_rd_length" : {
7148 "description" : "Maximum length of read I/O bursts in seconds.",
7149 "format_description" : "seconds",
7150 "minimum" : 1,
7151 "optional" : 1,
7152 "type" : "integer"
7153 },
44660702 7154 "iops_rd_max" : {
de0983cb 7155 "description" : "Maximum unthrottled read I/O pool in operations per second.",
44660702 7156 "format_description" : "iops",
7aacca6f 7157 "optional" : 1,
44660702 7158 "type" : "integer"
56122987 7159 },
44660702 7160 "iops_wr" : {
de0983cb 7161 "description" : "Maximum write I/O in operations per second.",
44660702 7162 "format_description" : "iops",
7aacca6f 7163 "optional" : 1,
44660702 7164 "type" : "integer"
56122987 7165 },
de0983cb
DM
7166 "iops_wr_length" : {
7167 "description" : "Maximum length of write I/O bursts in seconds.",
7168 "format_description" : "seconds",
7169 "minimum" : 1,
7170 "optional" : 1,
7171 "type" : "integer"
7172 },
44660702 7173 "iops_wr_max" : {
de0983cb 7174 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702 7175 "format_description" : "iops",
56122987
DM
7176 "optional" : 1,
7177 "type" : "integer"
7178 },
44660702
DM
7179 "iothread" : {
7180 "description" : "Whether to use iothreads for this drive",
44660702
DM
7181 "optional" : 1,
7182 "type" : "boolean"
7183 },
7184 "mbps" : {
de0983cb 7185 "description" : "Maximum r/w speed in megabytes per second.",
7aacca6f 7186 "format_description" : "mbps",
44660702
DM
7187 "optional" : 1,
7188 "type" : "number"
7189 },
7190 "mbps_max" : {
de0983cb 7191 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702
DM
7192 "format_description" : "mbps",
7193 "optional" : 1,
7194 "type" : "number"
7aacca6f 7195 },
44660702 7196 "mbps_rd" : {
de0983cb 7197 "description" : "Maximum read speed in megabytes per second.",
44660702 7198 "format_description" : "mbps",
56122987 7199 "optional" : 1,
44660702 7200 "type" : "number"
56122987 7201 },
44660702 7202 "mbps_rd_max" : {
de0983cb 7203 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702 7204 "format_description" : "mbps",
7aacca6f 7205 "optional" : 1,
44660702 7206 "type" : "number"
56122987 7207 },
44660702 7208 "mbps_wr" : {
de0983cb 7209 "description" : "Maximum write speed in megabytes per second.",
44660702 7210 "format_description" : "mbps",
56122987 7211 "optional" : 1,
44660702 7212 "type" : "number"
56122987 7213 },
44660702 7214 "mbps_wr_max" : {
de0983cb 7215 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702 7216 "format_description" : "mbps",
56122987 7217 "optional" : 1,
44660702 7218 "type" : "number"
56122987
DM
7219 },
7220 "media" : {
7aacca6f 7221 "default" : "disk",
44660702 7222 "description" : "The drive's media type.",
56122987
DM
7223 "enum" : [
7224 "cdrom",
7225 "disk"
7226 ],
44660702
DM
7227 "optional" : 1,
7228 "type" : "string"
56122987 7229 },
7aacca6f 7230 "rerror" : {
44660702 7231 "description" : "Read error action.",
56122987 7232 "enum" : [
7aacca6f
DM
7233 "ignore",
7234 "report",
7235 "stop"
56122987 7236 ],
56122987 7237 "optional" : 1,
44660702 7238 "type" : "string"
56122987 7239 },
44660702
DM
7240 "secs" : {
7241 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
7242 "optional" : 1,
7243 "type" : "integer"
7244 },
7245 "serial" : {
7246 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
7247 "format" : "urlencoded",
7248 "format_description" : "serial",
7249 "maxLength" : 60,
56122987 7250 "optional" : 1,
7aacca6f 7251 "type" : "string"
56122987 7252 },
44660702
DM
7253 "size" : {
7254 "description" : "Disk size. This is purely informational and has no effect.",
7255 "format" : "disk-size",
f004f5b9 7256 "format_description" : "DiskSize",
56122987 7257 "optional" : 1,
44660702 7258 "type" : "string"
56122987 7259 },
44660702
DM
7260 "snapshot" : {
7261 "description" : "Whether the drive should be included when making snapshots.",
56122987 7262 "optional" : 1,
44660702 7263 "type" : "boolean"
56122987 7264 },
44660702
DM
7265 "trans" : {
7266 "description" : "Force disk geometry bios translation mode.",
7267 "enum" : [
7268 "none",
7269 "lba",
7270 "auto"
7271 ],
44660702
DM
7272 "optional" : 1,
7273 "type" : "string"
7274 },
7275 "volume" : {
7276 "alias" : "file"
7277 },
7278 "werror" : {
7279 "description" : "Write error action.",
7280 "enum" : [
7281 "enospc",
7282 "ignore",
7283 "report",
7284 "stop"
7285 ],
56122987 7286 "optional" : 1,
44660702 7287 "type" : "string"
56122987 7288 }
44660702 7289 },
56122987 7290 "optional" : 1,
4bd7df8b 7291 "type" : "string",
013dc89f 7292 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
56122987 7293 },
7aacca6f
DM
7294 "vmid" : {
7295 "description" : "The (unique) ID of the VM.",
7aacca6f 7296 "format" : "pve-vmid",
44660702 7297 "minimum" : 1,
4bd7df8b 7298 "type" : "integer",
013dc89f 7299 "typetext" : "<integer> (1 - N)"
56122987 7300 },
44660702 7301 "watchdog" : {
c2993fe5 7302 "description" : "Create a virtual hardware watchdog device.",
44660702 7303 "format" : "pve-qm-watchdog",
56122987 7304 "optional" : 1,
c2993fe5 7305 "type" : "string",
013dc89f 7306 "typetext" : "[[model=]<i6300esb|ib700>] [,action=<enum>]",
c2993fe5 7307 "verbose_description" : "Create a virtual hardware watchdog device. Once enabled (by a guest action), the watchdog must be periodically polled by an agent inside the guest or else the watchdog will reset the guest (or execute the respective action specified)"
56122987 7308 }
44660702 7309 }
56122987 7310 },
7aacca6f
DM
7311 "permissions" : {
7312 "check" : [
7313 "perm",
7314 "/vms/{vmid}",
7315 [
44660702
DM
7316 "VM.Config.Disk",
7317 "VM.Config.CDROM",
7318 "VM.Config.CPU",
7319 "VM.Config.Memory",
7320 "VM.Config.Network",
7321 "VM.Config.HWType",
7322 "VM.Config.Options"
7323 ],
7324 "any",
7325 1
7aacca6f 7326 ]
56122987 7327 },
44660702 7328 "protected" : 1,
7aacca6f 7329 "proxyto" : "node",
44660702
DM
7330 "returns" : {
7331 "optional" : 1,
7332 "type" : "string"
7333 }
56122987 7334 },
7aacca6f 7335 "PUT" : {
44660702
DM
7336 "description" : "Set virtual machine options (synchrounous API) - You should consider using the POST method instead for any actions involving hotplug or storage allocation.",
7337 "method" : "PUT",
7338 "name" : "update_vm",
56122987 7339 "parameters" : {
7aacca6f 7340 "additionalProperties" : 0,
56122987 7341 "properties" : {
44660702
DM
7342 "acpi" : {
7343 "default" : 1,
7344 "description" : "Enable/disable ACPI.",
7aacca6f 7345 "optional" : 1,
013dc89f
DM
7346 "type" : "boolean",
7347 "typetext" : "<boolean>"
7aacca6f 7348 },
44660702
DM
7349 "agent" : {
7350 "default" : 0,
7351 "description" : "Enable/disable Qemu GuestAgent.",
7aacca6f 7352 "optional" : 1,
013dc89f
DM
7353 "type" : "boolean",
7354 "typetext" : "<boolean>"
56122987 7355 },
44660702 7356 "args" : {
c2993fe5 7357 "description" : "Arbitrary arguments passed to kvm.",
7aacca6f 7358 "optional" : 1,
c2993fe5 7359 "type" : "string",
013dc89f 7360 "typetext" : "<string>",
c2993fe5 7361 "verbose_description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n"
7aacca6f 7362 },
44660702
DM
7363 "autostart" : {
7364 "default" : 0,
7365 "description" : "Automatic restart after crash (currently ignored).",
7aacca6f 7366 "optional" : 1,
013dc89f
DM
7367 "type" : "boolean",
7368 "typetext" : "<boolean>"
7aacca6f 7369 },
44660702
DM
7370 "balloon" : {
7371 "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.",
7372 "minimum" : 0,
7373 "optional" : 1,
4bd7df8b 7374 "type" : "integer",
013dc89f 7375 "typetext" : "<integer> (0 - N)"
44660702
DM
7376 },
7377 "bios" : {
7378 "default" : "seabios",
7379 "description" : "Select BIOS implementation.",
7aacca6f 7380 "enum" : [
44660702
DM
7381 "seabios",
7382 "ovmf"
7aacca6f 7383 ],
56122987 7384 "optional" : 1,
7aacca6f
DM
7385 "type" : "string"
7386 },
44660702
DM
7387 "boot" : {
7388 "default" : "cdn",
7389 "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).",
7aacca6f 7390 "optional" : 1,
44660702
DM
7391 "pattern" : "[acdn]{1,4}",
7392 "type" : "string"
56122987 7393 },
44660702
DM
7394 "bootdisk" : {
7395 "description" : "Enable booting from specified disk.",
7396 "format" : "pve-qm-bootdisk",
7397 "optional" : 1,
7398 "pattern" : "(ide|sata|scsi|virtio)\\d+",
7399 "type" : "string"
7400 },
7401 "cdrom" : {
7402 "description" : "This is an alias for option -ide2",
de0983cb 7403 "format" : "pve-qm-ide",
56122987 7404 "optional" : 1,
7aacca6f 7405 "type" : "string",
013dc89f 7406 "typetext" : "<volume>"
44660702
DM
7407 },
7408 "cores" : {
7409 "default" : 1,
7410 "description" : "The number of cores per socket.",
7411 "minimum" : 1,
7412 "optional" : 1,
4bd7df8b 7413 "type" : "integer",
013dc89f 7414 "typetext" : "<integer> (1 - N)"
44660702
DM
7415 },
7416 "cpu" : {
7417 "description" : "Emulated CPU type.",
7418 "format" : {
7419 "cputype" : {
7420 "default" : "kvm64",
7421 "default_key" : 1,
7422 "description" : "Emulated CPU type.",
7423 "enum" : [
7424 "486",
7425 "athlon",
f004f5b9
DM
7426 "Broadwell",
7427 "Broadwell-noTSX",
7428 "Conroe",
44660702 7429 "core2duo",
f004f5b9
DM
7430 "coreduo",
7431 "Haswell",
7432 "Haswell-noTSX",
7433 "host",
7434 "IvyBridge",
44660702
DM
7435 "kvm32",
7436 "kvm64",
44660702 7437 "Nehalem",
44660702
DM
7438 "Opteron_G1",
7439 "Opteron_G2",
7440 "Opteron_G3",
7441 "Opteron_G4",
7442 "Opteron_G5",
f004f5b9
DM
7443 "Penryn",
7444 "pentium",
7445 "pentium2",
7446 "pentium3",
7447 "phenom",
7448 "qemu32",
7449 "qemu64",
7450 "SandyBridge",
7451 "Westmere"
44660702 7452 ],
44660702
DM
7453 "type" : "string"
7454 },
7455 "hidden" : {
7456 "default" : 0,
7457 "description" : "Do not identify as a KVM virtual machine.",
7458 "optional" : 1,
7459 "type" : "boolean"
7460 }
7461 },
7462 "optional" : 1,
4bd7df8b 7463 "type" : "string",
013dc89f 7464 "typetext" : "[cputype=]<enum> [,hidden=<1|0>]"
44660702
DM
7465 },
7466 "cpulimit" : {
7467 "default" : 0,
c2993fe5 7468 "description" : "Limit of CPU usage.",
44660702
DM
7469 "maximum" : 128,
7470 "minimum" : 0,
7471 "optional" : 1,
c2993fe5 7472 "type" : "number",
013dc89f 7473 "typetext" : "<number> (0 - 128)",
c2993fe5 7474 "verbose_description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has total of '2' CPU time. Value '0' indicates no CPU limit."
44660702
DM
7475 },
7476 "cpuunits" : {
de0983cb 7477 "default" : 1024,
c2993fe5 7478 "description" : "CPU weight for a VM.",
44660702
DM
7479 "maximum" : 500000,
7480 "minimum" : 0,
7481 "optional" : 1,
c2993fe5 7482 "type" : "integer",
013dc89f 7483 "typetext" : "<integer> (0 - 500000)",
c2993fe5 7484 "verbose_description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0."
44660702
DM
7485 },
7486 "delete" : {
7487 "description" : "A list of settings you want to delete.",
7488 "format" : "pve-configid-list",
7489 "optional" : 1,
013dc89f
DM
7490 "type" : "string",
7491 "typetext" : "<string>"
44660702
DM
7492 },
7493 "description" : {
7494 "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.",
7495 "optional" : 1,
013dc89f
DM
7496 "type" : "string",
7497 "typetext" : "<string>"
44660702
DM
7498 },
7499 "digest" : {
7500 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
7501 "maxLength" : 40,
7502 "optional" : 1,
013dc89f
DM
7503 "type" : "string",
7504 "typetext" : "<string>"
44660702
DM
7505 },
7506 "force" : {
7507 "description" : "Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal.",
7508 "optional" : 1,
7509 "requires" : "delete",
013dc89f
DM
7510 "type" : "boolean",
7511 "typetext" : "<boolean>"
44660702
DM
7512 },
7513 "freeze" : {
7514 "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).",
7515 "optional" : 1,
013dc89f
DM
7516 "type" : "boolean",
7517 "typetext" : "<boolean>"
44660702
DM
7518 },
7519 "hostpci[n]" : {
c2993fe5 7520 "description" : "Map host PCI devices into guest.",
44660702
DM
7521 "format" : "pve-qm-hostpci",
7522 "optional" : 1,
57b78691 7523 "type" : "string",
52e44c50 7524 "typetext" : "[host=]<HOSTPCIID[;HOSTPCIID2...]> [,pcie=<1|0>] [,rombar=<1|0>] [,romfile=<string>] [,x-vga=<1|0>]",
57b78691 7525 "verbose_description" : "Map host PCI devices into guest.\n\nNOTE: This option allows direct access to host hardware. So it is no longer \npossible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
56122987 7526 },
7aacca6f 7527 "hotplug" : {
7aacca6f 7528 "default" : "network,disk,usb",
44660702
DM
7529 "description" : "Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'.",
7530 "format" : "pve-hotplug-features",
56122987 7531 "optional" : 1,
013dc89f
DM
7532 "type" : "string",
7533 "typetext" : "<string>"
56122987 7534 },
4bd7df8b
DM
7535 "hugepages" : {
7536 "description" : "Enable/disable hugepages memory.",
7537 "enum" : [
7538 "any",
7539 "2",
7540 "1024"
7541 ],
7542 "optional" : 1,
7543 "type" : "string"
7544 },
56122987 7545 "ide[n]" : {
7aacca6f 7546 "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).",
56122987 7547 "format" : {
44660702
DM
7548 "aio" : {
7549 "description" : "AIO type to use.",
7550 "enum" : [
7551 "native",
7552 "threads"
7553 ],
56122987 7554 "optional" : 1,
44660702 7555 "type" : "string"
56122987 7556 },
44660702
DM
7557 "backup" : {
7558 "description" : "Whether the drive should be included when making backups.",
44660702
DM
7559 "optional" : 1,
7560 "type" : "boolean"
7561 },
7562 "bps" : {
de0983cb 7563 "description" : "Maximum r/w speed in bytes per second.",
44660702 7564 "format_description" : "bps",
56122987 7565 "optional" : 1,
44660702 7566 "type" : "integer"
56122987 7567 },
de0983cb
DM
7568 "bps_max_length" : {
7569 "description" : "Maximum length of I/O bursts in seconds.",
7570 "format_description" : "seconds",
7571 "minimum" : 1,
7572 "optional" : 1,
7573 "type" : "integer"
7574 },
44660702 7575 "bps_rd" : {
de0983cb 7576 "description" : "Maximum read speed in bytes per second.",
44660702 7577 "format_description" : "bps",
56122987 7578 "optional" : 1,
44660702 7579 "type" : "integer"
56122987 7580 },
de0983cb
DM
7581 "bps_rd_length" : {
7582 "description" : "Maximum length of read I/O bursts in seconds.",
7583 "format_description" : "seconds",
7584 "minimum" : 1,
7585 "optional" : 1,
7586 "type" : "integer"
7587 },
7aacca6f 7588 "bps_wr" : {
de0983cb 7589 "description" : "Maximum write speed in bytes per second.",
44660702
DM
7590 "format_description" : "bps",
7591 "optional" : 1,
7592 "type" : "integer"
7aacca6f 7593 },
de0983cb
DM
7594 "bps_wr_length" : {
7595 "description" : "Maximum length of write I/O bursts in seconds.",
7596 "format_description" : "seconds",
7597 "minimum" : 1,
7598 "optional" : 1,
7599 "type" : "integer"
7600 },
44660702
DM
7601 "cache" : {
7602 "description" : "The drive's cache mode",
7603 "enum" : [
7604 "none",
7605 "writethrough",
7606 "writeback",
7607 "unsafe",
7608 "directsync"
7609 ],
56122987 7610 "optional" : 1,
44660702
DM
7611 "type" : "string"
7612 },
7613 "cyls" : {
7614 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
7615 "optional" : 1,
7616 "type" : "integer"
7617 },
7618 "detect_zeroes" : {
7619 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
7620 "optional" : 1,
7621 "type" : "boolean"
56122987 7622 },
7aacca6f 7623 "discard" : {
7aacca6f 7624 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
56122987 7625 "enum" : [
7aacca6f
DM
7626 "ignore",
7627 "on"
56122987
DM
7628 ],
7629 "optional" : 1,
44660702 7630 "type" : "string"
7aacca6f 7631 },
44660702
DM
7632 "file" : {
7633 "default_key" : 1,
7634 "description" : "The drive's backing volume.",
7635 "format" : "pve-volume-id-or-qm-path",
7636 "format_description" : "volume",
7637 "type" : "string"
7aacca6f
DM
7638 },
7639 "format" : {
44660702 7640 "description" : "The drive's backing file's data format.",
7aacca6f
DM
7641 "enum" : [
7642 "raw",
7643 "cow",
7644 "qcow",
7645 "qed",
7646 "qcow2",
7647 "vmdk",
7648 "cloop"
7649 ],
7aacca6f 7650 "optional" : 1,
44660702 7651 "type" : "string"
56122987 7652 },
7aacca6f 7653 "heads" : {
44660702 7654 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 7655 "optional" : 1,
44660702 7656 "type" : "integer"
7aacca6f 7657 },
44660702 7658 "iops" : {
de0983cb 7659 "description" : "Maximum r/w I/O in operations per second.",
44660702 7660 "format_description" : "iops",
7aacca6f 7661 "optional" : 1,
44660702 7662 "type" : "integer"
56122987 7663 },
44660702 7664 "iops_max" : {
de0983cb 7665 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702 7666 "format_description" : "iops",
56122987 7667 "optional" : 1,
44660702 7668 "type" : "integer"
56122987 7669 },
de0983cb
DM
7670 "iops_max_length" : {
7671 "description" : "Maximum length of I/O bursts in seconds.",
7672 "format_description" : "seconds",
7673 "minimum" : 1,
7674 "optional" : 1,
7675 "type" : "integer"
7676 },
44660702 7677 "iops_rd" : {
de0983cb 7678 "description" : "Maximum read I/O in operations per second.",
44660702 7679 "format_description" : "iops",
56122987 7680 "optional" : 1,
44660702 7681 "type" : "integer"
7aacca6f 7682 },
de0983cb
DM
7683 "iops_rd_length" : {
7684 "description" : "Maximum length of read I/O bursts in seconds.",
7685 "format_description" : "seconds",
7686 "minimum" : 1,
7687 "optional" : 1,
7688 "type" : "integer"
7689 },
44660702 7690 "iops_rd_max" : {
de0983cb 7691 "description" : "Maximum unthrottled read I/O pool in operations per second.",
44660702 7692 "format_description" : "iops",
7aacca6f 7693 "optional" : 1,
44660702 7694 "type" : "integer"
7aacca6f 7695 },
44660702 7696 "iops_wr" : {
de0983cb 7697 "description" : "Maximum write I/O in operations per second.",
44660702 7698 "format_description" : "iops",
7aacca6f 7699 "optional" : 1,
44660702 7700 "type" : "integer"
56122987 7701 },
de0983cb
DM
7702 "iops_wr_length" : {
7703 "description" : "Maximum length of write I/O bursts in seconds.",
7704 "format_description" : "seconds",
7705 "minimum" : 1,
7706 "optional" : 1,
7707 "type" : "integer"
7708 },
44660702 7709 "iops_wr_max" : {
de0983cb 7710 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702 7711 "format_description" : "iops",
7aacca6f 7712 "optional" : 1,
44660702 7713 "type" : "integer"
7aacca6f
DM
7714 },
7715 "mbps" : {
de0983cb 7716 "description" : "Maximum r/w speed in megabytes per second.",
7aacca6f 7717 "format_description" : "mbps",
7aacca6f 7718 "optional" : 1,
44660702 7719 "type" : "number"
7aacca6f 7720 },
44660702 7721 "mbps_max" : {
de0983cb 7722 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702 7723 "format_description" : "mbps",
7aacca6f 7724 "optional" : 1,
44660702 7725 "type" : "number"
7aacca6f 7726 },
44660702 7727 "mbps_rd" : {
de0983cb 7728 "description" : "Maximum read speed in megabytes per second.",
44660702 7729 "format_description" : "mbps",
7aacca6f 7730 "optional" : 1,
44660702 7731 "type" : "number"
7aacca6f 7732 },
44660702 7733 "mbps_rd_max" : {
de0983cb 7734 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702
DM
7735 "format_description" : "mbps",
7736 "optional" : 1,
7737 "type" : "number"
7aacca6f 7738 },
44660702 7739 "mbps_wr" : {
de0983cb 7740 "description" : "Maximum write speed in megabytes per second.",
44660702 7741 "format_description" : "mbps",
7aacca6f 7742 "optional" : 1,
44660702
DM
7743 "type" : "number"
7744 },
7745 "mbps_wr_max" : {
de0983cb 7746 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702
DM
7747 "format_description" : "mbps",
7748 "optional" : 1,
7749 "type" : "number"
7750 },
7751 "media" : {
7752 "default" : "disk",
7753 "description" : "The drive's media type.",
56122987 7754 "enum" : [
44660702
DM
7755 "cdrom",
7756 "disk"
56122987 7757 ],
44660702
DM
7758 "optional" : 1,
7759 "type" : "string"
56122987 7760 },
7aacca6f 7761 "model" : {
44660702 7762 "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.",
56122987 7763 "format" : "urlencoded",
7aacca6f 7764 "format_description" : "model",
44660702 7765 "maxLength" : 120,
56122987 7766 "optional" : 1,
44660702 7767 "type" : "string"
56122987 7768 },
44660702
DM
7769 "rerror" : {
7770 "description" : "Read error action.",
7771 "enum" : [
7772 "ignore",
7773 "report",
7774 "stop"
7775 ],
56122987 7776 "optional" : 1,
44660702 7777 "type" : "string"
56122987 7778 },
44660702
DM
7779 "secs" : {
7780 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
7781 "optional" : 1,
7782 "type" : "integer"
56122987 7783 },
44660702
DM
7784 "serial" : {
7785 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
7786 "format" : "urlencoded",
7787 "format_description" : "serial",
7788 "maxLength" : 60,
56122987 7789 "optional" : 1,
44660702 7790 "type" : "string"
56122987 7791 },
44660702
DM
7792 "size" : {
7793 "description" : "Disk size. This is purely informational and has no effect.",
7794 "format" : "disk-size",
f004f5b9 7795 "format_description" : "DiskSize",
56122987 7796 "optional" : 1,
44660702 7797 "type" : "string"
56122987 7798 },
44660702
DM
7799 "snapshot" : {
7800 "description" : "Whether the drive should be included when making snapshots.",
56122987 7801 "optional" : 1,
44660702 7802 "type" : "boolean"
56122987 7803 },
44660702
DM
7804 "trans" : {
7805 "description" : "Force disk geometry bios translation mode.",
7806 "enum" : [
7807 "none",
7808 "lba",
7809 "auto"
7810 ],
56122987 7811 "optional" : 1,
44660702
DM
7812 "type" : "string"
7813 },
7814 "volume" : {
7815 "alias" : "file"
56122987 7816 },
7aacca6f 7817 "werror" : {
44660702 7818 "description" : "Write error action.",
7aacca6f
DM
7819 "enum" : [
7820 "enospc",
7821 "ignore",
7822 "report",
7823 "stop"
7824 ],
56122987 7825 "optional" : 1,
44660702 7826 "type" : "string"
7aacca6f 7827 }
44660702
DM
7828 },
7829 "optional" : 1,
4bd7df8b 7830 "type" : "string",
013dc89f 7831 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,model=<model>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
7aacca6f 7832 },
44660702
DM
7833 "keyboard" : {
7834 "default" : "en-us",
c2993fe5 7835 "description" : "Keybord layout for vnc server. Default is read from the '/etc/pve/datacenter.conf' configuration file.",
44660702
DM
7836 "enum" : [
7837 "de",
7838 "de-ch",
7839 "da",
7840 "en-gb",
7841 "en-us",
7842 "es",
7843 "fi",
7844 "fr",
7845 "fr-be",
7846 "fr-ca",
7847 "fr-ch",
7848 "hu",
7849 "is",
7850 "it",
7851 "ja",
7852 "lt",
7853 "mk",
7854 "nl",
7855 "no",
7856 "pl",
7857 "pt",
7858 "pt-br",
7859 "sv",
7860 "sl",
7861 "tr"
7862 ],
7aacca6f 7863 "optional" : 1,
44660702 7864 "type" : "string"
7aacca6f 7865 },
44660702 7866 "kvm" : {
7aacca6f 7867 "default" : 1,
44660702 7868 "description" : "Enable/disable KVM hardware virtualization.",
7aacca6f 7869 "optional" : 1,
013dc89f
DM
7870 "type" : "boolean",
7871 "typetext" : "<boolean>"
7aacca6f 7872 },
44660702
DM
7873 "localtime" : {
7874 "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.",
7aacca6f 7875 "optional" : 1,
013dc89f
DM
7876 "type" : "boolean",
7877 "typetext" : "<boolean>"
7aacca6f 7878 },
44660702
DM
7879 "lock" : {
7880 "description" : "Lock/unlock the VM.",
7881 "enum" : [
7882 "migrate",
7883 "backup",
7884 "snapshot",
7885 "rollback"
7886 ],
7aacca6f 7887 "optional" : 1,
44660702 7888 "type" : "string"
7aacca6f 7889 },
44660702
DM
7890 "machine" : {
7891 "description" : "Specific the Qemu machine type.",
7892 "maxLength" : 40,
7aacca6f 7893 "optional" : 1,
44660702
DM
7894 "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)",
7895 "type" : "string"
7aacca6f 7896 },
44660702
DM
7897 "memory" : {
7898 "default" : 512,
7899 "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.",
7900 "minimum" : 16,
7aacca6f 7901 "optional" : 1,
4bd7df8b 7902 "type" : "integer",
013dc89f 7903 "typetext" : "<integer> (16 - N)"
7aacca6f 7904 },
44660702
DM
7905 "migrate_downtime" : {
7906 "default" : 0.1,
7907 "description" : "Set maximum tolerated downtime (in seconds) for migrations.",
7908 "minimum" : 0,
7aacca6f 7909 "optional" : 1,
4bd7df8b 7910 "type" : "number",
013dc89f 7911 "typetext" : "<number> (0 - N)"
7aacca6f 7912 },
44660702 7913 "migrate_speed" : {
7aacca6f 7914 "default" : 0,
44660702
DM
7915 "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.",
7916 "minimum" : 0,
7917 "optional" : 1,
4bd7df8b 7918 "type" : "integer",
013dc89f 7919 "typetext" : "<integer> (0 - N)"
7aacca6f 7920 },
44660702
DM
7921 "name" : {
7922 "description" : "Set a name for the VM. Only used on the configuration web interface.",
7923 "format" : "dns-name",
7aacca6f 7924 "optional" : 1,
013dc89f
DM
7925 "type" : "string",
7926 "typetext" : "<string>"
7aacca6f 7927 },
44660702 7928 "net[n]" : {
c2993fe5 7929 "description" : "Specify network devices.",
f004f5b9
DM
7930 "format" : {
7931 "bridge" : {
c2993fe5 7932 "description" : "Bridge to attach the network device to. The Proxmox VE standard bridge\nis called 'vmbr0'.\n\nIf you do not specify a bridge, we create a kvm user (NATed) network\ndevice, which provides DHCP and DNS services. The following addresses\nare used:\n\n 10.0.2.2 Gateway\n 10.0.2.3 DNS Server\n 10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n",
f004f5b9
DM
7933 "format_description" : "bridge",
7934 "optional" : 1,
7935 "type" : "string"
7936 },
7937 "e1000" : {
7938 "alias" : "macaddr",
7939 "keyAlias" : "model"
7940 },
7941 "e1000-82540em" : {
7942 "alias" : "macaddr",
7943 "keyAlias" : "model"
7944 },
7945 "e1000-82544gc" : {
7946 "alias" : "macaddr",
7947 "keyAlias" : "model"
7948 },
7949 "e1000-82545em" : {
7950 "alias" : "macaddr",
7951 "keyAlias" : "model"
7952 },
7953 "firewall" : {
7954 "description" : "Whether this interface should be protected by the firewall.",
7955 "optional" : 1,
7956 "type" : "boolean"
7957 },
7958 "i82551" : {
7959 "alias" : "macaddr",
7960 "keyAlias" : "model"
7961 },
7962 "i82557b" : {
7963 "alias" : "macaddr",
7964 "keyAlias" : "model"
7965 },
7966 "i82559er" : {
7967 "alias" : "macaddr",
7968 "keyAlias" : "model"
7969 },
7970 "link_down" : {
c2993fe5 7971 "description" : "Whether this interface should be disconnected (like pulling the plug).",
f004f5b9
DM
7972 "optional" : 1,
7973 "type" : "boolean"
7974 },
7975 "macaddr" : {
c2993fe5 7976 "description" : "MAC address. That address must be unique withing your network. This is automatically generated if not specified.",
f004f5b9 7977 "format_description" : "XX:XX:XX:XX:XX:XX",
f004f5b9
DM
7978 "optional" : 1,
7979 "pattern" : "(?^i:[0-9a-f]{2}(?::[0-9a-f]{2}){5})",
7980 "type" : "string"
7981 },
7982 "model" : {
7983 "default_key" : 1,
c2993fe5 7984 "description" : "Network Card Model. The 'virtio' model provides the best performance with very low CPU overhead. If your guest does not support this driver, it is usually best to use 'e1000'.",
f004f5b9
DM
7985 "enum" : [
7986 "rtl8139",
7987 "ne2k_pci",
7988 "e1000",
7989 "pcnet",
7990 "virtio",
7991 "ne2k_isa",
7992 "i82551",
7993 "i82557b",
7994 "i82559er",
7995 "vmxnet3",
7996 "e1000-82540em",
7997 "e1000-82544gc",
7998 "e1000-82545em"
7999 ],
f004f5b9
DM
8000 "type" : "string"
8001 },
8002 "ne2k_isa" : {
8003 "alias" : "macaddr",
8004 "keyAlias" : "model"
8005 },
8006 "ne2k_pci" : {
8007 "alias" : "macaddr",
8008 "keyAlias" : "model"
8009 },
8010 "pcnet" : {
8011 "alias" : "macaddr",
8012 "keyAlias" : "model"
8013 },
8014 "queues" : {
8015 "description" : "Number of packet queues to be used on the device.",
8016 "maximum" : 16,
8017 "minimum" : 0,
8018 "optional" : 1,
8019 "type" : "integer"
8020 },
8021 "rate" : {
c2993fe5 8022 "description" : "Rate limit in mbps (megabytes per second) as floating point number.",
f004f5b9
DM
8023 "minimum" : 0,
8024 "optional" : 1,
8025 "type" : "number"
8026 },
8027 "rtl8139" : {
8028 "alias" : "macaddr",
8029 "keyAlias" : "model"
8030 },
8031 "tag" : {
8032 "description" : "VLAN tag to apply to packets on this interface.",
8033 "maximum" : 4094,
c2993fe5 8034 "minimum" : 1,
f004f5b9
DM
8035 "optional" : 1,
8036 "type" : "integer"
8037 },
8038 "trunks" : {
8039 "description" : "VLAN trunks to pass through this interface.",
8040 "format_description" : "vlanid[;vlanid...]",
8041 "optional" : 1,
8042 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
8043 "type" : "string"
8044 },
8045 "virtio" : {
8046 "alias" : "macaddr",
8047 "keyAlias" : "model"
8048 },
8049 "vmxnet3" : {
8050 "alias" : "macaddr",
8051 "keyAlias" : "model"
8052 }
8053 },
7aacca6f 8054 "optional" : 1,
4bd7df8b 8055 "type" : "string",
013dc89f 8056 "typetext" : "[model=]<enum> [,bridge=<bridge>] [,firewall=<1|0>] [,link_down=<1|0>] [,macaddr=<XX:XX:XX:XX:XX:XX>] [,queues=<integer>] [,rate=<number>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,<model>=<macaddr>]"
7aacca6f 8057 },
44660702
DM
8058 "node" : {
8059 "description" : "The cluster node name.",
8060 "format" : "pve-node",
013dc89f
DM
8061 "type" : "string",
8062 "typetext" : "<string>"
44660702
DM
8063 },
8064 "numa" : {
8065 "default" : 0,
8066 "description" : "Enable/disable NUMA.",
7aacca6f 8067 "optional" : 1,
013dc89f
DM
8068 "type" : "boolean",
8069 "typetext" : "<boolean>"
7aacca6f 8070 },
44660702 8071 "numa[n]" : {
c2993fe5 8072 "description" : "NUMA topology.",
44660702
DM
8073 "format" : {
8074 "cpus" : {
c2993fe5 8075 "description" : "CPUs accessing this NUMA node.",
44660702
DM
8076 "format_description" : "id[-id];...",
8077 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
8078 "type" : "string"
8079 },
8080 "hostnodes" : {
c2993fe5 8081 "description" : "Host NUMA nodes to use.",
44660702
DM
8082 "format_description" : "id[-id];...",
8083 "optional" : 1,
8084 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
8085 "type" : "string"
8086 },
8087 "memory" : {
c2993fe5 8088 "description" : "Amount of memory this NUMA node provides.",
44660702
DM
8089 "optional" : 1,
8090 "type" : "number"
8091 },
8092 "policy" : {
c2993fe5 8093 "description" : "NUMA allocation policy.",
44660702
DM
8094 "enum" : [
8095 "preferred",
8096 "bind",
8097 "interleave"
8098 ],
44660702
DM
8099 "optional" : 1,
8100 "type" : "string"
8101 }
8102 },
7aacca6f 8103 "optional" : 1,
4bd7df8b
DM
8104 "type" : "string",
8105 "typetext" : "cpus=<id[-id];...> [,hostnodes=<id[-id];...>] [,memory=<number>] [,policy=<preferred|bind|interleave>]"
7aacca6f 8106 },
44660702
DM
8107 "onboot" : {
8108 "default" : 0,
8109 "description" : "Specifies whether a VM will be started during system bootup.",
7aacca6f 8110 "optional" : 1,
013dc89f
DM
8111 "type" : "boolean",
8112 "typetext" : "<boolean>"
7aacca6f 8113 },
44660702 8114 "ostype" : {
c2993fe5 8115 "description" : "Specify guest operating system.",
44660702
DM
8116 "enum" : [
8117 "other",
8118 "wxp",
8119 "w2k",
8120 "w2k3",
8121 "w2k8",
8122 "wvista",
8123 "win7",
8124 "win8",
32d876b5 8125 "win10",
44660702
DM
8126 "l24",
8127 "l26",
8128 "solaris"
8129 ],
7aacca6f 8130 "optional" : 1,
c2993fe5
DM
8131 "type" : "string",
8132 "verbose_description" : "Specify guest operating system. This is used to enable special\noptimization/features for specific operating systems:\n\n[horizontal]\nother;; unspecified OS\nwxp;; Microsoft Windows XP\nw2k;; Microsoft Windows 2000\nw2k3;; Microsoft Windows 2003\nw2k8;; Microsoft Windows 2008\nwvista;; Microsoft Windows Vista\nwin7;; Microsoft Windows 7\nwin8;; Microsoft Windows 8/2012\nl24;; Linux 2.4 Kernel\nl26;; Linux 2.6/3.X Kernel\nsolaris;; Solaris/OpenSolaris/OpenIndiania kernel\n"
7aacca6f 8133 },
44660702 8134 "parallel[n]" : {
c2993fe5 8135 "description" : "Map host parallel devices (n is 0 to 2).",
7aacca6f 8136 "optional" : 1,
44660702 8137 "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+",
c2993fe5
DM
8138 "type" : "string",
8139 "verbose_description" : "Map host parallel devices (n is 0 to 2).\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
7aacca6f 8140 },
44660702
DM
8141 "protection" : {
8142 "default" : 0,
c2993fe5 8143 "description" : "Sets the protection flag of the VM. This will disable the remove VM and remove disk operations.",
7aacca6f 8144 "optional" : 1,
013dc89f
DM
8145 "type" : "boolean",
8146 "typetext" : "<boolean>"
7aacca6f 8147 },
44660702
DM
8148 "reboot" : {
8149 "default" : 1,
8150 "description" : "Allow reboot. If set to '0' the VM exit on reboot.",
7aacca6f 8151 "optional" : 1,
013dc89f
DM
8152 "type" : "boolean",
8153 "typetext" : "<boolean>"
7aacca6f 8154 },
44660702
DM
8155 "revert" : {
8156 "description" : "Revert a pending change.",
8157 "format" : "pve-configid-list",
7aacca6f 8158 "optional" : 1,
013dc89f
DM
8159 "type" : "string",
8160 "typetext" : "<string>"
7aacca6f 8161 },
44660702
DM
8162 "sata[n]" : {
8163 "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).",
7aacca6f 8164 "format" : {
44660702
DM
8165 "aio" : {
8166 "description" : "AIO type to use.",
8167 "enum" : [
8168 "native",
8169 "threads"
8170 ],
44660702
DM
8171 "optional" : 1,
8172 "type" : "string"
8173 },
8174 "backup" : {
8175 "description" : "Whether the drive should be included when making backups.",
44660702
DM
8176 "optional" : 1,
8177 "type" : "boolean"
8178 },
8179 "bps" : {
de0983cb 8180 "description" : "Maximum r/w speed in bytes per second.",
7aacca6f 8181 "format_description" : "bps",
7aacca6f
DM
8182 "optional" : 1,
8183 "type" : "integer"
56122987 8184 },
de0983cb
DM
8185 "bps_max_length" : {
8186 "description" : "Maximum length of I/O bursts in seconds.",
8187 "format_description" : "seconds",
8188 "minimum" : 1,
8189 "optional" : 1,
8190 "type" : "integer"
8191 },
44660702 8192 "bps_rd" : {
de0983cb 8193 "description" : "Maximum read speed in bytes per second.",
44660702 8194 "format_description" : "bps",
7aacca6f 8195 "optional" : 1,
44660702 8196 "type" : "integer"
7aacca6f 8197 },
de0983cb
DM
8198 "bps_rd_length" : {
8199 "description" : "Maximum length of read I/O bursts in seconds.",
8200 "format_description" : "seconds",
8201 "minimum" : 1,
8202 "optional" : 1,
8203 "type" : "integer"
8204 },
44660702 8205 "bps_wr" : {
de0983cb 8206 "description" : "Maximum write speed in bytes per second.",
44660702 8207 "format_description" : "bps",
7aacca6f 8208 "optional" : 1,
44660702 8209 "type" : "integer"
7aacca6f 8210 },
de0983cb
DM
8211 "bps_wr_length" : {
8212 "description" : "Maximum length of write I/O bursts in seconds.",
8213 "format_description" : "seconds",
8214 "minimum" : 1,
8215 "optional" : 1,
8216 "type" : "integer"
8217 },
44660702
DM
8218 "cache" : {
8219 "description" : "The drive's cache mode",
8220 "enum" : [
8221 "none",
8222 "writethrough",
8223 "writeback",
8224 "unsafe",
8225 "directsync"
8226 ],
7aacca6f 8227 "optional" : 1,
44660702 8228 "type" : "string"
7aacca6f 8229 },
44660702
DM
8230 "cyls" : {
8231 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
7aacca6f 8232 "optional" : 1,
44660702 8233 "type" : "integer"
7aacca6f 8234 },
44660702
DM
8235 "detect_zeroes" : {
8236 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
7aacca6f 8237 "optional" : 1,
44660702 8238 "type" : "boolean"
7aacca6f 8239 },
44660702
DM
8240 "discard" : {
8241 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
8242 "enum" : [
8243 "ignore",
8244 "on"
8245 ],
7aacca6f 8246 "optional" : 1,
44660702
DM
8247 "type" : "string"
8248 },
8249 "file" : {
8250 "default_key" : 1,
8251 "description" : "The drive's backing volume.",
8252 "format" : "pve-volume-id-or-qm-path",
8253 "format_description" : "volume",
8254 "type" : "string"
7aacca6f
DM
8255 },
8256 "format" : {
7aacca6f 8257 "description" : "The drive's backing file's data format.",
56122987
DM
8258 "enum" : [
8259 "raw",
8260 "cow",
8261 "qcow",
8262 "qed",
8263 "qcow2",
8264 "vmdk",
8265 "cloop"
8266 ],
8267 "optional" : 1,
7aacca6f 8268 "type" : "string"
56122987 8269 },
7aacca6f 8270 "heads" : {
7aacca6f 8271 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
8272 "optional" : 1,
8273 "type" : "integer"
56122987 8274 },
44660702 8275 "iops" : {
de0983cb 8276 "description" : "Maximum r/w I/O in operations per second.",
44660702 8277 "format_description" : "iops",
56122987 8278 "optional" : 1,
44660702 8279 "type" : "integer"
7aacca6f 8280 },
44660702 8281 "iops_max" : {
de0983cb 8282 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702 8283 "format_description" : "iops",
7aacca6f 8284 "optional" : 1,
44660702 8285 "type" : "integer"
56122987 8286 },
de0983cb
DM
8287 "iops_max_length" : {
8288 "description" : "Maximum length of I/O bursts in seconds.",
8289 "format_description" : "seconds",
8290 "minimum" : 1,
8291 "optional" : 1,
8292 "type" : "integer"
8293 },
44660702 8294 "iops_rd" : {
de0983cb 8295 "description" : "Maximum read I/O in operations per second.",
44660702 8296 "format_description" : "iops",
56122987 8297 "optional" : 1,
44660702 8298 "type" : "integer"
7aacca6f 8299 },
de0983cb
DM
8300 "iops_rd_length" : {
8301 "description" : "Maximum length of read I/O bursts in seconds.",
8302 "format_description" : "seconds",
8303 "minimum" : 1,
8304 "optional" : 1,
8305 "type" : "integer"
8306 },
44660702 8307 "iops_rd_max" : {
de0983cb 8308 "description" : "Maximum unthrottled read I/O pool in operations per second.",
44660702 8309 "format_description" : "iops",
56122987 8310 "optional" : 1,
44660702 8311 "type" : "integer"
56122987 8312 },
44660702 8313 "iops_wr" : {
de0983cb 8314 "description" : "Maximum write I/O in operations per second.",
44660702
DM
8315 "format_description" : "iops",
8316 "optional" : 1,
8317 "type" : "integer"
56122987 8318 },
de0983cb
DM
8319 "iops_wr_length" : {
8320 "description" : "Maximum length of write I/O bursts in seconds.",
8321 "format_description" : "seconds",
8322 "minimum" : 1,
8323 "optional" : 1,
8324 "type" : "integer"
8325 },
44660702 8326 "iops_wr_max" : {
de0983cb 8327 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702
DM
8328 "format_description" : "iops",
8329 "optional" : 1,
8330 "type" : "integer"
8331 },
8332 "mbps" : {
de0983cb 8333 "description" : "Maximum r/w speed in megabytes per second.",
44660702
DM
8334 "format_description" : "mbps",
8335 "optional" : 1,
8336 "type" : "number"
8337 },
8338 "mbps_max" : {
de0983cb 8339 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702
DM
8340 "format_description" : "mbps",
8341 "optional" : 1,
8342 "type" : "number"
8343 },
8344 "mbps_rd" : {
de0983cb 8345 "description" : "Maximum read speed in megabytes per second.",
44660702
DM
8346 "format_description" : "mbps",
8347 "optional" : 1,
8348 "type" : "number"
8349 },
8350 "mbps_rd_max" : {
de0983cb 8351 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702
DM
8352 "format_description" : "mbps",
8353 "optional" : 1,
8354 "type" : "number"
8355 },
8356 "mbps_wr" : {
de0983cb 8357 "description" : "Maximum write speed in megabytes per second.",
44660702
DM
8358 "format_description" : "mbps",
8359 "optional" : 1,
8360 "type" : "number"
8361 },
8362 "mbps_wr_max" : {
de0983cb 8363 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702
DM
8364 "format_description" : "mbps",
8365 "optional" : 1,
8366 "type" : "number"
8367 },
8368 "media" : {
8369 "default" : "disk",
8370 "description" : "The drive's media type.",
8371 "enum" : [
8372 "cdrom",
8373 "disk"
8374 ],
56122987 8375 "optional" : 1,
44660702
DM
8376 "type" : "string"
8377 },
8378 "rerror" : {
7aacca6f
DM
8379 "description" : "Read error action.",
8380 "enum" : [
8381 "ignore",
8382 "report",
8383 "stop"
44660702 8384 ],
56122987 8385 "optional" : 1,
44660702 8386 "type" : "string"
56122987 8387 },
7aacca6f 8388 "secs" : {
44660702 8389 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 8390 "optional" : 1,
44660702 8391 "type" : "integer"
56122987 8392 },
44660702
DM
8393 "serial" : {
8394 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
8395 "format" : "urlencoded",
8396 "format_description" : "serial",
8397 "maxLength" : 60,
56122987 8398 "optional" : 1,
44660702 8399 "type" : "string"
56122987 8400 },
44660702
DM
8401 "size" : {
8402 "description" : "Disk size. This is purely informational and has no effect.",
8403 "format" : "disk-size",
f004f5b9 8404 "format_description" : "DiskSize",
56122987 8405 "optional" : 1,
44660702 8406 "type" : "string"
56122987
DM
8407 },
8408 "snapshot" : {
7aacca6f 8409 "description" : "Whether the drive should be included when making snapshots.",
56122987 8410 "optional" : 1,
44660702 8411 "type" : "boolean"
56122987 8412 },
56122987 8413 "trans" : {
7aacca6f 8414 "description" : "Force disk geometry bios translation mode.",
56122987
DM
8415 "enum" : [
8416 "none",
8417 "lba",
8418 "auto"
8419 ],
8420 "optional" : 1,
44660702 8421 "type" : "string"
56122987 8422 },
44660702
DM
8423 "volume" : {
8424 "alias" : "file"
56122987 8425 },
7aacca6f 8426 "werror" : {
44660702 8427 "description" : "Write error action.",
56122987 8428 "enum" : [
7aacca6f 8429 "enospc",
56122987 8430 "ignore",
7aacca6f
DM
8431 "report",
8432 "stop"
8433 ],
7aacca6f 8434 "optional" : 1,
44660702
DM
8435 "type" : "string"
8436 }
8437 },
8438 "optional" : 1,
4bd7df8b 8439 "type" : "string",
013dc89f 8440 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
44660702
DM
8441 },
8442 "scsi[n]" : {
8443 "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).",
8444 "format" : {
8445 "aio" : {
7aacca6f 8446 "description" : "AIO type to use.",
56122987
DM
8447 "enum" : [
8448 "native",
8449 "threads"
44660702 8450 ],
56122987 8451 "optional" : 1,
44660702 8452 "type" : "string"
56122987 8453 },
7aacca6f 8454 "backup" : {
7aacca6f 8455 "description" : "Whether the drive should be included when making backups.",
7aacca6f 8456 "optional" : 1,
44660702 8457 "type" : "boolean"
56122987 8458 },
44660702 8459 "bps" : {
de0983cb 8460 "description" : "Maximum r/w speed in bytes per second.",
44660702 8461 "format_description" : "bps",
7aacca6f 8462 "optional" : 1,
44660702 8463 "type" : "integer"
7aacca6f 8464 },
de0983cb
DM
8465 "bps_max_length" : {
8466 "description" : "Maximum length of I/O bursts in seconds.",
8467 "format_description" : "seconds",
8468 "minimum" : 1,
8469 "optional" : 1,
8470 "type" : "integer"
8471 },
44660702 8472 "bps_rd" : {
de0983cb 8473 "description" : "Maximum read speed in bytes per second.",
44660702 8474 "format_description" : "bps",
56122987 8475 "optional" : 1,
44660702 8476 "type" : "integer"
56122987 8477 },
de0983cb
DM
8478 "bps_rd_length" : {
8479 "description" : "Maximum length of read I/O bursts in seconds.",
8480 "format_description" : "seconds",
8481 "minimum" : 1,
8482 "optional" : 1,
8483 "type" : "integer"
8484 },
44660702 8485 "bps_wr" : {
de0983cb 8486 "description" : "Maximum write speed in bytes per second.",
44660702 8487 "format_description" : "bps",
56122987 8488 "optional" : 1,
44660702 8489 "type" : "integer"
56122987 8490 },
de0983cb
DM
8491 "bps_wr_length" : {
8492 "description" : "Maximum length of write I/O bursts in seconds.",
8493 "format_description" : "seconds",
8494 "minimum" : 1,
8495 "optional" : 1,
8496 "type" : "integer"
8497 },
44660702
DM
8498 "cache" : {
8499 "description" : "The drive's cache mode",
8500 "enum" : [
8501 "none",
8502 "writethrough",
8503 "writeback",
8504 "unsafe",
8505 "directsync"
8506 ],
56122987 8507 "optional" : 1,
44660702
DM
8508 "type" : "string"
8509 },
8510 "cyls" : {
8511 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
8512 "optional" : 1,
8513 "type" : "integer"
8514 },
8515 "detect_zeroes" : {
8516 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
8517 "optional" : 1,
8518 "type" : "boolean"
8519 },
8520 "discard" : {
8521 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
8522 "enum" : [
8523 "ignore",
8524 "on"
8525 ],
44660702
DM
8526 "optional" : 1,
8527 "type" : "string"
8528 },
8529 "file" : {
8530 "default_key" : 1,
8531 "description" : "The drive's backing volume.",
8532 "format" : "pve-volume-id-or-qm-path",
8533 "format_description" : "volume",
8534 "type" : "string"
56122987 8535 },
7aacca6f 8536 "format" : {
44660702 8537 "description" : "The drive's backing file's data format.",
7aacca6f
DM
8538 "enum" : [
8539 "raw",
8540 "cow",
8541 "qcow",
8542 "qed",
8543 "qcow2",
8544 "vmdk",
8545 "cloop"
8546 ],
56122987 8547 "optional" : 1,
44660702 8548 "type" : "string"
56122987 8549 },
44660702
DM
8550 "heads" : {
8551 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 8552 "optional" : 1,
44660702 8553 "type" : "integer"
56122987 8554 },
44660702 8555 "iops" : {
de0983cb 8556 "description" : "Maximum r/w I/O in operations per second.",
44660702 8557 "format_description" : "iops",
7aacca6f 8558 "optional" : 1,
44660702 8559 "type" : "integer"
56122987 8560 },
44660702 8561 "iops_max" : {
de0983cb 8562 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
7aacca6f 8563 "format_description" : "iops",
7aacca6f 8564 "optional" : 1,
44660702 8565 "type" : "integer"
56122987 8566 },
de0983cb
DM
8567 "iops_max_length" : {
8568 "description" : "Maximum length of I/O bursts in seconds.",
8569 "format_description" : "seconds",
8570 "minimum" : 1,
8571 "optional" : 1,
8572 "type" : "integer"
8573 },
44660702 8574 "iops_rd" : {
de0983cb 8575 "description" : "Maximum read I/O in operations per second.",
44660702 8576 "format_description" : "iops",
56122987 8577 "optional" : 1,
44660702 8578 "type" : "integer"
56122987 8579 },
de0983cb
DM
8580 "iops_rd_length" : {
8581 "description" : "Maximum length of read I/O bursts in seconds.",
8582 "format_description" : "seconds",
8583 "minimum" : 1,
8584 "optional" : 1,
8585 "type" : "integer"
8586 },
44660702 8587 "iops_rd_max" : {
de0983cb 8588 "description" : "Maximum unthrottled read I/O pool in operations per second.",
44660702 8589 "format_description" : "iops",
56122987 8590 "optional" : 1,
44660702 8591 "type" : "integer"
56122987 8592 },
44660702 8593 "iops_wr" : {
de0983cb 8594 "description" : "Maximum write I/O in operations per second.",
44660702 8595 "format_description" : "iops",
56122987 8596 "optional" : 1,
44660702 8597 "type" : "integer"
56122987 8598 },
de0983cb
DM
8599 "iops_wr_length" : {
8600 "description" : "Maximum length of write I/O bursts in seconds.",
8601 "format_description" : "seconds",
8602 "minimum" : 1,
8603 "optional" : 1,
8604 "type" : "integer"
8605 },
44660702 8606 "iops_wr_max" : {
de0983cb 8607 "description" : "Maximum unthrottled write I/O pool in operations per second.",
7aacca6f 8608 "format_description" : "iops",
44660702
DM
8609 "optional" : 1,
8610 "type" : "integer"
7aacca6f
DM
8611 },
8612 "iothread" : {
44660702 8613 "description" : "Whether to use iothreads for this drive",
56122987 8614 "optional" : 1,
44660702 8615 "type" : "boolean"
56122987 8616 },
44660702 8617 "mbps" : {
de0983cb 8618 "description" : "Maximum r/w speed in megabytes per second.",
44660702 8619 "format_description" : "mbps",
56122987 8620 "optional" : 1,
44660702 8621 "type" : "number"
56122987 8622 },
44660702 8623 "mbps_max" : {
de0983cb 8624 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702 8625 "format_description" : "mbps",
56122987 8626 "optional" : 1,
44660702 8627 "type" : "number"
56122987 8628 },
44660702 8629 "mbps_rd" : {
de0983cb 8630 "description" : "Maximum read speed in megabytes per second.",
44660702 8631 "format_description" : "mbps",
7aacca6f 8632 "optional" : 1,
44660702 8633 "type" : "number"
56122987 8634 },
44660702 8635 "mbps_rd_max" : {
de0983cb 8636 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702 8637 "format_description" : "mbps",
7aacca6f 8638 "optional" : 1,
44660702 8639 "type" : "number"
7aacca6f 8640 },
44660702 8641 "mbps_wr" : {
de0983cb 8642 "description" : "Maximum write speed in megabytes per second.",
44660702 8643 "format_description" : "mbps",
56122987 8644 "optional" : 1,
44660702 8645 "type" : "number"
56122987 8646 },
44660702 8647 "mbps_wr_max" : {
de0983cb 8648 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702 8649 "format_description" : "mbps",
56122987 8650 "optional" : 1,
44660702
DM
8651 "type" : "number"
8652 },
8653 "media" : {
8654 "default" : "disk",
8655 "description" : "The drive's media type.",
7aacca6f 8656 "enum" : [
44660702
DM
8657 "cdrom",
8658 "disk"
7aacca6f 8659 ],
56122987 8660 "optional" : 1,
44660702 8661 "type" : "string"
56122987 8662 },
7aacca6f 8663 "queues" : {
44660702 8664 "description" : "Number of queues.",
7aacca6f 8665 "minimum" : 2,
7aacca6f
DM
8666 "optional" : 1,
8667 "type" : "integer"
56122987 8668 },
52e44c50
FG
8669 "scsiblock" : {
8670 "default" : 0,
8671 "description" : "whether to use scsi-block for full passthrough of host block device\n\nWARNING: can lead to I/O errors in combination with low memory or high memory fragmentation on host",
8672 "optional" : 1,
8673 "type" : "boolean"
8674 },
44660702
DM
8675 "secs" : {
8676 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 8677 "optional" : 1,
44660702 8678 "type" : "integer"
56122987 8679 },
44660702
DM
8680 "serial" : {
8681 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
8682 "format" : "urlencoded",
8683 "format_description" : "serial",
8684 "maxLength" : 60,
56122987 8685 "optional" : 1,
44660702 8686 "type" : "string"
56122987 8687 },
44660702
DM
8688 "size" : {
8689 "description" : "Disk size. This is purely informational and has no effect.",
8690 "format" : "disk-size",
f004f5b9 8691 "format_description" : "DiskSize",
44660702
DM
8692 "optional" : 1,
8693 "type" : "string"
8694 },
8695 "snapshot" : {
8696 "description" : "Whether the drive should be included when making snapshots.",
56122987 8697 "optional" : 1,
44660702
DM
8698 "type" : "boolean"
8699 },
8700 "trans" : {
8701 "description" : "Force disk geometry bios translation mode.",
56122987 8702 "enum" : [
44660702
DM
8703 "none",
8704 "lba",
8705 "auto"
56122987 8706 ],
44660702
DM
8707 "optional" : 1,
8708 "type" : "string"
8709 },
8710 "volume" : {
8711 "alias" : "file"
56122987 8712 },
7aacca6f 8713 "werror" : {
7aacca6f
DM
8714 "description" : "Write error action.",
8715 "enum" : [
8716 "enospc",
8717 "ignore",
8718 "report",
8719 "stop"
44660702 8720 ],
56122987 8721 "optional" : 1,
7aacca6f 8722 "type" : "string"
56122987 8723 }
44660702 8724 },
56122987 8725 "optional" : 1,
4bd7df8b 8726 "type" : "string",
52e44c50 8727 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,queues=<integer>] [,scsiblock=<1|0>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
56122987
DM
8728 },
8729 "scsihw" : {
44660702 8730 "default" : "lsi",
c2993fe5 8731 "description" : "SCSI controller model",
56122987
DM
8732 "enum" : [
8733 "lsi",
8734 "lsi53c810",
8735 "virtio-scsi-pci",
8736 "virtio-scsi-single",
8737 "megasas",
8738 "pvscsi"
8739 ],
8740 "optional" : 1,
56122987
DM
8741 "type" : "string"
8742 },
44660702 8743 "serial[n]" : {
c2993fe5 8744 "description" : "Create a serial device inside the VM (n is 0 to 3)",
56122987 8745 "optional" : 1,
44660702 8746 "pattern" : "(/dev/.+|socket)",
c2993fe5 8747 "type" : "string",
57b78691 8748 "verbose_description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a\nhost serial device (i.e. /dev/ttyS0), or create a unix socket on the\nhost side (use 'qm terminal' to open a terminal connection).\n\nNOTE: If you pass through a host serial device, it is no longer possible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
56122987 8749 },
44660702
DM
8750 "shares" : {
8751 "default" : 1000,
8752 "description" : "Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning",
8753 "maximum" : 50000,
8754 "minimum" : 0,
7aacca6f 8755 "optional" : 1,
4bd7df8b 8756 "type" : "integer",
013dc89f 8757 "typetext" : "<integer> (0 - 50000)"
56122987 8758 },
7aacca6f
DM
8759 "skiplock" : {
8760 "description" : "Ignore locks - only root is allowed to use this option.",
44660702 8761 "optional" : 1,
013dc89f
DM
8762 "type" : "boolean",
8763 "typetext" : "<boolean>"
56122987 8764 },
44660702
DM
8765 "smbios1" : {
8766 "description" : "Specify SMBIOS type 1 fields.",
8767 "format" : "pve-qm-smbios1",
8768 "maxLength" : 256,
56122987 8769 "optional" : 1,
4bd7df8b
DM
8770 "type" : "string",
8771 "typetext" : "[family=<string>] [,manufacturer=<string>] [,product=<string>] [,serial=<string>] [,sku=<string>] [,uuid=<UUID>] [,version=<string>]"
56122987 8772 },
44660702
DM
8773 "smp" : {
8774 "default" : 1,
8775 "description" : "The number of CPUs. Please use option -sockets instead.",
8776 "minimum" : 1,
56122987 8777 "optional" : 1,
4bd7df8b 8778 "type" : "integer",
013dc89f 8779 "typetext" : "<integer> (1 - N)"
56122987 8780 },
44660702
DM
8781 "sockets" : {
8782 "default" : 1,
8783 "description" : "The number of CPU sockets.",
8784 "minimum" : 1,
56122987 8785 "optional" : 1,
4bd7df8b 8786 "type" : "integer",
013dc89f 8787 "typetext" : "<integer> (1 - N)"
56122987 8788 },
44660702
DM
8789 "startdate" : {
8790 "default" : "now",
8791 "description" : "Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'.",
8792 "optional" : 1,
8793 "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)",
7aacca6f 8794 "type" : "string",
44660702
DM
8795 "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)"
8796 },
8797 "startup" : {
8798 "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.",
8799 "format" : "pve-startup-order",
7aacca6f 8800 "optional" : 1,
44660702
DM
8801 "type" : "string",
8802 "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] "
7aacca6f 8803 },
44660702
DM
8804 "tablet" : {
8805 "default" : 1,
c2993fe5 8806 "description" : "Enable/disable the USB tablet device.",
7aacca6f 8807 "optional" : 1,
c2993fe5 8808 "type" : "boolean",
013dc89f 8809 "typetext" : "<boolean>",
c2993fe5 8810 "verbose_description" : "Enable/disable the USB tablet device. This device is usually needed to allow absolute mouse positioning with VNC. Else the mouse runs out of sync with normal VNC clients. If you're running lots of console-only guests on one host, you may consider disabling this to save some context switches. This is turned off by default if you use spice (-vga=qxl)."
7aacca6f 8811 },
44660702
DM
8812 "tdf" : {
8813 "default" : 0,
8814 "description" : "Enable/disable time drift fix.",
7aacca6f 8815 "optional" : 1,
013dc89f
DM
8816 "type" : "boolean",
8817 "typetext" : "<boolean>"
7aacca6f 8818 },
44660702
DM
8819 "template" : {
8820 "default" : 0,
8821 "description" : "Enable/disable Template.",
7aacca6f 8822 "optional" : 1,
013dc89f
DM
8823 "type" : "boolean",
8824 "typetext" : "<boolean>"
7aacca6f 8825 },
44660702 8826 "unused[n]" : {
c2993fe5 8827 "description" : "Reference to unused volumes. This is used internally, and should not be modified manually.",
44660702 8828 "format" : "pve-volume-id",
7aacca6f 8829 "optional" : 1,
013dc89f
DM
8830 "type" : "string",
8831 "typetext" : "<string>"
7aacca6f 8832 },
44660702 8833 "usb[n]" : {
c2993fe5 8834 "description" : "Configure an USB device (n is 0 to 4).",
56122987 8835 "format" : {
44660702
DM
8836 "host" : {
8837 "default_key" : 1,
c2993fe5 8838 "description" : "The Host USB device or port or the value 'spice'. HOSTUSBDEVICE syntax is:\n\n 'bus-port(.port)*' (decimal numbers) or\n 'vendor_id:product_id' (hexadeciaml numbers) or\n 'spice'\n\nYou can use the 'lsusb -t' command to list existing usb devices.\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nThe value 'spice' can be used to add a usb redirection devices for spice.\n",
44660702
DM
8839 "format" : "pve-qm-usb-device",
8840 "format_description" : "HOSTUSBDEVICE|spice",
8841 "type" : "string"
7aacca6f 8842 },
44660702 8843 "usb3" : {
c2993fe5
DM
8844 "default" : 0,
8845 "description" : "Specifies whether if given host option is a USB3 device or port (this does currently not work reliably with spice redirection and is then ignored).",
7aacca6f 8846 "optional" : 1,
44660702 8847 "type" : "boolean"
7aacca6f 8848 }
44660702 8849 },
7aacca6f 8850 "optional" : 1,
4bd7df8b
DM
8851 "type" : "string",
8852 "typetext" : "[host=]<HOSTUSBDEVICE|spice> [,usb3=<1|0>]"
7aacca6f 8853 },
44660702 8854 "vcpus" : {
7aacca6f 8855 "default" : 0,
44660702
DM
8856 "description" : "Number of hotplugged vcpus.",
8857 "minimum" : 1,
7aacca6f 8858 "optional" : 1,
4bd7df8b 8859 "type" : "integer",
013dc89f 8860 "typetext" : "<integer> (1 - N)"
7aacca6f 8861 },
44660702 8862 "vga" : {
c2993fe5 8863 "description" : "Select the VGA type.",
44660702
DM
8864 "enum" : [
8865 "std",
8866 "cirrus",
8867 "vmware",
8868 "qxl",
8869 "serial0",
8870 "serial1",
8871 "serial2",
8872 "serial3",
8873 "qxl2",
8874 "qxl3",
8875 "qxl4"
8876 ],
7aacca6f 8877 "optional" : 1,
c2993fe5
DM
8878 "type" : "string",
8879 "verbose_description" : "Select the VGA type. If you want to use high resolution modes (>= 1280x1024x16) then you should use the options 'std' or 'vmware'. Default is 'std' for win8/win7/w2k8, and 'cirrus' for other OS types. The 'qxl' option enables the SPICE display sever. For win* OS you can select how many independent displays you want, Linux guests can add displays them self. You can also run without any graphic card, using a serial device as terminal."
7aacca6f 8880 },
44660702
DM
8881 "virtio[n]" : {
8882 "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).",
7aacca6f 8883 "format" : {
7aacca6f 8884 "aio" : {
7aacca6f 8885 "description" : "AIO type to use.",
56122987 8886 "enum" : [
7aacca6f
DM
8887 "native",
8888 "threads"
7aacca6f 8889 ],
44660702
DM
8890 "optional" : 1,
8891 "type" : "string"
56122987 8892 },
44660702
DM
8893 "backup" : {
8894 "description" : "Whether the drive should be included when making backups.",
56122987 8895 "optional" : 1,
44660702 8896 "type" : "boolean"
7aacca6f 8897 },
44660702 8898 "bps" : {
de0983cb 8899 "description" : "Maximum r/w speed in bytes per second.",
44660702 8900 "format_description" : "bps",
7aacca6f 8901 "optional" : 1,
44660702 8902 "type" : "integer"
56122987 8903 },
de0983cb
DM
8904 "bps_max_length" : {
8905 "description" : "Maximum length of I/O bursts in seconds.",
8906 "format_description" : "seconds",
8907 "minimum" : 1,
8908 "optional" : 1,
8909 "type" : "integer"
8910 },
56122987 8911 "bps_rd" : {
de0983cb 8912 "description" : "Maximum read speed in bytes per second.",
44660702 8913 "format_description" : "bps",
56122987 8914 "optional" : 1,
7aacca6f 8915 "type" : "integer"
56122987 8916 },
de0983cb
DM
8917 "bps_rd_length" : {
8918 "description" : "Maximum length of read I/O bursts in seconds.",
8919 "format_description" : "seconds",
8920 "minimum" : 1,
8921 "optional" : 1,
8922 "type" : "integer"
8923 },
44660702 8924 "bps_wr" : {
de0983cb 8925 "description" : "Maximum write speed in bytes per second.",
44660702 8926 "format_description" : "bps",
56122987 8927 "optional" : 1,
7aacca6f 8928 "type" : "integer"
56122987 8929 },
de0983cb
DM
8930 "bps_wr_length" : {
8931 "description" : "Maximum length of write I/O bursts in seconds.",
8932 "format_description" : "seconds",
8933 "minimum" : 1,
8934 "optional" : 1,
8935 "type" : "integer"
8936 },
7aacca6f 8937 "cache" : {
44660702 8938 "description" : "The drive's cache mode",
7aacca6f
DM
8939 "enum" : [
8940 "none",
8941 "writethrough",
8942 "writeback",
8943 "unsafe",
8944 "directsync"
8945 ],
56122987 8946 "optional" : 1,
44660702 8947 "type" : "string"
7aacca6f 8948 },
44660702
DM
8949 "cyls" : {
8950 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
8951 "optional" : 1,
8952 "type" : "integer"
8953 },
8954 "detect_zeroes" : {
8955 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
8956 "optional" : 1,
8957 "type" : "boolean"
8958 },
8959 "discard" : {
8960 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
56122987 8961 "enum" : [
44660702
DM
8962 "ignore",
8963 "on"
56122987
DM
8964 ],
8965 "optional" : 1,
44660702 8966 "type" : "string"
56122987 8967 },
44660702
DM
8968 "file" : {
8969 "default_key" : 1,
8970 "description" : "The drive's backing volume.",
8971 "format" : "pve-volume-id-or-qm-path",
8972 "format_description" : "volume",
8973 "type" : "string"
8974 },
8975 "format" : {
8976 "description" : "The drive's backing file's data format.",
8977 "enum" : [
8978 "raw",
8979 "cow",
8980 "qcow",
8981 "qed",
8982 "qcow2",
8983 "vmdk",
8984 "cloop"
8985 ],
56122987 8986 "optional" : 1,
44660702 8987 "type" : "string"
56122987 8988 },
44660702
DM
8989 "heads" : {
8990 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
8991 "optional" : 1,
8992 "type" : "integer"
8993 },
8994 "iops" : {
de0983cb 8995 "description" : "Maximum r/w I/O in operations per second.",
44660702 8996 "format_description" : "iops",
56122987 8997 "optional" : 1,
44660702
DM
8998 "type" : "integer"
8999 },
9000 "iops_max" : {
de0983cb 9001 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702
DM
9002 "format_description" : "iops",
9003 "optional" : 1,
9004 "type" : "integer"
56122987 9005 },
de0983cb
DM
9006 "iops_max_length" : {
9007 "description" : "Maximum length of I/O bursts in seconds.",
9008 "format_description" : "seconds",
9009 "minimum" : 1,
9010 "optional" : 1,
9011 "type" : "integer"
9012 },
7aacca6f 9013 "iops_rd" : {
de0983cb 9014 "description" : "Maximum read I/O in operations per second.",
7aacca6f 9015 "format_description" : "iops",
7aacca6f 9016 "optional" : 1,
44660702 9017 "type" : "integer"
56122987 9018 },
de0983cb
DM
9019 "iops_rd_length" : {
9020 "description" : "Maximum length of read I/O bursts in seconds.",
9021 "format_description" : "seconds",
9022 "minimum" : 1,
9023 "optional" : 1,
9024 "type" : "integer"
9025 },
44660702 9026 "iops_rd_max" : {
de0983cb 9027 "description" : "Maximum unthrottled read I/O pool in operations per second.",
44660702
DM
9028 "format_description" : "iops",
9029 "optional" : 1,
9030 "type" : "integer"
9031 },
9032 "iops_wr" : {
de0983cb 9033 "description" : "Maximum write I/O in operations per second.",
44660702
DM
9034 "format_description" : "iops",
9035 "optional" : 1,
9036 "type" : "integer"
9037 },
de0983cb
DM
9038 "iops_wr_length" : {
9039 "description" : "Maximum length of write I/O bursts in seconds.",
9040 "format_description" : "seconds",
9041 "minimum" : 1,
9042 "optional" : 1,
9043 "type" : "integer"
9044 },
44660702 9045 "iops_wr_max" : {
de0983cb 9046 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702
DM
9047 "format_description" : "iops",
9048 "optional" : 1,
9049 "type" : "integer"
9050 },
9051 "iothread" : {
9052 "description" : "Whether to use iothreads for this drive",
44660702
DM
9053 "optional" : 1,
9054 "type" : "boolean"
9055 },
9056 "mbps" : {
de0983cb 9057 "description" : "Maximum r/w speed in megabytes per second.",
44660702 9058 "format_description" : "mbps",
7aacca6f 9059 "optional" : 1,
44660702 9060 "type" : "number"
7aacca6f
DM
9061 },
9062 "mbps_max" : {
de0983cb 9063 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702 9064 "format_description" : "mbps",
56122987 9065 "optional" : 1,
44660702 9066 "type" : "number"
56122987 9067 },
44660702 9068 "mbps_rd" : {
de0983cb 9069 "description" : "Maximum read speed in megabytes per second.",
44660702 9070 "format_description" : "mbps",
56122987 9071 "optional" : 1,
44660702 9072 "type" : "number"
56122987 9073 },
44660702 9074 "mbps_rd_max" : {
de0983cb 9075 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702
DM
9076 "format_description" : "mbps",
9077 "optional" : 1,
9078 "type" : "number"
9079 },
9080 "mbps_wr" : {
de0983cb 9081 "description" : "Maximum write speed in megabytes per second.",
44660702
DM
9082 "format_description" : "mbps",
9083 "optional" : 1,
9084 "type" : "number"
9085 },
9086 "mbps_wr_max" : {
de0983cb 9087 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702
DM
9088 "format_description" : "mbps",
9089 "optional" : 1,
9090 "type" : "number"
9091 },
9092 "media" : {
9093 "default" : "disk",
9094 "description" : "The drive's media type.",
56122987 9095 "enum" : [
44660702
DM
9096 "cdrom",
9097 "disk"
56122987
DM
9098 ],
9099 "optional" : 1,
44660702 9100 "type" : "string"
56122987 9101 },
44660702
DM
9102 "rerror" : {
9103 "description" : "Read error action.",
9104 "enum" : [
9105 "ignore",
9106 "report",
9107 "stop"
9108 ],
56122987 9109 "optional" : 1,
44660702 9110 "type" : "string"
56122987 9111 },
44660702
DM
9112 "secs" : {
9113 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 9114 "optional" : 1,
44660702 9115 "type" : "integer"
56122987 9116 },
7aacca6f
DM
9117 "serial" : {
9118 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
7aacca6f 9119 "format" : "urlencoded",
44660702 9120 "format_description" : "serial",
7aacca6f 9121 "maxLength" : 60,
44660702
DM
9122 "optional" : 1,
9123 "type" : "string"
56122987 9124 },
44660702
DM
9125 "size" : {
9126 "description" : "Disk size. This is purely informational and has no effect.",
9127 "format" : "disk-size",
f004f5b9 9128 "format_description" : "DiskSize",
44660702
DM
9129 "optional" : 1,
9130 "type" : "string"
56122987 9131 },
44660702
DM
9132 "snapshot" : {
9133 "description" : "Whether the drive should be included when making snapshots.",
56122987 9134 "optional" : 1,
44660702 9135 "type" : "boolean"
56122987 9136 },
44660702
DM
9137 "trans" : {
9138 "description" : "Force disk geometry bios translation mode.",
9139 "enum" : [
9140 "none",
9141 "lba",
9142 "auto"
9143 ],
7aacca6f 9144 "optional" : 1,
44660702 9145 "type" : "string"
7aacca6f 9146 },
44660702
DM
9147 "volume" : {
9148 "alias" : "file"
9149 },
9150 "werror" : {
9151 "description" : "Write error action.",
9152 "enum" : [
9153 "enospc",
9154 "ignore",
9155 "report",
9156 "stop"
9157 ],
7aacca6f 9158 "optional" : 1,
44660702 9159 "type" : "string"
56122987
DM
9160 }
9161 },
7aacca6f 9162 "optional" : 1,
4bd7df8b 9163 "type" : "string",
013dc89f 9164 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
7aacca6f 9165 },
44660702
DM
9166 "vmid" : {
9167 "description" : "The (unique) ID of the VM.",
9168 "format" : "pve-vmid",
9169 "minimum" : 1,
4bd7df8b 9170 "type" : "integer",
013dc89f 9171 "typetext" : "<integer> (1 - N)"
56122987 9172 },
44660702 9173 "watchdog" : {
c2993fe5 9174 "description" : "Create a virtual hardware watchdog device.",
44660702 9175 "format" : "pve-qm-watchdog",
56122987 9176 "optional" : 1,
c2993fe5 9177 "type" : "string",
013dc89f 9178 "typetext" : "[[model=]<i6300esb|ib700>] [,action=<enum>]",
c2993fe5 9179 "verbose_description" : "Create a virtual hardware watchdog device. Once enabled (by a guest action), the watchdog must be periodically polled by an agent inside the guest or else the watchdog will reset the guest (or execute the respective action specified)"
56122987 9180 }
7aacca6f 9181 }
56122987 9182 },
56122987
DM
9183 "permissions" : {
9184 "check" : [
9185 "perm",
9186 "/vms/{vmid}",
9187 [
9188 "VM.Config.Disk",
9189 "VM.Config.CDROM",
9190 "VM.Config.CPU",
9191 "VM.Config.Memory",
9192 "VM.Config.Network",
9193 "VM.Config.HWType",
9194 "VM.Config.Options"
9195 ],
9196 "any",
9197 1
9198 ]
9199 },
44660702 9200 "protected" : 1,
7aacca6f 9201 "proxyto" : "node",
56122987 9202 "returns" : {
7aacca6f
DM
9203 "type" : "null"
9204 }
9205 }
9206 },
44660702
DM
9207 "leaf" : 1,
9208 "path" : "/nodes/{node}/qemu/{vmid}/config",
7aacca6f
DM
9209 "text" : "config"
9210 },
9211 {
9212 "info" : {
56122987 9213 "GET" : {
44660702 9214 "description" : "Get virtual machine configuration, including pending changes.",
56122987 9215 "method" : "GET",
44660702 9216 "name" : "vm_pending",
7aacca6f 9217 "parameters" : {
44660702 9218 "additionalProperties" : 0,
7aacca6f
DM
9219 "properties" : {
9220 "node" : {
7aacca6f 9221 "description" : "The cluster node name.",
44660702 9222 "format" : "pve-node",
013dc89f
DM
9223 "type" : "string",
9224 "typetext" : "<string>"
7aacca6f
DM
9225 },
9226 "vmid" : {
44660702 9227 "description" : "The (unique) ID of the VM.",
7aacca6f 9228 "format" : "pve-vmid",
44660702 9229 "minimum" : 1,
4bd7df8b 9230 "type" : "integer",
013dc89f 9231 "typetext" : "<integer> (1 - N)"
7aacca6f 9232 }
44660702 9233 }
7aacca6f 9234 },
56122987
DM
9235 "permissions" : {
9236 "check" : [
9237 "perm",
9238 "/vms/{vmid}",
9239 [
9240 "VM.Audit"
9241 ]
9242 ]
9243 },
7aacca6f 9244 "proxyto" : "node",
44660702
DM
9245 "returns" : {
9246 "items" : {
9247 "properties" : {
9248 "delete" : {
9249 "description" : "Indicates a pending delete request if present and not 0. The value 2 indicates a force-delete request.",
9250 "maximum" : 2,
9251 "minimum" : 0,
9252 "optional" : 1,
9253 "type" : "integer"
9254 },
9255 "key" : {
9256 "description" : "Configuration option name.",
9257 "type" : "string"
9258 },
9259 "pending" : {
9260 "description" : "Pending value.",
9261 "optional" : 1,
9262 "type" : "string"
9263 },
9264 "value" : {
9265 "description" : "Current value.",
9266 "optional" : 1,
9267 "type" : "string"
9268 }
9269 },
9270 "type" : "object"
9271 },
9272 "type" : "array"
9273 }
56122987
DM
9274 }
9275 },
7aacca6f 9276 "leaf" : 1,
44660702
DM
9277 "path" : "/nodes/{node}/qemu/{vmid}/pending",
9278 "text" : "pending"
56122987
DM
9279 },
9280 {
56122987
DM
9281 "info" : {
9282 "PUT" : {
7aacca6f 9283 "description" : "Unlink/delete disk images.",
7aacca6f 9284 "method" : "PUT",
7aacca6f 9285 "name" : "unlink",
56122987 9286 "parameters" : {
44660702 9287 "additionalProperties" : 0,
56122987 9288 "properties" : {
7aacca6f 9289 "force" : {
44660702 9290 "description" : "Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal.",
7aacca6f 9291 "optional" : 1,
013dc89f
DM
9292 "type" : "boolean",
9293 "typetext" : "<boolean>"
7aacca6f 9294 },
56122987
DM
9295 "idlist" : {
9296 "description" : "A list of disk IDs you want to delete.",
44660702 9297 "format" : "pve-configid-list",
013dc89f
DM
9298 "type" : "string",
9299 "typetext" : "<string>"
44660702
DM
9300 },
9301 "node" : {
9302 "description" : "The cluster node name.",
9303 "format" : "pve-node",
013dc89f
DM
9304 "type" : "string",
9305 "typetext" : "<string>"
56122987
DM
9306 },
9307 "vmid" : {
7aacca6f 9308 "description" : "The (unique) ID of the VM.",
44660702 9309 "format" : "pve-vmid",
7aacca6f 9310 "minimum" : 1,
4bd7df8b 9311 "type" : "integer",
013dc89f 9312 "typetext" : "<integer> (1 - N)"
56122987 9313 }
44660702
DM
9314 }
9315 },
9316 "permissions" : {
9317 "check" : [
9318 "perm",
9319 "/vms/{vmid}",
9320 [
9321 "VM.Config.Disk"
9322 ]
9323 ]
9324 },
9325 "protected" : 1,
9326 "proxyto" : "node",
9327 "returns" : {
9328 "type" : "null"
7aacca6f 9329 }
56122987 9330 }
7aacca6f 9331 },
44660702 9332 "leaf" : 1,
7aacca6f 9333 "path" : "/nodes/{node}/qemu/{vmid}/unlink",
44660702 9334 "text" : "unlink"
56122987
DM
9335 },
9336 {
56122987
DM
9337 "info" : {
9338 "POST" : {
7aacca6f 9339 "description" : "Creates a TCP VNC proxy connections.",
44660702
DM
9340 "method" : "POST",
9341 "name" : "vncproxy",
56122987 9342 "parameters" : {
44660702 9343 "additionalProperties" : 0,
56122987 9344 "properties" : {
44660702
DM
9345 "node" : {
9346 "description" : "The cluster node name.",
9347 "format" : "pve-node",
013dc89f
DM
9348 "type" : "string",
9349 "typetext" : "<string>"
44660702 9350 },
56122987 9351 "vmid" : {
7aacca6f 9352 "description" : "The (unique) ID of the VM.",
44660702 9353 "format" : "pve-vmid",
56122987 9354 "minimum" : 1,
4bd7df8b 9355 "type" : "integer",
013dc89f 9356 "typetext" : "<integer> (1 - N)"
7aacca6f
DM
9357 },
9358 "websocket" : {
9359 "description" : "starts websockify instead of vncproxy",
44660702 9360 "optional" : 1,
013dc89f
DM
9361 "type" : "boolean",
9362 "typetext" : "<boolean>"
56122987 9363 }
44660702 9364 }
56122987 9365 },
44660702
DM
9366 "permissions" : {
9367 "check" : [
9368 "perm",
9369 "/vms/{vmid}",
9370 [
9371 "VM.Console"
9372 ]
9373 ]
9374 },
9375 "protected" : 1,
56122987 9376 "returns" : {
7aacca6f 9377 "additionalProperties" : 0,
56122987 9378 "properties" : {
7aacca6f 9379 "cert" : {
56122987
DM
9380 "type" : "string"
9381 },
56122987
DM
9382 "port" : {
9383 "type" : "integer"
9384 },
7aacca6f
DM
9385 "ticket" : {
9386 "type" : "string"
9387 },
44660702
DM
9388 "upid" : {
9389 "type" : "string"
9390 },
7aacca6f 9391 "user" : {
56122987
DM
9392 "type" : "string"
9393 }
7aacca6f 9394 }
56122987
DM
9395 }
9396 }
9397 },
44660702
DM
9398 "leaf" : 1,
9399 "path" : "/nodes/{node}/qemu/{vmid}/vncproxy",
7aacca6f 9400 "text" : "vncproxy"
56122987
DM
9401 },
9402 {
56122987
DM
9403 "info" : {
9404 "GET" : {
44660702
DM
9405 "description" : "Opens a weksocket for VNC traffic.",
9406 "method" : "GET",
9407 "name" : "vncwebsocket",
56122987 9408 "parameters" : {
44660702 9409 "additionalProperties" : 0,
56122987 9410 "properties" : {
7aacca6f 9411 "node" : {
7aacca6f 9412 "description" : "The cluster node name.",
44660702 9413 "format" : "pve-node",
013dc89f
DM
9414 "type" : "string",
9415 "typetext" : "<string>"
7aacca6f 9416 },
44660702
DM
9417 "port" : {
9418 "description" : "Port number returned by previous vncproxy call.",
9419 "maximum" : 5999,
9420 "minimum" : 5900,
4bd7df8b 9421 "type" : "integer",
013dc89f 9422 "typetext" : "<integer> (5900 - 5999)"
56122987 9423 },
7aacca6f 9424 "vmid" : {
44660702 9425 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
9426 "format" : "pve-vmid",
9427 "minimum" : 1,
4bd7df8b 9428 "type" : "integer",
013dc89f 9429 "typetext" : "<integer> (1 - N)"
44660702
DM
9430 },
9431 "vncticket" : {
9432 "description" : "Ticket from previous call to vncproxy.",
9433 "maxLength" : 512,
013dc89f
DM
9434 "type" : "string",
9435 "typetext" : "<string>"
56122987 9436 }
44660702
DM
9437 }
9438 },
9439 "permissions" : {
9440 "check" : [
9441 "perm",
9442 "/vms/{vmid}",
9443 [
9444 "VM.Console"
9445 ]
9446 ],
9447 "description" : "You also need to pass a valid ticket (vncticket)."
56122987 9448 },
7aacca6f
DM
9449 "returns" : {
9450 "properties" : {
9451 "port" : {
9452 "type" : "string"
9453 }
9454 },
9455 "type" : "object"
9456 }
56122987
DM
9457 }
9458 },
7aacca6f 9459 "leaf" : 1,
44660702
DM
9460 "path" : "/nodes/{node}/qemu/{vmid}/vncwebsocket",
9461 "text" : "vncwebsocket"
56122987
DM
9462 },
9463 {
9464 "info" : {
9465 "POST" : {
44660702
DM
9466 "description" : "Returns a SPICE configuration to connect to the VM.",
9467 "method" : "POST",
7aacca6f
DM
9468 "name" : "spiceproxy",
9469 "parameters" : {
44660702 9470 "additionalProperties" : 0,
56122987 9471 "properties" : {
44660702
DM
9472 "node" : {
9473 "description" : "The cluster node name.",
9474 "format" : "pve-node",
013dc89f
DM
9475 "type" : "string",
9476 "typetext" : "<string>"
44660702 9477 },
7aacca6f 9478 "proxy" : {
44660702 9479 "description" : "SPICE proxy server. This can be used by the client to specify the proxy server. All nodes in a cluster runs 'spiceproxy', so it is up to the client to choose one. By default, we return the node where the VM is currently running. As resonable setting is to use same node you use to connect to the API (This is window.location.hostname for the JS GUI).",
7aacca6f 9480 "format" : "address",
7aacca6f 9481 "optional" : 1,
013dc89f
DM
9482 "type" : "string",
9483 "typetext" : "<string>"
56122987 9484 },
7aacca6f 9485 "vmid" : {
44660702 9486 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
9487 "format" : "pve-vmid",
9488 "minimum" : 1,
4bd7df8b 9489 "type" : "integer",
013dc89f 9490 "typetext" : "<integer> (1 - N)"
56122987 9491 }
44660702 9492 }
56122987 9493 },
56122987
DM
9494 "permissions" : {
9495 "check" : [
9496 "perm",
9497 "/vms/{vmid}",
9498 [
9499 "VM.Console"
9500 ]
9501 ]
9502 },
44660702
DM
9503 "protected" : 1,
9504 "proxyto" : "node",
7aacca6f 9505 "returns" : {
44660702
DM
9506 "additionalProperties" : 1,
9507 "description" : "Returned values can be directly passed to the 'remote-viewer' application.",
56122987 9508 "properties" : {
44660702 9509 "host" : {
7aacca6f
DM
9510 "type" : "string"
9511 },
7aacca6f
DM
9512 "password" : {
9513 "type" : "string"
9514 },
44660702 9515 "proxy" : {
7aacca6f
DM
9516 "type" : "string"
9517 },
44660702
DM
9518 "tls-port" : {
9519 "type" : "integer"
9520 },
9521 "type" : {
7aacca6f
DM
9522 "type" : "string"
9523 }
44660702 9524 }
7aacca6f
DM
9525 }
9526 }
9527 },
44660702
DM
9528 "leaf" : 1,
9529 "path" : "/nodes/{node}/qemu/{vmid}/spiceproxy",
7aacca6f
DM
9530 "text" : "spiceproxy"
9531 },
9532 {
56122987
DM
9533 "children" : [
9534 {
56122987
DM
9535 "info" : {
9536 "GET" : {
44660702
DM
9537 "description" : "Get virtual machine status.",
9538 "method" : "GET",
9539 "name" : "vm_status",
56122987 9540 "parameters" : {
44660702 9541 "additionalProperties" : 0,
56122987 9542 "properties" : {
44660702
DM
9543 "node" : {
9544 "description" : "The cluster node name.",
9545 "format" : "pve-node",
013dc89f
DM
9546 "type" : "string",
9547 "typetext" : "<string>"
44660702 9548 },
56122987 9549 "vmid" : {
44660702 9550 "description" : "The (unique) ID of the VM.",
7aacca6f 9551 "format" : "pve-vmid",
56122987 9552 "minimum" : 1,
4bd7df8b 9553 "type" : "integer",
013dc89f 9554 "typetext" : "<integer> (1 - N)"
56122987 9555 }
44660702 9556 }
56122987
DM
9557 },
9558 "permissions" : {
9559 "check" : [
9560 "perm",
9561 "/vms/{vmid}",
9562 [
9563 "VM.Audit"
9564 ]
9565 ]
9566 },
44660702 9567 "protected" : 1,
7aacca6f 9568 "proxyto" : "node",
56122987
DM
9569 "returns" : {
9570 "type" : "object"
7aacca6f 9571 }
56122987 9572 }
7aacca6f 9573 },
7aacca6f 9574 "leaf" : 1,
44660702
DM
9575 "path" : "/nodes/{node}/qemu/{vmid}/status/current",
9576 "text" : "current"
56122987
DM
9577 },
9578 {
56122987
DM
9579 "info" : {
9580 "POST" : {
44660702 9581 "description" : "Start virtual machine.",
56122987 9582 "method" : "POST",
44660702 9583 "name" : "vm_start",
56122987 9584 "parameters" : {
44660702 9585 "additionalProperties" : 0,
56122987 9586 "properties" : {
44660702
DM
9587 "machine" : {
9588 "description" : "Specific the Qemu machine type.",
9589 "maxLength" : 40,
9590 "optional" : 1,
9591 "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)",
9592 "type" : "string"
9593 },
9594 "migratedfrom" : {
9595 "description" : "The cluster node name.",
9596 "format" : "pve-node",
56122987 9597 "optional" : 1,
013dc89f
DM
9598 "type" : "string",
9599 "typetext" : "<string>"
56122987 9600 },
de0983cb
DM
9601 "migration_network" : {
9602 "description" : "CIDR of the (sub) network that is used for migration.",
9603 "format" : "CIDR",
9604 "optional" : 1,
013dc89f
DM
9605 "type" : "string",
9606 "typetext" : "<string>"
de0983cb
DM
9607 },
9608 "migration_type" : {
9609 "description" : "Migration traffic is encrypted using an SSH tunnel by default. On secure, completely private networks this can be disabled to increase performance.",
9610 "enum" : [
9611 "secure",
9612 "insecure"
9613 ],
9614 "optional" : 1,
9615 "type" : "string"
9616 },
7aacca6f 9617 "node" : {
7aacca6f 9618 "description" : "The cluster node name.",
44660702 9619 "format" : "pve-node",
013dc89f
DM
9620 "type" : "string",
9621 "typetext" : "<string>"
7aacca6f 9622 },
44660702
DM
9623 "skiplock" : {
9624 "description" : "Ignore locks - only root is allowed to use this option.",
7aacca6f 9625 "optional" : 1,
013dc89f
DM
9626 "type" : "boolean",
9627 "typetext" : "<boolean>"
56122987 9628 },
44660702
DM
9629 "stateuri" : {
9630 "description" : "Some command save/restore state from this location.",
9631 "maxLength" : 128,
56122987 9632 "optional" : 1,
013dc89f
DM
9633 "type" : "string",
9634 "typetext" : "<string>"
56122987 9635 },
52e44c50
FG
9636 "targetstorage" : {
9637 "description" : "Target storage for the migration. (Can be '1' to use the same storage id as on the source node.)",
9638 "optional" : 1,
9639 "type" : "string",
9640 "typetext" : "<string>"
9641 },
56122987 9642 "vmid" : {
7aacca6f 9643 "description" : "The (unique) ID of the VM.",
44660702
DM
9644 "format" : "pve-vmid",
9645 "minimum" : 1,
4bd7df8b 9646 "type" : "integer",
013dc89f 9647 "typetext" : "<integer> (1 - N)"
56122987 9648 }
44660702 9649 }
7aacca6f 9650 },
56122987
DM
9651 "permissions" : {
9652 "check" : [
9653 "perm",
9654 "/vms/{vmid}",
9655 [
9656 "VM.PowerMgmt"
9657 ]
9658 ]
44660702
DM
9659 },
9660 "protected" : 1,
9661 "proxyto" : "node",
9662 "returns" : {
9663 "type" : "string"
56122987
DM
9664 }
9665 }
44660702
DM
9666 },
9667 "leaf" : 1,
9668 "path" : "/nodes/{node}/qemu/{vmid}/status/start",
9669 "text" : "start"
56122987
DM
9670 },
9671 {
56122987
DM
9672 "info" : {
9673 "POST" : {
7aacca6f 9674 "description" : "Stop virtual machine. The qemu process will exit immediately. Thisis akin to pulling the power plug of a running computer and may damage the VM data",
44660702
DM
9675 "method" : "POST",
9676 "name" : "vm_stop",
56122987 9677 "parameters" : {
44660702 9678 "additionalProperties" : 0,
56122987 9679 "properties" : {
44660702
DM
9680 "keepActive" : {
9681 "default" : 0,
de0983cb 9682 "description" : "Do not deactivate storage volumes.",
56122987 9683 "optional" : 1,
013dc89f
DM
9684 "type" : "boolean",
9685 "typetext" : "<boolean>"
56122987
DM
9686 },
9687 "migratedfrom" : {
56122987 9688 "description" : "The cluster node name.",
44660702 9689 "format" : "pve-node",
7aacca6f 9690 "optional" : 1,
013dc89f
DM
9691 "type" : "string",
9692 "typetext" : "<string>"
7aacca6f 9693 },
44660702
DM
9694 "node" : {
9695 "description" : "The cluster node name.",
9696 "format" : "pve-node",
013dc89f
DM
9697 "type" : "string",
9698 "typetext" : "<string>"
56122987
DM
9699 },
9700 "skiplock" : {
9701 "description" : "Ignore locks - only root is allowed to use this option.",
9702 "optional" : 1,
013dc89f
DM
9703 "type" : "boolean",
9704 "typetext" : "<boolean>"
56122987 9705 },
44660702
DM
9706 "timeout" : {
9707 "description" : "Wait maximal timeout seconds.",
9708 "minimum" : 0,
56122987 9709 "optional" : 1,
4bd7df8b 9710 "type" : "integer",
013dc89f 9711 "typetext" : "<integer> (0 - N)"
7aacca6f 9712 },
44660702
DM
9713 "vmid" : {
9714 "description" : "The (unique) ID of the VM.",
9715 "format" : "pve-vmid",
9716 "minimum" : 1,
4bd7df8b 9717 "type" : "integer",
013dc89f 9718 "typetext" : "<integer> (1 - N)"
56122987 9719 }
44660702 9720 }
56122987 9721 },
56122987
DM
9722 "permissions" : {
9723 "check" : [
9724 "perm",
9725 "/vms/{vmid}",
9726 [
9727 "VM.PowerMgmt"
9728 ]
9729 ]
9730 },
44660702
DM
9731 "protected" : 1,
9732 "proxyto" : "node",
7aacca6f
DM
9733 "returns" : {
9734 "type" : "string"
44660702
DM
9735 }
9736 }
9737 },
9738 "leaf" : 1,
9739 "path" : "/nodes/{node}/qemu/{vmid}/status/stop",
9740 "text" : "stop"
9741 },
9742 {
9743 "info" : {
9744 "POST" : {
9745 "description" : "Reset virtual machine.",
9746 "method" : "POST",
9747 "name" : "vm_reset",
56122987 9748 "parameters" : {
7aacca6f 9749 "additionalProperties" : 0,
56122987 9750 "properties" : {
56122987
DM
9751 "node" : {
9752 "description" : "The cluster node name.",
44660702 9753 "format" : "pve-node",
013dc89f
DM
9754 "type" : "string",
9755 "typetext" : "<string>"
56122987
DM
9756 },
9757 "skiplock" : {
44660702 9758 "description" : "Ignore locks - only root is allowed to use this option.",
7aacca6f 9759 "optional" : 1,
013dc89f
DM
9760 "type" : "boolean",
9761 "typetext" : "<boolean>"
7aacca6f
DM
9762 },
9763 "vmid" : {
44660702 9764 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
9765 "format" : "pve-vmid",
9766 "minimum" : 1,
4bd7df8b 9767 "type" : "integer",
013dc89f 9768 "typetext" : "<integer> (1 - N)"
56122987 9769 }
7aacca6f 9770 }
56122987 9771 },
7aacca6f
DM
9772 "permissions" : {
9773 "check" : [
9774 "perm",
9775 "/vms/{vmid}",
9776 [
9777 "VM.PowerMgmt"
9778 ]
9779 ]
9780 },
44660702 9781 "protected" : 1,
7aacca6f 9782 "proxyto" : "node",
56122987
DM
9783 "returns" : {
9784 "type" : "string"
44660702
DM
9785 }
9786 }
9787 },
9788 "leaf" : 1,
9789 "path" : "/nodes/{node}/qemu/{vmid}/status/reset",
9790 "text" : "reset"
9791 },
9792 {
9793 "info" : {
9794 "POST" : {
9795 "description" : "Shutdown virtual machine. This is similar to pressing the power button on a physical machine.This will send an ACPI event for the guest OS, which should then proceed to a clean shutdown.",
9796 "method" : "POST",
56122987 9797 "name" : "vm_shutdown",
56122987 9798 "parameters" : {
7aacca6f 9799 "additionalProperties" : 0,
56122987 9800 "properties" : {
56122987 9801 "forceStop" : {
56122987 9802 "default" : 0,
44660702 9803 "description" : "Make sure the VM stops.",
7aacca6f 9804 "optional" : 1,
013dc89f
DM
9805 "type" : "boolean",
9806 "typetext" : "<boolean>"
56122987
DM
9807 },
9808 "keepActive" : {
7aacca6f 9809 "default" : 0,
de0983cb 9810 "description" : "Do not deactivate storage volumes.",
44660702 9811 "optional" : 1,
013dc89f
DM
9812 "type" : "boolean",
9813 "typetext" : "<boolean>"
44660702
DM
9814 },
9815 "node" : {
9816 "description" : "The cluster node name.",
9817 "format" : "pve-node",
013dc89f
DM
9818 "type" : "string",
9819 "typetext" : "<string>"
44660702
DM
9820 },
9821 "skiplock" : {
9822 "description" : "Ignore locks - only root is allowed to use this option.",
9823 "optional" : 1,
013dc89f
DM
9824 "type" : "boolean",
9825 "typetext" : "<boolean>"
56122987 9826 },
7aacca6f 9827 "timeout" : {
7aacca6f 9828 "description" : "Wait maximal timeout seconds.",
44660702 9829 "minimum" : 0,
7aacca6f 9830 "optional" : 1,
4bd7df8b 9831 "type" : "integer",
013dc89f 9832 "typetext" : "<integer> (0 - N)"
7aacca6f 9833 },
56122987 9834 "vmid" : {
7aacca6f 9835 "description" : "The (unique) ID of the VM.",
44660702
DM
9836 "format" : "pve-vmid",
9837 "minimum" : 1,
4bd7df8b 9838 "type" : "integer",
013dc89f 9839 "typetext" : "<integer> (1 - N)"
56122987 9840 }
7aacca6f 9841 }
56122987 9842 },
44660702
DM
9843 "permissions" : {
9844 "check" : [
9845 "perm",
9846 "/vms/{vmid}",
9847 [
9848 "VM.PowerMgmt"
9849 ]
9850 ]
9851 },
7aacca6f 9852 "protected" : 1,
44660702
DM
9853 "proxyto" : "node",
9854 "returns" : {
9855 "type" : "string"
9856 }
56122987
DM
9857 }
9858 },
44660702 9859 "leaf" : 1,
7aacca6f 9860 "path" : "/nodes/{node}/qemu/{vmid}/status/shutdown",
44660702 9861 "text" : "shutdown"
56122987
DM
9862 },
9863 {
56122987
DM
9864 "info" : {
9865 "POST" : {
44660702 9866 "description" : "Suspend virtual machine.",
56122987 9867 "method" : "POST",
44660702 9868 "name" : "vm_suspend",
7aacca6f 9869 "parameters" : {
44660702 9870 "additionalProperties" : 0,
7aacca6f
DM
9871 "properties" : {
9872 "node" : {
7aacca6f 9873 "description" : "The cluster node name.",
44660702 9874 "format" : "pve-node",
013dc89f
DM
9875 "type" : "string",
9876 "typetext" : "<string>"
7aacca6f
DM
9877 },
9878 "skiplock" : {
9879 "description" : "Ignore locks - only root is allowed to use this option.",
44660702 9880 "optional" : 1,
013dc89f
DM
9881 "type" : "boolean",
9882 "typetext" : "<boolean>"
44660702
DM
9883 },
9884 "vmid" : {
9885 "description" : "The (unique) ID of the VM.",
9886 "format" : "pve-vmid",
9887 "minimum" : 1,
4bd7df8b 9888 "type" : "integer",
013dc89f 9889 "typetext" : "<integer> (1 - N)"
44660702
DM
9890 }
9891 }
56122987
DM
9892 },
9893 "permissions" : {
9894 "check" : [
9895 "perm",
9896 "/vms/{vmid}",
9897 [
9898 "VM.PowerMgmt"
9899 ]
9900 ]
9901 },
44660702
DM
9902 "protected" : 1,
9903 "proxyto" : "node",
9904 "returns" : {
9905 "type" : "string"
9906 }
56122987
DM
9907 }
9908 },
44660702 9909 "leaf" : 1,
7aacca6f 9910 "path" : "/nodes/{node}/qemu/{vmid}/status/suspend",
44660702 9911 "text" : "suspend"
56122987
DM
9912 },
9913 {
56122987
DM
9914 "info" : {
9915 "POST" : {
44660702
DM
9916 "description" : "Resume virtual machine.",
9917 "method" : "POST",
7aacca6f 9918 "name" : "vm_resume",
56122987
DM
9919 "parameters" : {
9920 "additionalProperties" : 0,
9921 "properties" : {
44660702
DM
9922 "nocheck" : {
9923 "optional" : 1,
013dc89f
DM
9924 "type" : "boolean",
9925 "typetext" : "<boolean>"
44660702 9926 },
7aacca6f 9927 "node" : {
44660702 9928 "description" : "The cluster node name.",
7aacca6f 9929 "format" : "pve-node",
013dc89f
DM
9930 "type" : "string",
9931 "typetext" : "<string>"
56122987
DM
9932 },
9933 "skiplock" : {
56122987 9934 "description" : "Ignore locks - only root is allowed to use this option.",
44660702 9935 "optional" : 1,
013dc89f
DM
9936 "type" : "boolean",
9937 "typetext" : "<boolean>"
56122987 9938 },
7aacca6f 9939 "vmid" : {
7aacca6f
DM
9940 "description" : "The (unique) ID of the VM.",
9941 "format" : "pve-vmid",
44660702 9942 "minimum" : 1,
4bd7df8b 9943 "type" : "integer",
013dc89f 9944 "typetext" : "<integer> (1 - N)"
56122987
DM
9945 }
9946 }
9947 },
9948 "permissions" : {
9949 "check" : [
9950 "perm",
9951 "/vms/{vmid}",
9952 [
9953 "VM.PowerMgmt"
9954 ]
9955 ]
9956 },
44660702
DM
9957 "protected" : 1,
9958 "proxyto" : "node",
56122987
DM
9959 "returns" : {
9960 "type" : "string"
7aacca6f 9961 }
56122987
DM
9962 }
9963 },
44660702
DM
9964 "leaf" : 1,
9965 "path" : "/nodes/{node}/qemu/{vmid}/status/resume",
7aacca6f 9966 "text" : "resume"
56122987
DM
9967 }
9968 ],
9969 "info" : {
44660702
DM
9970 "GET" : {
9971 "description" : "Directory index",
9972 "method" : "GET",
9973 "name" : "vmcmdidx",
56122987 9974 "parameters" : {
44660702 9975 "additionalProperties" : 0,
56122987 9976 "properties" : {
44660702
DM
9977 "node" : {
9978 "description" : "The cluster node name.",
9979 "format" : "pve-node",
013dc89f
DM
9980 "type" : "string",
9981 "typetext" : "<string>"
7aacca6f 9982 },
56122987 9983 "vmid" : {
7aacca6f 9984 "description" : "The (unique) ID of the VM.",
44660702
DM
9985 "format" : "pve-vmid",
9986 "minimum" : 1,
4bd7df8b 9987 "type" : "integer",
013dc89f 9988 "typetext" : "<integer> (1 - N)"
56122987 9989 }
44660702 9990 }
56122987 9991 },
44660702
DM
9992 "permissions" : {
9993 "user" : "all"
9994 },
9995 "proxyto" : "node",
9996 "returns" : {
9997 "items" : {
9998 "properties" : {
9999 "subdir" : {
10000 "type" : "string"
10001 }
10002 },
10003 "type" : "object"
10004 },
10005 "links" : [
10006 {
10007 "href" : "{subdir}",
10008 "rel" : "child"
10009 }
10010 ],
10011 "type" : "array"
10012 }
56122987 10013 }
7aacca6f 10014 },
44660702
DM
10015 "leaf" : 0,
10016 "path" : "/nodes/{node}/qemu/{vmid}/status",
10017 "text" : "status"
56122987
DM
10018 },
10019 {
56122987 10020 "info" : {
44660702
DM
10021 "PUT" : {
10022 "description" : "Send key event to virtual machine.",
10023 "method" : "PUT",
10024 "name" : "vm_sendkey",
10025 "parameters" : {
10026 "additionalProperties" : 0,
56122987 10027 "properties" : {
44660702
DM
10028 "key" : {
10029 "description" : "The key (qemu monitor encoding).",
013dc89f
DM
10030 "type" : "string",
10031 "typetext" : "<string>"
44660702
DM
10032 },
10033 "node" : {
10034 "description" : "The cluster node name.",
10035 "format" : "pve-node",
013dc89f
DM
10036 "type" : "string",
10037 "typetext" : "<string>"
44660702
DM
10038 },
10039 "skiplock" : {
10040 "description" : "Ignore locks - only root is allowed to use this option.",
10041 "optional" : 1,
013dc89f
DM
10042 "type" : "boolean",
10043 "typetext" : "<boolean>"
7aacca6f 10044 },
44660702
DM
10045 "vmid" : {
10046 "description" : "The (unique) ID of the VM.",
10047 "format" : "pve-vmid",
10048 "minimum" : 1,
4bd7df8b 10049 "type" : "integer",
013dc89f 10050 "typetext" : "<integer> (1 - N)"
56122987 10051 }
7aacca6f 10052 }
56122987 10053 },
56122987
DM
10054 "permissions" : {
10055 "check" : [
10056 "perm",
10057 "/vms/{vmid}",
10058 [
44660702 10059 "VM.Console"
56122987
DM
10060 ]
10061 ]
10062 },
7aacca6f 10063 "protected" : 1,
44660702
DM
10064 "proxyto" : "node",
10065 "returns" : {
10066 "type" : "null"
10067 }
10068 }
10069 },
10070 "leaf" : 1,
10071 "path" : "/nodes/{node}/qemu/{vmid}/sendkey",
10072 "text" : "sendkey"
10073 },
10074 {
10075 "info" : {
10076 "GET" : {
10077 "description" : "Check if feature for virtual machine is available.",
10078 "method" : "GET",
7aacca6f 10079 "name" : "vm_feature",
56122987 10080 "parameters" : {
44660702 10081 "additionalProperties" : 0,
56122987 10082 "properties" : {
56122987 10083 "feature" : {
44660702 10084 "description" : "Feature to check.",
56122987
DM
10085 "enum" : [
10086 "snapshot",
10087 "clone",
10088 "copy"
10089 ],
44660702
DM
10090 "type" : "string"
10091 },
10092 "node" : {
10093 "description" : "The cluster node name.",
10094 "format" : "pve-node",
013dc89f
DM
10095 "type" : "string",
10096 "typetext" : "<string>"
56122987
DM
10097 },
10098 "snapname" : {
56122987 10099 "description" : "The name of the snapshot.",
44660702
DM
10100 "format" : "pve-configid",
10101 "maxLength" : 40,
7aacca6f 10102 "optional" : 1,
013dc89f
DM
10103 "type" : "string",
10104 "typetext" : "<string>"
7aacca6f 10105 },
44660702
DM
10106 "vmid" : {
10107 "description" : "The (unique) ID of the VM.",
10108 "format" : "pve-vmid",
10109 "minimum" : 1,
4bd7df8b 10110 "type" : "integer",
013dc89f 10111 "typetext" : "<integer> (1 - N)"
44660702
DM
10112 }
10113 }
10114 },
10115 "permissions" : {
10116 "check" : [
10117 "perm",
10118 "/vms/{vmid}",
10119 [
10120 "VM.Audit"
10121 ]
10122 ]
10123 },
10124 "protected" : 1,
10125 "proxyto" : "node",
10126 "returns" : {
10127 "properties" : {
10128 "hasFeature" : {
10129 "type" : "boolean"
10130 },
10131 "nodes" : {
10132 "items" : {
10133 "type" : "string"
10134 },
10135 "type" : "array"
56122987
DM
10136 }
10137 },
44660702 10138 "type" : "object"
56122987
DM
10139 }
10140 }
10141 },
7aacca6f 10142 "leaf" : 1,
44660702
DM
10143 "path" : "/nodes/{node}/qemu/{vmid}/feature",
10144 "text" : "feature"
56122987
DM
10145 },
10146 {
56122987
DM
10147 "info" : {
10148 "POST" : {
44660702 10149 "description" : "Create a copy of virtual machine/template.",
56122987 10150 "method" : "POST",
7aacca6f 10151 "name" : "clone_vm",
56122987
DM
10152 "parameters" : {
10153 "additionalProperties" : 0,
10154 "properties" : {
44660702
DM
10155 "description" : {
10156 "description" : "Description for the new VM.",
56122987 10157 "optional" : 1,
013dc89f
DM
10158 "type" : "string",
10159 "typetext" : "<string>"
56122987 10160 },
44660702
DM
10161 "format" : {
10162 "description" : "Target format for file storage.",
10163 "enum" : [
10164 "raw",
10165 "qcow2",
10166 "vmdk"
10167 ],
10168 "optional" : 1,
10169 "requires" : "full",
56122987
DM
10170 "type" : "string"
10171 },
44660702
DM
10172 "full" : {
10173 "default" : 0,
10174 "description" : "Create a full copy of all disk. This is always done when you clone a normal VM. For VM templates, we try to create a linked clone by default.",
7aacca6f 10175 "optional" : 1,
013dc89f
DM
10176 "type" : "boolean",
10177 "typetext" : "<boolean>"
44660702
DM
10178 },
10179 "name" : {
56122987 10180 "description" : "Set a name for the new VM.",
44660702
DM
10181 "format" : "dns-name",
10182 "optional" : 1,
013dc89f
DM
10183 "type" : "string",
10184 "typetext" : "<string>"
44660702
DM
10185 },
10186 "newid" : {
10187 "description" : "VMID for the clone.",
10188 "format" : "pve-vmid",
10189 "minimum" : 1,
4bd7df8b 10190 "type" : "integer",
013dc89f 10191 "typetext" : "<integer> (1 - N)"
44660702
DM
10192 },
10193 "node" : {
10194 "description" : "The cluster node name.",
10195 "format" : "pve-node",
013dc89f
DM
10196 "type" : "string",
10197 "typetext" : "<string>"
7aacca6f
DM
10198 },
10199 "pool" : {
10200 "description" : "Add the new VM to the specified pool.",
44660702 10201 "format" : "pve-poolid",
56122987 10202 "optional" : 1,
013dc89f
DM
10203 "type" : "string",
10204 "typetext" : "<string>"
56122987 10205 },
44660702
DM
10206 "snapname" : {
10207 "description" : "The name of the snapshot.",
10208 "format" : "pve-configid",
10209 "maxLength" : 40,
7aacca6f 10210 "optional" : 1,
013dc89f
DM
10211 "type" : "string",
10212 "typetext" : "<string>"
56122987 10213 },
44660702
DM
10214 "storage" : {
10215 "description" : "Target storage for full clone.",
10216 "format" : "pve-storage-id",
7aacca6f 10217 "optional" : 1,
44660702 10218 "requires" : "full",
013dc89f
DM
10219 "type" : "string",
10220 "typetext" : "<string>"
56122987 10221 },
44660702
DM
10222 "target" : {
10223 "description" : "Target node. Only allowed if the original VM is on shared storage.",
10224 "format" : "pve-node",
56122987 10225 "optional" : 1,
013dc89f
DM
10226 "type" : "string",
10227 "typetext" : "<string>"
44660702
DM
10228 },
10229 "vmid" : {
10230 "description" : "The (unique) ID of the VM.",
10231 "format" : "pve-vmid",
10232 "minimum" : 1,
4bd7df8b 10233 "type" : "integer",
013dc89f 10234 "typetext" : "<integer> (1 - N)"
56122987
DM
10235 }
10236 }
10237 },
56122987
DM
10238 "permissions" : {
10239 "check" : [
10240 "and",
10241 [
10242 "perm",
10243 "/vms/{vmid}",
10244 [
10245 "VM.Clone"
10246 ]
10247 ],
10248 [
10249 "or",
10250 [
10251 "perm",
10252 "/vms/{newid}",
10253 [
10254 "VM.Allocate"
10255 ]
10256 ],
10257 [
10258 "perm",
10259 "/pool/{pool}",
10260 [
10261 "VM.Allocate"
10262 ],
10263 "require_param",
10264 "pool"
10265 ]
10266 ]
44660702
DM
10267 ],
10268 "description" : "You need 'VM.Clone' permissions on /vms/{vmid}, and 'VM.Allocate' permissions on /vms/{newid} (or on the VM pool /pool/{pool}). You also need 'Datastore.AllocateSpace' on any used storage."
10269 },
10270 "protected" : 1,
10271 "proxyto" : "node",
10272 "returns" : {
10273 "type" : "string"
56122987
DM
10274 }
10275 }
10276 },
44660702
DM
10277 "leaf" : 1,
10278 "path" : "/nodes/{node}/qemu/{vmid}/clone",
56122987
DM
10279 "text" : "clone"
10280 },
10281 {
56122987
DM
10282 "info" : {
10283 "POST" : {
7aacca6f 10284 "description" : "Move volume to different storage.",
44660702
DM
10285 "method" : "POST",
10286 "name" : "move_vm_disk",
56122987
DM
10287 "parameters" : {
10288 "additionalProperties" : 0,
10289 "properties" : {
10290 "delete" : {
44660702 10291 "default" : 0,
56122987 10292 "description" : "Delete the original disk after successful copy. By default the original disk is kept as unused disk.",
7aacca6f 10293 "optional" : 1,
013dc89f
DM
10294 "type" : "boolean",
10295 "typetext" : "<boolean>"
56122987 10296 },
44660702
DM
10297 "digest" : {
10298 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
10299 "maxLength" : 40,
10300 "optional" : 1,
013dc89f
DM
10301 "type" : "string",
10302 "typetext" : "<string>"
56122987 10303 },
56122987 10304 "disk" : {
56122987
DM
10305 "description" : "The disk you want to move.",
10306 "enum" : [
10307 "ide0",
10308 "ide1",
10309 "ide2",
10310 "ide3",
10311 "scsi0",
10312 "scsi1",
10313 "scsi2",
10314 "scsi3",
10315 "scsi4",
10316 "scsi5",
10317 "scsi6",
10318 "scsi7",
10319 "scsi8",
10320 "scsi9",
10321 "scsi10",
10322 "scsi11",
10323 "scsi12",
10324 "scsi13",
10325 "virtio0",
10326 "virtio1",
10327 "virtio2",
10328 "virtio3",
10329 "virtio4",
10330 "virtio5",
10331 "virtio6",
10332 "virtio7",
10333 "virtio8",
10334 "virtio9",
10335 "virtio10",
10336 "virtio11",
10337 "virtio12",
10338 "virtio13",
10339 "virtio14",
10340 "virtio15",
10341 "sata0",
10342 "sata1",
10343 "sata2",
10344 "sata3",
10345 "sata4",
2c0dde61
DM
10346 "sata5",
10347 "efidisk0"
44660702
DM
10348 ],
10349 "type" : "string"
7aacca6f
DM
10350 },
10351 "format" : {
10352 "description" : "Target Format.",
10353 "enum" : [
10354 "raw",
10355 "qcow2",
10356 "vmdk"
10357 ],
10358 "optional" : 1,
10359 "type" : "string"
44660702
DM
10360 },
10361 "node" : {
10362 "description" : "The cluster node name.",
10363 "format" : "pve-node",
013dc89f
DM
10364 "type" : "string",
10365 "typetext" : "<string>"
44660702
DM
10366 },
10367 "storage" : {
10368 "description" : "Target storage.",
10369 "format" : "pve-storage-id",
013dc89f
DM
10370 "type" : "string",
10371 "typetext" : "<string>"
44660702
DM
10372 },
10373 "vmid" : {
10374 "description" : "The (unique) ID of the VM.",
10375 "format" : "pve-vmid",
10376 "minimum" : 1,
4bd7df8b 10377 "type" : "integer",
013dc89f 10378 "typetext" : "<integer> (1 - N)"
56122987
DM
10379 }
10380 }
10381 },
44660702
DM
10382 "permissions" : {
10383 "check" : [
10384 "and",
10385 [
10386 "perm",
10387 "/vms/{vmid}",
10388 [
10389 "VM.Config.Disk"
10390 ]
10391 ],
10392 [
10393 "perm",
10394 "/storage/{storage}",
10395 [
10396 "Datastore.AllocateSpace"
10397 ]
10398 ]
10399 ],
10400 "description" : "You need 'VM.Config.Disk' permissions on /vms/{vmid}, and 'Datastore.AllocateSpace' permissions on the storage."
10401 },
10402 "protected" : 1,
10403 "proxyto" : "node",
10404 "returns" : {
10405 "description" : "the task ID.",
10406 "type" : "string"
10407 }
56122987 10408 }
7aacca6f 10409 },
44660702 10410 "leaf" : 1,
7aacca6f 10411 "path" : "/nodes/{node}/qemu/{vmid}/move_disk",
44660702 10412 "text" : "move_disk"
56122987
DM
10413 },
10414 {
56122987
DM
10415 "info" : {
10416 "POST" : {
7aacca6f 10417 "description" : "Migrate virtual machine. Creates a new migration task.",
44660702 10418 "method" : "POST",
7aacca6f 10419 "name" : "migrate_vm",
56122987 10420 "parameters" : {
44660702 10421 "additionalProperties" : 0,
56122987 10422 "properties" : {
44660702
DM
10423 "force" : {
10424 "description" : "Allow to migrate VMs which use local devices. Only root may use this option.",
10425 "optional" : 1,
013dc89f
DM
10426 "type" : "boolean",
10427 "typetext" : "<boolean>"
44660702 10428 },
de0983cb
DM
10429 "migration_network" : {
10430 "description" : "CIDR of the (sub) network that is used for migration.",
10431 "format" : "CIDR",
10432 "optional" : 1,
013dc89f
DM
10433 "type" : "string",
10434 "typetext" : "<string>"
de0983cb
DM
10435 },
10436 "migration_type" : {
10437 "description" : "Migration traffic is encrypted using an SSH tunnel by default. On secure, completely private networks this can be disabled to increase performance.",
10438 "enum" : [
10439 "secure",
10440 "insecure"
10441 ],
10442 "optional" : 1,
10443 "type" : "string"
10444 },
7aacca6f 10445 "node" : {
44660702 10446 "description" : "The cluster node name.",
7aacca6f 10447 "format" : "pve-node",
013dc89f
DM
10448 "type" : "string",
10449 "typetext" : "<string>"
56122987
DM
10450 },
10451 "online" : {
44660702 10452 "description" : "Use online/live migration.",
56122987 10453 "optional" : 1,
013dc89f
DM
10454 "type" : "boolean",
10455 "typetext" : "<boolean>"
56122987 10456 },
44660702
DM
10457 "target" : {
10458 "description" : "Target node.",
10459 "format" : "pve-node",
013dc89f
DM
10460 "type" : "string",
10461 "typetext" : "<string>"
56122987 10462 },
52e44c50
FG
10463 "targetstorage" : {
10464 "description" : "Default target storage.",
10465 "format" : "pve-storage-id",
10466 "optional" : 1,
10467 "type" : "string",
10468 "typetext" : "<string>"
10469 },
7aacca6f 10470 "vmid" : {
7aacca6f 10471 "description" : "The (unique) ID of the VM.",
44660702 10472 "format" : "pve-vmid",
7aacca6f 10473 "minimum" : 1,
4bd7df8b 10474 "type" : "integer",
013dc89f 10475 "typetext" : "<integer> (1 - N)"
52e44c50
FG
10476 },
10477 "with-local-disks" : {
10478 "description" : "Enable live storage migration for local disk",
10479 "optional" : 1,
10480 "type" : "boolean",
10481 "typetext" : "<boolean>"
56122987 10482 }
44660702
DM
10483 }
10484 },
10485 "permissions" : {
10486 "check" : [
10487 "perm",
10488 "/vms/{vmid}",
10489 [
10490 "VM.Migrate"
10491 ]
10492 ]
56122987
DM
10493 },
10494 "protected" : 1,
44660702
DM
10495 "proxyto" : "node",
10496 "returns" : {
10497 "description" : "the task ID.",
10498 "type" : "string"
10499 }
56122987 10500 }
7aacca6f 10501 },
44660702
DM
10502 "leaf" : 1,
10503 "path" : "/nodes/{node}/qemu/{vmid}/migrate",
7aacca6f 10504 "text" : "migrate"
56122987
DM
10505 },
10506 {
10507 "info" : {
10508 "POST" : {
44660702 10509 "description" : "Execute Qemu monitor commands.",
56122987 10510 "method" : "POST",
44660702 10511 "name" : "monitor",
56122987 10512 "parameters" : {
7aacca6f 10513 "additionalProperties" : 0,
56122987 10514 "properties" : {
44660702
DM
10515 "command" : {
10516 "description" : "The monitor command.",
013dc89f
DM
10517 "type" : "string",
10518 "typetext" : "<string>"
44660702 10519 },
56122987 10520 "node" : {
44660702 10521 "description" : "The cluster node name.",
7aacca6f 10522 "format" : "pve-node",
013dc89f
DM
10523 "type" : "string",
10524 "typetext" : "<string>"
56122987
DM
10525 },
10526 "vmid" : {
44660702 10527 "description" : "The (unique) ID of the VM.",
56122987 10528 "format" : "pve-vmid",
7aacca6f 10529 "minimum" : 1,
4bd7df8b 10530 "type" : "integer",
013dc89f 10531 "typetext" : "<integer> (1 - N)"
56122987 10532 }
7aacca6f 10533 }
56122987 10534 },
56122987
DM
10535 "permissions" : {
10536 "check" : [
10537 "perm",
10538 "/vms/{vmid}",
10539 [
10540 "VM.Monitor"
10541 ]
32d876b5
DM
10542 ],
10543 "description" : "Sys.Modify is required for (sub)commands which are not read-only ('info *' and 'help')"
7aacca6f 10544 },
44660702
DM
10545 "protected" : 1,
10546 "proxyto" : "node",
10547 "returns" : {
10548 "type" : "string"
10549 }
56122987 10550 }
44660702
DM
10551 },
10552 "leaf" : 1,
10553 "path" : "/nodes/{node}/qemu/{vmid}/monitor",
10554 "text" : "monitor"
56122987 10555 },
32d876b5
DM
10556 {
10557 "info" : {
10558 "POST" : {
10559 "description" : "Execute Qemu Guest Agent commands.",
10560 "method" : "POST",
10561 "name" : "agent",
10562 "parameters" : {
10563 "additionalProperties" : 0,
10564 "properties" : {
10565 "command" : {
10566 "description" : "The QGA command.",
10567 "enum" : [
10568 "ping",
10569 "get-time",
10570 "info",
10571 "fsfreeze-status",
10572 "fsfreeze-freeze",
10573 "fsfreeze-thaw",
10574 "fstrim",
10575 "network-get-interfaces",
10576 "get-vcpus",
10577 "get-fsinfo",
10578 "get-memory-blocks",
10579 "get-memory-block-info",
10580 "suspend-hybrid",
10581 "suspend-ram",
10582 "suspend-disk",
10583 "shutdown"
10584 ],
10585 "type" : "string"
10586 },
10587 "node" : {
10588 "description" : "The cluster node name.",
10589 "format" : "pve-node",
10590 "type" : "string",
10591 "typetext" : "<string>"
10592 },
10593 "vmid" : {
10594 "description" : "The (unique) ID of the VM.",
10595 "format" : "pve-vmid",
10596 "minimum" : 1,
10597 "type" : "integer",
10598 "typetext" : "<integer> (1 - N)"
10599 }
10600 }
10601 },
10602 "permissions" : {
10603 "check" : [
10604 "perm",
10605 "/vms/{vmid}",
10606 [
10607 "VM.Monitor"
10608 ]
10609 ]
10610 },
10611 "protected" : 1,
10612 "proxyto" : "node",
10613 "returns" : {
10614 "description" : "Returns an object with a single `result` property. The type of that\nproperty depends on the executed command.",
10615 "type" : "object"
10616 }
10617 }
10618 },
10619 "leaf" : 1,
10620 "path" : "/nodes/{node}/qemu/{vmid}/agent",
10621 "text" : "agent"
10622 },
56122987 10623 {
56122987
DM
10624 "info" : {
10625 "PUT" : {
44660702
DM
10626 "description" : "Extend volume size.",
10627 "method" : "PUT",
10628 "name" : "resize_vm",
56122987 10629 "parameters" : {
44660702 10630 "additionalProperties" : 0,
56122987 10631 "properties" : {
44660702
DM
10632 "digest" : {
10633 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
10634 "maxLength" : 40,
10635 "optional" : 1,
013dc89f
DM
10636 "type" : "string",
10637 "typetext" : "<string>"
56122987 10638 },
56122987
DM
10639 "disk" : {
10640 "description" : "The disk you want to resize.",
10641 "enum" : [
10642 "ide0",
10643 "ide1",
10644 "ide2",
10645 "ide3",
10646 "scsi0",
10647 "scsi1",
10648 "scsi2",
10649 "scsi3",
10650 "scsi4",
10651 "scsi5",
10652 "scsi6",
10653 "scsi7",
10654 "scsi8",
10655 "scsi9",
10656 "scsi10",
10657 "scsi11",
10658 "scsi12",
10659 "scsi13",
10660 "virtio0",
10661 "virtio1",
10662 "virtio2",
10663 "virtio3",
10664 "virtio4",
10665 "virtio5",
10666 "virtio6",
10667 "virtio7",
10668 "virtio8",
10669 "virtio9",
10670 "virtio10",
10671 "virtio11",
10672 "virtio12",
10673 "virtio13",
10674 "virtio14",
10675 "virtio15",
10676 "sata0",
10677 "sata1",
10678 "sata2",
10679 "sata3",
10680 "sata4",
2c0dde61
DM
10681 "sata5",
10682 "efidisk0"
44660702
DM
10683 ],
10684 "type" : "string"
56122987 10685 },
44660702
DM
10686 "node" : {
10687 "description" : "The cluster node name.",
10688 "format" : "pve-node",
013dc89f
DM
10689 "type" : "string",
10690 "typetext" : "<string>"
7aacca6f 10691 },
44660702
DM
10692 "size" : {
10693 "description" : "The new size. With the '+' sign the value is added to the actual size of the volume and without it, the value is taken as an absolute one. Shrinking disk size is not supported.",
10694 "pattern" : "\\+?\\d+(\\.\\d+)?[KMGT]?",
10695 "type" : "string"
56122987
DM
10696 },
10697 "skiplock" : {
10698 "description" : "Ignore locks - only root is allowed to use this option.",
10699 "optional" : 1,
013dc89f
DM
10700 "type" : "boolean",
10701 "typetext" : "<boolean>"
56122987
DM
10702 },
10703 "vmid" : {
7aacca6f 10704 "description" : "The (unique) ID of the VM.",
56122987 10705 "format" : "pve-vmid",
44660702 10706 "minimum" : 1,
4bd7df8b 10707 "type" : "integer",
013dc89f 10708 "typetext" : "<integer> (1 - N)"
56122987
DM
10709 }
10710 }
10711 },
10712 "permissions" : {
10713 "check" : [
10714 "perm",
10715 "/vms/{vmid}",
10716 [
44660702 10717 "VM.Config.Disk"
56122987
DM
10718 ]
10719 ]
10720 },
7aacca6f 10721 "protected" : 1,
7aacca6f 10722 "proxyto" : "node",
44660702
DM
10723 "returns" : {
10724 "type" : "null"
10725 }
7aacca6f
DM
10726 }
10727 },
44660702
DM
10728 "leaf" : 1,
10729 "path" : "/nodes/{node}/qemu/{vmid}/resize",
10730 "text" : "resize"
10731 },
10732 {
56122987
DM
10733 "children" : [
10734 {
10735 "children" : [
10736 {
56122987 10737 "info" : {
44660702
DM
10738 "GET" : {
10739 "description" : "Get snapshot configuration",
10740 "method" : "GET",
10741 "name" : "get_snapshot_config",
56122987 10742 "parameters" : {
44660702 10743 "additionalProperties" : 0,
56122987 10744 "properties" : {
56122987 10745 "node" : {
44660702 10746 "description" : "The cluster node name.",
56122987 10747 "format" : "pve-node",
013dc89f
DM
10748 "type" : "string",
10749 "typetext" : "<string>"
7aacca6f
DM
10750 },
10751 "snapname" : {
44660702 10752 "description" : "The name of the snapshot.",
7aacca6f 10753 "format" : "pve-configid",
44660702 10754 "maxLength" : 40,
013dc89f
DM
10755 "type" : "string",
10756 "typetext" : "<string>"
7aacca6f
DM
10757 },
10758 "vmid" : {
44660702 10759 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
10760 "format" : "pve-vmid",
10761 "minimum" : 1,
4bd7df8b 10762 "type" : "integer",
013dc89f 10763 "typetext" : "<integer> (1 - N)"
56122987 10764 }
44660702 10765 }
56122987
DM
10766 },
10767 "permissions" : {
10768 "check" : [
10769 "perm",
10770 "/vms/{vmid}",
10771 [
10772 "VM.Snapshot"
10773 ]
10774 ]
10775 },
44660702 10776 "proxyto" : "node",
56122987 10777 "returns" : {
44660702 10778 "type" : "object"
7aacca6f
DM
10779 }
10780 },
44660702
DM
10781 "PUT" : {
10782 "description" : "Update snapshot metadata.",
10783 "method" : "PUT",
10784 "name" : "update_snapshot_config",
56122987 10785 "parameters" : {
44660702 10786 "additionalProperties" : 0,
56122987 10787 "properties" : {
44660702
DM
10788 "description" : {
10789 "description" : "A textual description or comment.",
10790 "optional" : 1,
013dc89f
DM
10791 "type" : "string",
10792 "typetext" : "<string>"
44660702 10793 },
56122987 10794 "node" : {
7aacca6f 10795 "description" : "The cluster node name.",
44660702 10796 "format" : "pve-node",
013dc89f
DM
10797 "type" : "string",
10798 "typetext" : "<string>"
56122987 10799 },
56122987
DM
10800 "snapname" : {
10801 "description" : "The name of the snapshot.",
44660702 10802 "format" : "pve-configid",
7aacca6f 10803 "maxLength" : 40,
013dc89f
DM
10804 "type" : "string",
10805 "typetext" : "<string>"
7aacca6f
DM
10806 },
10807 "vmid" : {
10808 "description" : "The (unique) ID of the VM.",
44660702 10809 "format" : "pve-vmid",
7aacca6f 10810 "minimum" : 1,
4bd7df8b 10811 "type" : "integer",
013dc89f 10812 "typetext" : "<integer> (1 - N)"
56122987 10813 }
44660702 10814 }
56122987 10815 },
7aacca6f
DM
10816 "permissions" : {
10817 "check" : [
10818 "perm",
10819 "/vms/{vmid}",
10820 [
10821 "VM.Snapshot"
10822 ]
10823 ]
44660702
DM
10824 },
10825 "protected" : 1,
10826 "proxyto" : "node",
10827 "returns" : {
10828 "type" : "null"
7aacca6f 10829 }
56122987
DM
10830 }
10831 },
44660702 10832 "leaf" : 1,
7aacca6f 10833 "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}/config",
44660702 10834 "text" : "config"
56122987
DM
10835 },
10836 {
56122987
DM
10837 "info" : {
10838 "POST" : {
44660702 10839 "description" : "Rollback VM state to specified snapshot.",
7aacca6f 10840 "method" : "POST",
44660702 10841 "name" : "rollback",
56122987
DM
10842 "parameters" : {
10843 "additionalProperties" : 0,
10844 "properties" : {
44660702
DM
10845 "node" : {
10846 "description" : "The cluster node name.",
10847 "format" : "pve-node",
013dc89f
DM
10848 "type" : "string",
10849 "typetext" : "<string>"
44660702 10850 },
56122987 10851 "snapname" : {
44660702 10852 "description" : "The name of the snapshot.",
56122987
DM
10853 "format" : "pve-configid",
10854 "maxLength" : 40,
013dc89f
DM
10855 "type" : "string",
10856 "typetext" : "<string>"
7aacca6f 10857 },
56122987 10858 "vmid" : {
7aacca6f 10859 "description" : "The (unique) ID of the VM.",
44660702 10860 "format" : "pve-vmid",
56122987 10861 "minimum" : 1,
4bd7df8b 10862 "type" : "integer",
013dc89f 10863 "typetext" : "<integer> (1 - N)"
56122987
DM
10864 }
10865 }
10866 },
7aacca6f 10867 "permissions" : {
56122987
DM
10868 "check" : [
10869 "perm",
10870 "/vms/{vmid}",
10871 [
10872 "VM.Snapshot"
10873 ]
10874 ]
10875 },
44660702 10876 "protected" : 1,
7aacca6f 10877 "proxyto" : "node",
44660702
DM
10878 "returns" : {
10879 "description" : "the task ID.",
10880 "type" : "string"
10881 }
56122987
DM
10882 }
10883 },
44660702
DM
10884 "leaf" : 1,
10885 "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}/rollback",
7aacca6f 10886 "text" : "rollback"
56122987 10887 }
44660702
DM
10888 ],
10889 "info" : {
10890 "DELETE" : {
10891 "description" : "Delete a VM snapshot.",
10892 "method" : "DELETE",
10893 "name" : "delsnapshot",
10894 "parameters" : {
10895 "additionalProperties" : 0,
10896 "properties" : {
10897 "force" : {
10898 "description" : "For removal from config file, even if removing disk snapshots fails.",
10899 "optional" : 1,
013dc89f
DM
10900 "type" : "boolean",
10901 "typetext" : "<boolean>"
44660702
DM
10902 },
10903 "node" : {
10904 "description" : "The cluster node name.",
10905 "format" : "pve-node",
013dc89f
DM
10906 "type" : "string",
10907 "typetext" : "<string>"
44660702
DM
10908 },
10909 "snapname" : {
10910 "description" : "The name of the snapshot.",
10911 "format" : "pve-configid",
10912 "maxLength" : 40,
013dc89f
DM
10913 "type" : "string",
10914 "typetext" : "<string>"
44660702
DM
10915 },
10916 "vmid" : {
10917 "description" : "The (unique) ID of the VM.",
10918 "format" : "pve-vmid",
10919 "minimum" : 1,
4bd7df8b 10920 "type" : "integer",
013dc89f 10921 "typetext" : "<integer> (1 - N)"
44660702
DM
10922 }
10923 }
10924 },
10925 "permissions" : {
10926 "check" : [
10927 "perm",
10928 "/vms/{vmid}",
10929 [
10930 "VM.Snapshot"
10931 ]
10932 ]
10933 },
10934 "protected" : 1,
10935 "proxyto" : "node",
10936 "returns" : {
10937 "description" : "the task ID.",
10938 "type" : "string"
10939 }
10940 },
10941 "GET" : {
10942 "description" : "",
10943 "method" : "GET",
10944 "name" : "snapshot_cmd_idx",
10945 "parameters" : {
10946 "additionalProperties" : 0,
10947 "properties" : {
10948 "node" : {
10949 "description" : "The cluster node name.",
10950 "format" : "pve-node",
013dc89f
DM
10951 "type" : "string",
10952 "typetext" : "<string>"
44660702
DM
10953 },
10954 "snapname" : {
10955 "description" : "The name of the snapshot.",
10956 "format" : "pve-configid",
10957 "maxLength" : 40,
013dc89f
DM
10958 "type" : "string",
10959 "typetext" : "<string>"
44660702
DM
10960 },
10961 "vmid" : {
10962 "description" : "The (unique) ID of the VM.",
10963 "format" : "pve-vmid",
10964 "minimum" : 1,
4bd7df8b 10965 "type" : "integer",
013dc89f 10966 "typetext" : "<integer> (1 - N)"
44660702
DM
10967 }
10968 }
10969 },
10970 "permissions" : {
10971 "user" : "all"
10972 },
10973 "returns" : {
10974 "items" : {
10975 "properties" : {},
10976 "type" : "object"
10977 },
10978 "links" : [
10979 {
10980 "href" : "{cmd}",
10981 "rel" : "child"
10982 }
10983 ],
10984 "type" : "array"
10985 }
10986 }
10987 },
10988 "leaf" : 0,
10989 "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}",
10990 "text" : "{snapname}"
56122987
DM
10991 }
10992 ],
44660702
DM
10993 "info" : {
10994 "GET" : {
10995 "description" : "List all snapshots.",
10996 "method" : "GET",
10997 "name" : "snapshot_list",
10998 "parameters" : {
10999 "additionalProperties" : 0,
11000 "properties" : {
11001 "node" : {
11002 "description" : "The cluster node name.",
11003 "format" : "pve-node",
013dc89f
DM
11004 "type" : "string",
11005 "typetext" : "<string>"
44660702
DM
11006 },
11007 "vmid" : {
11008 "description" : "The (unique) ID of the VM.",
11009 "format" : "pve-vmid",
11010 "minimum" : 1,
4bd7df8b 11011 "type" : "integer",
013dc89f 11012 "typetext" : "<integer> (1 - N)"
44660702
DM
11013 }
11014 }
11015 },
11016 "permissions" : {
11017 "check" : [
11018 "perm",
11019 "/vms/{vmid}",
11020 [
11021 "VM.Audit"
11022 ]
11023 ]
11024 },
11025 "protected" : 1,
11026 "proxyto" : "node",
11027 "returns" : {
11028 "items" : {
11029 "properties" : {},
11030 "type" : "object"
11031 },
11032 "links" : [
11033 {
11034 "href" : "{name}",
11035 "rel" : "child"
11036 }
11037 ],
11038 "type" : "array"
11039 }
11040 },
11041 "POST" : {
11042 "description" : "Snapshot a VM.",
11043 "method" : "POST",
11044 "name" : "snapshot",
11045 "parameters" : {
11046 "additionalProperties" : 0,
11047 "properties" : {
11048 "description" : {
11049 "description" : "A textual description or comment.",
11050 "optional" : 1,
013dc89f
DM
11051 "type" : "string",
11052 "typetext" : "<string>"
44660702
DM
11053 },
11054 "node" : {
11055 "description" : "The cluster node name.",
11056 "format" : "pve-node",
013dc89f
DM
11057 "type" : "string",
11058 "typetext" : "<string>"
44660702
DM
11059 },
11060 "snapname" : {
11061 "description" : "The name of the snapshot.",
11062 "format" : "pve-configid",
11063 "maxLength" : 40,
013dc89f
DM
11064 "type" : "string",
11065 "typetext" : "<string>"
44660702
DM
11066 },
11067 "vmid" : {
11068 "description" : "The (unique) ID of the VM.",
11069 "format" : "pve-vmid",
11070 "minimum" : 1,
4bd7df8b 11071 "type" : "integer",
013dc89f 11072 "typetext" : "<integer> (1 - N)"
44660702
DM
11073 },
11074 "vmstate" : {
11075 "description" : "Save the vmstate",
11076 "optional" : 1,
013dc89f
DM
11077 "type" : "boolean",
11078 "typetext" : "<boolean>"
44660702
DM
11079 }
11080 }
11081 },
11082 "permissions" : {
11083 "check" : [
11084 "perm",
11085 "/vms/{vmid}",
11086 [
11087 "VM.Snapshot"
11088 ]
11089 ]
11090 },
11091 "protected" : 1,
11092 "proxyto" : "node",
11093 "returns" : {
11094 "description" : "the task ID.",
11095 "type" : "string"
11096 }
11097 }
11098 },
11099 "leaf" : 0,
11100 "path" : "/nodes/{node}/qemu/{vmid}/snapshot",
7aacca6f 11101 "text" : "snapshot"
56122987
DM
11102 },
11103 {
56122987
DM
11104 "info" : {
11105 "POST" : {
44660702
DM
11106 "description" : "Create a Template.",
11107 "method" : "POST",
56122987 11108 "name" : "template",
56122987 11109 "parameters" : {
7aacca6f 11110 "additionalProperties" : 0,
56122987 11111 "properties" : {
56122987 11112 "disk" : {
56122987
DM
11113 "description" : "If you want to convert only 1 disk to base image.",
11114 "enum" : [
11115 "ide0",
11116 "ide1",
11117 "ide2",
11118 "ide3",
11119 "scsi0",
11120 "scsi1",
11121 "scsi2",
11122 "scsi3",
11123 "scsi4",
11124 "scsi5",
11125 "scsi6",
11126 "scsi7",
11127 "scsi8",
11128 "scsi9",
11129 "scsi10",
11130 "scsi11",
11131 "scsi12",
11132 "scsi13",
11133 "virtio0",
11134 "virtio1",
11135 "virtio2",
11136 "virtio3",
11137 "virtio4",
11138 "virtio5",
11139 "virtio6",
11140 "virtio7",
11141 "virtio8",
11142 "virtio9",
11143 "virtio10",
11144 "virtio11",
11145 "virtio12",
11146 "virtio13",
11147 "virtio14",
11148 "virtio15",
11149 "sata0",
11150 "sata1",
11151 "sata2",
11152 "sata3",
11153 "sata4",
2c0dde61
DM
11154 "sata5",
11155 "efidisk0"
56122987 11156 ],
7aacca6f 11157 "optional" : 1,
56122987
DM
11158 "type" : "string"
11159 },
44660702
DM
11160 "node" : {
11161 "description" : "The cluster node name.",
11162 "format" : "pve-node",
013dc89f
DM
11163 "type" : "string",
11164 "typetext" : "<string>"
44660702
DM
11165 },
11166 "vmid" : {
11167 "description" : "The (unique) ID of the VM.",
7aacca6f 11168 "format" : "pve-vmid",
44660702 11169 "minimum" : 1,
4bd7df8b 11170 "type" : "integer",
013dc89f 11171 "typetext" : "<integer> (1 - N)"
56122987 11172 }
7aacca6f 11173 }
56122987 11174 },
7aacca6f
DM
11175 "permissions" : {
11176 "check" : [
11177 "perm",
11178 "/vms/{vmid}",
11179 [
11180 "VM.Allocate"
11181 ]
11182 ],
11183 "description" : "You need 'VM.Allocate' permissions on /vms/{vmid}"
11184 },
44660702 11185 "protected" : 1,
7aacca6f 11186 "proxyto" : "node",
7aacca6f
DM
11187 "returns" : {
11188 "type" : "null"
11189 }
56122987
DM
11190 }
11191 },
44660702 11192 "leaf" : 1,
7aacca6f 11193 "path" : "/nodes/{node}/qemu/{vmid}/template",
44660702 11194 "text" : "template"
56122987
DM
11195 }
11196 ],
7aacca6f 11197 "info" : {
44660702
DM
11198 "DELETE" : {
11199 "description" : "Destroy the vm (also delete all used/owned volumes).",
11200 "method" : "DELETE",
11201 "name" : "destroy_vm",
7aacca6f 11202 "parameters" : {
44660702 11203 "additionalProperties" : 0,
7aacca6f
DM
11204 "properties" : {
11205 "node" : {
44660702 11206 "description" : "The cluster node name.",
7aacca6f 11207 "format" : "pve-node",
013dc89f
DM
11208 "type" : "string",
11209 "typetext" : "<string>"
44660702
DM
11210 },
11211 "skiplock" : {
11212 "description" : "Ignore locks - only root is allowed to use this option.",
11213 "optional" : 1,
013dc89f
DM
11214 "type" : "boolean",
11215 "typetext" : "<boolean>"
7aacca6f
DM
11216 },
11217 "vmid" : {
44660702 11218 "description" : "The (unique) ID of the VM.",
7aacca6f 11219 "format" : "pve-vmid",
44660702 11220 "minimum" : 1,
4bd7df8b 11221 "type" : "integer",
013dc89f 11222 "typetext" : "<integer> (1 - N)"
7aacca6f 11223 }
44660702 11224 }
7aacca6f 11225 },
7aacca6f
DM
11226 "permissions" : {
11227 "check" : [
11228 "perm",
11229 "/vms/{vmid}",
11230 [
11231 "VM.Allocate"
11232 ]
11233 ]
11234 },
44660702
DM
11235 "protected" : 1,
11236 "proxyto" : "node",
7aacca6f
DM
11237 "returns" : {
11238 "type" : "string"
44660702
DM
11239 }
11240 },
11241 "GET" : {
11242 "description" : "Directory index",
11243 "method" : "GET",
11244 "name" : "vmdiridx",
7aacca6f 11245 "parameters" : {
44660702 11246 "additionalProperties" : 0,
7aacca6f 11247 "properties" : {
7aacca6f 11248 "node" : {
7aacca6f 11249 "description" : "The cluster node name.",
44660702 11250 "format" : "pve-node",
013dc89f
DM
11251 "type" : "string",
11252 "typetext" : "<string>"
44660702
DM
11253 },
11254 "vmid" : {
11255 "description" : "The (unique) ID of the VM.",
11256 "format" : "pve-vmid",
11257 "minimum" : 1,
4bd7df8b 11258 "type" : "integer",
013dc89f 11259 "typetext" : "<integer> (1 - N)"
7aacca6f 11260 }
44660702 11261 }
7aacca6f 11262 },
44660702
DM
11263 "permissions" : {
11264 "user" : "all"
11265 },
11266 "proxyto" : "node",
11267 "returns" : {
11268 "items" : {
11269 "properties" : {
11270 "subdir" : {
11271 "type" : "string"
11272 }
11273 },
11274 "type" : "object"
11275 },
11276 "links" : [
11277 {
11278 "href" : "{subdir}",
11279 "rel" : "child"
11280 }
11281 ],
11282 "type" : "array"
11283 }
7aacca6f 11284 }
44660702
DM
11285 },
11286 "leaf" : 0,
11287 "path" : "/nodes/{node}/qemu/{vmid}",
11288 "text" : "{vmid}"
56122987
DM
11289 }
11290 ],
11291 "info" : {
44660702
DM
11292 "GET" : {
11293 "description" : "Virtual machine index (per node).",
11294 "method" : "GET",
11295 "name" : "vmlist",
56122987 11296 "parameters" : {
44660702 11297 "additionalProperties" : 0,
56122987 11298 "properties" : {
44660702
DM
11299 "full" : {
11300 "description" : "Determine the full status of active VMs.",
56122987 11301 "optional" : 1,
013dc89f
DM
11302 "type" : "boolean",
11303 "typetext" : "<boolean>"
56122987 11304 },
44660702
DM
11305 "node" : {
11306 "description" : "The cluster node name.",
11307 "format" : "pve-node",
013dc89f
DM
11308 "type" : "string",
11309 "typetext" : "<string>"
44660702
DM
11310 }
11311 }
11312 },
11313 "permissions" : {
11314 "description" : "Only list VMs where you have VM.Audit permissons on /vms/<vmid>.",
11315 "user" : "all"
11316 },
11317 "protected" : 1,
11318 "proxyto" : "node",
11319 "returns" : {
11320 "items" : {
11321 "properties" : {},
11322 "type" : "object"
11323 },
11324 "links" : [
11325 {
11326 "href" : "{vmid}",
11327 "rel" : "child"
11328 }
11329 ],
11330 "type" : "array"
11331 }
11332 },
11333 "POST" : {
11334 "description" : "Create or restore a virtual machine.",
11335 "method" : "POST",
11336 "name" : "create_vm",
11337 "parameters" : {
11338 "additionalProperties" : 0,
11339 "properties" : {
7aacca6f 11340 "acpi" : {
7aacca6f 11341 "default" : 1,
44660702 11342 "description" : "Enable/disable ACPI.",
56122987 11343 "optional" : 1,
013dc89f
DM
11344 "type" : "boolean",
11345 "typetext" : "<boolean>"
56122987 11346 },
44660702
DM
11347 "agent" : {
11348 "default" : 0,
11349 "description" : "Enable/disable Qemu GuestAgent.",
7aacca6f 11350 "optional" : 1,
013dc89f
DM
11351 "type" : "boolean",
11352 "typetext" : "<boolean>"
56122987 11353 },
44660702
DM
11354 "archive" : {
11355 "description" : "The backup file.",
11356 "maxLength" : 255,
56122987 11357 "optional" : 1,
013dc89f
DM
11358 "type" : "string",
11359 "typetext" : "<string>"
56122987 11360 },
44660702 11361 "args" : {
c2993fe5 11362 "description" : "Arbitrary arguments passed to kvm.",
56122987 11363 "optional" : 1,
c2993fe5 11364 "type" : "string",
013dc89f 11365 "typetext" : "<string>",
c2993fe5 11366 "verbose_description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n"
56122987 11367 },
44660702 11368 "autostart" : {
7aacca6f 11369 "default" : 0,
44660702
DM
11370 "description" : "Automatic restart after crash (currently ignored).",
11371 "optional" : 1,
013dc89f
DM
11372 "type" : "boolean",
11373 "typetext" : "<boolean>"
7aacca6f 11374 },
44660702
DM
11375 "balloon" : {
11376 "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.",
11377 "minimum" : 0,
56122987 11378 "optional" : 1,
4bd7df8b 11379 "type" : "integer",
013dc89f 11380 "typetext" : "<integer> (0 - N)"
56122987 11381 },
44660702
DM
11382 "bios" : {
11383 "default" : "seabios",
11384 "description" : "Select BIOS implementation.",
11385 "enum" : [
11386 "seabios",
11387 "ovmf"
11388 ],
56122987 11389 "optional" : 1,
44660702 11390 "type" : "string"
56122987 11391 },
44660702
DM
11392 "boot" : {
11393 "default" : "cdn",
11394 "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).",
56122987 11395 "optional" : 1,
44660702
DM
11396 "pattern" : "[acdn]{1,4}",
11397 "type" : "string"
56122987 11398 },
7aacca6f
DM
11399 "bootdisk" : {
11400 "description" : "Enable booting from specified disk.",
44660702
DM
11401 "format" : "pve-qm-bootdisk",
11402 "optional" : 1,
7aacca6f 11403 "pattern" : "(ide|sata|scsi|virtio)\\d+",
44660702
DM
11404 "type" : "string"
11405 },
11406 "cdrom" : {
11407 "description" : "This is an alias for option -ide2",
de0983cb 11408 "format" : "pve-qm-ide",
56122987 11409 "optional" : 1,
44660702 11410 "type" : "string",
013dc89f 11411 "typetext" : "<volume>"
56122987 11412 },
44660702
DM
11413 "cores" : {
11414 "default" : 1,
11415 "description" : "The number of cores per socket.",
7aacca6f 11416 "minimum" : 1,
44660702 11417 "optional" : 1,
4bd7df8b 11418 "type" : "integer",
013dc89f 11419 "typetext" : "<integer> (1 - N)"
7aacca6f 11420 },
44660702
DM
11421 "cpu" : {
11422 "description" : "Emulated CPU type.",
11423 "format" : {
11424 "cputype" : {
11425 "default" : "kvm64",
11426 "default_key" : 1,
11427 "description" : "Emulated CPU type.",
11428 "enum" : [
11429 "486",
11430 "athlon",
f004f5b9
DM
11431 "Broadwell",
11432 "Broadwell-noTSX",
11433 "Conroe",
44660702 11434 "core2duo",
f004f5b9
DM
11435 "coreduo",
11436 "Haswell",
11437 "Haswell-noTSX",
11438 "host",
11439 "IvyBridge",
44660702
DM
11440 "kvm32",
11441 "kvm64",
44660702 11442 "Nehalem",
44660702
DM
11443 "Opteron_G1",
11444 "Opteron_G2",
11445 "Opteron_G3",
11446 "Opteron_G4",
11447 "Opteron_G5",
f004f5b9
DM
11448 "Penryn",
11449 "pentium",
11450 "pentium2",
11451 "pentium3",
11452 "phenom",
11453 "qemu32",
11454 "qemu64",
11455 "SandyBridge",
11456 "Westmere"
44660702 11457 ],
44660702
DM
11458 "type" : "string"
11459 },
11460 "hidden" : {
11461 "default" : 0,
11462 "description" : "Do not identify as a KVM virtual machine.",
11463 "optional" : 1,
11464 "type" : "boolean"
11465 }
11466 },
56122987 11467 "optional" : 1,
4bd7df8b 11468 "type" : "string",
013dc89f 11469 "typetext" : "[cputype=]<enum> [,hidden=<1|0>]"
56122987 11470 },
44660702 11471 "cpulimit" : {
7aacca6f 11472 "default" : 0,
c2993fe5 11473 "description" : "Limit of CPU usage.",
44660702
DM
11474 "maximum" : 128,
11475 "minimum" : 0,
7aacca6f 11476 "optional" : 1,
c2993fe5 11477 "type" : "number",
013dc89f 11478 "typetext" : "<number> (0 - 128)",
c2993fe5 11479 "verbose_description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has total of '2' CPU time. Value '0' indicates no CPU limit."
7aacca6f
DM
11480 },
11481 "cpuunits" : {
de0983cb 11482 "default" : 1024,
c2993fe5 11483 "description" : "CPU weight for a VM.",
7aacca6f 11484 "maximum" : 500000,
44660702
DM
11485 "minimum" : 0,
11486 "optional" : 1,
c2993fe5 11487 "type" : "integer",
013dc89f 11488 "typetext" : "<integer> (0 - 500000)",
c2993fe5 11489 "verbose_description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0."
44660702
DM
11490 },
11491 "description" : {
11492 "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.",
56122987 11493 "optional" : 1,
013dc89f
DM
11494 "type" : "string",
11495 "typetext" : "<string>"
44660702
DM
11496 },
11497 "force" : {
11498 "description" : "Allow to overwrite existing VM.",
11499 "optional" : 1,
11500 "requires" : "archive",
013dc89f
DM
11501 "type" : "boolean",
11502 "typetext" : "<boolean>"
44660702
DM
11503 },
11504 "freeze" : {
11505 "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).",
11506 "optional" : 1,
013dc89f
DM
11507 "type" : "boolean",
11508 "typetext" : "<boolean>"
44660702
DM
11509 },
11510 "hostpci[n]" : {
c2993fe5 11511 "description" : "Map host PCI devices into guest.",
44660702
DM
11512 "format" : "pve-qm-hostpci",
11513 "optional" : 1,
57b78691 11514 "type" : "string",
52e44c50 11515 "typetext" : "[host=]<HOSTPCIID[;HOSTPCIID2...]> [,pcie=<1|0>] [,rombar=<1|0>] [,romfile=<string>] [,x-vga=<1|0>]",
57b78691 11516 "verbose_description" : "Map host PCI devices into guest.\n\nNOTE: This option allows direct access to host hardware. So it is no longer \npossible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
44660702
DM
11517 },
11518 "hotplug" : {
11519 "default" : "network,disk,usb",
11520 "description" : "Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'.",
11521 "format" : "pve-hotplug-features",
11522 "optional" : 1,
013dc89f
DM
11523 "type" : "string",
11524 "typetext" : "<string>"
7aacca6f 11525 },
4bd7df8b
DM
11526 "hugepages" : {
11527 "description" : "Enable/disable hugepages memory.",
11528 "enum" : [
11529 "any",
11530 "2",
11531 "1024"
11532 ],
11533 "optional" : 1,
11534 "type" : "string"
11535 },
7aacca6f 11536 "ide[n]" : {
44660702 11537 "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).",
56122987 11538 "format" : {
44660702
DM
11539 "aio" : {
11540 "description" : "AIO type to use.",
11541 "enum" : [
11542 "native",
11543 "threads"
11544 ],
44660702
DM
11545 "optional" : 1,
11546 "type" : "string"
11547 },
11548 "backup" : {
11549 "description" : "Whether the drive should be included when making backups.",
44660702
DM
11550 "optional" : 1,
11551 "type" : "boolean"
11552 },
11553 "bps" : {
de0983cb 11554 "description" : "Maximum r/w speed in bytes per second.",
7aacca6f 11555 "format_description" : "bps",
56122987 11556 "optional" : 1,
44660702 11557 "type" : "integer"
56122987 11558 },
de0983cb
DM
11559 "bps_max_length" : {
11560 "description" : "Maximum length of I/O bursts in seconds.",
11561 "format_description" : "seconds",
11562 "minimum" : 1,
11563 "optional" : 1,
11564 "type" : "integer"
11565 },
44660702 11566 "bps_rd" : {
de0983cb 11567 "description" : "Maximum read speed in bytes per second.",
44660702 11568 "format_description" : "bps",
56122987 11569 "optional" : 1,
44660702 11570 "type" : "integer"
56122987 11571 },
de0983cb
DM
11572 "bps_rd_length" : {
11573 "description" : "Maximum length of read I/O bursts in seconds.",
11574 "format_description" : "seconds",
11575 "minimum" : 1,
11576 "optional" : 1,
11577 "type" : "integer"
11578 },
44660702 11579 "bps_wr" : {
de0983cb 11580 "description" : "Maximum write speed in bytes per second.",
44660702 11581 "format_description" : "bps",
56122987 11582 "optional" : 1,
44660702 11583 "type" : "integer"
56122987 11584 },
de0983cb
DM
11585 "bps_wr_length" : {
11586 "description" : "Maximum length of write I/O bursts in seconds.",
11587 "format_description" : "seconds",
11588 "minimum" : 1,
11589 "optional" : 1,
11590 "type" : "integer"
11591 },
44660702
DM
11592 "cache" : {
11593 "description" : "The drive's cache mode",
56122987 11594 "enum" : [
7aacca6f 11595 "none",
44660702
DM
11596 "writethrough",
11597 "writeback",
11598 "unsafe",
11599 "directsync"
56122987 11600 ],
56122987 11601 "optional" : 1,
44660702 11602 "type" : "string"
56122987 11603 },
44660702
DM
11604 "cyls" : {
11605 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
11606 "optional" : 1,
11607 "type" : "integer"
7aacca6f 11608 },
44660702
DM
11609 "detect_zeroes" : {
11610 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
56122987 11611 "optional" : 1,
44660702 11612 "type" : "boolean"
56122987 11613 },
44660702
DM
11614 "discard" : {
11615 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
11616 "enum" : [
11617 "ignore",
11618 "on"
11619 ],
56122987 11620 "optional" : 1,
44660702 11621 "type" : "string"
56122987 11622 },
7aacca6f 11623 "file" : {
44660702 11624 "default_key" : 1,
7aacca6f 11625 "description" : "The drive's backing volume.",
7aacca6f
DM
11626 "format" : "pve-volume-id-or-qm-path",
11627 "format_description" : "volume",
7aacca6f 11628 "type" : "string"
56122987 11629 },
44660702
DM
11630 "format" : {
11631 "description" : "The drive's backing file's data format.",
56122987 11632 "enum" : [
44660702
DM
11633 "raw",
11634 "cow",
11635 "qcow",
11636 "qed",
11637 "qcow2",
11638 "vmdk",
11639 "cloop"
7aacca6f 11640 ],
7aacca6f
DM
11641 "optional" : 1,
11642 "type" : "string"
56122987 11643 },
44660702
DM
11644 "heads" : {
11645 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 11646 "optional" : 1,
44660702 11647 "type" : "integer"
56122987 11648 },
44660702 11649 "iops" : {
de0983cb 11650 "description" : "Maximum r/w I/O in operations per second.",
7aacca6f 11651 "format_description" : "iops",
56122987 11652 "optional" : 1,
44660702 11653 "type" : "integer"
56122987 11654 },
44660702 11655 "iops_max" : {
de0983cb 11656 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702 11657 "format_description" : "iops",
56122987 11658 "optional" : 1,
44660702 11659 "type" : "integer"
56122987 11660 },
de0983cb
DM
11661 "iops_max_length" : {
11662 "description" : "Maximum length of I/O bursts in seconds.",
11663 "format_description" : "seconds",
11664 "minimum" : 1,
11665 "optional" : 1,
11666 "type" : "integer"
11667 },
7aacca6f 11668 "iops_rd" : {
de0983cb 11669 "description" : "Maximum read I/O in operations per second.",
44660702
DM
11670 "format_description" : "iops",
11671 "optional" : 1,
11672 "type" : "integer"
7aacca6f 11673 },
de0983cb
DM
11674 "iops_rd_length" : {
11675 "description" : "Maximum length of read I/O bursts in seconds.",
11676 "format_description" : "seconds",
11677 "minimum" : 1,
11678 "optional" : 1,
11679 "type" : "integer"
11680 },
44660702 11681 "iops_rd_max" : {
de0983cb 11682 "description" : "Maximum unthrottled read I/O pool in operations per second.",
44660702 11683 "format_description" : "iops",
56122987 11684 "optional" : 1,
44660702 11685 "type" : "integer"
56122987 11686 },
44660702 11687 "iops_wr" : {
de0983cb 11688 "description" : "Maximum write I/O in operations per second.",
44660702 11689 "format_description" : "iops",
56122987 11690 "optional" : 1,
44660702 11691 "type" : "integer"
7aacca6f 11692 },
de0983cb
DM
11693 "iops_wr_length" : {
11694 "description" : "Maximum length of write I/O bursts in seconds.",
11695 "format_description" : "seconds",
11696 "minimum" : 1,
11697 "optional" : 1,
11698 "type" : "integer"
11699 },
44660702 11700 "iops_wr_max" : {
de0983cb 11701 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702 11702 "format_description" : "iops",
7aacca6f 11703 "optional" : 1,
44660702 11704 "type" : "integer"
56122987 11705 },
44660702 11706 "mbps" : {
de0983cb 11707 "description" : "Maximum r/w speed in megabytes per second.",
44660702 11708 "format_description" : "mbps",
7aacca6f 11709 "optional" : 1,
44660702 11710 "type" : "number"
56122987 11711 },
44660702 11712 "mbps_max" : {
de0983cb 11713 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
7aacca6f 11714 "format_description" : "mbps",
56122987 11715 "optional" : 1,
44660702 11716 "type" : "number"
56122987 11717 },
44660702 11718 "mbps_rd" : {
de0983cb 11719 "description" : "Maximum read speed in megabytes per second.",
44660702 11720 "format_description" : "mbps",
7aacca6f 11721 "optional" : 1,
44660702 11722 "type" : "number"
7aacca6f 11723 },
44660702 11724 "mbps_rd_max" : {
de0983cb 11725 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702 11726 "format_description" : "mbps",
56122987 11727 "optional" : 1,
44660702 11728 "type" : "number"
56122987 11729 },
44660702 11730 "mbps_wr" : {
de0983cb 11731 "description" : "Maximum write speed in megabytes per second.",
44660702 11732 "format_description" : "mbps",
7aacca6f 11733 "optional" : 1,
44660702 11734 "type" : "number"
56122987 11735 },
44660702 11736 "mbps_wr_max" : {
de0983cb 11737 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702 11738 "format_description" : "mbps",
56122987 11739 "optional" : 1,
44660702 11740 "type" : "number"
7aacca6f
DM
11741 },
11742 "media" : {
44660702
DM
11743 "default" : "disk",
11744 "description" : "The drive's media type.",
56122987 11745 "enum" : [
7aacca6f
DM
11746 "cdrom",
11747 "disk"
56122987 11748 ],
56122987 11749 "optional" : 1,
44660702 11750 "type" : "string"
56122987 11751 },
44660702
DM
11752 "model" : {
11753 "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.",
11754 "format" : "urlencoded",
11755 "format_description" : "model",
11756 "maxLength" : 120,
56122987 11757 "optional" : 1,
44660702 11758 "type" : "string"
56122987 11759 },
7aacca6f 11760 "rerror" : {
7aacca6f
DM
11761 "description" : "Read error action.",
11762 "enum" : [
11763 "ignore",
11764 "report",
11765 "stop"
44660702 11766 ],
44660702
DM
11767 "optional" : 1,
11768 "type" : "string"
56122987 11769 },
44660702
DM
11770 "secs" : {
11771 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 11772 "optional" : 1,
44660702
DM
11773 "type" : "integer"
11774 },
11775 "serial" : {
11776 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
11777 "format" : "urlencoded",
11778 "format_description" : "serial",
11779 "maxLength" : 60,
11780 "optional" : 1,
11781 "type" : "string"
11782 },
11783 "size" : {
11784 "description" : "Disk size. This is purely informational and has no effect.",
11785 "format" : "disk-size",
f004f5b9 11786 "format_description" : "DiskSize",
44660702
DM
11787 "optional" : 1,
11788 "type" : "string"
7aacca6f
DM
11789 },
11790 "snapshot" : {
44660702 11791 "description" : "Whether the drive should be included when making snapshots.",
7aacca6f 11792 "optional" : 1,
44660702 11793 "type" : "boolean"
7aacca6f 11794 },
44660702
DM
11795 "trans" : {
11796 "description" : "Force disk geometry bios translation mode.",
11797 "enum" : [
11798 "none",
11799 "lba",
11800 "auto"
11801 ],
7aacca6f 11802 "optional" : 1,
44660702
DM
11803 "type" : "string"
11804 },
11805 "volume" : {
11806 "alias" : "file"
11807 },
11808 "werror" : {
11809 "description" : "Write error action.",
11810 "enum" : [
11811 "enospc",
11812 "ignore",
11813 "report",
11814 "stop"
11815 ],
44660702
DM
11816 "optional" : 1,
11817 "type" : "string"
56122987
DM
11818 }
11819 },
56122987 11820 "optional" : 1,
4bd7df8b 11821 "type" : "string",
013dc89f 11822 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,model=<model>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
56122987 11823 },
56122987 11824 "keyboard" : {
44660702 11825 "default" : "en-us",
c2993fe5 11826 "description" : "Keybord layout for vnc server. Default is read from the '/etc/pve/datacenter.conf' configuration file.",
56122987 11827 "enum" : [
44660702
DM
11828 "de",
11829 "de-ch",
7aacca6f 11830 "da",
56122987 11831 "en-gb",
44660702
DM
11832 "en-us",
11833 "es",
11834 "fi",
11835 "fr",
11836 "fr-be",
11837 "fr-ca",
11838 "fr-ch",
11839 "hu",
7aacca6f 11840 "is",
44660702
DM
11841 "it",
11842 "ja",
11843 "lt",
56122987 11844 "mk",
7aacca6f 11845 "nl",
56122987 11846 "no",
44660702 11847 "pl",
7aacca6f 11848 "pt",
44660702
DM
11849 "pt-br",
11850 "sv",
11851 "sl",
11852 "tr"
56122987 11853 ],
44660702
DM
11854 "optional" : 1,
11855 "type" : "string"
56122987 11856 },
44660702
DM
11857 "kvm" : {
11858 "default" : 1,
11859 "description" : "Enable/disable KVM hardware virtualization.",
7aacca6f 11860 "optional" : 1,
013dc89f
DM
11861 "type" : "boolean",
11862 "typetext" : "<boolean>"
7aacca6f 11863 },
44660702
DM
11864 "localtime" : {
11865 "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.",
56122987 11866 "optional" : 1,
013dc89f
DM
11867 "type" : "boolean",
11868 "typetext" : "<boolean>"
44660702
DM
11869 },
11870 "lock" : {
11871 "description" : "Lock/unlock the VM.",
7aacca6f
DM
11872 "enum" : [
11873 "migrate",
11874 "backup",
11875 "snapshot",
11876 "rollback"
11877 ],
44660702
DM
11878 "optional" : 1,
11879 "type" : "string"
56122987 11880 },
44660702
DM
11881 "machine" : {
11882 "description" : "Specific the Qemu machine type.",
11883 "maxLength" : 40,
11884 "optional" : 1,
11885 "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)",
11886 "type" : "string"
11887 },
11888 "memory" : {
11889 "default" : 512,
11890 "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.",
11891 "minimum" : 16,
11892 "optional" : 1,
4bd7df8b 11893 "type" : "integer",
013dc89f 11894 "typetext" : "<integer> (16 - N)"
44660702
DM
11895 },
11896 "migrate_downtime" : {
11897 "default" : 0.1,
11898 "description" : "Set maximum tolerated downtime (in seconds) for migrations.",
11899 "minimum" : 0,
11900 "optional" : 1,
4bd7df8b 11901 "type" : "number",
013dc89f 11902 "typetext" : "<number> (0 - N)"
44660702
DM
11903 },
11904 "migrate_speed" : {
56122987 11905 "default" : 0,
44660702
DM
11906 "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.",
11907 "minimum" : 0,
56122987 11908 "optional" : 1,
4bd7df8b 11909 "type" : "integer",
013dc89f 11910 "typetext" : "<integer> (0 - N)"
56122987 11911 },
44660702
DM
11912 "name" : {
11913 "description" : "Set a name for the VM. Only used on the configuration web interface.",
11914 "format" : "dns-name",
11915 "optional" : 1,
013dc89f
DM
11916 "type" : "string",
11917 "typetext" : "<string>"
44660702
DM
11918 },
11919 "net[n]" : {
c2993fe5 11920 "description" : "Specify network devices.",
f004f5b9
DM
11921 "format" : {
11922 "bridge" : {
c2993fe5 11923 "description" : "Bridge to attach the network device to. The Proxmox VE standard bridge\nis called 'vmbr0'.\n\nIf you do not specify a bridge, we create a kvm user (NATed) network\ndevice, which provides DHCP and DNS services. The following addresses\nare used:\n\n 10.0.2.2 Gateway\n 10.0.2.3 DNS Server\n 10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n",
f004f5b9
DM
11924 "format_description" : "bridge",
11925 "optional" : 1,
11926 "type" : "string"
11927 },
11928 "e1000" : {
11929 "alias" : "macaddr",
11930 "keyAlias" : "model"
11931 },
11932 "e1000-82540em" : {
11933 "alias" : "macaddr",
11934 "keyAlias" : "model"
11935 },
11936 "e1000-82544gc" : {
11937 "alias" : "macaddr",
11938 "keyAlias" : "model"
11939 },
11940 "e1000-82545em" : {
11941 "alias" : "macaddr",
11942 "keyAlias" : "model"
11943 },
11944 "firewall" : {
11945 "description" : "Whether this interface should be protected by the firewall.",
11946 "optional" : 1,
11947 "type" : "boolean"
11948 },
11949 "i82551" : {
11950 "alias" : "macaddr",
11951 "keyAlias" : "model"
11952 },
11953 "i82557b" : {
11954 "alias" : "macaddr",
11955 "keyAlias" : "model"
11956 },
11957 "i82559er" : {
11958 "alias" : "macaddr",
11959 "keyAlias" : "model"
11960 },
11961 "link_down" : {
c2993fe5 11962 "description" : "Whether this interface should be disconnected (like pulling the plug).",
f004f5b9
DM
11963 "optional" : 1,
11964 "type" : "boolean"
11965 },
11966 "macaddr" : {
c2993fe5 11967 "description" : "MAC address. That address must be unique withing your network. This is automatically generated if not specified.",
f004f5b9 11968 "format_description" : "XX:XX:XX:XX:XX:XX",
f004f5b9
DM
11969 "optional" : 1,
11970 "pattern" : "(?^i:[0-9a-f]{2}(?::[0-9a-f]{2}){5})",
11971 "type" : "string"
11972 },
11973 "model" : {
11974 "default_key" : 1,
c2993fe5 11975 "description" : "Network Card Model. The 'virtio' model provides the best performance with very low CPU overhead. If your guest does not support this driver, it is usually best to use 'e1000'.",
f004f5b9
DM
11976 "enum" : [
11977 "rtl8139",
11978 "ne2k_pci",
11979 "e1000",
11980 "pcnet",
11981 "virtio",
11982 "ne2k_isa",
11983 "i82551",
11984 "i82557b",
11985 "i82559er",
11986 "vmxnet3",
11987 "e1000-82540em",
11988 "e1000-82544gc",
11989 "e1000-82545em"
11990 ],
f004f5b9
DM
11991 "type" : "string"
11992 },
11993 "ne2k_isa" : {
11994 "alias" : "macaddr",
11995 "keyAlias" : "model"
11996 },
11997 "ne2k_pci" : {
11998 "alias" : "macaddr",
11999 "keyAlias" : "model"
12000 },
12001 "pcnet" : {
12002 "alias" : "macaddr",
12003 "keyAlias" : "model"
12004 },
12005 "queues" : {
12006 "description" : "Number of packet queues to be used on the device.",
12007 "maximum" : 16,
12008 "minimum" : 0,
12009 "optional" : 1,
12010 "type" : "integer"
12011 },
12012 "rate" : {
c2993fe5 12013 "description" : "Rate limit in mbps (megabytes per second) as floating point number.",
f004f5b9
DM
12014 "minimum" : 0,
12015 "optional" : 1,
12016 "type" : "number"
12017 },
12018 "rtl8139" : {
12019 "alias" : "macaddr",
12020 "keyAlias" : "model"
12021 },
12022 "tag" : {
12023 "description" : "VLAN tag to apply to packets on this interface.",
12024 "maximum" : 4094,
c2993fe5 12025 "minimum" : 1,
f004f5b9
DM
12026 "optional" : 1,
12027 "type" : "integer"
12028 },
12029 "trunks" : {
12030 "description" : "VLAN trunks to pass through this interface.",
12031 "format_description" : "vlanid[;vlanid...]",
12032 "optional" : 1,
12033 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
12034 "type" : "string"
12035 },
12036 "virtio" : {
12037 "alias" : "macaddr",
12038 "keyAlias" : "model"
12039 },
12040 "vmxnet3" : {
12041 "alias" : "macaddr",
12042 "keyAlias" : "model"
12043 }
12044 },
44660702 12045 "optional" : 1,
4bd7df8b 12046 "type" : "string",
013dc89f 12047 "typetext" : "[model=]<enum> [,bridge=<bridge>] [,firewall=<1|0>] [,link_down=<1|0>] [,macaddr=<XX:XX:XX:XX:XX:XX>] [,queues=<integer>] [,rate=<number>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,<model>=<macaddr>]"
44660702
DM
12048 },
12049 "node" : {
12050 "description" : "The cluster node name.",
12051 "format" : "pve-node",
013dc89f
DM
12052 "type" : "string",
12053 "typetext" : "<string>"
44660702
DM
12054 },
12055 "numa" : {
7aacca6f 12056 "default" : 0,
44660702
DM
12057 "description" : "Enable/disable NUMA.",
12058 "optional" : 1,
013dc89f
DM
12059 "type" : "boolean",
12060 "typetext" : "<boolean>"
56122987 12061 },
7aacca6f 12062 "numa[n]" : {
c2993fe5 12063 "description" : "NUMA topology.",
7aacca6f 12064 "format" : {
44660702 12065 "cpus" : {
c2993fe5 12066 "description" : "CPUs accessing this NUMA node.",
44660702
DM
12067 "format_description" : "id[-id];...",
12068 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
12069 "type" : "string"
12070 },
7aacca6f 12071 "hostnodes" : {
c2993fe5 12072 "description" : "Host NUMA nodes to use.",
44660702 12073 "format_description" : "id[-id];...",
7aacca6f 12074 "optional" : 1,
44660702
DM
12075 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
12076 "type" : "string"
7aacca6f 12077 },
44660702 12078 "memory" : {
c2993fe5 12079 "description" : "Amount of memory this NUMA node provides.",
44660702
DM
12080 "optional" : 1,
12081 "type" : "number"
7aacca6f
DM
12082 },
12083 "policy" : {
c2993fe5 12084 "description" : "NUMA allocation policy.",
7aacca6f
DM
12085 "enum" : [
12086 "preferred",
12087 "bind",
12088 "interleave"
12089 ],
7aacca6f 12090 "optional" : 1,
44660702 12091 "type" : "string"
7aacca6f
DM
12092 }
12093 },
56122987 12094 "optional" : 1,
4bd7df8b
DM
12095 "type" : "string",
12096 "typetext" : "cpus=<id[-id];...> [,hostnodes=<id[-id];...>] [,memory=<number>] [,policy=<preferred|bind|interleave>]"
56122987 12097 },
44660702
DM
12098 "onboot" : {
12099 "default" : 0,
12100 "description" : "Specifies whether a VM will be started during system bootup.",
56122987 12101 "optional" : 1,
013dc89f
DM
12102 "type" : "boolean",
12103 "typetext" : "<boolean>"
56122987
DM
12104 },
12105 "ostype" : {
c2993fe5 12106 "description" : "Specify guest operating system.",
56122987
DM
12107 "enum" : [
12108 "other",
12109 "wxp",
12110 "w2k",
12111 "w2k3",
12112 "w2k8",
12113 "wvista",
12114 "win7",
12115 "win8",
32d876b5 12116 "win10",
56122987
DM
12117 "l24",
12118 "l26",
12119 "solaris"
44660702 12120 ],
56122987 12121 "optional" : 1,
c2993fe5
DM
12122 "type" : "string",
12123 "verbose_description" : "Specify guest operating system. This is used to enable special\noptimization/features for specific operating systems:\n\n[horizontal]\nother;; unspecified OS\nwxp;; Microsoft Windows XP\nw2k;; Microsoft Windows 2000\nw2k3;; Microsoft Windows 2003\nw2k8;; Microsoft Windows 2008\nwvista;; Microsoft Windows Vista\nwin7;; Microsoft Windows 7\nwin8;; Microsoft Windows 8/2012\nl24;; Linux 2.4 Kernel\nl26;; Linux 2.6/3.X Kernel\nsolaris;; Solaris/OpenSolaris/OpenIndiania kernel\n"
56122987 12124 },
44660702 12125 "parallel[n]" : {
c2993fe5 12126 "description" : "Map host parallel devices (n is 0 to 2).",
56122987 12127 "optional" : 1,
44660702 12128 "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+",
c2993fe5
DM
12129 "type" : "string",
12130 "verbose_description" : "Map host parallel devices (n is 0 to 2).\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
56122987 12131 },
44660702
DM
12132 "pool" : {
12133 "description" : "Add the VM to the specified pool.",
12134 "format" : "pve-poolid",
56122987 12135 "optional" : 1,
013dc89f
DM
12136 "type" : "string",
12137 "typetext" : "<string>"
56122987 12138 },
44660702
DM
12139 "protection" : {
12140 "default" : 0,
c2993fe5 12141 "description" : "Sets the protection flag of the VM. This will disable the remove VM and remove disk operations.",
56122987 12142 "optional" : 1,
013dc89f
DM
12143 "type" : "boolean",
12144 "typetext" : "<boolean>"
56122987 12145 },
44660702 12146 "reboot" : {
7aacca6f 12147 "default" : 1,
44660702
DM
12148 "description" : "Allow reboot. If set to '0' the VM exit on reboot.",
12149 "optional" : 1,
013dc89f
DM
12150 "type" : "boolean",
12151 "typetext" : "<boolean>"
56122987 12152 },
56122987 12153 "sata[n]" : {
44660702 12154 "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).",
56122987 12155 "format" : {
7aacca6f 12156 "aio" : {
44660702 12157 "description" : "AIO type to use.",
56122987 12158 "enum" : [
7aacca6f
DM
12159 "native",
12160 "threads"
56122987 12161 ],
7aacca6f 12162 "optional" : 1,
44660702 12163 "type" : "string"
7aacca6f
DM
12164 },
12165 "backup" : {
7aacca6f 12166 "description" : "Whether the drive should be included when making backups.",
7aacca6f 12167 "optional" : 1,
44660702 12168 "type" : "boolean"
56122987 12169 },
44660702 12170 "bps" : {
de0983cb 12171 "description" : "Maximum r/w speed in bytes per second.",
44660702 12172 "format_description" : "bps",
7aacca6f 12173 "optional" : 1,
44660702 12174 "type" : "integer"
56122987 12175 },
de0983cb
DM
12176 "bps_max_length" : {
12177 "description" : "Maximum length of I/O bursts in seconds.",
12178 "format_description" : "seconds",
12179 "minimum" : 1,
12180 "optional" : 1,
12181 "type" : "integer"
12182 },
44660702 12183 "bps_rd" : {
de0983cb 12184 "description" : "Maximum read speed in bytes per second.",
44660702 12185 "format_description" : "bps",
56122987 12186 "optional" : 1,
44660702 12187 "type" : "integer"
7aacca6f 12188 },
de0983cb
DM
12189 "bps_rd_length" : {
12190 "description" : "Maximum length of read I/O bursts in seconds.",
12191 "format_description" : "seconds",
12192 "minimum" : 1,
12193 "optional" : 1,
12194 "type" : "integer"
12195 },
44660702 12196 "bps_wr" : {
de0983cb 12197 "description" : "Maximum write speed in bytes per second.",
44660702 12198 "format_description" : "bps",
56122987 12199 "optional" : 1,
44660702 12200 "type" : "integer"
56122987 12201 },
de0983cb
DM
12202 "bps_wr_length" : {
12203 "description" : "Maximum length of write I/O bursts in seconds.",
12204 "format_description" : "seconds",
12205 "minimum" : 1,
12206 "optional" : 1,
12207 "type" : "integer"
12208 },
7aacca6f 12209 "cache" : {
7aacca6f
DM
12210 "description" : "The drive's cache mode",
12211 "enum" : [
12212 "none",
12213 "writethrough",
12214 "writeback",
12215 "unsafe",
12216 "directsync"
12217 ],
44660702
DM
12218 "optional" : 1,
12219 "type" : "string"
56122987 12220 },
44660702
DM
12221 "cyls" : {
12222 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
56122987 12223 "optional" : 1,
7aacca6f 12224 "type" : "integer"
56122987 12225 },
7aacca6f
DM
12226 "detect_zeroes" : {
12227 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
56122987 12228 "optional" : 1,
7aacca6f 12229 "type" : "boolean"
56122987 12230 },
44660702
DM
12231 "discard" : {
12232 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
12233 "enum" : [
12234 "ignore",
12235 "on"
12236 ],
56122987 12237 "optional" : 1,
44660702 12238 "type" : "string"
56122987 12239 },
44660702
DM
12240 "file" : {
12241 "default_key" : 1,
12242 "description" : "The drive's backing volume.",
12243 "format" : "pve-volume-id-or-qm-path",
12244 "format_description" : "volume",
12245 "type" : "string"
56122987
DM
12246 },
12247 "format" : {
44660702 12248 "description" : "The drive's backing file's data format.",
56122987
DM
12249 "enum" : [
12250 "raw",
12251 "cow",
12252 "qcow",
12253 "qed",
12254 "qcow2",
12255 "vmdk",
12256 "cloop"
12257 ],
56122987 12258 "optional" : 1,
44660702 12259 "type" : "string"
56122987 12260 },
7aacca6f 12261 "heads" : {
7aacca6f 12262 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
12263 "optional" : 1,
12264 "type" : "integer"
56122987 12265 },
44660702 12266 "iops" : {
de0983cb 12267 "description" : "Maximum r/w I/O in operations per second.",
44660702
DM
12268 "format_description" : "iops",
12269 "optional" : 1,
12270 "type" : "integer"
56122987 12271 },
44660702 12272 "iops_max" : {
de0983cb 12273 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702 12274 "format_description" : "iops",
56122987 12275 "optional" : 1,
44660702 12276 "type" : "integer"
56122987 12277 },
de0983cb
DM
12278 "iops_max_length" : {
12279 "description" : "Maximum length of I/O bursts in seconds.",
12280 "format_description" : "seconds",
12281 "minimum" : 1,
12282 "optional" : 1,
12283 "type" : "integer"
12284 },
44660702 12285 "iops_rd" : {
de0983cb 12286 "description" : "Maximum read I/O in operations per second.",
44660702 12287 "format_description" : "iops",
56122987 12288 "optional" : 1,
44660702 12289 "type" : "integer"
56122987 12290 },
de0983cb
DM
12291 "iops_rd_length" : {
12292 "description" : "Maximum length of read I/O bursts in seconds.",
12293 "format_description" : "seconds",
12294 "minimum" : 1,
12295 "optional" : 1,
12296 "type" : "integer"
12297 },
44660702 12298 "iops_rd_max" : {
de0983cb 12299 "description" : "Maximum unthrottled read I/O pool in operations per second.",
7aacca6f 12300 "format_description" : "iops",
56122987 12301 "optional" : 1,
44660702 12302 "type" : "integer"
56122987 12303 },
44660702 12304 "iops_wr" : {
de0983cb 12305 "description" : "Maximum write I/O in operations per second.",
44660702 12306 "format_description" : "iops",
7aacca6f 12307 "optional" : 1,
44660702 12308 "type" : "integer"
7aacca6f 12309 },
de0983cb
DM
12310 "iops_wr_length" : {
12311 "description" : "Maximum length of write I/O bursts in seconds.",
12312 "format_description" : "seconds",
12313 "minimum" : 1,
12314 "optional" : 1,
12315 "type" : "integer"
12316 },
44660702 12317 "iops_wr_max" : {
de0983cb 12318 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702 12319 "format_description" : "iops",
56122987 12320 "optional" : 1,
7aacca6f 12321 "type" : "integer"
56122987 12322 },
44660702 12323 "mbps" : {
de0983cb 12324 "description" : "Maximum r/w speed in megabytes per second.",
44660702 12325 "format_description" : "mbps",
56122987 12326 "optional" : 1,
44660702 12327 "type" : "number"
56122987 12328 },
44660702 12329 "mbps_max" : {
de0983cb 12330 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702 12331 "format_description" : "mbps",
7aacca6f 12332 "optional" : 1,
44660702 12333 "type" : "number"
7aacca6f 12334 },
44660702 12335 "mbps_rd" : {
de0983cb 12336 "description" : "Maximum read speed in megabytes per second.",
44660702 12337 "format_description" : "mbps",
7aacca6f 12338 "optional" : 1,
44660702 12339 "type" : "number"
7aacca6f 12340 },
44660702 12341 "mbps_rd_max" : {
de0983cb 12342 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702 12343 "format_description" : "mbps",
7aacca6f 12344 "optional" : 1,
44660702 12345 "type" : "number"
7aacca6f 12346 },
44660702 12347 "mbps_wr" : {
de0983cb 12348 "description" : "Maximum write speed in megabytes per second.",
44660702 12349 "format_description" : "mbps",
7aacca6f 12350 "optional" : 1,
44660702 12351 "type" : "number"
7aacca6f
DM
12352 },
12353 "mbps_wr_max" : {
de0983cb 12354 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702 12355 "format_description" : "mbps",
7aacca6f 12356 "optional" : 1,
44660702 12357 "type" : "number"
7aacca6f 12358 },
44660702
DM
12359 "media" : {
12360 "default" : "disk",
12361 "description" : "The drive's media type.",
56122987 12362 "enum" : [
44660702
DM
12363 "cdrom",
12364 "disk"
56122987 12365 ],
56122987 12366 "optional" : 1,
44660702 12367 "type" : "string"
56122987 12368 },
44660702
DM
12369 "rerror" : {
12370 "description" : "Read error action.",
7aacca6f
DM
12371 "enum" : [
12372 "ignore",
44660702
DM
12373 "report",
12374 "stop"
7aacca6f 12375 ],
56122987 12376 "optional" : 1,
44660702 12377 "type" : "string"
56122987 12378 },
44660702
DM
12379 "secs" : {
12380 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 12381 "optional" : 1,
44660702 12382 "type" : "integer"
56122987 12383 },
44660702
DM
12384 "serial" : {
12385 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
12386 "format" : "urlencoded",
12387 "format_description" : "serial",
12388 "maxLength" : 60,
12389 "optional" : 1,
12390 "type" : "string"
7aacca6f
DM
12391 },
12392 "size" : {
12393 "description" : "Disk size. This is purely informational and has no effect.",
44660702 12394 "format" : "disk-size",
f004f5b9 12395 "format_description" : "DiskSize",
56122987 12396 "optional" : 1,
44660702 12397 "type" : "string"
56122987 12398 },
44660702
DM
12399 "snapshot" : {
12400 "description" : "Whether the drive should be included when making snapshots.",
56122987 12401 "optional" : 1,
44660702 12402 "type" : "boolean"
56122987 12403 },
44660702
DM
12404 "trans" : {
12405 "description" : "Force disk geometry bios translation mode.",
56122987 12406 "enum" : [
44660702
DM
12407 "none",
12408 "lba",
12409 "auto"
7aacca6f 12410 ],
44660702
DM
12411 "optional" : 1,
12412 "type" : "string"
12413 },
12414 "volume" : {
12415 "alias" : "file"
56122987
DM
12416 },
12417 "werror" : {
56122987
DM
12418 "description" : "Write error action.",
12419 "enum" : [
12420 "enospc",
12421 "ignore",
12422 "report",
12423 "stop"
12424 ],
56122987 12425 "optional" : 1,
44660702
DM
12426 "type" : "string"
12427 }
12428 },
12429 "optional" : 1,
4bd7df8b 12430 "type" : "string",
013dc89f 12431 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
44660702
DM
12432 },
12433 "scsi[n]" : {
12434 "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).",
12435 "format" : {
12436 "aio" : {
12437 "description" : "AIO type to use.",
12438 "enum" : [
12439 "native",
12440 "threads"
12441 ],
44660702
DM
12442 "optional" : 1,
12443 "type" : "string"
56122987 12444 },
7aacca6f 12445 "backup" : {
44660702 12446 "description" : "Whether the drive should be included when making backups.",
7aacca6f 12447 "optional" : 1,
44660702 12448 "type" : "boolean"
7aacca6f 12449 },
44660702 12450 "bps" : {
de0983cb 12451 "description" : "Maximum r/w speed in bytes per second.",
44660702 12452 "format_description" : "bps",
7aacca6f 12453 "optional" : 1,
44660702 12454 "type" : "integer"
7aacca6f 12455 },
de0983cb
DM
12456 "bps_max_length" : {
12457 "description" : "Maximum length of I/O bursts in seconds.",
12458 "format_description" : "seconds",
12459 "minimum" : 1,
12460 "optional" : 1,
12461 "type" : "integer"
12462 },
44660702 12463 "bps_rd" : {
de0983cb 12464 "description" : "Maximum read speed in bytes per second.",
44660702 12465 "format_description" : "bps",
56122987 12466 "optional" : 1,
44660702 12467 "type" : "integer"
56122987 12468 },
de0983cb
DM
12469 "bps_rd_length" : {
12470 "description" : "Maximum length of read I/O bursts in seconds.",
12471 "format_description" : "seconds",
12472 "minimum" : 1,
12473 "optional" : 1,
12474 "type" : "integer"
12475 },
44660702 12476 "bps_wr" : {
de0983cb 12477 "description" : "Maximum write speed in bytes per second.",
44660702 12478 "format_description" : "bps",
7aacca6f 12479 "optional" : 1,
44660702 12480 "type" : "integer"
56122987 12481 },
de0983cb
DM
12482 "bps_wr_length" : {
12483 "description" : "Maximum length of write I/O bursts in seconds.",
12484 "format_description" : "seconds",
12485 "minimum" : 1,
12486 "optional" : 1,
12487 "type" : "integer"
12488 },
44660702
DM
12489 "cache" : {
12490 "description" : "The drive's cache mode",
7aacca6f
DM
12491 "enum" : [
12492 "none",
44660702
DM
12493 "writethrough",
12494 "writeback",
12495 "unsafe",
12496 "directsync"
7aacca6f 12497 ],
56122987 12498 "optional" : 1,
44660702 12499 "type" : "string"
56122987 12500 },
7aacca6f
DM
12501 "cyls" : {
12502 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
12503 "optional" : 1,
44660702 12504 "type" : "integer"
7aacca6f 12505 },
44660702
DM
12506 "detect_zeroes" : {
12507 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
56122987 12508 "optional" : 1,
44660702 12509 "type" : "boolean"
56122987 12510 },
44660702
DM
12511 "discard" : {
12512 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
7aacca6f 12513 "enum" : [
44660702
DM
12514 "ignore",
12515 "on"
7aacca6f 12516 ],
7aacca6f 12517 "optional" : 1,
44660702 12518 "type" : "string"
56122987
DM
12519 },
12520 "file" : {
7aacca6f
DM
12521 "default_key" : 1,
12522 "description" : "The drive's backing volume.",
44660702
DM
12523 "format" : "pve-volume-id-or-qm-path",
12524 "format_description" : "volume",
7aacca6f 12525 "type" : "string"
56122987 12526 },
7aacca6f 12527 "format" : {
44660702 12528 "description" : "The drive's backing file's data format.",
56122987 12529 "enum" : [
7aacca6f
DM
12530 "raw",
12531 "cow",
12532 "qcow",
12533 "qed",
12534 "qcow2",
12535 "vmdk",
12536 "cloop"
56122987 12537 ],
44660702
DM
12538 "optional" : 1,
12539 "type" : "string"
56122987 12540 },
44660702
DM
12541 "heads" : {
12542 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
12543 "optional" : 1,
12544 "type" : "integer"
12545 },
12546 "iops" : {
de0983cb 12547 "description" : "Maximum r/w I/O in operations per second.",
7aacca6f 12548 "format_description" : "iops",
56122987 12549 "optional" : 1,
44660702 12550 "type" : "integer"
56122987 12551 },
44660702 12552 "iops_max" : {
de0983cb 12553 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702 12554 "format_description" : "iops",
7aacca6f 12555 "optional" : 1,
44660702 12556 "type" : "integer"
56122987 12557 },
de0983cb
DM
12558 "iops_max_length" : {
12559 "description" : "Maximum length of I/O bursts in seconds.",
12560 "format_description" : "seconds",
12561 "minimum" : 1,
12562 "optional" : 1,
12563 "type" : "integer"
12564 },
44660702 12565 "iops_rd" : {
de0983cb 12566 "description" : "Maximum read I/O in operations per second.",
44660702 12567 "format_description" : "iops",
56122987 12568 "optional" : 1,
44660702 12569 "type" : "integer"
56122987 12570 },
de0983cb
DM
12571 "iops_rd_length" : {
12572 "description" : "Maximum length of read I/O bursts in seconds.",
12573 "format_description" : "seconds",
12574 "minimum" : 1,
12575 "optional" : 1,
12576 "type" : "integer"
12577 },
44660702 12578 "iops_rd_max" : {
de0983cb 12579 "description" : "Maximum unthrottled read I/O pool in operations per second.",
44660702
DM
12580 "format_description" : "iops",
12581 "optional" : 1,
12582 "type" : "integer"
56122987 12583 },
44660702 12584 "iops_wr" : {
de0983cb 12585 "description" : "Maximum write I/O in operations per second.",
44660702 12586 "format_description" : "iops",
56122987 12587 "optional" : 1,
44660702 12588 "type" : "integer"
56122987 12589 },
de0983cb
DM
12590 "iops_wr_length" : {
12591 "description" : "Maximum length of write I/O bursts in seconds.",
12592 "format_description" : "seconds",
12593 "minimum" : 1,
12594 "optional" : 1,
12595 "type" : "integer"
12596 },
44660702 12597 "iops_wr_max" : {
de0983cb 12598 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702 12599 "format_description" : "iops",
56122987 12600 "optional" : 1,
56122987
DM
12601 "type" : "integer"
12602 },
44660702
DM
12603 "iothread" : {
12604 "description" : "Whether to use iothreads for this drive",
44660702
DM
12605 "optional" : 1,
12606 "type" : "boolean"
12607 },
12608 "mbps" : {
de0983cb 12609 "description" : "Maximum r/w speed in megabytes per second.",
44660702
DM
12610 "format_description" : "mbps",
12611 "optional" : 1,
12612 "type" : "number"
12613 },
7aacca6f 12614 "mbps_max" : {
de0983cb 12615 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702 12616 "format_description" : "mbps",
56122987 12617 "optional" : 1,
44660702 12618 "type" : "number"
56122987 12619 },
44660702 12620 "mbps_rd" : {
de0983cb 12621 "description" : "Maximum read speed in megabytes per second.",
44660702
DM
12622 "format_description" : "mbps",
12623 "optional" : 1,
12624 "type" : "number"
56122987 12625 },
44660702 12626 "mbps_rd_max" : {
de0983cb 12627 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702 12628 "format_description" : "mbps",
56122987 12629 "optional" : 1,
44660702 12630 "type" : "number"
56122987 12631 },
44660702 12632 "mbps_wr" : {
de0983cb 12633 "description" : "Maximum write speed in megabytes per second.",
44660702 12634 "format_description" : "mbps",
56122987 12635 "optional" : 1,
44660702 12636 "type" : "number"
56122987 12637 },
44660702 12638 "mbps_wr_max" : {
de0983cb 12639 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702 12640 "format_description" : "mbps",
7aacca6f 12641 "optional" : 1,
44660702 12642 "type" : "number"
56122987 12643 },
7aacca6f 12644 "media" : {
44660702 12645 "default" : "disk",
7aacca6f
DM
12646 "description" : "The drive's media type.",
12647 "enum" : [
12648 "cdrom",
12649 "disk"
12650 ],
56122987 12651 "optional" : 1,
44660702 12652 "type" : "string"
56122987 12653 },
44660702
DM
12654 "queues" : {
12655 "description" : "Number of queues.",
44660702
DM
12656 "minimum" : 2,
12657 "optional" : 1,
12658 "type" : "integer"
56122987 12659 },
52e44c50
FG
12660 "scsiblock" : {
12661 "default" : 0,
12662 "description" : "whether to use scsi-block for full passthrough of host block device\n\nWARNING: can lead to I/O errors in combination with low memory or high memory fragmentation on host",
12663 "optional" : 1,
12664 "type" : "boolean"
12665 },
7aacca6f 12666 "secs" : {
7aacca6f 12667 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
12668 "optional" : 1,
12669 "type" : "integer"
12670 },
12671 "serial" : {
12672 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
12673 "format" : "urlencoded",
12674 "format_description" : "serial",
12675 "maxLength" : 60,
12676 "optional" : 1,
12677 "type" : "string"
12678 },
12679 "size" : {
12680 "description" : "Disk size. This is purely informational and has no effect.",
12681 "format" : "disk-size",
f004f5b9 12682 "format_description" : "DiskSize",
44660702
DM
12683 "optional" : 1,
12684 "type" : "string"
12685 },
12686 "snapshot" : {
12687 "description" : "Whether the drive should be included when making snapshots.",
44660702
DM
12688 "optional" : 1,
12689 "type" : "boolean"
12690 },
12691 "trans" : {
12692 "description" : "Force disk geometry bios translation mode.",
12693 "enum" : [
12694 "none",
12695 "lba",
12696 "auto"
12697 ],
44660702
DM
12698 "optional" : 1,
12699 "type" : "string"
12700 },
12701 "volume" : {
12702 "alias" : "file"
12703 },
12704 "werror" : {
12705 "description" : "Write error action.",
12706 "enum" : [
12707 "enospc",
12708 "ignore",
12709 "report",
12710 "stop"
12711 ],
44660702
DM
12712 "optional" : 1,
12713 "type" : "string"
56122987
DM
12714 }
12715 },
7aacca6f 12716 "optional" : 1,
4bd7df8b 12717 "type" : "string",
52e44c50 12718 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,queues=<integer>] [,scsiblock=<1|0>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
56122987 12719 },
44660702
DM
12720 "scsihw" : {
12721 "default" : "lsi",
c2993fe5 12722 "description" : "SCSI controller model",
44660702
DM
12723 "enum" : [
12724 "lsi",
12725 "lsi53c810",
12726 "virtio-scsi-pci",
12727 "virtio-scsi-single",
12728 "megasas",
12729 "pvscsi"
12730 ],
7aacca6f 12731 "optional" : 1,
44660702 12732 "type" : "string"
7aacca6f 12733 },
44660702 12734 "serial[n]" : {
c2993fe5 12735 "description" : "Create a serial device inside the VM (n is 0 to 3)",
44660702
DM
12736 "optional" : 1,
12737 "pattern" : "(/dev/.+|socket)",
c2993fe5 12738 "type" : "string",
57b78691 12739 "verbose_description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a\nhost serial device (i.e. /dev/ttyS0), or create a unix socket on the\nhost side (use 'qm terminal' to open a terminal connection).\n\nNOTE: If you pass through a host serial device, it is no longer possible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
44660702
DM
12740 },
12741 "shares" : {
12742 "default" : 1000,
12743 "description" : "Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning",
12744 "maximum" : 50000,
12745 "minimum" : 0,
12746 "optional" : 1,
4bd7df8b 12747 "type" : "integer",
013dc89f 12748 "typetext" : "<integer> (0 - 50000)"
44660702
DM
12749 },
12750 "smbios1" : {
12751 "description" : "Specify SMBIOS type 1 fields.",
12752 "format" : "pve-qm-smbios1",
12753 "maxLength" : 256,
7aacca6f 12754 "optional" : 1,
4bd7df8b
DM
12755 "type" : "string",
12756 "typetext" : "[family=<string>] [,manufacturer=<string>] [,product=<string>] [,serial=<string>] [,sku=<string>] [,uuid=<UUID>] [,version=<string>]"
7aacca6f
DM
12757 },
12758 "smp" : {
44660702 12759 "default" : 1,
7aacca6f 12760 "description" : "The number of CPUs. Please use option -sockets instead.",
44660702 12761 "minimum" : 1,
56122987 12762 "optional" : 1,
4bd7df8b 12763 "type" : "integer",
013dc89f 12764 "typetext" : "<integer> (1 - N)"
44660702
DM
12765 },
12766 "sockets" : {
7aacca6f 12767 "default" : 1,
44660702
DM
12768 "description" : "The number of CPU sockets.",
12769 "minimum" : 1,
12770 "optional" : 1,
4bd7df8b 12771 "type" : "integer",
013dc89f 12772 "typetext" : "<integer> (1 - N)"
7aacca6f 12773 },
44660702
DM
12774 "startdate" : {
12775 "default" : "now",
12776 "description" : "Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'.",
12777 "optional" : 1,
12778 "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)",
12779 "type" : "string",
12780 "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)"
12781 },
12782 "startup" : {
12783 "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.",
12784 "format" : "pve-startup-order",
12785 "optional" : 1,
12786 "type" : "string",
12787 "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] "
12788 },
12789 "storage" : {
12790 "description" : "Default storage.",
12791 "format" : "pve-storage-id",
7aacca6f 12792 "optional" : 1,
013dc89f
DM
12793 "type" : "string",
12794 "typetext" : "<string>"
56122987 12795 },
44660702
DM
12796 "tablet" : {
12797 "default" : 1,
c2993fe5 12798 "description" : "Enable/disable the USB tablet device.",
56122987 12799 "optional" : 1,
c2993fe5 12800 "type" : "boolean",
013dc89f 12801 "typetext" : "<boolean>",
c2993fe5 12802 "verbose_description" : "Enable/disable the USB tablet device. This device is usually needed to allow absolute mouse positioning with VNC. Else the mouse runs out of sync with normal VNC clients. If you're running lots of console-only guests on one host, you may consider disabling this to save some context switches. This is turned off by default if you use spice (-vga=qxl)."
44660702
DM
12803 },
12804 "tdf" : {
12805 "default" : 0,
12806 "description" : "Enable/disable time drift fix.",
12807 "optional" : 1,
013dc89f
DM
12808 "type" : "boolean",
12809 "typetext" : "<boolean>"
7aacca6f
DM
12810 },
12811 "template" : {
7aacca6f 12812 "default" : 0,
44660702 12813 "description" : "Enable/disable Template.",
7aacca6f 12814 "optional" : 1,
013dc89f
DM
12815 "type" : "boolean",
12816 "typetext" : "<boolean>"
7aacca6f 12817 },
44660702
DM
12818 "unique" : {
12819 "description" : "Assign a unique random ethernet address.",
7aacca6f 12820 "optional" : 1,
44660702 12821 "requires" : "archive",
013dc89f
DM
12822 "type" : "boolean",
12823 "typetext" : "<boolean>"
56122987 12824 },
44660702 12825 "unused[n]" : {
c2993fe5 12826 "description" : "Reference to unused volumes. This is used internally, and should not be modified manually.",
44660702 12827 "format" : "pve-volume-id",
7aacca6f 12828 "optional" : 1,
013dc89f
DM
12829 "type" : "string",
12830 "typetext" : "<string>"
44660702
DM
12831 },
12832 "usb[n]" : {
c2993fe5 12833 "description" : "Configure an USB device (n is 0 to 4).",
56122987 12834 "format" : {
7aacca6f
DM
12835 "host" : {
12836 "default_key" : 1,
c2993fe5 12837 "description" : "The Host USB device or port or the value 'spice'. HOSTUSBDEVICE syntax is:\n\n 'bus-port(.port)*' (decimal numbers) or\n 'vendor_id:product_id' (hexadeciaml numbers) or\n 'spice'\n\nYou can use the 'lsusb -t' command to list existing usb devices.\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nThe value 'spice' can be used to add a usb redirection devices for spice.\n",
7aacca6f 12838 "format" : "pve-qm-usb-device",
44660702
DM
12839 "format_description" : "HOSTUSBDEVICE|spice",
12840 "type" : "string"
7aacca6f 12841 },
56122987 12842 "usb3" : {
c2993fe5
DM
12843 "default" : 0,
12844 "description" : "Specifies whether if given host option is a USB3 device or port (this does currently not work reliably with spice redirection and is then ignored).",
56122987 12845 "optional" : 1,
56122987 12846 "type" : "boolean"
7aacca6f 12847 }
56122987 12848 },
56122987 12849 "optional" : 1,
4bd7df8b
DM
12850 "type" : "string",
12851 "typetext" : "[host=]<HOSTUSBDEVICE|spice> [,usb3=<1|0>]"
56122987 12852 },
44660702
DM
12853 "vcpus" : {
12854 "default" : 0,
12855 "description" : "Number of hotplugged vcpus.",
12856 "minimum" : 1,
56122987 12857 "optional" : 1,
4bd7df8b 12858 "type" : "integer",
013dc89f 12859 "typetext" : "<integer> (1 - N)"
7aacca6f 12860 },
44660702 12861 "vga" : {
c2993fe5 12862 "description" : "Select the VGA type.",
44660702
DM
12863 "enum" : [
12864 "std",
12865 "cirrus",
12866 "vmware",
12867 "qxl",
12868 "serial0",
12869 "serial1",
12870 "serial2",
12871 "serial3",
12872 "qxl2",
12873 "qxl3",
12874 "qxl4"
12875 ],
12876 "optional" : 1,
c2993fe5
DM
12877 "type" : "string",
12878 "verbose_description" : "Select the VGA type. If you want to use high resolution modes (>= 1280x1024x16) then you should use the options 'std' or 'vmware'. Default is 'std' for win8/win7/w2k8, and 'cirrus' for other OS types. The 'qxl' option enables the SPICE display sever. For win* OS you can select how many independent displays you want, Linux guests can add displays them self. You can also run without any graphic card, using a serial device as terminal."
7aacca6f 12879 },
44660702
DM
12880 "virtio[n]" : {
12881 "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).",
12882 "format" : {
12883 "aio" : {
12884 "description" : "AIO type to use.",
12885 "enum" : [
12886 "native",
12887 "threads"
12888 ],
44660702
DM
12889 "optional" : 1,
12890 "type" : "string"
12891 },
12892 "backup" : {
12893 "description" : "Whether the drive should be included when making backups.",
44660702
DM
12894 "optional" : 1,
12895 "type" : "boolean"
12896 },
12897 "bps" : {
de0983cb 12898 "description" : "Maximum r/w speed in bytes per second.",
44660702
DM
12899 "format_description" : "bps",
12900 "optional" : 1,
12901 "type" : "integer"
12902 },
de0983cb
DM
12903 "bps_max_length" : {
12904 "description" : "Maximum length of I/O bursts in seconds.",
12905 "format_description" : "seconds",
12906 "minimum" : 1,
12907 "optional" : 1,
12908 "type" : "integer"
12909 },
44660702 12910 "bps_rd" : {
de0983cb 12911 "description" : "Maximum read speed in bytes per second.",
44660702
DM
12912 "format_description" : "bps",
12913 "optional" : 1,
12914 "type" : "integer"
12915 },
de0983cb
DM
12916 "bps_rd_length" : {
12917 "description" : "Maximum length of read I/O bursts in seconds.",
12918 "format_description" : "seconds",
12919 "minimum" : 1,
12920 "optional" : 1,
12921 "type" : "integer"
12922 },
44660702 12923 "bps_wr" : {
de0983cb 12924 "description" : "Maximum write speed in bytes per second.",
44660702
DM
12925 "format_description" : "bps",
12926 "optional" : 1,
12927 "type" : "integer"
12928 },
de0983cb
DM
12929 "bps_wr_length" : {
12930 "description" : "Maximum length of write I/O bursts in seconds.",
12931 "format_description" : "seconds",
12932 "minimum" : 1,
12933 "optional" : 1,
12934 "type" : "integer"
12935 },
44660702
DM
12936 "cache" : {
12937 "description" : "The drive's cache mode",
12938 "enum" : [
12939 "none",
12940 "writethrough",
12941 "writeback",
12942 "unsafe",
12943 "directsync"
12944 ],
44660702
DM
12945 "optional" : 1,
12946 "type" : "string"
12947 },
12948 "cyls" : {
12949 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
12950 "optional" : 1,
12951 "type" : "integer"
12952 },
12953 "detect_zeroes" : {
12954 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
12955 "optional" : 1,
12956 "type" : "boolean"
12957 },
12958 "discard" : {
12959 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
12960 "enum" : [
12961 "ignore",
12962 "on"
12963 ],
44660702
DM
12964 "optional" : 1,
12965 "type" : "string"
12966 },
12967 "file" : {
12968 "default_key" : 1,
12969 "description" : "The drive's backing volume.",
12970 "format" : "pve-volume-id-or-qm-path",
12971 "format_description" : "volume",
12972 "type" : "string"
12973 },
12974 "format" : {
12975 "description" : "The drive's backing file's data format.",
12976 "enum" : [
12977 "raw",
12978 "cow",
12979 "qcow",
12980 "qed",
12981 "qcow2",
12982 "vmdk",
12983 "cloop"
12984 ],
44660702
DM
12985 "optional" : 1,
12986 "type" : "string"
12987 },
12988 "heads" : {
12989 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
12990 "optional" : 1,
12991 "type" : "integer"
12992 },
12993 "iops" : {
de0983cb 12994 "description" : "Maximum r/w I/O in operations per second.",
44660702
DM
12995 "format_description" : "iops",
12996 "optional" : 1,
12997 "type" : "integer"
12998 },
12999 "iops_max" : {
de0983cb 13000 "description" : "Maximum unthrottled r/w I/O pool in operations per second.",
44660702
DM
13001 "format_description" : "iops",
13002 "optional" : 1,
13003 "type" : "integer"
13004 },
de0983cb
DM
13005 "iops_max_length" : {
13006 "description" : "Maximum length of I/O bursts in seconds.",
13007 "format_description" : "seconds",
13008 "minimum" : 1,
13009 "optional" : 1,
13010 "type" : "integer"
13011 },
44660702 13012 "iops_rd" : {
de0983cb 13013 "description" : "Maximum read I/O in operations per second.",
44660702
DM
13014 "format_description" : "iops",
13015 "optional" : 1,
13016 "type" : "integer"
13017 },
de0983cb
DM
13018 "iops_rd_length" : {
13019 "description" : "Maximum length of read I/O bursts in seconds.",
13020 "format_description" : "seconds",
13021 "minimum" : 1,
13022 "optional" : 1,
13023 "type" : "integer"
13024 },
44660702 13025 "iops_rd_max" : {
de0983cb 13026 "description" : "Maximum unthrottled read I/O pool in operations per second.",
44660702
DM
13027 "format_description" : "iops",
13028 "optional" : 1,
13029 "type" : "integer"
13030 },
13031 "iops_wr" : {
de0983cb 13032 "description" : "Maximum write I/O in operations per second.",
44660702
DM
13033 "format_description" : "iops",
13034 "optional" : 1,
13035 "type" : "integer"
13036 },
de0983cb
DM
13037 "iops_wr_length" : {
13038 "description" : "Maximum length of write I/O bursts in seconds.",
13039 "format_description" : "seconds",
13040 "minimum" : 1,
13041 "optional" : 1,
13042 "type" : "integer"
13043 },
44660702 13044 "iops_wr_max" : {
de0983cb 13045 "description" : "Maximum unthrottled write I/O pool in operations per second.",
44660702
DM
13046 "format_description" : "iops",
13047 "optional" : 1,
13048 "type" : "integer"
13049 },
13050 "iothread" : {
13051 "description" : "Whether to use iothreads for this drive",
44660702
DM
13052 "optional" : 1,
13053 "type" : "boolean"
13054 },
13055 "mbps" : {
de0983cb 13056 "description" : "Maximum r/w speed in megabytes per second.",
44660702
DM
13057 "format_description" : "mbps",
13058 "optional" : 1,
13059 "type" : "number"
13060 },
13061 "mbps_max" : {
de0983cb 13062 "description" : "Maximum unthrottled r/w pool in megabytes per second.",
44660702
DM
13063 "format_description" : "mbps",
13064 "optional" : 1,
13065 "type" : "number"
13066 },
13067 "mbps_rd" : {
de0983cb 13068 "description" : "Maximum read speed in megabytes per second.",
44660702
DM
13069 "format_description" : "mbps",
13070 "optional" : 1,
13071 "type" : "number"
13072 },
13073 "mbps_rd_max" : {
de0983cb 13074 "description" : "Maximum unthrottled read pool in megabytes per second.",
44660702
DM
13075 "format_description" : "mbps",
13076 "optional" : 1,
13077 "type" : "number"
13078 },
13079 "mbps_wr" : {
de0983cb 13080 "description" : "Maximum write speed in megabytes per second.",
44660702
DM
13081 "format_description" : "mbps",
13082 "optional" : 1,
13083 "type" : "number"
13084 },
13085 "mbps_wr_max" : {
de0983cb 13086 "description" : "Maximum unthrottled write pool in megabytes per second.",
44660702
DM
13087 "format_description" : "mbps",
13088 "optional" : 1,
13089 "type" : "number"
13090 },
13091 "media" : {
13092 "default" : "disk",
13093 "description" : "The drive's media type.",
13094 "enum" : [
13095 "cdrom",
13096 "disk"
13097 ],
44660702
DM
13098 "optional" : 1,
13099 "type" : "string"
13100 },
13101 "rerror" : {
13102 "description" : "Read error action.",
13103 "enum" : [
13104 "ignore",
13105 "report",
13106 "stop"
13107 ],
44660702
DM
13108 "optional" : 1,
13109 "type" : "string"
13110 },
13111 "secs" : {
13112 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
13113 "optional" : 1,
13114 "type" : "integer"
13115 },
13116 "serial" : {
13117 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
13118 "format" : "urlencoded",
13119 "format_description" : "serial",
13120 "maxLength" : 60,
13121 "optional" : 1,
13122 "type" : "string"
13123 },
13124 "size" : {
13125 "description" : "Disk size. This is purely informational and has no effect.",
13126 "format" : "disk-size",
f004f5b9 13127 "format_description" : "DiskSize",
44660702
DM
13128 "optional" : 1,
13129 "type" : "string"
13130 },
13131 "snapshot" : {
13132 "description" : "Whether the drive should be included when making snapshots.",
44660702
DM
13133 "optional" : 1,
13134 "type" : "boolean"
13135 },
13136 "trans" : {
13137 "description" : "Force disk geometry bios translation mode.",
13138 "enum" : [
13139 "none",
13140 "lba",
13141 "auto"
13142 ],
44660702
DM
13143 "optional" : 1,
13144 "type" : "string"
13145 },
13146 "volume" : {
13147 "alias" : "file"
13148 },
13149 "werror" : {
13150 "description" : "Write error action.",
13151 "enum" : [
13152 "enospc",
13153 "ignore",
13154 "report",
13155 "stop"
13156 ],
44660702
DM
13157 "optional" : 1,
13158 "type" : "string"
13159 }
13160 },
13161 "optional" : 1,
4bd7df8b 13162 "type" : "string",
013dc89f 13163 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_length=<seconds>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_length=<seconds>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]"
7aacca6f 13164 },
44660702
DM
13165 "vmid" : {
13166 "description" : "The (unique) ID of the VM.",
13167 "format" : "pve-vmid",
13168 "minimum" : 1,
4bd7df8b 13169 "type" : "integer",
013dc89f 13170 "typetext" : "<integer> (1 - N)"
44660702
DM
13171 },
13172 "watchdog" : {
c2993fe5 13173 "description" : "Create a virtual hardware watchdog device.",
44660702 13174 "format" : "pve-qm-watchdog",
7aacca6f 13175 "optional" : 1,
c2993fe5 13176 "type" : "string",
013dc89f 13177 "typetext" : "[[model=]<i6300esb|ib700>] [,action=<enum>]",
c2993fe5 13178 "verbose_description" : "Create a virtual hardware watchdog device. Once enabled (by a guest action), the watchdog must be periodically polled by an agent inside the guest or else the watchdog will reset the guest (or execute the respective action specified)"
56122987 13179 }
44660702 13180 }
56122987 13181 },
56122987 13182 "permissions" : {
44660702
DM
13183 "description" : "You need 'VM.Allocate' permissions on /vms/{vmid} or on the VM pool /pool/{pool}. For restore (option 'archive'), it is enough if the user has 'VM.Backup' permission and the VM already exists. If you create disks you need 'Datastore.AllocateSpace' on any used storage.",
13184 "user" : "all"
56122987 13185 },
44660702
DM
13186 "protected" : 1,
13187 "proxyto" : "node",
56122987 13188 "returns" : {
44660702 13189 "type" : "string"
7aacca6f 13190 }
56122987 13191 }
7aacca6f 13192 },
44660702 13193 "leaf" : 0,
7aacca6f 13194 "path" : "/nodes/{node}/qemu",
44660702 13195 "text" : "qemu"
56122987
DM
13196 },
13197 {
13198 "children" : [
13199 {
56122987
DM
13200 "children" : [
13201 {
56122987 13202 "info" : {
44660702
DM
13203 "GET" : {
13204 "description" : "Get container configuration.",
13205 "method" : "GET",
13206 "name" : "vm_config",
13207 "parameters" : {
13208 "additionalProperties" : 0,
13209 "properties" : {
13210 "node" : {
13211 "description" : "The cluster node name.",
13212 "format" : "pve-node",
013dc89f
DM
13213 "type" : "string",
13214 "typetext" : "<string>"
44660702
DM
13215 },
13216 "vmid" : {
13217 "description" : "The (unique) ID of the VM.",
13218 "format" : "pve-vmid",
13219 "minimum" : 1,
4bd7df8b 13220 "type" : "integer",
013dc89f 13221 "typetext" : "<integer> (1 - N)"
44660702
DM
13222 }
13223 }
13224 },
13225 "permissions" : {
13226 "check" : [
13227 "perm",
13228 "/vms/{vmid}",
13229 [
13230 "VM.Audit"
13231 ]
13232 ]
13233 },
13234 "proxyto" : "node",
13235 "returns" : {
13236 "properties" : {
13237 "digest" : {
13238 "description" : "SHA1 digest of configuration file. This can be used to prevent concurrent modifications.",
13239 "type" : "string"
13240 }
13241 },
13242 "type" : "object"
13243 }
13244 },
56122987 13245 "PUT" : {
44660702
DM
13246 "description" : "Set container options.",
13247 "method" : "PUT",
13248 "name" : "update_vm",
56122987 13249 "parameters" : {
44660702 13250 "additionalProperties" : 0,
56122987 13251 "properties" : {
44660702
DM
13252 "arch" : {
13253 "default" : "amd64",
13254 "description" : "OS architecture type.",
13255 "enum" : [
13256 "amd64",
13257 "i386"
13258 ],
7aacca6f 13259 "optional" : 1,
44660702
DM
13260 "type" : "string"
13261 },
13262 "cmode" : {
7aacca6f 13263 "default" : "tty",
44660702 13264 "description" : "Console mode. By default, the console command tries to open a connection to one of the available tty devices. By setting cmode to 'console' it tries to attach to /dev/console instead. If you set cmode to 'shell', it simply invokes a shell inside the container (no login).",
7aacca6f
DM
13265 "enum" : [
13266 "shell",
13267 "console",
13268 "tty"
13269 ],
44660702
DM
13270 "optional" : 1,
13271 "type" : "string"
7aacca6f 13272 },
44660702
DM
13273 "console" : {
13274 "default" : 1,
13275 "description" : "Attach a console device (/dev/console) to the container.",
7aacca6f 13276 "optional" : 1,
013dc89f
DM
13277 "type" : "boolean",
13278 "typetext" : "<boolean>"
7aacca6f 13279 },
de0983cb
DM
13280 "cores" : {
13281 "description" : "The number of cores assigned to the container. A container can use all available cores by default.",
13282 "maximum" : 128,
13283 "minimum" : 1,
13284 "optional" : 1,
13285 "type" : "integer",
013dc89f 13286 "typetext" : "<integer> (1 - 128)"
de0983cb 13287 },
44660702
DM
13288 "cpulimit" : {
13289 "default" : 0,
13290 "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has a total of '2' CPU time. Value '0' indicates no CPU limit.",
13291 "maximum" : 128,
7aacca6f 13292 "minimum" : 0,
7aacca6f 13293 "optional" : 1,
4bd7df8b 13294 "type" : "number",
013dc89f 13295 "typetext" : "<number> (0 - 128)"
7aacca6f 13296 },
44660702
DM
13297 "cpuunits" : {
13298 "default" : 1024,
13299 "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to the weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0.",
13300 "maximum" : 500000,
13301 "minimum" : 0,
13302 "optional" : 1,
4bd7df8b 13303 "type" : "integer",
013dc89f 13304 "typetext" : "<integer> (0 - 500000)"
7aacca6f 13305 },
44660702
DM
13306 "delete" : {
13307 "description" : "A list of settings you want to delete.",
13308 "format" : "pve-configid-list",
7aacca6f 13309 "optional" : 1,
013dc89f
DM
13310 "type" : "string",
13311 "typetext" : "<string>"
7aacca6f 13312 },
44660702
DM
13313 "description" : {
13314 "description" : "Container description. Only used on the configuration web interface.",
7aacca6f 13315 "optional" : 1,
013dc89f
DM
13316 "type" : "string",
13317 "typetext" : "<string>"
7aacca6f 13318 },
44660702
DM
13319 "digest" : {
13320 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
13321 "maxLength" : 40,
7aacca6f 13322 "optional" : 1,
013dc89f
DM
13323 "type" : "string",
13324 "typetext" : "<string>"
7aacca6f 13325 },
44660702
DM
13326 "hostname" : {
13327 "description" : "Set a host name for the container.",
13328 "format" : "dns-name",
13329 "maxLength" : 255,
56122987 13330 "optional" : 1,
013dc89f
DM
13331 "type" : "string",
13332 "typetext" : "<string>"
44660702
DM
13333 },
13334 "lock" : {
13335 "description" : "Lock/unlock the VM.",
13336 "enum" : [
13337 "migrate",
13338 "backup",
13339 "snapshot",
13340 "rollback"
13341 ],
13342 "optional" : 1,
13343 "type" : "string"
13344 },
13345 "memory" : {
13346 "default" : 512,
13347 "description" : "Amount of RAM for the VM in MB.",
13348 "minimum" : 16,
13349 "optional" : 1,
4bd7df8b 13350 "type" : "integer",
013dc89f 13351 "typetext" : "<integer> (16 - N)"
7aacca6f
DM
13352 },
13353 "mp[n]" : {
c2993fe5 13354 "description" : "Use volume as container mount point.",
7aacca6f 13355 "format" : {
7aacca6f
DM
13356 "acl" : {
13357 "description" : "Explicitly enable or disable ACL support.",
7aacca6f 13358 "optional" : 1,
44660702 13359 "type" : "boolean"
7aacca6f
DM
13360 },
13361 "backup" : {
de0983cb 13362 "description" : "Whether to include the mount point in backups.",
7aacca6f 13363 "optional" : 1,
4bd7df8b 13364 "type" : "boolean",
de0983cb 13365 "verbose_description" : "Whether to include the mount point in backups (only used for volume mount points)."
7aacca6f
DM
13366 },
13367 "mp" : {
de0983cb 13368 "description" : "Path to the mount point as seen from inside the container (must not contain symlinks).",
7aacca6f 13369 "format" : "pve-lxc-mp-string",
44660702 13370 "format_description" : "Path",
4bd7df8b 13371 "type" : "string",
de0983cb 13372 "verbose_description" : "Path to the mount point as seen from inside the container.\n\nNOTE: Must not contain any symlinks for security reasons."
44660702
DM
13373 },
13374 "quota" : {
13375 "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)",
44660702
DM
13376 "optional" : 1,
13377 "type" : "boolean"
13378 },
13379 "ro" : {
de0983cb 13380 "description" : "Read-only mount point",
44660702
DM
13381 "optional" : 1,
13382 "type" : "boolean"
13383 },
de0983cb
DM
13384 "shared" : {
13385 "default" : 0,
13386 "description" : "Mark this non-volume mount point as available on multiple nodes (see 'nodes')",
13387 "optional" : 1,
13388 "type" : "boolean",
13389 "verbose_description" : "Mark this non-volume mount point as available on all nodes.\n\nWARNING: This option does not share the mount point automatically, it assumes it is shared already!"
13390 },
44660702
DM
13391 "size" : {
13392 "description" : "Volume size (read only value).",
13393 "format" : "disk-size",
13394 "format_description" : "DiskSize",
13395 "optional" : 1,
13396 "type" : "string"
13397 },
13398 "volume" : {
13399 "default_key" : 1,
13400 "description" : "Volume, device or directory to mount into the container.",
13401 "format" : "pve-lxc-mp-string",
13402 "format_description" : "volume",
13403 "type" : "string"
13404 }
13405 },
7aacca6f 13406 "optional" : 1,
4bd7df8b 13407 "type" : "string",
de0983cb 13408 "typetext" : "[volume=]<volume> ,mp=<Path> [,acl=<1|0>] [,backup=<1|0>] [,quota=<1|0>] [,ro=<1|0>] [,shared=<1|0>] [,size=<DiskSize>]"
56122987 13409 },
44660702
DM
13410 "nameserver" : {
13411 "description" : "Sets DNS server IP address for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.",
13412 "format" : "address-list",
56122987 13413 "optional" : 1,
013dc89f
DM
13414 "type" : "string",
13415 "typetext" : "<string>"
56122987
DM
13416 },
13417 "net[n]" : {
44660702 13418 "description" : "Specifies network interfaces for the container.",
56122987 13419 "format" : {
44660702
DM
13420 "bridge" : {
13421 "description" : "Bridge to attach the network device to.",
f004f5b9 13422 "format_description" : "bridge",
56122987 13423 "optional" : 1,
44660702
DM
13424 "pattern" : "[-_.\\w\\d]+",
13425 "type" : "string"
56122987 13426 },
44660702
DM
13427 "firewall" : {
13428 "description" : "Controls whether this interface's firewall rules should be used.",
56122987 13429 "optional" : 1,
44660702 13430 "type" : "boolean"
56122987 13431 },
44660702
DM
13432 "gw" : {
13433 "description" : "Default gateway for IPv4 traffic.",
13434 "format" : "ipv4",
13435 "format_description" : "GatewayIPv4",
56122987 13436 "optional" : 1,
44660702 13437 "type" : "string"
56122987
DM
13438 },
13439 "gw6" : {
7aacca6f 13440 "description" : "Default gateway for IPv6 traffic.",
44660702
DM
13441 "format" : "ipv6",
13442 "format_description" : "GatewayIPv6",
7aacca6f 13443 "optional" : 1,
56122987
DM
13444 "type" : "string"
13445 },
44660702 13446 "hwaddr" : {
f004f5b9
DM
13447 "description" : "The interface MAC address. This is dynamically allocated by default, but you can set that statically if needed, for example to always have the same link-local IPv6 address. (lxc.network.hwaddr)",
13448 "format_description" : "XX:XX:XX:XX:XX:XX",
44660702
DM
13449 "optional" : 1,
13450 "pattern" : "(?^i:(?:[a-f0-9]{2}:){5}[a-f0-9]{2})",
13451 "type" : "string"
13452 },
13453 "ip" : {
13454 "description" : "IPv4 address in CIDR format.",
13455 "format" : "pve-ipv4-config",
13456 "format_description" : "IPv4Format/CIDR",
56122987 13457 "optional" : 1,
44660702 13458 "type" : "string"
56122987 13459 },
7aacca6f 13460 "ip6" : {
7aacca6f
DM
13461 "description" : "IPv6 address in CIDR format.",
13462 "format" : "pve-ipv6-config",
44660702 13463 "format_description" : "IPv6Format/CIDR",
7aacca6f 13464 "optional" : 1,
44660702 13465 "type" : "string"
56122987 13466 },
44660702
DM
13467 "mtu" : {
13468 "description" : "Maximum transfer unit of the interface. (lxc.network.mtu)",
44660702 13469 "minimum" : 64,
56122987 13470 "optional" : 1,
44660702 13471 "type" : "integer"
56122987
DM
13472 },
13473 "name" : {
44660702 13474 "description" : "Name of the network device as seen from inside the container. (lxc.network.name)",
f004f5b9 13475 "format_description" : "string",
56122987 13476 "pattern" : "[-_.\\w\\d]+",
44660702 13477 "type" : "string"
56122987 13478 },
44660702
DM
13479 "rate" : {
13480 "description" : "Apply rate limiting to the interface",
13481 "format_description" : "mbps",
56122987 13482 "optional" : 1,
44660702 13483 "type" : "number"
7aacca6f 13484 },
44660702
DM
13485 "tag" : {
13486 "description" : "VLAN tag for this interface.",
4bd7df8b
DM
13487 "maximum" : 4094,
13488 "minimum" : 1,
56122987 13489 "optional" : 1,
7aacca6f 13490 "type" : "integer"
56122987 13491 },
44660702
DM
13492 "trunks" : {
13493 "description" : "VLAN ids to pass through the interface",
13494 "format_description" : "vlanid[;vlanid...]",
13495 "optional" : 1,
13496 "pattern" : "(?^:\\d+(?:;\\d+)*)",
13497 "type" : "string"
13498 },
13499 "type" : {
13500 "description" : "Network interface type.",
13501 "enum" : [
13502 "veth"
13503 ],
56122987 13504 "optional" : 1,
44660702 13505 "type" : "string"
56122987
DM
13506 }
13507 },
7aacca6f 13508 "optional" : 1,
4bd7df8b
DM
13509 "type" : "string",
13510 "typetext" : "name=<string> [,bridge=<bridge>] [,firewall=<1|0>] [,gw=<GatewayIPv4>] [,gw6=<GatewayIPv6>] [,hwaddr=<XX:XX:XX:XX:XX:XX>] [,ip=<IPv4Format/CIDR>] [,ip6=<IPv6Format/CIDR>] [,mtu=<integer>] [,rate=<mbps>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,type=<veth>]"
56122987 13511 },
44660702
DM
13512 "node" : {
13513 "description" : "The cluster node name.",
13514 "format" : "pve-node",
013dc89f
DM
13515 "type" : "string",
13516 "typetext" : "<string>"
56122987 13517 },
44660702
DM
13518 "onboot" : {
13519 "default" : 0,
13520 "description" : "Specifies whether a VM will be started during system bootup.",
56122987 13521 "optional" : 1,
013dc89f
DM
13522 "type" : "boolean",
13523 "typetext" : "<boolean>"
56122987 13524 },
44660702
DM
13525 "ostype" : {
13526 "description" : "OS type. This is used to setup configuration inside the container, and corresponds to lxc setup scripts in /usr/share/lxc/config/<ostype>.common.conf. Value 'unmanaged' can be used to skip and OS specific setup.",
13527 "enum" : [
13528 "debian",
13529 "ubuntu",
13530 "centos",
13531 "fedora",
13532 "opensuse",
13533 "archlinux",
13534 "alpine",
57b78691 13535 "gentoo",
44660702
DM
13536 "unmanaged"
13537 ],
56122987 13538 "optional" : 1,
44660702 13539 "type" : "string"
56122987 13540 },
44660702
DM
13541 "protection" : {
13542 "default" : 0,
13543 "description" : "Sets the protection flag of the container. This will prevent the CT or CT's disk remove/update operation.",
56122987 13544 "optional" : 1,
013dc89f
DM
13545 "type" : "boolean",
13546 "typetext" : "<boolean>"
56122987 13547 },
7aacca6f
DM
13548 "rootfs" : {
13549 "description" : "Use volume as container root.",
56122987
DM
13550 "format" : {
13551 "acl" : {
44660702 13552 "description" : "Explicitly enable or disable ACL support.",
7aacca6f
DM
13553 "optional" : 1,
13554 "type" : "boolean"
56122987 13555 },
44660702
DM
13556 "quota" : {
13557 "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)",
44660702
DM
13558 "optional" : 1,
13559 "type" : "boolean"
13560 },
13561 "ro" : {
de0983cb 13562 "description" : "Read-only mount point",
56122987 13563 "optional" : 1,
44660702
DM
13564 "type" : "boolean"
13565 },
de0983cb
DM
13566 "shared" : {
13567 "default" : 0,
13568 "description" : "Mark this non-volume mount point as available on multiple nodes (see 'nodes')",
13569 "optional" : 1,
13570 "type" : "boolean",
13571 "verbose_description" : "Mark this non-volume mount point as available on all nodes.\n\nWARNING: This option does not share the mount point automatically, it assumes it is shared already!"
13572 },
44660702 13573 "size" : {
7aacca6f 13574 "description" : "Volume size (read only value).",
44660702 13575 "format" : "disk-size",
56122987 13576 "format_description" : "DiskSize",
56122987 13577 "optional" : 1,
44660702 13578 "type" : "string"
7aacca6f
DM
13579 },
13580 "volume" : {
7aacca6f
DM
13581 "default_key" : 1,
13582 "description" : "Volume, device or directory to mount into the container.",
44660702
DM
13583 "format" : "pve-lxc-mp-string",
13584 "format_description" : "volume",
7aacca6f 13585 "type" : "string"
56122987 13586 }
44660702
DM
13587 },
13588 "optional" : 1,
4bd7df8b 13589 "type" : "string",
de0983cb 13590 "typetext" : "[volume=]<volume> [,acl=<1|0>] [,quota=<1|0>] [,ro=<1|0>] [,shared=<1|0>] [,size=<DiskSize>]"
44660702
DM
13591 },
13592 "searchdomain" : {
13593 "description" : "Sets DNS search domains for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.",
13594 "format" : "dns-name-list",
13595 "optional" : 1,
013dc89f
DM
13596 "type" : "string",
13597 "typetext" : "<string>"
44660702
DM
13598 },
13599 "startup" : {
13600 "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.",
13601 "format" : "pve-startup-order",
13602 "optional" : 1,
13603 "type" : "string",
13604 "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] "
13605 },
13606 "swap" : {
13607 "default" : 512,
13608 "description" : "Amount of SWAP for the VM in MB.",
13609 "minimum" : 0,
13610 "optional" : 1,
4bd7df8b 13611 "type" : "integer",
013dc89f 13612 "typetext" : "<integer> (0 - N)"
56122987 13613 },
56122987 13614 "template" : {
44660702 13615 "default" : 0,
7aacca6f 13616 "description" : "Enable/disable Template.",
56122987 13617 "optional" : 1,
013dc89f
DM
13618 "type" : "boolean",
13619 "typetext" : "<boolean>"
56122987 13620 },
44660702
DM
13621 "tty" : {
13622 "default" : 2,
13623 "description" : "Specify the number of tty available to the container",
13624 "maximum" : 6,
13625 "minimum" : 0,
13626 "optional" : 1,
4bd7df8b 13627 "type" : "integer",
013dc89f 13628 "typetext" : "<integer> (0 - 6)"
56122987 13629 },
44660702
DM
13630 "unprivileged" : {
13631 "default" : 0,
13632 "description" : "Makes the container run as unprivileged user. (Should not be modified manually.)",
56122987 13633 "optional" : 1,
013dc89f
DM
13634 "type" : "boolean",
13635 "typetext" : "<boolean>"
56122987 13636 },
44660702 13637 "unused[n]" : {
c2993fe5 13638 "description" : "Reference to unused volumes. This is used internally, and should not be modified manually.",
44660702 13639 "format" : "pve-volume-id",
56122987 13640 "optional" : 1,
013dc89f
DM
13641 "type" : "string",
13642 "typetext" : "<string>"
44660702
DM
13643 },
13644 "vmid" : {
13645 "description" : "The (unique) ID of the VM.",
13646 "format" : "pve-vmid",
13647 "minimum" : 1,
4bd7df8b 13648 "type" : "integer",
013dc89f 13649 "typetext" : "<integer> (1 - N)"
56122987 13650 }
44660702 13651 }
56122987 13652 },
56122987
DM
13653 "permissions" : {
13654 "check" : [
13655 "perm",
13656 "/vms/{vmid}",
13657 [
13658 "VM.Config.Disk",
13659 "VM.Config.CPU",
13660 "VM.Config.Memory",
13661 "VM.Config.Network",
13662 "VM.Config.Options"
13663 ],
13664 "any",
13665 1
52e44c50
FG
13666 ],
13667 "description" : "non-volume mount points in rootfs and mp[n] are restricted to root@pam"
56122987 13668 },
44660702
DM
13669 "protected" : 1,
13670 "proxyto" : "node",
56122987
DM
13671 "returns" : {
13672 "type" : "null"
7aacca6f 13673 }
56122987 13674 }
7aacca6f 13675 },
44660702 13676 "leaf" : 1,
7aacca6f 13677 "path" : "/nodes/{node}/lxc/{vmid}/config",
44660702 13678 "text" : "config"
56122987
DM
13679 },
13680 {
56122987
DM
13681 "children" : [
13682 {
13683 "info" : {
13684 "GET" : {
44660702 13685 "description" : "Get virtual machine status.",
7aacca6f 13686 "method" : "GET",
44660702 13687 "name" : "vm_status",
56122987 13688 "parameters" : {
44660702 13689 "additionalProperties" : 0,
56122987 13690 "properties" : {
56122987 13691 "node" : {
44660702 13692 "description" : "The cluster node name.",
56122987 13693 "format" : "pve-node",
013dc89f
DM
13694 "type" : "string",
13695 "typetext" : "<string>"
7aacca6f
DM
13696 },
13697 "vmid" : {
13698 "description" : "The (unique) ID of the VM.",
44660702 13699 "format" : "pve-vmid",
7aacca6f 13700 "minimum" : 1,
4bd7df8b 13701 "type" : "integer",
013dc89f 13702 "typetext" : "<integer> (1 - N)"
56122987 13703 }
44660702 13704 }
7aacca6f
DM
13705 },
13706 "permissions" : {
13707 "check" : [
13708 "perm",
13709 "/vms/{vmid}",
13710 [
13711 "VM.Audit"
13712 ]
13713 ]
13714 },
44660702 13715 "protected" : 1,
7aacca6f 13716 "proxyto" : "node",
44660702
DM
13717 "returns" : {
13718 "type" : "object"
13719 }
56122987
DM
13720 }
13721 },
44660702
DM
13722 "leaf" : 1,
13723 "path" : "/nodes/{node}/lxc/{vmid}/status/current",
56122987
DM
13724 "text" : "current"
13725 },
13726 {
56122987
DM
13727 "info" : {
13728 "POST" : {
7aacca6f 13729 "description" : "Start the container.",
44660702 13730 "method" : "POST",
7aacca6f 13731 "name" : "vm_start",
56122987
DM
13732 "parameters" : {
13733 "additionalProperties" : 0,
13734 "properties" : {
56122987 13735 "node" : {
7aacca6f 13736 "description" : "The cluster node name.",
44660702 13737 "format" : "pve-node",
013dc89f
DM
13738 "type" : "string",
13739 "typetext" : "<string>"
56122987 13740 },
7aacca6f 13741 "skiplock" : {
44660702 13742 "description" : "Ignore locks - only root is allowed to use this option.",
7aacca6f 13743 "optional" : 1,
013dc89f
DM
13744 "type" : "boolean",
13745 "typetext" : "<boolean>"
7aacca6f 13746 },
56122987 13747 "vmid" : {
7aacca6f 13748 "description" : "The (unique) ID of the VM.",
44660702 13749 "format" : "pve-vmid",
56122987 13750 "minimum" : 1,
4bd7df8b 13751 "type" : "integer",
013dc89f 13752 "typetext" : "<integer> (1 - N)"
56122987
DM
13753 }
13754 }
13755 },
13756 "permissions" : {
13757 "check" : [
13758 "perm",
13759 "/vms/{vmid}",
13760 [
13761 "VM.PowerMgmt"
13762 ]
13763 ]
13764 },
44660702 13765 "protected" : 1,
7aacca6f 13766 "proxyto" : "node",
44660702
DM
13767 "returns" : {
13768 "type" : "string"
13769 }
13770 }
13771 },
13772 "leaf" : 1,
13773 "path" : "/nodes/{node}/lxc/{vmid}/status/start",
13774 "text" : "start"
13775 },
13776 {
13777 "info" : {
13778 "POST" : {
13779 "description" : "Stop the container. This will abruptly stop all processes running in the container.",
7aacca6f
DM
13780 "method" : "POST",
13781 "name" : "vm_stop",
13782 "parameters" : {
44660702 13783 "additionalProperties" : 0,
7aacca6f 13784 "properties" : {
44660702
DM
13785 "node" : {
13786 "description" : "The cluster node name.",
13787 "format" : "pve-node",
013dc89f
DM
13788 "type" : "string",
13789 "typetext" : "<string>"
44660702 13790 },
7aacca6f
DM
13791 "skiplock" : {
13792 "description" : "Ignore locks - only root is allowed to use this option.",
44660702 13793 "optional" : 1,
013dc89f
DM
13794 "type" : "boolean",
13795 "typetext" : "<boolean>"
7aacca6f
DM
13796 },
13797 "vmid" : {
44660702 13798 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
13799 "format" : "pve-vmid",
13800 "minimum" : 1,
4bd7df8b 13801 "type" : "integer",
013dc89f 13802 "typetext" : "<integer> (1 - N)"
7aacca6f 13803 }
44660702
DM
13804 }
13805 },
13806 "permissions" : {
13807 "check" : [
13808 "perm",
13809 "/vms/{vmid}",
13810 [
13811 "VM.PowerMgmt"
13812 ]
13813 ]
7aacca6f 13814 },
44660702
DM
13815 "protected" : 1,
13816 "proxyto" : "node",
13817 "returns" : {
13818 "type" : "string"
13819 }
56122987 13820 }
7aacca6f 13821 },
7aacca6f 13822 "leaf" : 1,
44660702
DM
13823 "path" : "/nodes/{node}/lxc/{vmid}/status/stop",
13824 "text" : "stop"
56122987
DM
13825 },
13826 {
56122987
DM
13827 "info" : {
13828 "POST" : {
44660702
DM
13829 "description" : "Shutdown the container. This will trigger a clean shutdown of the container, see lxc-stop(1) for details.",
13830 "method" : "POST",
7aacca6f 13831 "name" : "vm_shutdown",
56122987 13832 "parameters" : {
44660702 13833 "additionalProperties" : 0,
56122987 13834 "properties" : {
7aacca6f 13835 "forceStop" : {
44660702 13836 "default" : 0,
7aacca6f
DM
13837 "description" : "Make sure the Container stops.",
13838 "optional" : 1,
013dc89f
DM
13839 "type" : "boolean",
13840 "typetext" : "<boolean>"
44660702
DM
13841 },
13842 "node" : {
13843 "description" : "The cluster node name.",
13844 "format" : "pve-node",
013dc89f
DM
13845 "type" : "string",
13846 "typetext" : "<string>"
7aacca6f
DM
13847 },
13848 "timeout" : {
7aacca6f 13849 "default" : 60,
44660702
DM
13850 "description" : "Wait maximal timeout seconds.",
13851 "minimum" : 0,
56122987 13852 "optional" : 1,
4bd7df8b 13853 "type" : "integer",
013dc89f 13854 "typetext" : "<integer> (0 - N)"
56122987
DM
13855 },
13856 "vmid" : {
7aacca6f 13857 "description" : "The (unique) ID of the VM.",
44660702
DM
13858 "format" : "pve-vmid",
13859 "minimum" : 1,
4bd7df8b 13860 "type" : "integer",
013dc89f 13861 "typetext" : "<integer> (1 - N)"
56122987 13862 }
44660702 13863 }
56122987
DM
13864 },
13865 "permissions" : {
13866 "check" : [
13867 "perm",
13868 "/vms/{vmid}",
13869 [
13870 "VM.PowerMgmt"
13871 ]
13872 ]
13873 },
44660702
DM
13874 "protected" : 1,
13875 "proxyto" : "node",
7aacca6f
DM
13876 "returns" : {
13877 "type" : "string"
13878 }
56122987
DM
13879 }
13880 },
44660702
DM
13881 "leaf" : 1,
13882 "path" : "/nodes/{node}/lxc/{vmid}/status/shutdown",
7aacca6f 13883 "text" : "shutdown"
56122987
DM
13884 },
13885 {
56122987
DM
13886 "info" : {
13887 "POST" : {
7aacca6f 13888 "description" : "Suspend the container.",
7aacca6f 13889 "method" : "POST",
7aacca6f 13890 "name" : "vm_suspend",
56122987
DM
13891 "parameters" : {
13892 "additionalProperties" : 0,
13893 "properties" : {
44660702
DM
13894 "node" : {
13895 "description" : "The cluster node name.",
13896 "format" : "pve-node",
013dc89f
DM
13897 "type" : "string",
13898 "typetext" : "<string>"
44660702 13899 },
7aacca6f 13900 "vmid" : {
7aacca6f
DM
13901 "description" : "The (unique) ID of the VM.",
13902 "format" : "pve-vmid",
44660702 13903 "minimum" : 1,
4bd7df8b 13904 "type" : "integer",
013dc89f 13905 "typetext" : "<integer> (1 - N)"
56122987
DM
13906 }
13907 }
7aacca6f 13908 },
56122987
DM
13909 "permissions" : {
13910 "check" : [
13911 "perm",
13912 "/vms/{vmid}",
13913 [
13914 "VM.PowerMgmt"
13915 ]
13916 ]
13917 },
7aacca6f 13918 "protected" : 1,
44660702
DM
13919 "proxyto" : "node",
13920 "returns" : {
13921 "type" : "string"
13922 }
13923 }
13924 },
13925 "leaf" : 1,
13926 "path" : "/nodes/{node}/lxc/{vmid}/status/suspend",
13927 "text" : "suspend"
13928 },
13929 {
13930 "info" : {
13931 "POST" : {
13932 "description" : "Resume the container.",
13933 "method" : "POST",
13934 "name" : "vm_resume",
56122987 13935 "parameters" : {
44660702 13936 "additionalProperties" : 0,
56122987
DM
13937 "properties" : {
13938 "node" : {
7aacca6f 13939 "description" : "The cluster node name.",
44660702 13940 "format" : "pve-node",
013dc89f
DM
13941 "type" : "string",
13942 "typetext" : "<string>"
56122987
DM
13943 },
13944 "vmid" : {
7aacca6f 13945 "description" : "The (unique) ID of the VM.",
56122987 13946 "format" : "pve-vmid",
44660702 13947 "minimum" : 1,
4bd7df8b 13948 "type" : "integer",
013dc89f 13949 "typetext" : "<integer> (1 - N)"
56122987 13950 }
44660702
DM
13951 }
13952 },
13953 "permissions" : {
13954 "check" : [
13955 "perm",
13956 "/vms/{vmid}",
13957 [
13958 "VM.PowerMgmt"
13959 ]
13960 ]
56122987 13961 },
44660702
DM
13962 "protected" : 1,
13963 "proxyto" : "node",
13964 "returns" : {
13965 "type" : "string"
13966 }
7aacca6f
DM
13967 }
13968 },
44660702
DM
13969 "leaf" : 1,
13970 "path" : "/nodes/{node}/lxc/{vmid}/status/resume",
7aacca6f
DM
13971 "text" : "resume"
13972 }
13973 ],
13974 "info" : {
13975 "GET" : {
7aacca6f 13976 "description" : "Directory index",
44660702 13977 "method" : "GET",
7aacca6f 13978 "name" : "vmcmdidx",
7aacca6f
DM
13979 "parameters" : {
13980 "additionalProperties" : 0,
13981 "properties" : {
13982 "node" : {
13983 "description" : "The cluster node name.",
44660702 13984 "format" : "pve-node",
013dc89f
DM
13985 "type" : "string",
13986 "typetext" : "<string>"
56122987 13987 },
7aacca6f 13988 "vmid" : {
44660702 13989 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
13990 "format" : "pve-vmid",
13991 "minimum" : 1,
4bd7df8b 13992 "type" : "integer",
013dc89f 13993 "typetext" : "<integer> (1 - N)"
7aacca6f 13994 }
56122987
DM
13995 }
13996 },
44660702
DM
13997 "permissions" : {
13998 "user" : "all"
13999 },
14000 "proxyto" : "node",
7aacca6f 14001 "returns" : {
7aacca6f
DM
14002 "items" : {
14003 "properties" : {
14004 "subdir" : {
14005 "type" : "string"
14006 }
14007 },
14008 "type" : "object"
14009 },
14010 "links" : [
14011 {
44660702
DM
14012 "href" : "{subdir}",
14013 "rel" : "child"
7aacca6f 14014 }
44660702
DM
14015 ],
14016 "type" : "array"
7aacca6f
DM
14017 }
14018 }
44660702
DM
14019 },
14020 "leaf" : 0,
14021 "path" : "/nodes/{node}/lxc/{vmid}/status",
14022 "text" : "status"
7aacca6f
DM
14023 },
14024 {
7aacca6f 14025 "children" : [
56122987 14026 {
7aacca6f
DM
14027 "children" : [
14028 {
14029 "info" : {
14030 "POST" : {
7aacca6f 14031 "description" : "Rollback LXC state to specified snapshot.",
7aacca6f 14032 "method" : "POST",
44660702 14033 "name" : "rollback",
7aacca6f 14034 "parameters" : {
44660702 14035 "additionalProperties" : 0,
7aacca6f 14036 "properties" : {
44660702
DM
14037 "node" : {
14038 "description" : "The cluster node name.",
14039 "format" : "pve-node",
013dc89f
DM
14040 "type" : "string",
14041 "typetext" : "<string>"
44660702 14042 },
7aacca6f 14043 "snapname" : {
44660702 14044 "description" : "The name of the snapshot.",
7aacca6f
DM
14045 "format" : "pve-configid",
14046 "maxLength" : 40,
013dc89f
DM
14047 "type" : "string",
14048 "typetext" : "<string>"
7aacca6f 14049 },
7aacca6f 14050 "vmid" : {
44660702 14051 "description" : "The (unique) ID of the VM.",
7aacca6f 14052 "format" : "pve-vmid",
44660702 14053 "minimum" : 1,
4bd7df8b 14054 "type" : "integer",
013dc89f 14055 "typetext" : "<integer> (1 - N)"
7aacca6f 14056 }
44660702
DM
14057 }
14058 },
14059 "permissions" : {
14060 "check" : [
14061 "perm",
14062 "/vms/{vmid}",
14063 [
14064 "VM.Snapshot"
14065 ]
14066 ]
7aacca6f 14067 },
44660702
DM
14068 "protected" : 1,
14069 "proxyto" : "node",
14070 "returns" : {
14071 "description" : "the task ID.",
14072 "type" : "string"
14073 }
7aacca6f
DM
14074 }
14075 },
7aacca6f 14076 "leaf" : 1,
44660702
DM
14077 "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}/rollback",
14078 "text" : "rollback"
7aacca6f
DM
14079 },
14080 {
7aacca6f
DM
14081 "info" : {
14082 "GET" : {
7aacca6f 14083 "description" : "Get snapshot configuration",
44660702
DM
14084 "method" : "GET",
14085 "name" : "get_snapshot_config",
7aacca6f
DM
14086 "parameters" : {
14087 "additionalProperties" : 0,
14088 "properties" : {
7aacca6f 14089 "node" : {
7aacca6f 14090 "description" : "The cluster node name.",
44660702 14091 "format" : "pve-node",
013dc89f
DM
14092 "type" : "string",
14093 "typetext" : "<string>"
7aacca6f
DM
14094 },
14095 "snapname" : {
44660702 14096 "description" : "The name of the snapshot.",
7aacca6f
DM
14097 "format" : "pve-configid",
14098 "maxLength" : 40,
013dc89f
DM
14099 "type" : "string",
14100 "typetext" : "<string>"
44660702
DM
14101 },
14102 "vmid" : {
14103 "description" : "The (unique) ID of the VM.",
14104 "format" : "pve-vmid",
14105 "minimum" : 1,
4bd7df8b 14106 "type" : "integer",
013dc89f 14107 "typetext" : "<integer> (1 - N)"
7aacca6f
DM
14108 }
14109 }
14110 },
14111 "permissions" : {
14112 "check" : [
14113 "perm",
14114 "/vms/{vmid}",
14115 [
14116 "VM.Snapshot"
14117 ]
14118 ]
14119 },
44660702
DM
14120 "proxyto" : "node",
14121 "returns" : {
14122 "type" : "object"
14123 }
7aacca6f
DM
14124 },
14125 "PUT" : {
44660702
DM
14126 "description" : "Update snapshot metadata.",
14127 "method" : "PUT",
7aacca6f
DM
14128 "name" : "update_snapshot_config",
14129 "parameters" : {
14130 "additionalProperties" : 0,
14131 "properties" : {
44660702
DM
14132 "description" : {
14133 "description" : "A textual description or comment.",
14134 "optional" : 1,
013dc89f
DM
14135 "type" : "string",
14136 "typetext" : "<string>"
44660702 14137 },
7aacca6f 14138 "node" : {
7aacca6f 14139 "description" : "The cluster node name.",
44660702 14140 "format" : "pve-node",
013dc89f
DM
14141 "type" : "string",
14142 "typetext" : "<string>"
7aacca6f
DM
14143 },
14144 "snapname" : {
14145 "description" : "The name of the snapshot.",
7aacca6f 14146 "format" : "pve-configid",
44660702 14147 "maxLength" : 40,
013dc89f
DM
14148 "type" : "string",
14149 "typetext" : "<string>"
7aacca6f
DM
14150 },
14151 "vmid" : {
44660702 14152 "description" : "The (unique) ID of the VM.",
7aacca6f 14153 "format" : "pve-vmid",
44660702 14154 "minimum" : 1,
4bd7df8b 14155 "type" : "integer",
013dc89f 14156 "typetext" : "<integer> (1 - N)"
7aacca6f
DM
14157 }
14158 }
14159 },
7aacca6f
DM
14160 "permissions" : {
14161 "check" : [
14162 "perm",
14163 "/vms/{vmid}",
14164 [
14165 "VM.Snapshot"
14166 ]
14167 ]
14168 },
44660702
DM
14169 "protected" : 1,
14170 "proxyto" : "node",
7aacca6f
DM
14171 "returns" : {
14172 "type" : "null"
14173 }
14174 }
14175 },
44660702 14176 "leaf" : 1,
7aacca6f 14177 "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}/config",
44660702 14178 "text" : "config"
7aacca6f
DM
14179 }
14180 ],
56122987 14181 "info" : {
44660702
DM
14182 "DELETE" : {
14183 "description" : "Delete a LXC snapshot.",
14184 "method" : "DELETE",
14185 "name" : "delsnapshot",
56122987 14186 "parameters" : {
44660702 14187 "additionalProperties" : 0,
56122987 14188 "properties" : {
44660702
DM
14189 "force" : {
14190 "description" : "For removal from config file, even if removing disk snapshots fails.",
14191 "optional" : 1,
013dc89f
DM
14192 "type" : "boolean",
14193 "typetext" : "<boolean>"
44660702
DM
14194 },
14195 "node" : {
14196 "description" : "The cluster node name.",
14197 "format" : "pve-node",
013dc89f
DM
14198 "type" : "string",
14199 "typetext" : "<string>"
7aacca6f
DM
14200 },
14201 "snapname" : {
7aacca6f
DM
14202 "description" : "The name of the snapshot.",
14203 "format" : "pve-configid",
44660702 14204 "maxLength" : 40,
013dc89f
DM
14205 "type" : "string",
14206 "typetext" : "<string>"
44660702
DM
14207 },
14208 "vmid" : {
14209 "description" : "The (unique) ID of the VM.",
14210 "format" : "pve-vmid",
14211 "minimum" : 1,
4bd7df8b 14212 "type" : "integer",
013dc89f 14213 "typetext" : "<integer> (1 - N)"
56122987 14214 }
44660702 14215 }
7aacca6f 14216 },
56122987
DM
14217 "permissions" : {
14218 "check" : [
14219 "perm",
14220 "/vms/{vmid}",
14221 [
7aacca6f 14222 "VM.Snapshot"
56122987
DM
14223 ]
14224 ]
14225 },
44660702 14226 "protected" : 1,
7aacca6f 14227 "proxyto" : "node",
56122987 14228 "returns" : {
7aacca6f 14229 "description" : "the task ID.",
56122987 14230 "type" : "string"
44660702
DM
14231 }
14232 },
14233 "GET" : {
14234 "description" : "",
14235 "method" : "GET",
14236 "name" : "snapshot_cmd_idx",
7aacca6f
DM
14237 "parameters" : {
14238 "additionalProperties" : 0,
14239 "properties" : {
7aacca6f 14240 "node" : {
44660702 14241 "description" : "The cluster node name.",
7aacca6f 14242 "format" : "pve-node",
013dc89f
DM
14243 "type" : "string",
14244 "typetext" : "<string>"
7aacca6f
DM
14245 },
14246 "snapname" : {
44660702 14247 "description" : "The name of the snapshot.",
7aacca6f 14248 "format" : "pve-configid",
44660702 14249 "maxLength" : 40,
013dc89f
DM
14250 "type" : "string",
14251 "typetext" : "<string>"
44660702
DM
14252 },
14253 "vmid" : {
14254 "description" : "The (unique) ID of the VM.",
14255 "format" : "pve-vmid",
14256 "minimum" : 1,
4bd7df8b 14257 "type" : "integer",
013dc89f 14258 "typetext" : "<integer> (1 - N)"
7aacca6f
DM
14259 }
14260 }
14261 },
44660702
DM
14262 "permissions" : {
14263 "user" : "all"
14264 },
14265 "returns" : {
14266 "items" : {
14267 "properties" : {},
14268 "type" : "object"
14269 },
14270 "links" : [
14271 {
14272 "href" : "{cmd}",
14273 "rel" : "child"
14274 }
14275 ],
14276 "type" : "array"
14277 }
14278 }
14279 },
14280 "leaf" : 0,
14281 "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}",
14282 "text" : "{snapname}"
14283 }
14284 ],
14285 "info" : {
14286 "GET" : {
14287 "description" : "List all snapshots.",
14288 "method" : "GET",
14289 "name" : "list",
14290 "parameters" : {
14291 "additionalProperties" : 0,
14292 "properties" : {
14293 "node" : {
14294 "description" : "The cluster node name.",
14295 "format" : "pve-node",
013dc89f
DM
14296 "type" : "string",
14297 "typetext" : "<string>"
44660702
DM
14298 },
14299 "vmid" : {
14300 "description" : "The (unique) ID of the VM.",
14301 "format" : "pve-vmid",
14302 "minimum" : 1,
4bd7df8b 14303 "type" : "integer",
013dc89f 14304 "typetext" : "<integer> (1 - N)"
44660702 14305 }
56122987
DM
14306 }
14307 },
56122987 14308 "permissions" : {
7aacca6f
DM
14309 "check" : [
14310 "perm",
14311 "/vms/{vmid}",
14312 [
14313 "VM.Audit"
14314 ]
14315 ]
14316 },
44660702 14317 "protected" : 1,
56122987 14318 "proxyto" : "node",
7aacca6f 14319 "returns" : {
44660702
DM
14320 "items" : {
14321 "properties" : {},
14322 "type" : "object"
14323 },
7aacca6f
DM
14324 "links" : [
14325 {
14326 "href" : "{name}",
14327 "rel" : "child"
14328 }
14329 ],
7aacca6f 14330 "type" : "array"
44660702 14331 }
7aacca6f
DM
14332 },
14333 "POST" : {
44660702
DM
14334 "description" : "Snapshot a container.",
14335 "method" : "POST",
14336 "name" : "snapshot",
56122987
DM
14337 "parameters" : {
14338 "additionalProperties" : 0,
14339 "properties" : {
7aacca6f 14340 "description" : {
44660702 14341 "description" : "A textual description or comment.",
7aacca6f 14342 "optional" : 1,
013dc89f
DM
14343 "type" : "string",
14344 "typetext" : "<string>"
44660702
DM
14345 },
14346 "node" : {
14347 "description" : "The cluster node name.",
14348 "format" : "pve-node",
013dc89f
DM
14349 "type" : "string",
14350 "typetext" : "<string>"
56122987
DM
14351 },
14352 "snapname" : {
56122987 14353 "description" : "The name of the snapshot.",
44660702 14354 "format" : "pve-configid",
7aacca6f 14355 "maxLength" : 40,
013dc89f
DM
14356 "type" : "string",
14357 "typetext" : "<string>"
56122987 14358 },
44660702
DM
14359 "vmid" : {
14360 "description" : "The (unique) ID of the VM.",
14361 "format" : "pve-vmid",
14362 "minimum" : 1,
4bd7df8b 14363 "type" : "integer",
013dc89f 14364 "typetext" : "<integer> (1 - N)"
56122987 14365 }
7aacca6f 14366 }
56122987 14367 },
56122987
DM
14368 "permissions" : {
14369 "check" : [
14370 "perm",
14371 "/vms/{vmid}",
14372 [
7aacca6f 14373 "VM.Snapshot"
56122987
DM
14374 ]
14375 ]
7aacca6f 14376 },
44660702 14377 "protected" : 1,
7aacca6f
DM
14378 "proxyto" : "node",
14379 "returns" : {
14380 "description" : "the task ID.",
14381 "type" : "string"
56122987
DM
14382 }
14383 }
44660702
DM
14384 },
14385 "leaf" : 0,
14386 "path" : "/nodes/{node}/lxc/{vmid}/snapshot",
14387 "text" : "snapshot"
7aacca6f
DM
14388 },
14389 {
56122987
DM
14390 "children" : [
14391 {
56122987
DM
14392 "children" : [
14393 {
56122987 14394 "info" : {
44660702
DM
14395 "DELETE" : {
14396 "description" : "Delete rule.",
14397 "method" : "DELETE",
14398 "name" : "delete_rule",
56122987 14399 "parameters" : {
44660702 14400 "additionalProperties" : 0,
56122987 14401 "properties" : {
44660702
DM
14402 "digest" : {
14403 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
14404 "maxLength" : 40,
7aacca6f 14405 "optional" : 1,
013dc89f
DM
14406 "type" : "string",
14407 "typetext" : "<string>"
7aacca6f
DM
14408 },
14409 "node" : {
44660702 14410 "description" : "The cluster node name.",
7aacca6f 14411 "format" : "pve-node",
013dc89f
DM
14412 "type" : "string",
14413 "typetext" : "<string>"
44660702
DM
14414 },
14415 "pos" : {
14416 "description" : "Update rule at position <pos>.",
14417 "minimum" : 0,
14418 "optional" : 1,
4bd7df8b 14419 "type" : "integer",
013dc89f 14420 "typetext" : "<integer> (0 - N)"
44660702
DM
14421 },
14422 "vmid" : {
14423 "description" : "The (unique) ID of the VM.",
14424 "format" : "pve-vmid",
14425 "minimum" : 1,
4bd7df8b 14426 "type" : "integer",
013dc89f 14427 "typetext" : "<integer> (1 - N)"
56122987 14428 }
44660702 14429 }
56122987 14430 },
56122987
DM
14431 "permissions" : {
14432 "check" : [
14433 "perm",
14434 "/vms/{vmid}",
14435 [
44660702 14436 "VM.Config.Network"
56122987
DM
14437 ]
14438 ]
14439 },
44660702 14440 "protected" : 1,
7aacca6f 14441 "proxyto" : null,
44660702
DM
14442 "returns" : {
14443 "type" : "null"
14444 }
7aacca6f 14445 },
44660702
DM
14446 "GET" : {
14447 "description" : "Get single rule data.",
14448 "method" : "GET",
14449 "name" : "get_rule",
56122987 14450 "parameters" : {
44660702 14451 "additionalProperties" : 0,
56122987 14452 "properties" : {
7aacca6f 14453 "node" : {
7aacca6f 14454 "description" : "The cluster node name.",
44660702 14455 "format" : "pve-node",
013dc89f
DM
14456 "type" : "string",
14457 "typetext" : "<string>"
56122987 14458 },
7aacca6f 14459 "pos" : {
7aacca6f 14460 "description" : "Update rule at position <pos>.",
44660702 14461 "minimum" : 0,
7aacca6f 14462 "optional" : 1,
4bd7df8b 14463 "type" : "integer",
013dc89f 14464 "typetext" : "<integer> (0 - N)"
56122987 14465 },
7aacca6f 14466 "vmid" : {
44660702 14467 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
14468 "format" : "pve-vmid",
14469 "minimum" : 1,
4bd7df8b 14470 "type" : "integer",
013dc89f 14471 "typetext" : "<integer> (1 - N)"
56122987 14472 }
44660702 14473 }
56122987 14474 },
7aacca6f
DM
14475 "permissions" : {
14476 "check" : [
14477 "perm",
14478 "/vms/{vmid}",
14479 [
44660702 14480 "VM.Audit"
7aacca6f
DM
14481 ]
14482 ]
14483 },
7aacca6f
DM
14484 "proxyto" : null,
14485 "returns" : {
44660702
DM
14486 "properties" : {
14487 "pos" : {
14488 "type" : "integer"
14489 }
14490 },
14491 "type" : "object"
7aacca6f 14492 }
56122987 14493 },
44660702
DM
14494 "PUT" : {
14495 "description" : "Modify rule data.",
14496 "method" : "PUT",
14497 "name" : "update_rule",
56122987
DM
14498 "parameters" : {
14499 "additionalProperties" : 0,
14500 "properties" : {
44660702
DM
14501 "action" : {
14502 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
14503 "maxLength" : 20,
14504 "minLength" : 2,
14505 "optional" : 1,
14506 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
14507 "type" : "string"
14508 },
14509 "comment" : {
e94f0d56 14510 "description" : "Descriptive comment.",
44660702 14511 "optional" : 1,
013dc89f
DM
14512 "type" : "string",
14513 "typetext" : "<string>"
44660702
DM
14514 },
14515 "delete" : {
14516 "description" : "A list of settings you want to delete.",
14517 "format" : "pve-configid-list",
14518 "optional" : 1,
013dc89f
DM
14519 "type" : "string",
14520 "typetext" : "<string>"
44660702
DM
14521 },
14522 "dest" : {
14523 "description" : "Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
14524 "format" : "pve-fw-addr-spec",
14525 "optional" : 1,
013dc89f
DM
14526 "type" : "string",
14527 "typetext" : "<string>"
44660702
DM
14528 },
14529 "digest" : {
14530 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
14531 "maxLength" : 40,
14532 "optional" : 1,
013dc89f
DM
14533 "type" : "string",
14534 "typetext" : "<string>"
44660702
DM
14535 },
14536 "dport" : {
14537 "description" : "Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
14538 "format" : "pve-fw-dport-spec",
14539 "optional" : 1,
013dc89f
DM
14540 "type" : "string",
14541 "typetext" : "<string>"
44660702
DM
14542 },
14543 "enable" : {
e94f0d56 14544 "description" : "Flag to enable/disable a rule.",
44660702
DM
14545 "minimum" : 0,
14546 "optional" : 1,
4bd7df8b 14547 "type" : "integer",
013dc89f 14548 "typetext" : "<integer> (0 - N)"
44660702
DM
14549 },
14550 "iface" : {
14551 "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.",
14552 "format" : "pve-iface",
14553 "maxLength" : 20,
14554 "minLength" : 2,
14555 "optional" : 1,
013dc89f
DM
14556 "type" : "string",
14557 "typetext" : "<string>"
44660702
DM
14558 },
14559 "macro" : {
e94f0d56 14560 "description" : "Use predefined standard macro.",
44660702
DM
14561 "maxLength" : 128,
14562 "optional" : 1,
013dc89f
DM
14563 "type" : "string",
14564 "typetext" : "<string>"
44660702
DM
14565 },
14566 "moveto" : {
14567 "description" : "Move rule to new position <moveto>. Other arguments are ignored.",
14568 "minimum" : 0,
14569 "optional" : 1,
4bd7df8b 14570 "type" : "integer",
013dc89f 14571 "typetext" : "<integer> (0 - N)"
44660702 14572 },
7aacca6f
DM
14573 "node" : {
14574 "description" : "The cluster node name.",
44660702 14575 "format" : "pve-node",
013dc89f
DM
14576 "type" : "string",
14577 "typetext" : "<string>"
56122987
DM
14578 },
14579 "pos" : {
44660702 14580 "description" : "Update rule at position <pos>.",
56122987 14581 "minimum" : 0,
7aacca6f 14582 "optional" : 1,
4bd7df8b 14583 "type" : "integer",
013dc89f 14584 "typetext" : "<integer> (0 - N)"
56122987 14585 },
44660702
DM
14586 "proto" : {
14587 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
14588 "format" : "pve-fw-protocol-spec",
14589 "optional" : 1,
013dc89f
DM
14590 "type" : "string",
14591 "typetext" : "<string>"
7aacca6f 14592 },
44660702
DM
14593 "source" : {
14594 "description" : "Restrict packet source address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
14595 "format" : "pve-fw-addr-spec",
14596 "optional" : 1,
013dc89f
DM
14597 "type" : "string",
14598 "typetext" : "<string>"
44660702
DM
14599 },
14600 "sport" : {
14601 "description" : "Restrict TCP/UDP source port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
14602 "format" : "pve-fw-sport-spec",
14603 "optional" : 1,
013dc89f
DM
14604 "type" : "string",
14605 "typetext" : "<string>"
44660702
DM
14606 },
14607 "type" : {
e94f0d56 14608 "description" : "Rule type.",
44660702
DM
14609 "enum" : [
14610 "in",
14611 "out",
14612 "group"
14613 ],
7aacca6f 14614 "optional" : 1,
44660702
DM
14615 "type" : "string"
14616 },
14617 "vmid" : {
14618 "description" : "The (unique) ID of the VM.",
14619 "format" : "pve-vmid",
14620 "minimum" : 1,
4bd7df8b 14621 "type" : "integer",
013dc89f 14622 "typetext" : "<integer> (1 - N)"
56122987
DM
14623 }
14624 }
14625 },
56122987
DM
14626 "permissions" : {
14627 "check" : [
14628 "perm",
14629 "/vms/{vmid}",
14630 [
7aacca6f 14631 "VM.Config.Network"
56122987
DM
14632 ]
14633 ]
14634 },
44660702 14635 "protected" : 1,
56122987 14636 "proxyto" : null,
56122987 14637 "returns" : {
7aacca6f
DM
14638 "type" : "null"
14639 }
56122987 14640 }
44660702
DM
14641 },
14642 "leaf" : 1,
14643 "path" : "/nodes/{node}/lxc/{vmid}/firewall/rules/{pos}",
14644 "text" : "{pos}"
56122987
DM
14645 }
14646 ],
14647 "info" : {
7aacca6f 14648 "GET" : {
44660702
DM
14649 "description" : "List rules.",
14650 "method" : "GET",
14651 "name" : "get_rules",
7aacca6f 14652 "parameters" : {
44660702 14653 "additionalProperties" : 0,
7aacca6f
DM
14654 "properties" : {
14655 "node" : {
7aacca6f 14656 "description" : "The cluster node name.",
44660702 14657 "format" : "pve-node",
013dc89f
DM
14658 "type" : "string",
14659 "typetext" : "<string>"
7aacca6f
DM
14660 },
14661 "vmid" : {
14662 "description" : "The (unique) ID of the VM.",
44660702 14663 "format" : "pve-vmid",
7aacca6f 14664 "minimum" : 1,
4bd7df8b 14665 "type" : "integer",
013dc89f 14666 "typetext" : "<integer> (1 - N)"
7aacca6f 14667 }
44660702 14668 }
56122987 14669 },
56122987
DM
14670 "permissions" : {
14671 "check" : [
14672 "perm",
14673 "/vms/{vmid}",
14674 [
7aacca6f 14675 "VM.Audit"
56122987
DM
14676 ]
14677 ]
14678 },
14679 "proxyto" : null,
7aacca6f 14680 "returns" : {
7aacca6f
DM
14681 "items" : {
14682 "properties" : {
14683 "pos" : {
14684 "type" : "integer"
14685 }
14686 },
14687 "type" : "object"
14688 },
14689 "links" : [
14690 {
44660702
DM
14691 "href" : "{pos}",
14692 "rel" : "child"
7aacca6f 14693 }
44660702
DM
14694 ],
14695 "type" : "array"
14696 }
7aacca6f
DM
14697 },
14698 "POST" : {
44660702
DM
14699 "description" : "Create new rule.",
14700 "method" : "POST",
7aacca6f 14701 "name" : "create_rule",
56122987 14702 "parameters" : {
44660702 14703 "additionalProperties" : 0,
56122987 14704 "properties" : {
7aacca6f 14705 "action" : {
44660702 14706 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
7aacca6f 14707 "maxLength" : 20,
44660702 14708 "minLength" : 2,
7aacca6f
DM
14709 "optional" : 0,
14710 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
56122987
DM
14711 "type" : "string"
14712 },
44660702 14713 "comment" : {
e94f0d56 14714 "description" : "Descriptive comment.",
7aacca6f 14715 "optional" : 1,
013dc89f
DM
14716 "type" : "string",
14717 "typetext" : "<string>"
56122987 14718 },
44660702
DM
14719 "dest" : {
14720 "description" : "Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
14721 "format" : "pve-fw-addr-spec",
56122987 14722 "optional" : 1,
013dc89f
DM
14723 "type" : "string",
14724 "typetext" : "<string>"
56122987 14725 },
44660702
DM
14726 "digest" : {
14727 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
14728 "maxLength" : 40,
56122987 14729 "optional" : 1,
013dc89f
DM
14730 "type" : "string",
14731 "typetext" : "<string>"
56122987 14732 },
44660702
DM
14733 "dport" : {
14734 "description" : "Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
14735 "format" : "pve-fw-dport-spec",
56122987 14736 "optional" : 1,
013dc89f
DM
14737 "type" : "string",
14738 "typetext" : "<string>"
56122987 14739 },
44660702 14740 "enable" : {
e94f0d56 14741 "description" : "Flag to enable/disable a rule.",
44660702 14742 "minimum" : 0,
56122987 14743 "optional" : 1,
4bd7df8b 14744 "type" : "integer",
013dc89f 14745 "typetext" : "<integer> (0 - N)"
56122987 14746 },
44660702
DM
14747 "iface" : {
14748 "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.",
14749 "format" : "pve-iface",
14750 "maxLength" : 20,
14751 "minLength" : 2,
7aacca6f 14752 "optional" : 1,
013dc89f
DM
14753 "type" : "string",
14754 "typetext" : "<string>"
56122987 14755 },
44660702 14756 "macro" : {
e94f0d56 14757 "description" : "Use predefined standard macro.",
44660702 14758 "maxLength" : 128,
56122987 14759 "optional" : 1,
013dc89f
DM
14760 "type" : "string",
14761 "typetext" : "<string>"
56122987
DM
14762 },
14763 "node" : {
7aacca6f 14764 "description" : "The cluster node name.",
44660702 14765 "format" : "pve-node",
013dc89f
DM
14766 "type" : "string",
14767 "typetext" : "<string>"
7aacca6f 14768 },
44660702
DM
14769 "pos" : {
14770 "description" : "Update rule at position <pos>.",
14771 "minimum" : 0,
14772 "optional" : 1,
4bd7df8b 14773 "type" : "integer",
013dc89f 14774 "typetext" : "<integer> (0 - N)"
44660702
DM
14775 },
14776 "proto" : {
14777 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
14778 "format" : "pve-fw-protocol-spec",
7aacca6f 14779 "optional" : 1,
013dc89f
DM
14780 "type" : "string",
14781 "typetext" : "<string>"
7aacca6f 14782 },
44660702
DM
14783 "source" : {
14784 "description" : "Restrict packet source address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
14785 "format" : "pve-fw-addr-spec",
14786 "optional" : 1,
013dc89f
DM
14787 "type" : "string",
14788 "typetext" : "<string>"
56122987 14789 },
44660702
DM
14790 "sport" : {
14791 "description" : "Restrict TCP/UDP source port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
14792 "format" : "pve-fw-sport-spec",
14793 "optional" : 1,
013dc89f
DM
14794 "type" : "string",
14795 "typetext" : "<string>"
7aacca6f 14796 },
44660702 14797 "type" : {
e94f0d56 14798 "description" : "Rule type.",
44660702
DM
14799 "enum" : [
14800 "in",
14801 "out",
14802 "group"
14803 ],
14804 "optional" : 0,
14805 "type" : "string"
14806 },
14807 "vmid" : {
14808 "description" : "The (unique) ID of the VM.",
14809 "format" : "pve-vmid",
14810 "minimum" : 1,
4bd7df8b 14811 "type" : "integer",
013dc89f 14812 "typetext" : "<integer> (1 - N)"
44660702
DM
14813 }
14814 }
14815 },
14816 "permissions" : {
14817 "check" : [
14818 "perm",
14819 "/vms/{vmid}",
14820 [
14821 "VM.Config.Network"
14822 ]
14823 ]
14824 },
14825 "protected" : 1,
14826 "proxyto" : null,
14827 "returns" : {
14828 "type" : "null"
14829 }
14830 }
14831 },
14832 "leaf" : 0,
14833 "path" : "/nodes/{node}/lxc/{vmid}/firewall/rules",
14834 "text" : "rules"
14835 },
14836 {
14837 "children" : [
14838 {
14839 "info" : {
14840 "DELETE" : {
14841 "description" : "Remove IP or Network alias.",
14842 "method" : "DELETE",
14843 "name" : "remove_alias",
56122987 14844 "parameters" : {
44660702 14845 "additionalProperties" : 0,
56122987 14846 "properties" : {
44660702
DM
14847 "digest" : {
14848 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
14849 "maxLength" : 40,
56122987 14850 "optional" : 1,
013dc89f
DM
14851 "type" : "string",
14852 "typetext" : "<string>"
56122987 14853 },
7aacca6f 14854 "name" : {
44660702 14855 "description" : "Alias name.",
7aacca6f 14856 "maxLength" : 64,
7aacca6f
DM
14857 "minLength" : 2,
14858 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 14859 "type" : "string"
7aacca6f
DM
14860 },
14861 "node" : {
44660702 14862 "description" : "The cluster node name.",
56122987 14863 "format" : "pve-node",
013dc89f
DM
14864 "type" : "string",
14865 "typetext" : "<string>"
7aacca6f 14866 },
56122987 14867 "vmid" : {
44660702 14868 "description" : "The (unique) ID of the VM.",
56122987 14869 "format" : "pve-vmid",
44660702 14870 "minimum" : 1,
4bd7df8b 14871 "type" : "integer",
013dc89f 14872 "typetext" : "<integer> (1 - N)"
56122987 14873 }
44660702 14874 }
56122987 14875 },
56122987
DM
14876 "permissions" : {
14877 "check" : [
14878 "perm",
14879 "/vms/{vmid}",
14880 [
7aacca6f 14881 "VM.Config.Network"
56122987
DM
14882 ]
14883 ]
14884 },
44660702 14885 "protected" : 1,
56122987 14886 "returns" : {
7aacca6f 14887 "type" : "null"
44660702 14888 }
56122987 14889 },
44660702
DM
14890 "GET" : {
14891 "description" : "Read alias.",
14892 "method" : "GET",
14893 "name" : "read_alias",
14894 "parameters" : {
14895 "additionalProperties" : 0,
14896 "properties" : {
14897 "name" : {
14898 "description" : "Alias name.",
14899 "maxLength" : 64,
14900 "minLength" : 2,
14901 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
14902 "type" : "string"
14903 },
14904 "node" : {
14905 "description" : "The cluster node name.",
14906 "format" : "pve-node",
013dc89f
DM
14907 "type" : "string",
14908 "typetext" : "<string>"
44660702
DM
14909 },
14910 "vmid" : {
14911 "description" : "The (unique) ID of the VM.",
14912 "format" : "pve-vmid",
14913 "minimum" : 1,
4bd7df8b 14914 "type" : "integer",
013dc89f 14915 "typetext" : "<integer> (1 - N)"
44660702
DM
14916 }
14917 }
56122987 14918 },
7aacca6f
DM
14919 "permissions" : {
14920 "check" : [
14921 "perm",
14922 "/vms/{vmid}",
14923 [
44660702 14924 "VM.Audit"
7aacca6f
DM
14925 ]
14926 ]
14927 },
44660702
DM
14928 "returns" : {
14929 "type" : "object"
14930 }
14931 },
14932 "PUT" : {
14933 "description" : "Update IP or Network alias.",
14934 "method" : "PUT",
14935 "name" : "update_alias",
56122987
DM
14936 "parameters" : {
14937 "additionalProperties" : 0,
14938 "properties" : {
44660702
DM
14939 "cidr" : {
14940 "description" : "Network/IP specification in CIDR format.",
14941 "format" : "IPorCIDR",
013dc89f
DM
14942 "type" : "string",
14943 "typetext" : "<string>"
44660702
DM
14944 },
14945 "comment" : {
14946 "optional" : 1,
013dc89f
DM
14947 "type" : "string",
14948 "typetext" : "<string>"
44660702
DM
14949 },
14950 "digest" : {
14951 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
14952 "maxLength" : 40,
14953 "optional" : 1,
013dc89f
DM
14954 "type" : "string",
14955 "typetext" : "<string>"
44660702 14956 },
56122987 14957 "name" : {
7aacca6f 14958 "description" : "Alias name.",
44660702
DM
14959 "maxLength" : 64,
14960 "minLength" : 2,
7aacca6f 14961 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 14962 "type" : "string"
56122987
DM
14963 },
14964 "node" : {
14965 "description" : "The cluster node name.",
44660702 14966 "format" : "pve-node",
013dc89f
DM
14967 "type" : "string",
14968 "typetext" : "<string>"
44660702
DM
14969 },
14970 "rename" : {
14971 "description" : "Rename an existing alias.",
14972 "maxLength" : 64,
14973 "minLength" : 2,
14974 "optional" : 1,
14975 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
14976 "type" : "string"
56122987 14977 },
7aacca6f 14978 "vmid" : {
7aacca6f 14979 "description" : "The (unique) ID of the VM.",
44660702 14980 "format" : "pve-vmid",
7aacca6f 14981 "minimum" : 1,
4bd7df8b 14982 "type" : "integer",
013dc89f 14983 "typetext" : "<integer> (1 - N)"
56122987
DM
14984 }
14985 }
14986 },
44660702
DM
14987 "permissions" : {
14988 "check" : [
14989 "perm",
14990 "/vms/{vmid}",
14991 [
14992 "VM.Config.Network"
14993 ]
14994 ]
7aacca6f 14995 },
44660702
DM
14996 "protected" : 1,
14997 "returns" : {
14998 "type" : "null"
7aacca6f
DM
14999 }
15000 }
15001 },
44660702
DM
15002 "leaf" : 1,
15003 "path" : "/nodes/{node}/lxc/{vmid}/firewall/aliases/{name}",
15004 "text" : "{name}"
15005 }
15006 ],
15007 "info" : {
15008 "GET" : {
15009 "description" : "List aliases",
15010 "method" : "GET",
15011 "name" : "get_aliases",
56122987
DM
15012 "parameters" : {
15013 "additionalProperties" : 0,
15014 "properties" : {
15015 "node" : {
44660702 15016 "description" : "The cluster node name.",
56122987 15017 "format" : "pve-node",
013dc89f
DM
15018 "type" : "string",
15019 "typetext" : "<string>"
56122987
DM
15020 },
15021 "vmid" : {
7aacca6f 15022 "description" : "The (unique) ID of the VM.",
44660702 15023 "format" : "pve-vmid",
7aacca6f 15024 "minimum" : 1,
4bd7df8b 15025 "type" : "integer",
013dc89f 15026 "typetext" : "<integer> (1 - N)"
56122987
DM
15027 }
15028 }
15029 },
44660702
DM
15030 "permissions" : {
15031 "check" : [
15032 "perm",
15033 "/vms/{vmid}",
15034 [
15035 "VM.Audit"
15036 ]
15037 ]
15038 },
56122987
DM
15039 "returns" : {
15040 "items" : {
56122987 15041 "properties" : {
44660702
DM
15042 "cidr" : {
15043 "type" : "string"
7aacca6f 15044 },
44660702
DM
15045 "comment" : {
15046 "optional" : 1,
56122987
DM
15047 "type" : "string"
15048 },
56122987 15049 "digest" : {
56122987 15050 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702
DM
15051 "maxLength" : 40,
15052 "optional" : 0,
15053 "type" : "string"
15054 },
15055 "name" : {
15056 "type" : "string"
56122987 15057 }
44660702
DM
15058 },
15059 "type" : "object"
15060 },
15061 "links" : [
15062 {
15063 "href" : "{name}",
15064 "rel" : "child"
56122987 15065 }
44660702
DM
15066 ],
15067 "type" : "array"
7aacca6f
DM
15068 }
15069 },
15070 "POST" : {
44660702 15071 "description" : "Create IP or Network Alias.",
7aacca6f 15072 "method" : "POST",
44660702 15073 "name" : "create_alias",
7aacca6f
DM
15074 "parameters" : {
15075 "additionalProperties" : 0,
15076 "properties" : {
44660702
DM
15077 "cidr" : {
15078 "description" : "Network/IP specification in CIDR format.",
15079 "format" : "IPorCIDR",
013dc89f
DM
15080 "type" : "string",
15081 "typetext" : "<string>"
7aacca6f
DM
15082 },
15083 "comment" : {
15084 "optional" : 1,
013dc89f
DM
15085 "type" : "string",
15086 "typetext" : "<string>"
7aacca6f 15087 },
44660702
DM
15088 "name" : {
15089 "description" : "Alias name.",
15090 "maxLength" : 64,
7aacca6f
DM
15091 "minLength" : 2,
15092 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 15093 "type" : "string"
7aacca6f
DM
15094 },
15095 "node" : {
44660702 15096 "description" : "The cluster node name.",
7aacca6f 15097 "format" : "pve-node",
013dc89f
DM
15098 "type" : "string",
15099 "typetext" : "<string>"
7aacca6f 15100 },
44660702
DM
15101 "vmid" : {
15102 "description" : "The (unique) ID of the VM.",
15103 "format" : "pve-vmid",
15104 "minimum" : 1,
4bd7df8b 15105 "type" : "integer",
013dc89f 15106 "typetext" : "<integer> (1 - N)"
7aacca6f
DM
15107 }
15108 }
15109 },
44660702
DM
15110 "permissions" : {
15111 "check" : [
15112 "perm",
15113 "/vms/{vmid}",
15114 [
15115 "VM.Config.Network"
15116 ]
15117 ]
15118 },
15119 "protected" : 1,
15120 "returns" : {
15121 "type" : "null"
15122 }
56122987
DM
15123 }
15124 },
44660702
DM
15125 "leaf" : 0,
15126 "path" : "/nodes/{node}/lxc/{vmid}/firewall/aliases",
15127 "text" : "aliases"
15128 },
15129 {
56122987
DM
15130 "children" : [
15131 {
56122987
DM
15132 "children" : [
15133 {
15134 "info" : {
15135 "DELETE" : {
44660702 15136 "description" : "Remove IP or Network from IPSet.",
7aacca6f 15137 "method" : "DELETE",
44660702 15138 "name" : "remove_ip",
56122987
DM
15139 "parameters" : {
15140 "additionalProperties" : 0,
15141 "properties" : {
44660702
DM
15142 "cidr" : {
15143 "description" : "Network/IP specification in CIDR format.",
15144 "format" : "IPorCIDRorAlias",
013dc89f
DM
15145 "type" : "string",
15146 "typetext" : "<string>"
56122987
DM
15147 },
15148 "digest" : {
44660702 15149 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
56122987 15150 "maxLength" : 40,
7aacca6f 15151 "optional" : 1,
013dc89f
DM
15152 "type" : "string",
15153 "typetext" : "<string>"
56122987 15154 },
56122987 15155 "name" : {
44660702 15156 "description" : "IP set name.",
56122987 15157 "maxLength" : 64,
7aacca6f 15158 "minLength" : 2,
56122987 15159 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
56122987 15160 "type" : "string"
7aacca6f
DM
15161 },
15162 "node" : {
7aacca6f 15163 "description" : "The cluster node name.",
44660702 15164 "format" : "pve-node",
013dc89f
DM
15165 "type" : "string",
15166 "typetext" : "<string>"
44660702
DM
15167 },
15168 "vmid" : {
15169 "description" : "The (unique) ID of the VM.",
15170 "format" : "pve-vmid",
15171 "minimum" : 1,
4bd7df8b 15172 "type" : "integer",
013dc89f 15173 "typetext" : "<integer> (1 - N)"
56122987
DM
15174 }
15175 }
15176 },
44660702
DM
15177 "permissions" : {
15178 "check" : [
15179 "perm",
15180 "/vms/{vmid}",
15181 [
15182 "VM.Config.Network"
15183 ]
15184 ]
15185 },
7aacca6f 15186 "protected" : 1,
56122987
DM
15187 "returns" : {
15188 "type" : "null"
44660702
DM
15189 }
15190 },
15191 "GET" : {
15192 "description" : "Read IP or Network settings from IPSet.",
15193 "method" : "GET",
15194 "name" : "read_ip",
56122987
DM
15195 "parameters" : {
15196 "additionalProperties" : 0,
15197 "properties" : {
7aacca6f 15198 "cidr" : {
7aacca6f 15199 "description" : "Network/IP specification in CIDR format.",
44660702 15200 "format" : "IPorCIDRorAlias",
013dc89f
DM
15201 "type" : "string",
15202 "typetext" : "<string>"
56122987 15203 },
7aacca6f 15204 "name" : {
44660702 15205 "description" : "IP set name.",
7aacca6f
DM
15206 "maxLength" : 64,
15207 "minLength" : 2,
7aacca6f
DM
15208 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
15209 "type" : "string"
56122987 15210 },
44660702
DM
15211 "node" : {
15212 "description" : "The cluster node name.",
15213 "format" : "pve-node",
013dc89f
DM
15214 "type" : "string",
15215 "typetext" : "<string>"
44660702
DM
15216 },
15217 "vmid" : {
15218 "description" : "The (unique) ID of the VM.",
15219 "format" : "pve-vmid",
15220 "minimum" : 1,
4bd7df8b 15221 "type" : "integer",
013dc89f 15222 "typetext" : "<integer> (1 - N)"
56122987
DM
15223 }
15224 }
15225 },
56122987
DM
15226 "permissions" : {
15227 "check" : [
15228 "perm",
15229 "/vms/{vmid}",
15230 [
44660702 15231 "VM.Audit"
56122987
DM
15232 ]
15233 ]
7aacca6f 15234 },
44660702 15235 "protected" : 1,
7aacca6f
DM
15236 "returns" : {
15237 "type" : "object"
44660702
DM
15238 }
15239 },
15240 "PUT" : {
15241 "description" : "Update IP or Network settings",
15242 "method" : "PUT",
15243 "name" : "update_ip",
7aacca6f 15244 "parameters" : {
44660702 15245 "additionalProperties" : 0,
7aacca6f
DM
15246 "properties" : {
15247 "cidr" : {
44660702 15248 "description" : "Network/IP specification in CIDR format.",
7aacca6f 15249 "format" : "IPorCIDRorAlias",
013dc89f
DM
15250 "type" : "string",
15251 "typetext" : "<string>"
7aacca6f 15252 },
44660702
DM
15253 "comment" : {
15254 "optional" : 1,
013dc89f
DM
15255 "type" : "string",
15256 "typetext" : "<string>"
44660702
DM
15257 },
15258 "digest" : {
15259 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
15260 "maxLength" : 40,
15261 "optional" : 1,
013dc89f
DM
15262 "type" : "string",
15263 "typetext" : "<string>"
44660702
DM
15264 },
15265 "name" : {
15266 "description" : "IP set name.",
15267 "maxLength" : 64,
15268 "minLength" : 2,
15269 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
15270 "type" : "string"
7aacca6f
DM
15271 },
15272 "node" : {
7aacca6f 15273 "description" : "The cluster node name.",
44660702 15274 "format" : "pve-node",
013dc89f
DM
15275 "type" : "string",
15276 "typetext" : "<string>"
7aacca6f 15277 },
44660702
DM
15278 "nomatch" : {
15279 "optional" : 1,
013dc89f
DM
15280 "type" : "boolean",
15281 "typetext" : "<boolean>"
44660702
DM
15282 },
15283 "vmid" : {
15284 "description" : "The (unique) ID of the VM.",
15285 "format" : "pve-vmid",
15286 "minimum" : 1,
4bd7df8b 15287 "type" : "integer",
013dc89f 15288 "typetext" : "<integer> (1 - N)"
7aacca6f 15289 }
44660702
DM
15290 }
15291 },
15292 "permissions" : {
15293 "check" : [
15294 "perm",
15295 "/vms/{vmid}",
15296 [
15297 "VM.Config.Network"
15298 ]
15299 ]
7aacca6f
DM
15300 },
15301 "protected" : 1,
44660702
DM
15302 "returns" : {
15303 "type" : "null"
15304 }
56122987
DM
15305 }
15306 },
56122987 15307 "leaf" : 1,
44660702
DM
15308 "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset/{name}/{cidr}",
15309 "text" : "{cidr}"
56122987
DM
15310 }
15311 ],
15312 "info" : {
44660702
DM
15313 "DELETE" : {
15314 "description" : "Delete IPSet",
15315 "method" : "DELETE",
15316 "name" : "delete_ipset",
15317 "parameters" : {
15318 "additionalProperties" : 0,
15319 "properties" : {
15320 "name" : {
15321 "description" : "IP set name.",
15322 "maxLength" : 64,
15323 "minLength" : 2,
15324 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
15325 "type" : "string"
15326 },
15327 "node" : {
15328 "description" : "The cluster node name.",
15329 "format" : "pve-node",
013dc89f
DM
15330 "type" : "string",
15331 "typetext" : "<string>"
44660702
DM
15332 },
15333 "vmid" : {
15334 "description" : "The (unique) ID of the VM.",
15335 "format" : "pve-vmid",
15336 "minimum" : 1,
4bd7df8b 15337 "type" : "integer",
013dc89f 15338 "typetext" : "<integer> (1 - N)"
44660702
DM
15339 }
15340 }
15341 },
15342 "permissions" : {
15343 "check" : [
15344 "perm",
15345 "/vms/{vmid}",
15346 [
15347 "VM.Config.Network"
15348 ]
15349 ]
15350 },
15351 "protected" : 1,
15352 "returns" : {
15353 "type" : "null"
15354 }
15355 },
56122987 15356 "GET" : {
7aacca6f 15357 "description" : "List IPSet content",
44660702
DM
15358 "method" : "GET",
15359 "name" : "get_ipset",
7aacca6f
DM
15360 "parameters" : {
15361 "additionalProperties" : 0,
15362 "properties" : {
15363 "name" : {
15364 "description" : "IP set name.",
44660702 15365 "maxLength" : 64,
7aacca6f 15366 "minLength" : 2,
44660702
DM
15367 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
15368 "type" : "string"
7aacca6f
DM
15369 },
15370 "node" : {
7aacca6f 15371 "description" : "The cluster node name.",
44660702 15372 "format" : "pve-node",
013dc89f
DM
15373 "type" : "string",
15374 "typetext" : "<string>"
7aacca6f
DM
15375 },
15376 "vmid" : {
15377 "description" : "The (unique) ID of the VM.",
44660702 15378 "format" : "pve-vmid",
7aacca6f 15379 "minimum" : 1,
4bd7df8b 15380 "type" : "integer",
013dc89f 15381 "typetext" : "<integer> (1 - N)"
56122987 15382 }
7aacca6f
DM
15383 }
15384 },
7aacca6f
DM
15385 "permissions" : {
15386 "check" : [
15387 "perm",
15388 "/vms/{vmid}",
15389 [
15390 "VM.Audit"
15391 ]
15392 ]
15393 },
15394 "returns" : {
56122987
DM
15395 "items" : {
15396 "properties" : {
15397 "cidr" : {
15398 "type" : "string"
15399 },
44660702
DM
15400 "comment" : {
15401 "optional" : 1,
15402 "type" : "string"
15403 },
56122987 15404 "digest" : {
56122987 15405 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702 15406 "maxLength" : 40,
7aacca6f 15407 "optional" : 0,
56122987 15408 "type" : "string"
7aacca6f
DM
15409 },
15410 "nomatch" : {
44660702
DM
15411 "optional" : 1,
15412 "type" : "boolean"
56122987 15413 }
44660702
DM
15414 },
15415 "type" : "object"
56122987 15416 },
7aacca6f
DM
15417 "links" : [
15418 {
44660702
DM
15419 "href" : "{cidr}",
15420 "rel" : "child"
56122987 15421 }
44660702
DM
15422 ],
15423 "type" : "array"
15424 }
56122987 15425 },
7aacca6f
DM
15426 "POST" : {
15427 "description" : "Add IP or Network to IPSet.",
44660702 15428 "method" : "POST",
7aacca6f 15429 "name" : "create_ip",
56122987 15430 "parameters" : {
44660702 15431 "additionalProperties" : 0,
56122987 15432 "properties" : {
44660702
DM
15433 "cidr" : {
15434 "description" : "Network/IP specification in CIDR format.",
15435 "format" : "IPorCIDRorAlias",
013dc89f
DM
15436 "type" : "string",
15437 "typetext" : "<string>"
44660702
DM
15438 },
15439 "comment" : {
15440 "optional" : 1,
013dc89f
DM
15441 "type" : "string",
15442 "typetext" : "<string>"
56122987
DM
15443 },
15444 "name" : {
56122987 15445 "description" : "IP set name.",
44660702 15446 "maxLength" : 64,
7aacca6f 15447 "minLength" : 2,
44660702 15448 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
7aacca6f 15449 "type" : "string"
56122987 15450 },
7aacca6f 15451 "node" : {
7aacca6f 15452 "description" : "The cluster node name.",
44660702 15453 "format" : "pve-node",
013dc89f
DM
15454 "type" : "string",
15455 "typetext" : "<string>"
56122987 15456 },
44660702
DM
15457 "nomatch" : {
15458 "optional" : 1,
013dc89f
DM
15459 "type" : "boolean",
15460 "typetext" : "<boolean>"
7aacca6f
DM
15461 },
15462 "vmid" : {
44660702 15463 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
15464 "format" : "pve-vmid",
15465 "minimum" : 1,
4bd7df8b 15466 "type" : "integer",
013dc89f 15467 "typetext" : "<integer> (1 - N)"
56122987 15468 }
44660702
DM
15469 }
15470 },
15471 "permissions" : {
15472 "check" : [
15473 "perm",
15474 "/vms/{vmid}",
15475 [
15476 "VM.Config.Network"
15477 ]
15478 ]
15479 },
15480 "protected" : 1,
15481 "returns" : {
15482 "type" : "null"
15483 }
15484 }
15485 },
15486 "leaf" : 0,
15487 "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset/{name}",
15488 "text" : "{name}"
15489 }
15490 ],
15491 "info" : {
15492 "GET" : {
15493 "description" : "List IPSets",
15494 "method" : "GET",
15495 "name" : "ipset_index",
15496 "parameters" : {
15497 "additionalProperties" : 0,
15498 "properties" : {
15499 "node" : {
15500 "description" : "The cluster node name.",
15501 "format" : "pve-node",
013dc89f
DM
15502 "type" : "string",
15503 "typetext" : "<string>"
44660702
DM
15504 },
15505 "vmid" : {
15506 "description" : "The (unique) ID of the VM.",
15507 "format" : "pve-vmid",
15508 "minimum" : 1,
4bd7df8b 15509 "type" : "integer",
013dc89f 15510 "typetext" : "<integer> (1 - N)"
44660702
DM
15511 }
15512 }
15513 },
15514 "permissions" : {
15515 "check" : [
15516 "perm",
15517 "/vms/{vmid}",
15518 [
15519 "VM.Audit"
15520 ]
15521 ]
15522 },
15523 "returns" : {
15524 "items" : {
15525 "properties" : {
15526 "comment" : {
15527 "optional" : 1,
15528 "type" : "string"
15529 },
15530 "digest" : {
15531 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
15532 "maxLength" : 40,
15533 "optional" : 0,
15534 "type" : "string"
7aacca6f 15535 },
44660702
DM
15536 "name" : {
15537 "description" : "IP set name.",
15538 "maxLength" : 64,
15539 "minLength" : 2,
15540 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
15541 "type" : "string"
15542 }
15543 },
15544 "type" : "object"
15545 },
15546 "links" : [
15547 {
15548 "href" : "{name}",
15549 "rel" : "child"
15550 }
15551 ],
15552 "type" : "array"
15553 }
15554 },
15555 "POST" : {
15556 "description" : "Create new IPSet",
15557 "method" : "POST",
15558 "name" : "create_ipset",
15559 "parameters" : {
15560 "additionalProperties" : 0,
15561 "properties" : {
15562 "comment" : {
15563 "optional" : 1,
013dc89f
DM
15564 "type" : "string",
15565 "typetext" : "<string>"
44660702
DM
15566 },
15567 "digest" : {
15568 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
15569 "maxLength" : 40,
15570 "optional" : 1,
013dc89f
DM
15571 "type" : "string",
15572 "typetext" : "<string>"
56122987 15573 },
44660702
DM
15574 "name" : {
15575 "description" : "IP set name.",
15576 "maxLength" : 64,
15577 "minLength" : 2,
15578 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
15579 "type" : "string"
15580 },
15581 "node" : {
15582 "description" : "The cluster node name.",
15583 "format" : "pve-node",
013dc89f
DM
15584 "type" : "string",
15585 "typetext" : "<string>"
7aacca6f 15586 },
44660702
DM
15587 "rename" : {
15588 "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.",
15589 "maxLength" : 64,
15590 "minLength" : 2,
15591 "optional" : 1,
15592 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
15593 "type" : "string"
15594 },
15595 "vmid" : {
15596 "description" : "The (unique) ID of the VM.",
15597 "format" : "pve-vmid",
15598 "minimum" : 1,
4bd7df8b 15599 "type" : "integer",
013dc89f 15600 "typetext" : "<integer> (1 - N)"
44660702 15601 }
56122987 15602 }
44660702
DM
15603 },
15604 "permissions" : {
15605 "check" : [
15606 "perm",
15607 "/vms/{vmid}",
15608 [
15609 "VM.Config.Network"
15610 ]
15611 ]
15612 },
15613 "protected" : 1,
15614 "returns" : {
15615 "type" : "null"
56122987
DM
15616 }
15617 }
44660702
DM
15618 },
15619 "leaf" : 0,
15620 "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset",
15621 "text" : "ipset"
56122987
DM
15622 },
15623 {
56122987 15624 "info" : {
7aacca6f 15625 "GET" : {
44660702 15626 "description" : "Get VM firewall options.",
7aacca6f 15627 "method" : "GET",
44660702
DM
15628 "name" : "get_options",
15629 "parameters" : {
15630 "additionalProperties" : 0,
15631 "properties" : {
15632 "node" : {
15633 "description" : "The cluster node name.",
15634 "format" : "pve-node",
013dc89f
DM
15635 "type" : "string",
15636 "typetext" : "<string>"
44660702
DM
15637 },
15638 "vmid" : {
15639 "description" : "The (unique) ID of the VM.",
15640 "format" : "pve-vmid",
15641 "minimum" : 1,
4bd7df8b 15642 "type" : "integer",
013dc89f 15643 "typetext" : "<integer> (1 - N)"
44660702
DM
15644 }
15645 }
15646 },
15647 "permissions" : {
15648 "check" : [
15649 "perm",
15650 "/vms/{vmid}",
15651 [
15652 "VM.Audit"
15653 ]
15654 ]
15655 },
15656 "proxyto" : "node",
56122987 15657 "returns" : {
56122987 15658 "properties" : {
44660702
DM
15659 "dhcp" : {
15660 "description" : "Enable DHCP.",
15661 "optional" : 1,
15662 "type" : "boolean"
15663 },
15664 "enable" : {
15665 "description" : "Enable/disable firewall rules.",
15666 "optional" : 1,
15667 "type" : "boolean"
15668 },
15669 "ipfilter" : {
15670 "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net<id> ipset for every interface. Such ipsets implicitly contain sane default restrictions such as restricting IPv6 link local addresses to the one derived from the interface's MAC address. For containers the configured IP addresses will be implicitly added.",
7aacca6f 15671 "optional" : 1,
44660702
DM
15672 "type" : "boolean"
15673 },
15674 "log_level_in" : {
7aacca6f
DM
15675 "description" : "Log level for incoming traffic.",
15676 "enum" : [
15677 "emerg",
15678 "alert",
15679 "crit",
15680 "err",
15681 "warning",
15682 "notice",
15683 "info",
15684 "debug",
15685 "nolog"
44660702
DM
15686 ],
15687 "optional" : 1,
15688 "type" : "string"
56122987 15689 },
44660702
DM
15690 "log_level_out" : {
15691 "description" : "Log level for outgoing traffic.",
56122987 15692 "enum" : [
44660702
DM
15693 "emerg",
15694 "alert",
15695 "crit",
15696 "err",
15697 "warning",
15698 "notice",
15699 "info",
15700 "debug",
15701 "nolog"
7aacca6f 15702 ],
7aacca6f
DM
15703 "optional" : 1,
15704 "type" : "string"
56122987 15705 },
44660702
DM
15706 "macfilter" : {
15707 "description" : "Enable/disable MAC address filter.",
15708 "optional" : 1,
15709 "type" : "boolean"
7aacca6f 15710 },
44660702
DM
15711 "ndp" : {
15712 "description" : "Enable NDP.",
56122987 15713 "optional" : 1,
44660702 15714 "type" : "boolean"
56122987
DM
15715 },
15716 "policy_in" : {
7aacca6f 15717 "description" : "Input policy.",
56122987
DM
15718 "enum" : [
15719 "ACCEPT",
15720 "REJECT",
15721 "DROP"
15722 ],
7aacca6f 15723 "optional" : 1,
44660702 15724 "type" : "string"
56122987 15725 },
44660702
DM
15726 "policy_out" : {
15727 "description" : "Output policy.",
56122987 15728 "enum" : [
44660702
DM
15729 "ACCEPT",
15730 "REJECT",
15731 "DROP"
56122987 15732 ],
7aacca6f 15733 "optional" : 1,
56122987
DM
15734 "type" : "string"
15735 },
44660702
DM
15736 "radv" : {
15737 "description" : "Allow sending Router Advertisement.",
56122987 15738 "optional" : 1,
7aacca6f
DM
15739 "type" : "boolean"
15740 }
7aacca6f 15741 },
44660702
DM
15742 "type" : "object"
15743 }
7aacca6f
DM
15744 },
15745 "PUT" : {
44660702
DM
15746 "description" : "Set Firewall options.",
15747 "method" : "PUT",
7aacca6f
DM
15748 "name" : "set_options",
15749 "parameters" : {
44660702 15750 "additionalProperties" : 0,
7aacca6f 15751 "properties" : {
44660702
DM
15752 "delete" : {
15753 "description" : "A list of settings you want to delete.",
15754 "format" : "pve-configid-list",
15755 "optional" : 1,
013dc89f
DM
15756 "type" : "string",
15757 "typetext" : "<string>"
44660702
DM
15758 },
15759 "dhcp" : {
15760 "description" : "Enable DHCP.",
15761 "optional" : 1,
013dc89f
DM
15762 "type" : "boolean",
15763 "typetext" : "<boolean>"
44660702
DM
15764 },
15765 "digest" : {
15766 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
15767 "maxLength" : 40,
15768 "optional" : 1,
013dc89f
DM
15769 "type" : "string",
15770 "typetext" : "<string>"
44660702 15771 },
7aacca6f
DM
15772 "enable" : {
15773 "description" : "Enable/disable firewall rules.",
56122987 15774 "optional" : 1,
013dc89f
DM
15775 "type" : "boolean",
15776 "typetext" : "<boolean>"
56122987 15777 },
44660702
DM
15778 "ipfilter" : {
15779 "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net<id> ipset for every interface. Such ipsets implicitly contain sane default restrictions such as restricting IPv6 link local addresses to the one derived from the interface's MAC address. For containers the configured IP addresses will be implicitly added.",
15780 "optional" : 1,
013dc89f
DM
15781 "type" : "boolean",
15782 "typetext" : "<boolean>"
44660702
DM
15783 },
15784 "log_level_in" : {
15785 "description" : "Log level for incoming traffic.",
56122987
DM
15786 "enum" : [
15787 "emerg",
15788 "alert",
15789 "crit",
15790 "err",
15791 "warning",
15792 "notice",
15793 "info",
15794 "debug",
15795 "nolog"
15796 ],
56122987 15797 "optional" : 1,
44660702 15798 "type" : "string"
56122987 15799 },
44660702
DM
15800 "log_level_out" : {
15801 "description" : "Log level for outgoing traffic.",
56122987
DM
15802 "enum" : [
15803 "emerg",
15804 "alert",
15805 "crit",
15806 "err",
15807 "warning",
15808 "notice",
15809 "info",
15810 "debug",
15811 "nolog"
15812 ],
44660702
DM
15813 "optional" : 1,
15814 "type" : "string"
56122987 15815 },
44660702
DM
15816 "macfilter" : {
15817 "description" : "Enable/disable MAC address filter.",
15818 "optional" : 1,
013dc89f
DM
15819 "type" : "boolean",
15820 "typetext" : "<boolean>"
44660702
DM
15821 },
15822 "ndp" : {
15823 "description" : "Enable NDP.",
56122987 15824 "optional" : 1,
013dc89f
DM
15825 "type" : "boolean",
15826 "typetext" : "<boolean>"
56122987 15827 },
7aacca6f
DM
15828 "node" : {
15829 "description" : "The cluster node name.",
44660702 15830 "format" : "pve-node",
013dc89f
DM
15831 "type" : "string",
15832 "typetext" : "<string>"
7aacca6f 15833 },
44660702
DM
15834 "policy_in" : {
15835 "description" : "Input policy.",
15836 "enum" : [
15837 "ACCEPT",
15838 "REJECT",
15839 "DROP"
15840 ],
7aacca6f 15841 "optional" : 1,
44660702 15842 "type" : "string"
7aacca6f 15843 },
44660702
DM
15844 "policy_out" : {
15845 "description" : "Output policy.",
56122987 15846 "enum" : [
7aacca6f
DM
15847 "ACCEPT",
15848 "REJECT",
15849 "DROP"
56122987
DM
15850 ],
15851 "optional" : 1,
56122987 15852 "type" : "string"
7aacca6f 15853 },
44660702
DM
15854 "radv" : {
15855 "description" : "Allow sending Router Advertisement.",
7aacca6f 15856 "optional" : 1,
013dc89f
DM
15857 "type" : "boolean",
15858 "typetext" : "<boolean>"
44660702
DM
15859 },
15860 "vmid" : {
15861 "description" : "The (unique) ID of the VM.",
15862 "format" : "pve-vmid",
15863 "minimum" : 1,
4bd7df8b 15864 "type" : "integer",
013dc89f 15865 "typetext" : "<integer> (1 - N)"
56122987 15866 }
44660702 15867 }
56122987 15868 },
7aacca6f
DM
15869 "permissions" : {
15870 "check" : [
15871 "perm",
15872 "/vms/{vmid}",
15873 [
15874 "VM.Config.Network"
15875 ]
15876 ]
15877 },
44660702
DM
15878 "protected" : 1,
15879 "proxyto" : "node",
7aacca6f
DM
15880 "returns" : {
15881 "type" : "null"
56122987
DM
15882 }
15883 }
15884 },
44660702 15885 "leaf" : 1,
7aacca6f 15886 "path" : "/nodes/{node}/lxc/{vmid}/firewall/options",
44660702 15887 "text" : "options"
56122987
DM
15888 },
15889 {
56122987
DM
15890 "info" : {
15891 "GET" : {
44660702 15892 "description" : "Read firewall log",
56122987 15893 "method" : "GET",
7aacca6f 15894 "name" : "log",
56122987
DM
15895 "parameters" : {
15896 "additionalProperties" : 0,
15897 "properties" : {
44660702
DM
15898 "limit" : {
15899 "minimum" : 0,
15900 "optional" : 1,
4bd7df8b 15901 "type" : "integer",
013dc89f 15902 "typetext" : "<integer> (0 - N)"
44660702 15903 },
56122987
DM
15904 "node" : {
15905 "description" : "The cluster node name.",
44660702 15906 "format" : "pve-node",
013dc89f
DM
15907 "type" : "string",
15908 "typetext" : "<string>"
56122987 15909 },
44660702
DM
15910 "start" : {
15911 "minimum" : 0,
7aacca6f 15912 "optional" : 1,
4bd7df8b 15913 "type" : "integer",
013dc89f 15914 "typetext" : "<integer> (0 - N)"
56122987
DM
15915 },
15916 "vmid" : {
44660702 15917 "description" : "The (unique) ID of the VM.",
7aacca6f 15918 "format" : "pve-vmid",
56122987 15919 "minimum" : 1,
4bd7df8b 15920 "type" : "integer",
013dc89f 15921 "typetext" : "<integer> (1 - N)"
56122987
DM
15922 }
15923 }
15924 },
44660702
DM
15925 "permissions" : {
15926 "check" : [
15927 "perm",
15928 "/vms/{vmid}",
15929 [
15930 "VM.Console"
15931 ]
15932 ]
15933 },
56122987 15934 "protected" : 1,
44660702 15935 "proxyto" : "node",
7aacca6f
DM
15936 "returns" : {
15937 "items" : {
15938 "properties" : {
7aacca6f
DM
15939 "n" : {
15940 "description" : "Line number",
15941 "type" : "integer"
44660702
DM
15942 },
15943 "t" : {
15944 "description" : "Line text",
15945 "type" : "string"
7aacca6f
DM
15946 }
15947 },
15948 "type" : "object"
15949 },
15950 "type" : "array"
44660702 15951 }
56122987
DM
15952 }
15953 },
7aacca6f 15954 "leaf" : 1,
44660702
DM
15955 "path" : "/nodes/{node}/lxc/{vmid}/firewall/log",
15956 "text" : "log"
56122987
DM
15957 },
15958 {
56122987
DM
15959 "info" : {
15960 "GET" : {
7aacca6f 15961 "description" : "Lists possible IPSet/Alias reference which are allowed in source/dest properties.",
44660702
DM
15962 "method" : "GET",
15963 "name" : "refs",
56122987 15964 "parameters" : {
7aacca6f 15965 "additionalProperties" : 0,
56122987 15966 "properties" : {
44660702
DM
15967 "node" : {
15968 "description" : "The cluster node name.",
15969 "format" : "pve-node",
013dc89f
DM
15970 "type" : "string",
15971 "typetext" : "<string>"
7aacca6f 15972 },
56122987 15973 "type" : {
44660702 15974 "description" : "Only list references of specified type.",
56122987
DM
15975 "enum" : [
15976 "alias",
15977 "ipset"
15978 ],
44660702
DM
15979 "optional" : 1,
15980 "type" : "string"
56122987 15981 },
44660702
DM
15982 "vmid" : {
15983 "description" : "The (unique) ID of the VM.",
15984 "format" : "pve-vmid",
15985 "minimum" : 1,
4bd7df8b 15986 "type" : "integer",
013dc89f 15987 "typetext" : "<integer> (1 - N)"
56122987 15988 }
7aacca6f 15989 }
56122987 15990 },
44660702
DM
15991 "permissions" : {
15992 "check" : [
15993 "perm",
15994 "/vms/{vmid}",
15995 [
15996 "VM.Audit"
15997 ]
15998 ]
15999 },
56122987 16000 "returns" : {
56122987 16001 "items" : {
56122987 16002 "properties" : {
44660702
DM
16003 "comment" : {
16004 "optional" : 1,
16005 "type" : "string"
16006 },
16007 "name" : {
16008 "type" : "string"
16009 },
56122987 16010 "type" : {
56122987
DM
16011 "enum" : [
16012 "alias",
16013 "ipset"
44660702 16014 ],
7aacca6f 16015 "type" : "string"
56122987 16016 }
44660702
DM
16017 },
16018 "type" : "object"
16019 },
16020 "type" : "array"
56122987
DM
16021 }
16022 }
16023 },
44660702 16024 "leaf" : 1,
7aacca6f 16025 "path" : "/nodes/{node}/lxc/{vmid}/firewall/refs",
44660702 16026 "text" : "refs"
56122987
DM
16027 }
16028 ],
56122987
DM
16029 "info" : {
16030 "GET" : {
7aacca6f 16031 "description" : "Directory index.",
44660702
DM
16032 "method" : "GET",
16033 "name" : "index",
56122987 16034 "parameters" : {
44660702 16035 "additionalProperties" : 0,
56122987 16036 "properties" : {
56122987 16037 "node" : {
44660702 16038 "description" : "The cluster node name.",
56122987 16039 "format" : "pve-node",
013dc89f
DM
16040 "type" : "string",
16041 "typetext" : "<string>"
44660702
DM
16042 },
16043 "vmid" : {
16044 "description" : "The (unique) ID of the VM.",
16045 "format" : "pve-vmid",
16046 "minimum" : 1,
4bd7df8b 16047 "type" : "integer",
013dc89f 16048 "typetext" : "<integer> (1 - N)"
56122987 16049 }
44660702
DM
16050 }
16051 },
16052 "permissions" : {
16053 "user" : "all"
56122987
DM
16054 },
16055 "returns" : {
7aacca6f 16056 "items" : {
44660702
DM
16057 "properties" : {},
16058 "type" : "object"
7aacca6f 16059 },
56122987
DM
16060 "links" : [
16061 {
44660702
DM
16062 "href" : "{name}",
16063 "rel" : "child"
56122987 16064 }
44660702
DM
16065 ],
16066 "type" : "array"
56122987
DM
16067 }
16068 }
16069 },
44660702 16070 "leaf" : 0,
7aacca6f 16071 "path" : "/nodes/{node}/lxc/{vmid}/firewall",
44660702 16072 "text" : "firewall"
56122987
DM
16073 },
16074 {
56122987
DM
16075 "info" : {
16076 "GET" : {
56122987 16077 "description" : "Read VM RRD statistics (returns PNG)",
44660702 16078 "method" : "GET",
7aacca6f 16079 "name" : "rrd",
56122987 16080 "parameters" : {
7aacca6f 16081 "additionalProperties" : 0,
56122987 16082 "properties" : {
44660702
DM
16083 "cf" : {
16084 "description" : "The RRD consolidation function",
16085 "enum" : [
16086 "AVERAGE",
16087 "MAX"
16088 ],
16089 "optional" : 1,
16090 "type" : "string"
16091 },
16092 "ds" : {
16093 "description" : "The list of datasources you want to display.",
16094 "format" : "pve-configid-list",
013dc89f
DM
16095 "type" : "string",
16096 "typetext" : "<string>"
44660702 16097 },
7aacca6f
DM
16098 "node" : {
16099 "description" : "The cluster node name.",
44660702 16100 "format" : "pve-node",
013dc89f
DM
16101 "type" : "string",
16102 "typetext" : "<string>"
56122987
DM
16103 },
16104 "timeframe" : {
16105 "description" : "Specify the time frame you are interested in.",
16106 "enum" : [
16107 "hour",
16108 "day",
16109 "week",
16110 "month",
16111 "year"
7aacca6f 16112 ],
44660702 16113 "type" : "string"
7aacca6f
DM
16114 },
16115 "vmid" : {
44660702 16116 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
16117 "format" : "pve-vmid",
16118 "minimum" : 1,
4bd7df8b 16119 "type" : "integer",
013dc89f 16120 "typetext" : "<integer> (1 - N)"
56122987 16121 }
7aacca6f
DM
16122 }
16123 },
16124 "permissions" : {
16125 "check" : [
16126 "perm",
16127 "/vms/{vmid}",
16128 [
16129 "VM.Audit"
16130 ]
16131 ]
56122987 16132 },
44660702 16133 "protected" : 1,
7aacca6f
DM
16134 "returns" : {
16135 "properties" : {
16136 "filename" : {
16137 "type" : "string"
16138 }
16139 },
16140 "type" : "object"
16141 }
56122987 16142 }
7aacca6f 16143 },
44660702 16144 "leaf" : 1,
7aacca6f 16145 "path" : "/nodes/{node}/lxc/{vmid}/rrd",
44660702 16146 "text" : "rrd"
56122987
DM
16147 },
16148 {
56122987
DM
16149 "info" : {
16150 "GET" : {
44660702
DM
16151 "description" : "Read VM RRD statistics",
16152 "method" : "GET",
16153 "name" : "rrddata",
56122987 16154 "parameters" : {
7aacca6f 16155 "additionalProperties" : 0,
56122987 16156 "properties" : {
44660702
DM
16157 "cf" : {
16158 "description" : "The RRD consolidation function",
16159 "enum" : [
16160 "AVERAGE",
16161 "MAX"
16162 ],
16163 "optional" : 1,
16164 "type" : "string"
16165 },
7aacca6f 16166 "node" : {
44660702 16167 "description" : "The cluster node name.",
7aacca6f 16168 "format" : "pve-node",
013dc89f
DM
16169 "type" : "string",
16170 "typetext" : "<string>"
7aacca6f 16171 },
56122987
DM
16172 "timeframe" : {
16173 "description" : "Specify the time frame you are interested in.",
16174 "enum" : [
16175 "hour",
16176 "day",
16177 "week",
16178 "month",
16179 "year"
44660702
DM
16180 ],
16181 "type" : "string"
7aacca6f
DM
16182 },
16183 "vmid" : {
16184 "description" : "The (unique) ID of the VM.",
44660702 16185 "format" : "pve-vmid",
7aacca6f 16186 "minimum" : 1,
4bd7df8b 16187 "type" : "integer",
013dc89f 16188 "typetext" : "<integer> (1 - N)"
56122987 16189 }
56122987
DM
16190 }
16191 },
56122987
DM
16192 "permissions" : {
16193 "check" : [
16194 "perm",
16195 "/vms/{vmid}",
16196 [
16197 "VM.Audit"
16198 ]
16199 ]
16200 },
7aacca6f
DM
16201 "protected" : 1,
16202 "returns" : {
7aacca6f
DM
16203 "items" : {
16204 "properties" : {},
16205 "type" : "object"
44660702
DM
16206 },
16207 "type" : "array"
16208 }
56122987
DM
16209 }
16210 },
44660702 16211 "leaf" : 1,
7aacca6f 16212 "path" : "/nodes/{node}/lxc/{vmid}/rrddata",
44660702 16213 "text" : "rrddata"
56122987
DM
16214 },
16215 {
16216 "info" : {
16217 "POST" : {
16218 "description" : "Creates a TCP VNC proxy connections.",
44660702
DM
16219 "method" : "POST",
16220 "name" : "vncproxy",
7aacca6f 16221 "parameters" : {
44660702 16222 "additionalProperties" : 0,
7aacca6f 16223 "properties" : {
44660702
DM
16224 "node" : {
16225 "description" : "The cluster node name.",
16226 "format" : "pve-node",
013dc89f
DM
16227 "type" : "string",
16228 "typetext" : "<string>"
44660702 16229 },
7aacca6f 16230 "vmid" : {
44660702 16231 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
16232 "format" : "pve-vmid",
16233 "minimum" : 1,
4bd7df8b 16234 "type" : "integer",
013dc89f 16235 "typetext" : "<integer> (1 - N)"
7aacca6f
DM
16236 },
16237 "websocket" : {
44660702 16238 "description" : "use websocket instead of standard VNC.",
7aacca6f 16239 "optional" : 1,
013dc89f
DM
16240 "type" : "boolean",
16241 "typetext" : "<boolean>"
7aacca6f 16242 }
44660702 16243 }
7aacca6f 16244 },
56122987
DM
16245 "permissions" : {
16246 "check" : [
16247 "perm",
16248 "/vms/{vmid}",
16249 [
16250 "VM.Console"
16251 ]
16252 ]
16253 },
44660702 16254 "protected" : 1,
56122987 16255 "returns" : {
7aacca6f 16256 "additionalProperties" : 0,
56122987 16257 "properties" : {
7aacca6f 16258 "cert" : {
56122987
DM
16259 "type" : "string"
16260 },
44660702
DM
16261 "port" : {
16262 "type" : "integer"
56122987 16263 },
44660702 16264 "ticket" : {
56122987
DM
16265 "type" : "string"
16266 },
44660702 16267 "upid" : {
56122987
DM
16268 "type" : "string"
16269 },
44660702
DM
16270 "user" : {
16271 "type" : "string"
56122987 16272 }
7aacca6f 16273 }
56122987
DM
16274 }
16275 }
16276 },
44660702 16277 "leaf" : 1,
56122987 16278 "path" : "/nodes/{node}/lxc/{vmid}/vncproxy",
44660702 16279 "text" : "vncproxy"
56122987
DM
16280 },
16281 {
56122987
DM
16282 "info" : {
16283 "GET" : {
44660702
DM
16284 "description" : "Opens a weksocket for VNC traffic.",
16285 "method" : "GET",
16286 "name" : "vncwebsocket",
56122987 16287 "parameters" : {
44660702 16288 "additionalProperties" : 0,
56122987 16289 "properties" : {
56122987
DM
16290 "node" : {
16291 "description" : "The cluster node name.",
44660702 16292 "format" : "pve-node",
013dc89f
DM
16293 "type" : "string",
16294 "typetext" : "<string>"
7aacca6f 16295 },
44660702
DM
16296 "port" : {
16297 "description" : "Port number returned by previous vncproxy call.",
16298 "maximum" : 5999,
16299 "minimum" : 5900,
4bd7df8b 16300 "type" : "integer",
013dc89f 16301 "typetext" : "<integer> (5900 - 5999)"
44660702 16302 },
7aacca6f
DM
16303 "vmid" : {
16304 "description" : "The (unique) ID of the VM.",
7aacca6f 16305 "format" : "pve-vmid",
44660702 16306 "minimum" : 1,
4bd7df8b 16307 "type" : "integer",
013dc89f 16308 "typetext" : "<integer> (1 - N)"
44660702
DM
16309 },
16310 "vncticket" : {
16311 "description" : "Ticket from previous call to vncproxy.",
16312 "maxLength" : 512,
013dc89f
DM
16313 "type" : "string",
16314 "typetext" : "<string>"
56122987 16315 }
44660702 16316 }
7aacca6f 16317 },
7aacca6f
DM
16318 "permissions" : {
16319 "check" : [
16320 "perm",
16321 "/vms/{vmid}",
16322 [
16323 "VM.Console"
16324 ]
16325 ],
16326 "description" : "You also need to pass a valid ticket (vncticket)."
56122987
DM
16327 },
16328 "returns" : {
56122987
DM
16329 "properties" : {
16330 "port" : {
16331 "type" : "string"
16332 }
44660702
DM
16333 },
16334 "type" : "object"
16335 }
56122987
DM
16336 }
16337 },
44660702 16338 "leaf" : 1,
7aacca6f 16339 "path" : "/nodes/{node}/lxc/{vmid}/vncwebsocket",
44660702 16340 "text" : "vncwebsocket"
56122987
DM
16341 },
16342 {
56122987
DM
16343 "info" : {
16344 "POST" : {
44660702
DM
16345 "description" : "Returns a SPICE configuration to connect to the CT.",
16346 "method" : "POST",
16347 "name" : "spiceproxy",
56122987
DM
16348 "parameters" : {
16349 "additionalProperties" : 0,
16350 "properties" : {
44660702
DM
16351 "node" : {
16352 "description" : "The cluster node name.",
16353 "format" : "pve-node",
013dc89f
DM
16354 "type" : "string",
16355 "typetext" : "<string>"
56122987
DM
16356 },
16357 "proxy" : {
7aacca6f 16358 "description" : "SPICE proxy server. This can be used by the client to specify the proxy server. All nodes in a cluster runs 'spiceproxy', so it is up to the client to choose one. By default, we return the node where the VM is currently running. As resonable setting is to use same node you use to connect to the API (This is window.location.hostname for the JS GUI).",
44660702
DM
16359 "format" : "address",
16360 "optional" : 1,
013dc89f
DM
16361 "type" : "string",
16362 "typetext" : "<string>"
44660702
DM
16363 },
16364 "vmid" : {
16365 "description" : "The (unique) ID of the VM.",
16366 "format" : "pve-vmid",
16367 "minimum" : 1,
4bd7df8b 16368 "type" : "integer",
013dc89f 16369 "typetext" : "<integer> (1 - N)"
56122987
DM
16370 }
16371 }
16372 },
56122987
DM
16373 "permissions" : {
16374 "check" : [
16375 "perm",
16376 "/vms/{vmid}",
16377 [
16378 "VM.Console"
16379 ]
16380 ]
16381 },
44660702
DM
16382 "protected" : 1,
16383 "proxyto" : "node",
56122987 16384 "returns" : {
7aacca6f 16385 "additionalProperties" : 1,
44660702 16386 "description" : "Returned values can be directly passed to the 'remote-viewer' application.",
56122987 16387 "properties" : {
44660702 16388 "host" : {
56122987
DM
16389 "type" : "string"
16390 },
44660702 16391 "password" : {
56122987
DM
16392 "type" : "string"
16393 },
16394 "proxy" : {
16395 "type" : "string"
16396 },
56122987
DM
16397 "tls-port" : {
16398 "type" : "integer"
7aacca6f 16399 },
44660702 16400 "type" : {
7aacca6f 16401 "type" : "string"
56122987 16402 }
7aacca6f
DM
16403 }
16404 }
56122987 16405 }
44660702
DM
16406 },
16407 "leaf" : 1,
16408 "path" : "/nodes/{node}/lxc/{vmid}/spiceproxy",
16409 "text" : "spiceproxy"
56122987
DM
16410 },
16411 {
56122987
DM
16412 "info" : {
16413 "POST" : {
44660702 16414 "description" : "Migrate the container to another node. Creates a new migration task.",
7aacca6f 16415 "method" : "POST",
44660702 16416 "name" : "migrate_vm",
56122987 16417 "parameters" : {
44660702 16418 "additionalProperties" : 0,
56122987 16419 "properties" : {
44660702 16420 "force" : {
de0983cb 16421 "description" : "Force migration despite local bind / device mounts. NOTE: deprecated, use 'shared' property of mount point instead.",
44660702 16422 "optional" : 1,
013dc89f
DM
16423 "type" : "boolean",
16424 "typetext" : "<boolean>"
44660702
DM
16425 },
16426 "node" : {
16427 "description" : "The cluster node name.",
7aacca6f 16428 "format" : "pve-node",
013dc89f
DM
16429 "type" : "string",
16430 "typetext" : "<string>"
7aacca6f 16431 },
56122987 16432 "online" : {
56122987 16433 "description" : "Use online/live migration.",
44660702 16434 "optional" : 1,
013dc89f
DM
16435 "type" : "boolean",
16436 "typetext" : "<boolean>"
56122987 16437 },
6875b729
DM
16438 "restart" : {
16439 "description" : "Use restart migration",
16440 "optional" : 1,
16441 "type" : "boolean",
16442 "typetext" : "<boolean>"
16443 },
44660702
DM
16444 "target" : {
16445 "description" : "Target node.",
56122987 16446 "format" : "pve-node",
013dc89f
DM
16447 "type" : "string",
16448 "typetext" : "<string>"
56122987 16449 },
6875b729
DM
16450 "timeout" : {
16451 "default" : 180,
16452 "description" : "Timeout in seconds for shutdown for restart migration",
16453 "optional" : 1,
16454 "type" : "integer",
16455 "typetext" : "<integer>"
16456 },
44660702
DM
16457 "vmid" : {
16458 "description" : "The (unique) ID of the VM.",
16459 "format" : "pve-vmid",
16460 "minimum" : 1,
4bd7df8b 16461 "type" : "integer",
013dc89f 16462 "typetext" : "<integer> (1 - N)"
56122987 16463 }
44660702 16464 }
7aacca6f 16465 },
56122987
DM
16466 "permissions" : {
16467 "check" : [
16468 "perm",
16469 "/vms/{vmid}",
16470 [
16471 "VM.Migrate"
16472 ]
16473 ]
16474 },
44660702 16475 "protected" : 1,
7aacca6f 16476 "proxyto" : "node",
44660702
DM
16477 "returns" : {
16478 "description" : "the task ID.",
16479 "type" : "string"
16480 }
56122987
DM
16481 }
16482 },
44660702
DM
16483 "leaf" : 1,
16484 "path" : "/nodes/{node}/lxc/{vmid}/migrate",
7aacca6f 16485 "text" : "migrate"
56122987
DM
16486 },
16487 {
56122987
DM
16488 "info" : {
16489 "GET" : {
44660702
DM
16490 "description" : "Check if feature for virtual machine is available.",
16491 "method" : "GET",
56122987 16492 "name" : "vm_feature",
56122987 16493 "parameters" : {
7aacca6f 16494 "additionalProperties" : 0,
56122987 16495 "properties" : {
44660702
DM
16496 "feature" : {
16497 "description" : "Feature to check.",
16498 "enum" : [
16499 "snapshot"
16500 ],
16501 "type" : "string"
16502 },
7aacca6f 16503 "node" : {
44660702 16504 "description" : "The cluster node name.",
7aacca6f 16505 "format" : "pve-node",
013dc89f
DM
16506 "type" : "string",
16507 "typetext" : "<string>"
7aacca6f 16508 },
56122987 16509 "snapname" : {
7aacca6f
DM
16510 "description" : "The name of the snapshot.",
16511 "format" : "pve-configid",
44660702
DM
16512 "maxLength" : 40,
16513 "optional" : 1,
013dc89f
DM
16514 "type" : "string",
16515 "typetext" : "<string>"
56122987
DM
16516 },
16517 "vmid" : {
7aacca6f 16518 "description" : "The (unique) ID of the VM.",
44660702 16519 "format" : "pve-vmid",
7aacca6f 16520 "minimum" : 1,
4bd7df8b 16521 "type" : "integer",
013dc89f 16522 "typetext" : "<integer> (1 - N)"
56122987 16523 }
7aacca6f 16524 }
56122987
DM
16525 },
16526 "permissions" : {
16527 "check" : [
16528 "perm",
16529 "/vms/{vmid}",
16530 [
16531 "VM.Audit"
16532 ]
16533 ]
16534 },
44660702 16535 "protected" : 1,
7aacca6f 16536 "proxyto" : "node",
7aacca6f
DM
16537 "returns" : {
16538 "properties" : {
16539 "hasFeature" : {
16540 "type" : "boolean"
16541 }
16542 },
16543 "type" : "object"
16544 }
56122987
DM
16545 }
16546 },
7aacca6f 16547 "leaf" : 1,
44660702
DM
16548 "path" : "/nodes/{node}/lxc/{vmid}/feature",
16549 "text" : "feature"
56122987
DM
16550 },
16551 {
56122987
DM
16552 "info" : {
16553 "POST" : {
44660702
DM
16554 "description" : "Create a Template.",
16555 "method" : "POST",
56122987 16556 "name" : "template",
56122987
DM
16557 "parameters" : {
16558 "additionalProperties" : 0,
16559 "properties" : {
44660702
DM
16560 "experimental" : {
16561 "default" : 0,
16562 "description" : "The template feature is experimental, set this flag if you know what you are doing.",
013dc89f
DM
16563 "type" : "boolean",
16564 "typetext" : "<boolean>"
7aacca6f
DM
16565 },
16566 "node" : {
7aacca6f 16567 "description" : "The cluster node name.",
44660702 16568 "format" : "pve-node",
013dc89f
DM
16569 "type" : "string",
16570 "typetext" : "<string>"
56122987 16571 },
44660702
DM
16572 "vmid" : {
16573 "description" : "The (unique) ID of the VM.",
16574 "format" : "pve-vmid",
16575 "minimum" : 1,
4bd7df8b 16576 "type" : "integer",
013dc89f 16577 "typetext" : "<integer> (1 - N)"
56122987
DM
16578 }
16579 }
16580 },
56122987 16581 "permissions" : {
56122987
DM
16582 "check" : [
16583 "perm",
16584 "/vms/{vmid}",
16585 [
16586 "VM.Allocate"
16587 ]
44660702
DM
16588 ],
16589 "description" : "You need 'VM.Allocate' permissions on /vms/{vmid}"
7aacca6f 16590 },
44660702 16591 "protected" : 1,
7aacca6f
DM
16592 "proxyto" : "node",
16593 "returns" : {
16594 "type" : "null"
56122987
DM
16595 }
16596 }
16597 },
44660702 16598 "leaf" : 1,
7aacca6f 16599 "path" : "/nodes/{node}/lxc/{vmid}/template",
44660702 16600 "text" : "template"
56122987
DM
16601 },
16602 {
56122987
DM
16603 "info" : {
16604 "POST" : {
44660702
DM
16605 "description" : "Create a container clone/copy",
16606 "method" : "POST",
56122987 16607 "name" : "clone_vm",
7aacca6f
DM
16608 "parameters" : {
16609 "additionalProperties" : 0,
16610 "properties" : {
44660702
DM
16611 "description" : {
16612 "description" : "Description for the new CT.",
7aacca6f 16613 "optional" : 1,
013dc89f
DM
16614 "type" : "string",
16615 "typetext" : "<string>"
7aacca6f
DM
16616 },
16617 "experimental" : {
7aacca6f 16618 "default" : 0,
44660702 16619 "description" : "The clone feature is experimental, set this flag if you know what you are doing.",
013dc89f
DM
16620 "type" : "boolean",
16621 "typetext" : "<boolean>"
7aacca6f 16622 },
44660702
DM
16623 "full" : {
16624 "default" : 0,
16625 "description" : "Create a full copy of all disk. This is always done when you clone a normal CT. For CT templates, we try to create a linked clone by default.",
7aacca6f 16626 "optional" : 1,
013dc89f
DM
16627 "type" : "boolean",
16628 "typetext" : "<boolean>"
7aacca6f
DM
16629 },
16630 "hostname" : {
44660702 16631 "description" : "Set a hostname for the new CT.",
7aacca6f 16632 "format" : "dns-name",
7aacca6f 16633 "optional" : 1,
013dc89f
DM
16634 "type" : "string",
16635 "typetext" : "<string>"
7aacca6f 16636 },
44660702
DM
16637 "newid" : {
16638 "description" : "VMID for the clone.",
7aacca6f 16639 "format" : "pve-vmid",
44660702 16640 "minimum" : 1,
4bd7df8b 16641 "type" : "integer",
013dc89f 16642 "typetext" : "<integer> (1 - N)"
7aacca6f
DM
16643 },
16644 "node" : {
16645 "description" : "The cluster node name.",
44660702 16646 "format" : "pve-node",
013dc89f
DM
16647 "type" : "string",
16648 "typetext" : "<string>"
44660702
DM
16649 },
16650 "pool" : {
16651 "description" : "Add the new CT to the specified pool.",
16652 "format" : "pve-poolid",
16653 "optional" : 1,
013dc89f
DM
16654 "type" : "string",
16655 "typetext" : "<string>"
7aacca6f
DM
16656 },
16657 "snapname" : {
44660702 16658 "description" : "The name of the snapshot.",
7aacca6f
DM
16659 "format" : "pve-configid",
16660 "maxLength" : 40,
7aacca6f 16661 "optional" : 1,
013dc89f
DM
16662 "type" : "string",
16663 "typetext" : "<string>"
7aacca6f
DM
16664 },
16665 "storage" : {
44660702 16666 "description" : "Target storage for full clone.",
7aacca6f
DM
16667 "format" : "pve-storage-id",
16668 "optional" : 1,
7aacca6f 16669 "requires" : "full",
013dc89f
DM
16670 "type" : "string",
16671 "typetext" : "<string>"
44660702
DM
16672 },
16673 "vmid" : {
16674 "description" : "The (unique) ID of the VM.",
16675 "format" : "pve-vmid",
16676 "minimum" : 1,
4bd7df8b 16677 "type" : "integer",
013dc89f 16678 "typetext" : "<integer> (1 - N)"
7aacca6f
DM
16679 }
16680 }
56122987
DM
16681 },
16682 "permissions" : {
56122987
DM
16683 "check" : [
16684 "and",
16685 [
16686 "perm",
16687 "/vms/{vmid}",
16688 [
16689 "VM.Clone"
16690 ]
16691 ],
16692 [
16693 "or",
16694 [
16695 "perm",
16696 "/vms/{newid}",
16697 [
16698 "VM.Allocate"
16699 ]
16700 ],
16701 [
16702 "perm",
16703 "/pool/{pool}",
16704 [
16705 "VM.Allocate"
16706 ],
16707 "require_param",
16708 "pool"
16709 ]
16710 ]
7aacca6f
DM
16711 ],
16712 "description" : "You need 'VM.Clone' permissions on /vms/{vmid}, and 'VM.Allocate' permissions on /vms/{newid} (or on the VM pool /pool/{pool}). You also need 'Datastore.AllocateSpace' on any used storage."
56122987 16713 },
44660702 16714 "protected" : 1,
56122987 16715 "proxyto" : "node",
7aacca6f
DM
16716 "returns" : {
16717 "type" : "string"
56122987
DM
16718 }
16719 }
44660702
DM
16720 },
16721 "leaf" : 1,
16722 "path" : "/nodes/{node}/lxc/{vmid}/clone",
16723 "text" : "clone"
56122987
DM
16724 },
16725 {
56122987
DM
16726 "info" : {
16727 "PUT" : {
de0983cb 16728 "description" : "Resize a container mount point.",
44660702
DM
16729 "method" : "PUT",
16730 "name" : "resize_vm",
56122987 16731 "parameters" : {
44660702 16732 "additionalProperties" : 0,
56122987 16733 "properties" : {
44660702
DM
16734 "digest" : {
16735 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
16736 "maxLength" : 40,
16737 "optional" : 1,
013dc89f
DM
16738 "type" : "string",
16739 "typetext" : "<string>"
56122987
DM
16740 },
16741 "disk" : {
7aacca6f 16742 "description" : "The disk you want to resize.",
56122987
DM
16743 "enum" : [
16744 "rootfs",
16745 "mp0",
16746 "mp1",
16747 "mp2",
16748 "mp3",
16749 "mp4",
16750 "mp5",
16751 "mp6",
16752 "mp7",
16753 "mp8",
16754 "mp9"
16755 ],
7aacca6f
DM
16756 "type" : "string"
16757 },
44660702
DM
16758 "node" : {
16759 "description" : "The cluster node name.",
16760 "format" : "pve-node",
013dc89f
DM
16761 "type" : "string",
16762 "typetext" : "<string>"
44660702
DM
16763 },
16764 "size" : {
16765 "description" : "The new size. With the '+' sign the value is added to the actual size of the volume and without it, the value is taken as an absolute one. Shrinking disk size is not supported.",
16766 "pattern" : "\\+?\\d+(\\.\\d+)?[KMGT]?",
16767 "type" : "string"
16768 },
16769 "vmid" : {
16770 "description" : "The (unique) ID of the VM.",
16771 "format" : "pve-vmid",
16772 "minimum" : 1,
4bd7df8b 16773 "type" : "integer",
013dc89f 16774 "typetext" : "<integer> (1 - N)"
56122987 16775 }
44660702 16776 }
56122987 16777 },
7aacca6f
DM
16778 "permissions" : {
16779 "check" : [
16780 "perm",
16781 "/vms/{vmid}",
16782 [
16783 "VM.Config.Disk"
16784 ],
16785 "any",
16786 1
16787 ]
16788 },
44660702 16789 "protected" : 1,
7aacca6f
DM
16790 "proxyto" : "node",
16791 "returns" : {
16792 "description" : "the task ID.",
16793 "type" : "string"
16794 }
56122987
DM
16795 }
16796 },
44660702 16797 "leaf" : 1,
7aacca6f 16798 "path" : "/nodes/{node}/lxc/{vmid}/resize",
44660702 16799 "text" : "resize"
56122987
DM
16800 }
16801 ],
16802 "info" : {
16803 "DELETE" : {
7aacca6f 16804 "description" : "Destroy the container (also delete all uses files).",
44660702
DM
16805 "method" : "DELETE",
16806 "name" : "destroy_vm",
16807 "parameters" : {
16808 "additionalProperties" : 0,
16809 "properties" : {
16810 "node" : {
16811 "description" : "The cluster node name.",
16812 "format" : "pve-node",
013dc89f
DM
16813 "type" : "string",
16814 "typetext" : "<string>"
44660702
DM
16815 },
16816 "vmid" : {
16817 "description" : "The (unique) ID of the VM.",
16818 "format" : "pve-vmid",
16819 "minimum" : 1,
4bd7df8b 16820 "type" : "integer",
013dc89f 16821 "typetext" : "<integer> (1 - N)"
44660702
DM
16822 }
16823 }
16824 },
7aacca6f
DM
16825 "permissions" : {
16826 "check" : [
16827 "perm",
16828 "/vms/{vmid}",
16829 [
16830 "VM.Allocate"
16831 ]
16832 ]
16833 },
44660702
DM
16834 "protected" : 1,
16835 "proxyto" : "node",
56122987
DM
16836 "returns" : {
16837 "type" : "string"
44660702 16838 }
56122987
DM
16839 },
16840 "GET" : {
7aacca6f 16841 "description" : "Directory index",
44660702 16842 "method" : "GET",
7aacca6f 16843 "name" : "vmdiridx",
56122987 16844 "parameters" : {
7aacca6f 16845 "additionalProperties" : 0,
56122987
DM
16846 "properties" : {
16847 "node" : {
7aacca6f 16848 "description" : "The cluster node name.",
44660702 16849 "format" : "pve-node",
013dc89f
DM
16850 "type" : "string",
16851 "typetext" : "<string>"
56122987
DM
16852 },
16853 "vmid" : {
16854 "description" : "The (unique) ID of the VM.",
56122987 16855 "format" : "pve-vmid",
44660702 16856 "minimum" : 1,
4bd7df8b 16857 "type" : "integer",
013dc89f 16858 "typetext" : "<integer> (1 - N)"
56122987 16859 }
7aacca6f 16860 }
56122987 16861 },
56122987
DM
16862 "permissions" : {
16863 "user" : "all"
44660702
DM
16864 },
16865 "proxyto" : "node",
16866 "returns" : {
16867 "items" : {
16868 "properties" : {
16869 "subdir" : {
16870 "type" : "string"
16871 }
16872 },
16873 "type" : "object"
16874 },
16875 "links" : [
16876 {
16877 "href" : "{subdir}",
16878 "rel" : "child"
16879 }
16880 ],
16881 "type" : "array"
56122987
DM
16882 }
16883 }
44660702
DM
16884 },
16885 "leaf" : 0,
16886 "path" : "/nodes/{node}/lxc/{vmid}",
16887 "text" : "{vmid}"
56122987
DM
16888 }
16889 ],
56122987 16890 "info" : {
44660702
DM
16891 "GET" : {
16892 "description" : "LXC container index (per node).",
16893 "method" : "GET",
16894 "name" : "vmlist",
16895 "parameters" : {
16896 "additionalProperties" : 0,
16897 "properties" : {
16898 "node" : {
16899 "description" : "The cluster node name.",
16900 "format" : "pve-node",
013dc89f
DM
16901 "type" : "string",
16902 "typetext" : "<string>"
44660702
DM
16903 }
16904 }
16905 },
16906 "permissions" : {
16907 "description" : "Only list CTs where you have VM.Audit permissons on /vms/<vmid>.",
16908 "user" : "all"
16909 },
16910 "protected" : 1,
16911 "proxyto" : "node",
16912 "returns" : {
16913 "items" : {
16914 "properties" : {},
16915 "type" : "object"
16916 },
16917 "links" : [
16918 {
16919 "href" : "{vmid}",
16920 "rel" : "child"
16921 }
16922 ],
16923 "type" : "array"
16924 }
16925 },
56122987 16926 "POST" : {
44660702 16927 "description" : "Create or restore a container.",
7aacca6f
DM
16928 "method" : "POST",
16929 "name" : "create_vm",
56122987 16930 "parameters" : {
7aacca6f 16931 "additionalProperties" : 0,
56122987 16932 "properties" : {
44660702
DM
16933 "arch" : {
16934 "default" : "amd64",
16935 "description" : "OS architecture type.",
16936 "enum" : [
16937 "amd64",
16938 "i386"
16939 ],
7aacca6f 16940 "optional" : 1,
44660702 16941 "type" : "string"
7aacca6f 16942 },
44660702
DM
16943 "cmode" : {
16944 "default" : "tty",
16945 "description" : "Console mode. By default, the console command tries to open a connection to one of the available tty devices. By setting cmode to 'console' it tries to attach to /dev/console instead. If you set cmode to 'shell', it simply invokes a shell inside the container (no login).",
16946 "enum" : [
16947 "shell",
16948 "console",
16949 "tty"
16950 ],
7aacca6f 16951 "optional" : 1,
44660702 16952 "type" : "string"
7aacca6f
DM
16953 },
16954 "console" : {
7aacca6f 16955 "default" : 1,
44660702 16956 "description" : "Attach a console device (/dev/console) to the container.",
56122987 16957 "optional" : 1,
013dc89f
DM
16958 "type" : "boolean",
16959 "typetext" : "<boolean>"
56122987 16960 },
de0983cb
DM
16961 "cores" : {
16962 "description" : "The number of cores assigned to the container. A container can use all available cores by default.",
16963 "maximum" : 128,
16964 "minimum" : 1,
16965 "optional" : 1,
16966 "type" : "integer",
013dc89f 16967 "typetext" : "<integer> (1 - 128)"
de0983cb 16968 },
44660702
DM
16969 "cpulimit" : {
16970 "default" : 0,
16971 "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has a total of '2' CPU time. Value '0' indicates no CPU limit.",
16972 "maximum" : 128,
16973 "minimum" : 0,
56122987 16974 "optional" : 1,
4bd7df8b 16975 "type" : "number",
013dc89f 16976 "typetext" : "<number> (0 - 128)"
56122987 16977 },
44660702
DM
16978 "cpuunits" : {
16979 "default" : 1024,
16980 "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to the weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0.",
16981 "maximum" : 500000,
16982 "minimum" : 0,
56122987 16983 "optional" : 1,
4bd7df8b 16984 "type" : "integer",
013dc89f 16985 "typetext" : "<integer> (0 - 500000)"
7aacca6f
DM
16986 },
16987 "description" : {
44660702 16988 "description" : "Container description. Only used on the configuration web interface.",
7aacca6f 16989 "optional" : 1,
013dc89f
DM
16990 "type" : "string",
16991 "typetext" : "<string>"
7aacca6f 16992 },
44660702
DM
16993 "force" : {
16994 "description" : "Allow to overwrite existing container.",
7aacca6f 16995 "optional" : 1,
013dc89f
DM
16996 "type" : "boolean",
16997 "typetext" : "<boolean>"
44660702
DM
16998 },
16999 "hostname" : {
17000 "description" : "Set a host name for the container.",
17001 "format" : "dns-name",
17002 "maxLength" : 255,
17003 "optional" : 1,
013dc89f
DM
17004 "type" : "string",
17005 "typetext" : "<string>"
44660702
DM
17006 },
17007 "ignore-unpack-errors" : {
17008 "description" : "Ignore errors when extracting the template.",
17009 "optional" : 1,
013dc89f
DM
17010 "type" : "boolean",
17011 "typetext" : "<boolean>"
44660702
DM
17012 },
17013 "lock" : {
17014 "description" : "Lock/unlock the VM.",
7aacca6f
DM
17015 "enum" : [
17016 "migrate",
17017 "backup",
17018 "snapshot",
17019 "rollback"
17020 ],
44660702
DM
17021 "optional" : 1,
17022 "type" : "string"
7aacca6f 17023 },
44660702
DM
17024 "memory" : {
17025 "default" : 512,
17026 "description" : "Amount of RAM for the VM in MB.",
17027 "minimum" : 16,
7aacca6f 17028 "optional" : 1,
4bd7df8b 17029 "type" : "integer",
013dc89f 17030 "typetext" : "<integer> (16 - N)"
44660702
DM
17031 },
17032 "mp[n]" : {
c2993fe5 17033 "description" : "Use volume as container mount point.",
56122987 17034 "format" : {
7aacca6f
DM
17035 "acl" : {
17036 "description" : "Explicitly enable or disable ACL support.",
17037 "optional" : 1,
44660702 17038 "type" : "boolean"
56122987
DM
17039 },
17040 "backup" : {
de0983cb 17041 "description" : "Whether to include the mount point in backups.",
44660702 17042 "optional" : 1,
4bd7df8b 17043 "type" : "boolean",
de0983cb 17044 "verbose_description" : "Whether to include the mount point in backups (only used for volume mount points)."
44660702
DM
17045 },
17046 "mp" : {
de0983cb 17047 "description" : "Path to the mount point as seen from inside the container (must not contain symlinks).",
44660702
DM
17048 "format" : "pve-lxc-mp-string",
17049 "format_description" : "Path",
4bd7df8b 17050 "type" : "string",
de0983cb 17051 "verbose_description" : "Path to the mount point as seen from inside the container.\n\nNOTE: Must not contain any symlinks for security reasons."
44660702
DM
17052 },
17053 "quota" : {
17054 "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)",
7aacca6f 17055 "optional" : 1,
44660702
DM
17056 "type" : "boolean"
17057 },
17058 "ro" : {
de0983cb 17059 "description" : "Read-only mount point",
44660702
DM
17060 "optional" : 1,
17061 "type" : "boolean"
7aacca6f 17062 },
de0983cb
DM
17063 "shared" : {
17064 "default" : 0,
17065 "description" : "Mark this non-volume mount point as available on multiple nodes (see 'nodes')",
17066 "optional" : 1,
17067 "type" : "boolean",
17068 "verbose_description" : "Mark this non-volume mount point as available on all nodes.\n\nWARNING: This option does not share the mount point automatically, it assumes it is shared already!"
17069 },
7aacca6f 17070 "size" : {
44660702 17071 "description" : "Volume size (read only value).",
7aacca6f
DM
17072 "format" : "disk-size",
17073 "format_description" : "DiskSize",
7aacca6f
DM
17074 "optional" : 1,
17075 "type" : "string"
56122987
DM
17076 },
17077 "volume" : {
7aacca6f 17078 "default_key" : 1,
44660702 17079 "description" : "Volume, device or directory to mount into the container.",
56122987 17080 "format" : "pve-lxc-mp-string",
56122987 17081 "format_description" : "volume",
44660702 17082 "type" : "string"
56122987 17083 }
44660702 17084 },
56122987 17085 "optional" : 1,
4bd7df8b 17086 "type" : "string",
de0983cb 17087 "typetext" : "[volume=]<volume> ,mp=<Path> [,acl=<1|0>] [,backup=<1|0>] [,quota=<1|0>] [,ro=<1|0>] [,shared=<1|0>] [,size=<DiskSize>]"
56122987 17088 },
44660702
DM
17089 "nameserver" : {
17090 "description" : "Sets DNS server IP address for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.",
17091 "format" : "address-list",
56122987 17092 "optional" : 1,
013dc89f
DM
17093 "type" : "string",
17094 "typetext" : "<string>"
56122987 17095 },
44660702
DM
17096 "net[n]" : {
17097 "description" : "Specifies network interfaces for the container.",
7aacca6f 17098 "format" : {
44660702
DM
17099 "bridge" : {
17100 "description" : "Bridge to attach the network device to.",
f004f5b9 17101 "format_description" : "bridge",
7aacca6f 17102 "optional" : 1,
44660702
DM
17103 "pattern" : "[-_.\\w\\d]+",
17104 "type" : "string"
7aacca6f 17105 },
44660702
DM
17106 "firewall" : {
17107 "description" : "Controls whether this interface's firewall rules should be used.",
7aacca6f 17108 "optional" : 1,
44660702 17109 "type" : "boolean"
7aacca6f 17110 },
44660702
DM
17111 "gw" : {
17112 "description" : "Default gateway for IPv4 traffic.",
17113 "format" : "ipv4",
17114 "format_description" : "GatewayIPv4",
7aacca6f 17115 "optional" : 1,
44660702 17116 "type" : "string"
7aacca6f 17117 },
44660702
DM
17118 "gw6" : {
17119 "description" : "Default gateway for IPv6 traffic.",
17120 "format" : "ipv6",
17121 "format_description" : "GatewayIPv6",
17122 "optional" : 1,
17123 "type" : "string"
7aacca6f 17124 },
44660702 17125 "hwaddr" : {
f004f5b9
DM
17126 "description" : "The interface MAC address. This is dynamically allocated by default, but you can set that statically if needed, for example to always have the same link-local IPv6 address. (lxc.network.hwaddr)",
17127 "format_description" : "XX:XX:XX:XX:XX:XX",
44660702
DM
17128 "optional" : 1,
17129 "pattern" : "(?^i:(?:[a-f0-9]{2}:){5}[a-f0-9]{2})",
7aacca6f
DM
17130 "type" : "string"
17131 },
44660702
DM
17132 "ip" : {
17133 "description" : "IPv4 address in CIDR format.",
17134 "format" : "pve-ipv4-config",
17135 "format_description" : "IPv4Format/CIDR",
7aacca6f 17136 "optional" : 1,
44660702 17137 "type" : "string"
7aacca6f 17138 },
44660702
DM
17139 "ip6" : {
17140 "description" : "IPv6 address in CIDR format.",
17141 "format" : "pve-ipv6-config",
17142 "format_description" : "IPv6Format/CIDR",
17143 "optional" : 1,
17144 "type" : "string"
17145 },
17146 "mtu" : {
17147 "description" : "Maximum transfer unit of the interface. (lxc.network.mtu)",
44660702
DM
17148 "minimum" : 64,
17149 "optional" : 1,
17150 "type" : "integer"
17151 },
17152 "name" : {
17153 "description" : "Name of the network device as seen from inside the container. (lxc.network.name)",
f004f5b9 17154 "format_description" : "string",
44660702
DM
17155 "pattern" : "[-_.\\w\\d]+",
17156 "type" : "string"
17157 },
17158 "rate" : {
17159 "description" : "Apply rate limiting to the interface",
17160 "format_description" : "mbps",
17161 "optional" : 1,
17162 "type" : "number"
17163 },
17164 "tag" : {
17165 "description" : "VLAN tag for this interface.",
4bd7df8b
DM
17166 "maximum" : 4094,
17167 "minimum" : 1,
44660702
DM
17168 "optional" : 1,
17169 "type" : "integer"
17170 },
17171 "trunks" : {
17172 "description" : "VLAN ids to pass through the interface",
17173 "format_description" : "vlanid[;vlanid...]",
17174 "optional" : 1,
17175 "pattern" : "(?^:\\d+(?:;\\d+)*)",
17176 "type" : "string"
17177 },
17178 "type" : {
17179 "description" : "Network interface type.",
17180 "enum" : [
17181 "veth"
17182 ],
17183 "optional" : 1,
17184 "type" : "string"
7aacca6f
DM
17185 }
17186 },
56122987 17187 "optional" : 1,
4bd7df8b
DM
17188 "type" : "string",
17189 "typetext" : "name=<string> [,bridge=<bridge>] [,firewall=<1|0>] [,gw=<GatewayIPv4>] [,gw6=<GatewayIPv6>] [,hwaddr=<XX:XX:XX:XX:XX:XX>] [,ip=<IPv4Format/CIDR>] [,ip6=<IPv6Format/CIDR>] [,mtu=<integer>] [,rate=<mbps>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,type=<veth>]"
56122987 17190 },
44660702
DM
17191 "node" : {
17192 "description" : "The cluster node name.",
17193 "format" : "pve-node",
013dc89f
DM
17194 "type" : "string",
17195 "typetext" : "<string>"
56122987 17196 },
44660702
DM
17197 "onboot" : {
17198 "default" : 0,
17199 "description" : "Specifies whether a VM will be started during system bootup.",
56122987 17200 "optional" : 1,
013dc89f
DM
17201 "type" : "boolean",
17202 "typetext" : "<boolean>"
44660702
DM
17203 },
17204 "ostemplate" : {
17205 "description" : "The OS template or backup file.",
17206 "maxLength" : 255,
013dc89f
DM
17207 "type" : "string",
17208 "typetext" : "<string>"
56122987
DM
17209 },
17210 "ostype" : {
7aacca6f 17211 "description" : "OS type. This is used to setup configuration inside the container, and corresponds to lxc setup scripts in /usr/share/lxc/config/<ostype>.common.conf. Value 'unmanaged' can be used to skip and OS specific setup.",
56122987
DM
17212 "enum" : [
17213 "debian",
17214 "ubuntu",
17215 "centos",
17216 "fedora",
17217 "opensuse",
17218 "archlinux",
17219 "alpine",
57b78691 17220 "gentoo",
56122987 17221 "unmanaged"
44660702 17222 ],
56122987 17223 "optional" : 1,
7aacca6f 17224 "type" : "string"
56122987 17225 },
44660702
DM
17226 "password" : {
17227 "description" : "Sets root password inside container.",
17228 "minLength" : 5,
7aacca6f 17229 "optional" : 1,
013dc89f
DM
17230 "type" : "string",
17231 "typetext" : "<string>"
7aacca6f 17232 },
44660702
DM
17233 "pool" : {
17234 "description" : "Add the VM to the specified pool.",
17235 "format" : "pve-poolid",
7aacca6f 17236 "optional" : 1,
013dc89f
DM
17237 "type" : "string",
17238 "typetext" : "<string>"
7aacca6f 17239 },
44660702
DM
17240 "protection" : {
17241 "default" : 0,
17242 "description" : "Sets the protection flag of the container. This will prevent the CT or CT's disk remove/update operation.",
7aacca6f 17243 "optional" : 1,
013dc89f
DM
17244 "type" : "boolean",
17245 "typetext" : "<boolean>"
7aacca6f 17246 },
44660702
DM
17247 "restore" : {
17248 "description" : "Mark this as restore task.",
17249 "optional" : 1,
013dc89f
DM
17250 "type" : "boolean",
17251 "typetext" : "<boolean>"
7aacca6f 17252 },
44660702
DM
17253 "rootfs" : {
17254 "description" : "Use volume as container root.",
56122987 17255 "format" : {
44660702
DM
17256 "acl" : {
17257 "description" : "Explicitly enable or disable ACL support.",
56122987 17258 "optional" : 1,
44660702 17259 "type" : "boolean"
56122987 17260 },
44660702
DM
17261 "quota" : {
17262 "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)",
7aacca6f 17263 "optional" : 1,
44660702 17264 "type" : "boolean"
7aacca6f 17265 },
44660702 17266 "ro" : {
de0983cb 17267 "description" : "Read-only mount point",
7aacca6f 17268 "optional" : 1,
44660702 17269 "type" : "boolean"
7aacca6f 17270 },
de0983cb
DM
17271 "shared" : {
17272 "default" : 0,
17273 "description" : "Mark this non-volume mount point as available on multiple nodes (see 'nodes')",
17274 "optional" : 1,
17275 "type" : "boolean",
17276 "verbose_description" : "Mark this non-volume mount point as available on all nodes.\n\nWARNING: This option does not share the mount point automatically, it assumes it is shared already!"
17277 },
44660702
DM
17278 "size" : {
17279 "description" : "Volume size (read only value).",
17280 "format" : "disk-size",
17281 "format_description" : "DiskSize",
7aacca6f
DM
17282 "optional" : 1,
17283 "type" : "string"
17284 },
44660702
DM
17285 "volume" : {
17286 "default_key" : 1,
17287 "description" : "Volume, device or directory to mount into the container.",
17288 "format" : "pve-lxc-mp-string",
17289 "format_description" : "volume",
17290 "type" : "string"
56122987 17291 }
7aacca6f 17292 },
7aacca6f 17293 "optional" : 1,
4bd7df8b 17294 "type" : "string",
de0983cb 17295 "typetext" : "[volume=]<volume> [,acl=<1|0>] [,quota=<1|0>] [,ro=<1|0>] [,shared=<1|0>] [,size=<DiskSize>]"
44660702
DM
17296 },
17297 "searchdomain" : {
17298 "description" : "Sets DNS search domains for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.",
17299 "format" : "dns-name-list",
17300 "optional" : 1,
013dc89f
DM
17301 "type" : "string",
17302 "typetext" : "<string>"
44660702
DM
17303 },
17304 "ssh-public-keys" : {
17305 "description" : "Setup public SSH keys (one key per line, OpenSSH format).",
17306 "optional" : 1,
013dc89f
DM
17307 "type" : "string",
17308 "typetext" : "<string>"
44660702
DM
17309 },
17310 "startup" : {
17311 "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.",
17312 "format" : "pve-startup-order",
17313 "optional" : 1,
7aacca6f 17314 "type" : "string",
44660702 17315 "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] "
7aacca6f 17316 },
44660702
DM
17317 "storage" : {
17318 "default" : "local",
17319 "description" : "Default Storage.",
17320 "format" : "pve-storage-id",
17321 "optional" : 1,
013dc89f
DM
17322 "type" : "string",
17323 "typetext" : "<string>"
7aacca6f 17324 },
44660702
DM
17325 "swap" : {
17326 "default" : 512,
17327 "description" : "Amount of SWAP for the VM in MB.",
17328 "minimum" : 0,
17329 "optional" : 1,
4bd7df8b 17330 "type" : "integer",
013dc89f 17331 "typetext" : "<integer> (0 - N)"
44660702
DM
17332 },
17333 "template" : {
17334 "default" : 0,
17335 "description" : "Enable/disable Template.",
17336 "optional" : 1,
013dc89f
DM
17337 "type" : "boolean",
17338 "typetext" : "<boolean>"
7aacca6f 17339 },
44660702
DM
17340 "tty" : {
17341 "default" : 2,
17342 "description" : "Specify the number of tty available to the container",
17343 "maximum" : 6,
17344 "minimum" : 0,
17345 "optional" : 1,
4bd7df8b 17346 "type" : "integer",
013dc89f 17347 "typetext" : "<integer> (0 - 6)"
7aacca6f 17348 },
44660702
DM
17349 "unprivileged" : {
17350 "default" : 0,
17351 "description" : "Makes the container run as unprivileged user. (Should not be modified manually.)",
17352 "optional" : 1,
013dc89f
DM
17353 "type" : "boolean",
17354 "typetext" : "<boolean>"
44660702
DM
17355 },
17356 "unused[n]" : {
c2993fe5 17357 "description" : "Reference to unused volumes. This is used internally, and should not be modified manually.",
44660702
DM
17358 "format" : "pve-volume-id",
17359 "optional" : 1,
013dc89f
DM
17360 "type" : "string",
17361 "typetext" : "<string>"
44660702
DM
17362 },
17363 "vmid" : {
17364 "description" : "The (unique) ID of the VM.",
17365 "format" : "pve-vmid",
17366 "minimum" : 1,
4bd7df8b 17367 "type" : "integer",
013dc89f 17368 "typetext" : "<integer> (1 - N)"
44660702 17369 }
7aacca6f
DM
17370 }
17371 },
44660702
DM
17372 "permissions" : {
17373 "description" : "You need 'VM.Allocate' permissions on /vms/{vmid} or on the VM pool /pool/{pool}. For restore, it is enough if the user has 'VM.Backup' permission and the VM already exists. You also need 'Datastore.AllocateSpace' permissions on the storage.",
17374 "user" : "all"
17375 },
17376 "protected" : 1,
17377 "proxyto" : "node",
17378 "returns" : {
17379 "type" : "string"
17380 }
17381 }
17382 },
17383 "leaf" : 0,
17384 "path" : "/nodes/{node}/lxc",
17385 "text" : "lxc"
17386 },
17387 {
17388 "children" : [
17389 {
56122987
DM
17390 "children" : [
17391 {
7aacca6f
DM
17392 "children" : [
17393 {
7aacca6f
DM
17394 "info" : {
17395 "POST" : {
44660702
DM
17396 "description" : "ceph osd in",
17397 "method" : "POST",
17398 "name" : "in",
17399 "parameters" : {
17400 "additionalProperties" : 0,
17401 "properties" : {
17402 "node" : {
17403 "description" : "The cluster node name.",
17404 "format" : "pve-node",
013dc89f
DM
17405 "type" : "string",
17406 "typetext" : "<string>"
44660702
DM
17407 },
17408 "osdid" : {
17409 "description" : "OSD ID",
013dc89f
DM
17410 "type" : "integer",
17411 "typetext" : "<integer>"
44660702
DM
17412 }
17413 }
17414 },
56122987
DM
17415 "permissions" : {
17416 "check" : [
17417 "perm",
17418 "/",
17419 [
17420 "Sys.Modify"
17421 ]
17422 ]
7aacca6f 17423 },
44660702 17424 "protected" : 1,
7aacca6f
DM
17425 "proxyto" : "node",
17426 "returns" : {
17427 "type" : "null"
44660702 17428 }
56122987
DM
17429 }
17430 },
44660702 17431 "leaf" : 1,
7aacca6f 17432 "path" : "/nodes/{node}/ceph/osd/{osdid}/in",
44660702 17433 "text" : "in"
56122987
DM
17434 },
17435 {
56122987
DM
17436 "info" : {
17437 "POST" : {
44660702
DM
17438 "description" : "ceph osd out",
17439 "method" : "POST",
17440 "name" : "out",
17441 "parameters" : {
17442 "additionalProperties" : 0,
17443 "properties" : {
17444 "node" : {
17445 "description" : "The cluster node name.",
17446 "format" : "pve-node",
013dc89f
DM
17447 "type" : "string",
17448 "typetext" : "<string>"
44660702
DM
17449 },
17450 "osdid" : {
17451 "description" : "OSD ID",
013dc89f
DM
17452 "type" : "integer",
17453 "typetext" : "<integer>"
44660702
DM
17454 }
17455 }
17456 },
56122987
DM
17457 "permissions" : {
17458 "check" : [
17459 "perm",
17460 "/",
17461 [
17462 "Sys.Modify"
17463 ]
17464 ]
17465 },
44660702 17466 "protected" : 1,
56122987 17467 "proxyto" : "node",
7aacca6f
DM
17468 "returns" : {
17469 "type" : "null"
44660702
DM
17470 }
17471 }
17472 },
17473 "leaf" : 1,
17474 "path" : "/nodes/{node}/ceph/osd/{osdid}/out",
17475 "text" : "out"
17476 }
17477 ],
17478 "info" : {
17479 "DELETE" : {
17480 "description" : "Destroy OSD",
17481 "method" : "DELETE",
17482 "name" : "destroyosd",
17483 "parameters" : {
17484 "additionalProperties" : 0,
17485 "properties" : {
17486 "cleanup" : {
17487 "default" : 0,
17488 "description" : "If set, we remove partition table entries.",
17489 "optional" : 1,
013dc89f
DM
17490 "type" : "boolean",
17491 "typetext" : "<boolean>"
7aacca6f 17492 },
44660702
DM
17493 "node" : {
17494 "description" : "The cluster node name.",
17495 "format" : "pve-node",
013dc89f
DM
17496 "type" : "string",
17497 "typetext" : "<string>"
56122987 17498 },
44660702
DM
17499 "osdid" : {
17500 "description" : "OSD ID",
013dc89f
DM
17501 "type" : "integer",
17502 "typetext" : "<integer>"
44660702 17503 }
56122987
DM
17504 }
17505 },
44660702
DM
17506 "protected" : 1,
17507 "proxyto" : "node",
17508 "returns" : {
17509 "type" : "string"
17510 }
17511 }
17512 },
17513 "leaf" : 0,
17514 "path" : "/nodes/{node}/ceph/osd/{osdid}",
17515 "text" : "{osdid}"
17516 }
17517 ],
17518 "info" : {
17519 "GET" : {
17520 "description" : "Get Ceph osd list/tree.",
17521 "method" : "GET",
17522 "name" : "index",
17523 "parameters" : {
17524 "additionalProperties" : 0,
17525 "properties" : {
17526 "node" : {
17527 "description" : "The cluster node name.",
17528 "format" : "pve-node",
013dc89f
DM
17529 "type" : "string",
17530 "typetext" : "<string>"
44660702
DM
17531 }
17532 }
17533 },
17534 "permissions" : {
17535 "check" : [
17536 "perm",
17537 "/",
17538 [
17539 "Sys.Audit",
17540 "Datastore.Audit"
17541 ],
17542 "any",
17543 1
17544 ]
17545 },
17546 "protected" : 1,
17547 "proxyto" : "node",
17548 "returns" : {
17549 "type" : "object"
17550 }
17551 },
17552 "POST" : {
17553 "description" : "Create OSD",
17554 "method" : "POST",
17555 "name" : "createosd",
17556 "parameters" : {
17557 "additionalProperties" : 0,
17558 "properties" : {
17559 "dev" : {
17560 "description" : "Block device name.",
013dc89f
DM
17561 "type" : "string",
17562 "typetext" : "<string>"
44660702
DM
17563 },
17564 "fstype" : {
17565 "default" : "xfs",
17566 "description" : "File system type.",
17567 "enum" : [
17568 "xfs",
17569 "ext4",
17570 "btrfs"
17571 ],
17572 "optional" : 1,
17573 "type" : "string"
17574 },
17575 "journal_dev" : {
17576 "description" : "Block device name for journal.",
17577 "optional" : 1,
013dc89f
DM
17578 "type" : "string",
17579 "typetext" : "<string>"
44660702
DM
17580 },
17581 "node" : {
17582 "description" : "The cluster node name.",
17583 "format" : "pve-node",
013dc89f
DM
17584 "type" : "string",
17585 "typetext" : "<string>"
44660702 17586 }
56122987 17587 }
44660702
DM
17588 },
17589 "protected" : 1,
17590 "proxyto" : "node",
17591 "returns" : {
17592 "type" : "string"
17593 }
56122987 17594 }
44660702 17595 },
7aacca6f 17596 "leaf" : 0,
44660702
DM
17597 "path" : "/nodes/{node}/ceph/osd",
17598 "text" : "osd"
7aacca6f
DM
17599 },
17600 {
56122987
DM
17601 "info" : {
17602 "GET" : {
7aacca6f 17603 "description" : "List local disks.",
44660702
DM
17604 "method" : "GET",
17605 "name" : "disks",
17606 "parameters" : {
17607 "additionalProperties" : 0,
17608 "properties" : {
17609 "node" : {
17610 "description" : "The cluster node name.",
17611 "format" : "pve-node",
013dc89f
DM
17612 "type" : "string",
17613 "typetext" : "<string>"
44660702
DM
17614 },
17615 "type" : {
17616 "description" : "Only list specific types of disks.",
17617 "enum" : [
17618 "unused",
17619 "journal_disks"
17620 ],
17621 "optional" : 1,
17622 "type" : "string"
17623 }
17624 }
17625 },
56122987
DM
17626 "permissions" : {
17627 "check" : [
17628 "perm",
17629 "/",
17630 [
17631 "Sys.Audit",
17632 "Datastore.Audit"
17633 ],
17634 "any",
17635 1
17636 ]
7aacca6f 17637 },
44660702
DM
17638 "protected" : 1,
17639 "proxyto" : "node",
56122987 17640 "returns" : {
7aacca6f
DM
17641 "items" : {
17642 "properties" : {
44660702
DM
17643 "dev" : {
17644 "type" : "string"
17645 },
17646 "gpt" : {
17647 "type" : "boolean"
17648 },
17649 "model" : {
17650 "optional" : 1,
17651 "type" : "string"
7aacca6f
DM
17652 },
17653 "osdid" : {
17654 "type" : "integer"
17655 },
17656 "serial" : {
7aacca6f
DM
17657 "optional" : 1,
17658 "type" : "string"
17659 },
17660 "size" : {
17661 "type" : "integer"
17662 },
44660702
DM
17663 "used" : {
17664 "optional" : 1,
7aacca6f
DM
17665 "type" : "string"
17666 },
44660702
DM
17667 "vendor" : {
17668 "optional" : 1,
17669 "type" : "string"
7aacca6f
DM
17670 }
17671 },
17672 "type" : "object"
44660702
DM
17673 },
17674 "type" : "array"
17675 }
56122987 17676 }
44660702
DM
17677 },
17678 "leaf" : 1,
17679 "path" : "/nodes/{node}/ceph/disks",
17680 "text" : "disks"
56122987
DM
17681 },
17682 {
56122987
DM
17683 "info" : {
17684 "GET" : {
7aacca6f 17685 "description" : "Get Ceph configuration.",
44660702
DM
17686 "method" : "GET",
17687 "name" : "config",
56122987 17688 "parameters" : {
7aacca6f 17689 "additionalProperties" : 0,
56122987 17690 "properties" : {
56122987 17691 "node" : {
7aacca6f 17692 "description" : "The cluster node name.",
44660702 17693 "format" : "pve-node",
013dc89f
DM
17694 "type" : "string",
17695 "typetext" : "<string>"
56122987 17696 }
7aacca6f 17697 }
56122987 17698 },
56122987
DM
17699 "permissions" : {
17700 "check" : [
17701 "perm",
17702 "/",
17703 [
17704 "Sys.Audit",
17705 "Datastore.Audit"
17706 ],
17707 "any",
17708 1
17709 ]
44660702
DM
17710 },
17711 "returns" : {
17712 "type" : "string"
7aacca6f
DM
17713 }
17714 }
44660702
DM
17715 },
17716 "leaf" : 1,
17717 "path" : "/nodes/{node}/ceph/config",
17718 "text" : "config"
7aacca6f
DM
17719 },
17720 {
7aacca6f
DM
17721 "children" : [
17722 {
7aacca6f
DM
17723 "info" : {
17724 "DELETE" : {
7aacca6f 17725 "description" : "Destroy Ceph monitor.",
44660702
DM
17726 "method" : "DELETE",
17727 "name" : "destroymon",
17728 "parameters" : {
17729 "additionalProperties" : 0,
17730 "properties" : {
17731 "monid" : {
17732 "description" : "Monitor ID",
013dc89f
DM
17733 "type" : "integer",
17734 "typetext" : "<integer>"
44660702
DM
17735 },
17736 "node" : {
17737 "description" : "The cluster node name.",
17738 "format" : "pve-node",
013dc89f
DM
17739 "type" : "string",
17740 "typetext" : "<string>"
44660702
DM
17741 }
17742 }
17743 },
7aacca6f
DM
17744 "permissions" : {
17745 "check" : [
17746 "perm",
17747 "/",
17748 [
17749 "Sys.Modify"
17750 ]
17751 ]
17752 },
44660702
DM
17753 "protected" : 1,
17754 "proxyto" : "node",
7aacca6f
DM
17755 "returns" : {
17756 "type" : "string"
44660702 17757 }
7aacca6f 17758 }
44660702
DM
17759 },
17760 "leaf" : 1,
17761 "path" : "/nodes/{node}/ceph/mon/{monid}",
17762 "text" : "{monid}"
7aacca6f
DM
17763 }
17764 ],
17765 "info" : {
17766 "GET" : {
44660702 17767 "description" : "Get Ceph monitor list.",
7aacca6f 17768 "method" : "GET",
44660702 17769 "name" : "listmon",
7aacca6f
DM
17770 "parameters" : {
17771 "additionalProperties" : 0,
17772 "properties" : {
17773 "node" : {
7aacca6f 17774 "description" : "The cluster node name.",
44660702 17775 "format" : "pve-node",
013dc89f
DM
17776 "type" : "string",
17777 "typetext" : "<string>"
7aacca6f
DM
17778 }
17779 }
17780 },
44660702
DM
17781 "permissions" : {
17782 "check" : [
17783 "perm",
17784 "/",
17785 [
17786 "Sys.Audit",
17787 "Datastore.Audit"
17788 ],
17789 "any",
17790 1
17791 ]
17792 },
7aacca6f 17793 "protected" : 1,
44660702 17794 "proxyto" : "node",
7aacca6f
DM
17795 "returns" : {
17796 "items" : {
17797 "properties" : {
44660702 17798 "addr" : {
7aacca6f 17799 "type" : "string"
56122987 17800 },
44660702 17801 "name" : {
56122987
DM
17802 "type" : "string"
17803 }
7aacca6f
DM
17804 },
17805 "type" : "object"
56122987 17806 },
7aacca6f
DM
17807 "links" : [
17808 {
17809 "href" : "{name}",
17810 "rel" : "child"
17811 }
17812 ],
56122987 17813 "type" : "array"
44660702 17814 }
7aacca6f
DM
17815 },
17816 "POST" : {
44660702
DM
17817 "description" : "Create Ceph Monitor",
17818 "method" : "POST",
17819 "name" : "createmon",
17820 "parameters" : {
17821 "additionalProperties" : 0,
17822 "properties" : {
17823 "node" : {
17824 "description" : "The cluster node name.",
17825 "format" : "pve-node",
013dc89f
DM
17826 "type" : "string",
17827 "typetext" : "<string>"
44660702
DM
17828 }
17829 }
17830 },
7aacca6f
DM
17831 "permissions" : {
17832 "check" : [
17833 "perm",
17834 "/",
17835 [
17836 "Sys.Modify"
17837 ]
17838 ]
17839 },
44660702 17840 "protected" : 1,
7aacca6f 17841 "proxyto" : "node",
56122987
DM
17842 "returns" : {
17843 "type" : "string"
44660702 17844 }
56122987 17845 }
44660702
DM
17846 },
17847 "leaf" : 0,
17848 "path" : "/nodes/{node}/ceph/mon",
17849 "text" : "mon"
56122987
DM
17850 },
17851 {
17852 "info" : {
17853 "POST" : {
44660702
DM
17854 "description" : "Create initial ceph default configuration and setup symlinks.",
17855 "method" : "POST",
17856 "name" : "init",
17857 "parameters" : {
17858 "additionalProperties" : 0,
17859 "properties" : {
17860 "network" : {
17861 "description" : "Use specific network for all ceph related traffic",
17862 "format" : "CIDR",
17863 "maxLength" : 128,
17864 "optional" : 1,
013dc89f
DM
17865 "type" : "string",
17866 "typetext" : "<string>"
44660702
DM
17867 },
17868 "node" : {
17869 "description" : "The cluster node name.",
17870 "format" : "pve-node",
013dc89f
DM
17871 "type" : "string",
17872 "typetext" : "<string>"
44660702
DM
17873 },
17874 "pg_bits" : {
17875 "default" : 6,
17876 "description" : "Placement group bits, used to specify the default number of placement groups.\n\nNOTE: 'osd pool default pg num' does not work for default pools.",
17877 "maximum" : 14,
17878 "minimum" : 6,
17879 "optional" : 1,
4bd7df8b 17880 "type" : "integer",
013dc89f 17881 "typetext" : "<integer> (6 - 14)"
44660702
DM
17882 },
17883 "size" : {
17884 "default" : 2,
17885 "description" : "Number of replicas per object",
17886 "maximum" : 3,
17887 "minimum" : 1,
17888 "optional" : 1,
4bd7df8b 17889 "type" : "integer",
013dc89f 17890 "typetext" : "<integer> (1 - 3)"
44660702
DM
17891 }
17892 }
7aacca6f 17893 },
56122987
DM
17894 "permissions" : {
17895 "check" : [
17896 "perm",
17897 "/",
17898 [
17899 "Sys.Modify"
17900 ]
17901 ]
17902 },
7aacca6f 17903 "protected" : 1,
44660702
DM
17904 "proxyto" : "node",
17905 "returns" : {
17906 "type" : "null"
7aacca6f
DM
17907 }
17908 }
17909 },
7aacca6f 17910 "leaf" : 1,
44660702
DM
17911 "path" : "/nodes/{node}/ceph/init",
17912 "text" : "init"
7aacca6f
DM
17913 },
17914 {
7aacca6f
DM
17915 "info" : {
17916 "POST" : {
44660702 17917 "description" : "Stop ceph services.",
7aacca6f
DM
17918 "method" : "POST",
17919 "name" : "stop",
17920 "parameters" : {
44660702 17921 "additionalProperties" : 0,
7aacca6f
DM
17922 "properties" : {
17923 "node" : {
7aacca6f 17924 "description" : "The cluster node name.",
44660702 17925 "format" : "pve-node",
013dc89f
DM
17926 "type" : "string",
17927 "typetext" : "<string>"
7aacca6f
DM
17928 },
17929 "service" : {
7aacca6f 17930 "description" : "Ceph service name.",
44660702
DM
17931 "optional" : 1,
17932 "pattern" : "(mon|mds|osd)\\.[A-Za-z0-9]{1,32}",
17933 "type" : "string"
56122987 17934 }
44660702 17935 }
7aacca6f
DM
17936 },
17937 "permissions" : {
17938 "check" : [
17939 "perm",
17940 "/",
17941 [
17942 "Sys.Modify"
17943 ]
17944 ]
17945 },
44660702
DM
17946 "protected" : 1,
17947 "proxyto" : "node",
17948 "returns" : {
17949 "type" : "string"
17950 }
7aacca6f 17951 }
44660702
DM
17952 },
17953 "leaf" : 1,
17954 "path" : "/nodes/{node}/ceph/stop",
17955 "text" : "stop"
7aacca6f
DM
17956 },
17957 {
7aacca6f
DM
17958 "info" : {
17959 "POST" : {
7aacca6f 17960 "description" : "Start ceph services.",
44660702 17961 "method" : "POST",
7aacca6f 17962 "name" : "start",
56122987
DM
17963 "parameters" : {
17964 "additionalProperties" : 0,
17965 "properties" : {
17966 "node" : {
7aacca6f 17967 "description" : "The cluster node name.",
44660702 17968 "format" : "pve-node",
013dc89f
DM
17969 "type" : "string",
17970 "typetext" : "<string>"
7aacca6f
DM
17971 },
17972 "service" : {
17973 "description" : "Ceph service name.",
44660702 17974 "optional" : 1,
7aacca6f 17975 "pattern" : "(mon|mds|osd)\\.[A-Za-z0-9]{1,32}",
44660702 17976 "type" : "string"
7aacca6f
DM
17977 }
17978 }
17979 },
44660702
DM
17980 "permissions" : {
17981 "check" : [
17982 "perm",
17983 "/",
17984 [
17985 "Sys.Modify"
17986 ]
17987 ]
17988 },
7aacca6f 17989 "protected" : 1,
44660702
DM
17990 "proxyto" : "node",
17991 "returns" : {
17992 "type" : "string"
17993 }
7aacca6f 17994 }
44660702
DM
17995 },
17996 "leaf" : 1,
17997 "path" : "/nodes/{node}/ceph/start",
17998 "text" : "start"
7aacca6f
DM
17999 },
18000 {
7aacca6f
DM
18001 "info" : {
18002 "GET" : {
44660702
DM
18003 "description" : "Get ceph status.",
18004 "method" : "GET",
18005 "name" : "status",
7aacca6f
DM
18006 "parameters" : {
18007 "additionalProperties" : 0,
18008 "properties" : {
18009 "node" : {
7aacca6f 18010 "description" : "The cluster node name.",
44660702 18011 "format" : "pve-node",
013dc89f
DM
18012 "type" : "string",
18013 "typetext" : "<string>"
56122987
DM
18014 }
18015 }
18016 },
18017 "permissions" : {
18018 "check" : [
18019 "perm",
18020 "/",
18021 [
18022 "Sys.Audit",
18023 "Datastore.Audit"
18024 ],
18025 "any",
18026 1
18027 ]
18028 },
44660702
DM
18029 "protected" : 1,
18030 "proxyto" : "node",
56122987 18031 "returns" : {
7aacca6f
DM
18032 "type" : "object"
18033 }
18034 }
18035 },
44660702 18036 "leaf" : 1,
7aacca6f 18037 "path" : "/nodes/{node}/ceph/status",
44660702 18038 "text" : "status"
7aacca6f
DM
18039 },
18040 {
44660702
DM
18041 "children" : [
18042 {
18043 "info" : {
18044 "DELETE" : {
18045 "description" : "Destroy pool",
18046 "method" : "DELETE",
18047 "name" : "destroypool",
18048 "parameters" : {
18049 "additionalProperties" : 0,
18050 "properties" : {
4bd7df8b
DM
18051 "force" : {
18052 "default" : 0,
18053 "description" : "If true, destroys pool even if in use",
18054 "optional" : 1,
013dc89f
DM
18055 "type" : "boolean",
18056 "typetext" : "<boolean>"
4bd7df8b 18057 },
44660702
DM
18058 "name" : {
18059 "description" : "The name of the pool. It must be unique.",
013dc89f
DM
18060 "type" : "string",
18061 "typetext" : "<string>"
44660702
DM
18062 },
18063 "node" : {
18064 "description" : "The cluster node name.",
18065 "format" : "pve-node",
013dc89f
DM
18066 "type" : "string",
18067 "typetext" : "<string>"
44660702
DM
18068 }
18069 }
18070 },
18071 "permissions" : {
18072 "check" : [
18073 "perm",
18074 "/",
18075 [
18076 "Sys.Modify"
18077 ]
18078 ]
18079 },
18080 "protected" : 1,
18081 "proxyto" : "node",
18082 "returns" : {
18083 "type" : "null"
18084 }
18085 }
18086 },
18087 "leaf" : 1,
18088 "path" : "/nodes/{node}/ceph/pools/{name}",
18089 "text" : "{name}"
18090 }
18091 ],
7aacca6f
DM
18092 "info" : {
18093 "GET" : {
44660702
DM
18094 "description" : "List all pools.",
18095 "method" : "GET",
18096 "name" : "lspools",
7aacca6f
DM
18097 "parameters" : {
18098 "additionalProperties" : 0,
18099 "properties" : {
18100 "node" : {
7aacca6f 18101 "description" : "The cluster node name.",
44660702 18102 "format" : "pve-node",
013dc89f
DM
18103 "type" : "string",
18104 "typetext" : "<string>"
7aacca6f
DM
18105 }
18106 }
18107 },
7aacca6f
DM
18108 "permissions" : {
18109 "check" : [
18110 "perm",
18111 "/",
18112 [
18113 "Sys.Audit",
18114 "Datastore.Audit"
18115 ],
18116 "any",
18117 1
18118 ]
18119 },
44660702
DM
18120 "protected" : 1,
18121 "proxyto" : "node",
7aacca6f 18122 "returns" : {
56122987 18123 "items" : {
56122987 18124 "properties" : {
7aacca6f
DM
18125 "pool" : {
18126 "type" : "integer"
18127 },
44660702
DM
18128 "pool_name" : {
18129 "type" : "string"
18130 },
7aacca6f
DM
18131 "size" : {
18132 "type" : "integer"
56122987 18133 }
44660702
DM
18134 },
18135 "type" : "object"
7aacca6f 18136 },
44660702
DM
18137 "links" : [
18138 {
18139 "href" : "{pool_name}",
18140 "rel" : "child"
18141 }
18142 ],
7aacca6f
DM
18143 "type" : "array"
18144 }
18145 },
18146 "POST" : {
7aacca6f 18147 "description" : "Create POOL",
7aacca6f 18148 "method" : "POST",
7aacca6f
DM
18149 "name" : "createpool",
18150 "parameters" : {
18151 "additionalProperties" : 0,
18152 "properties" : {
7aacca6f 18153 "crush_ruleset" : {
7aacca6f 18154 "default" : 0,
44660702 18155 "description" : "The ruleset to use for mapping object placement in the cluster.",
7aacca6f 18156 "maximum" : 32768,
44660702 18157 "minimum" : 0,
7aacca6f 18158 "optional" : 1,
4bd7df8b 18159 "type" : "integer",
013dc89f 18160 "typetext" : "<integer> (0 - 32768)"
56122987 18161 },
44660702
DM
18162 "min_size" : {
18163 "default" : 1,
18164 "description" : "Minimum number of replicas per object",
18165 "maximum" : 3,
18166 "minimum" : 1,
18167 "optional" : 1,
4bd7df8b 18168 "type" : "integer",
013dc89f 18169 "typetext" : "<integer> (1 - 3)"
7aacca6f 18170 },
44660702
DM
18171 "name" : {
18172 "description" : "The name of the pool. It must be unique.",
013dc89f
DM
18173 "type" : "string",
18174 "typetext" : "<string>"
44660702
DM
18175 },
18176 "node" : {
18177 "description" : "The cluster node name.",
18178 "format" : "pve-node",
013dc89f
DM
18179 "type" : "string",
18180 "typetext" : "<string>"
44660702
DM
18181 },
18182 "pg_num" : {
18183 "default" : 64,
18184 "description" : "Number of placement groups.",
18185 "maximum" : 32768,
18186 "minimum" : 8,
18187 "optional" : 1,
4bd7df8b 18188 "type" : "integer",
013dc89f 18189 "typetext" : "<integer> (8 - 32768)"
44660702
DM
18190 },
18191 "size" : {
18192 "default" : 2,
18193 "description" : "Number of replicas per object",
18194 "maximum" : 3,
18195 "minimum" : 1,
18196 "optional" : 1,
4bd7df8b 18197 "type" : "integer",
013dc89f 18198 "typetext" : "<integer> (1 - 3)"
56122987
DM
18199 }
18200 }
44660702
DM
18201 },
18202 "permissions" : {
18203 "check" : [
18204 "perm",
18205 "/",
18206 [
18207 "Sys.Modify"
18208 ]
18209 ]
18210 },
18211 "protected" : 1,
18212 "proxyto" : "node",
18213 "returns" : {
18214 "type" : "null"
7aacca6f 18215 }
56122987 18216 }
44660702 18217 },
56122987 18218 "leaf" : 0,
44660702
DM
18219 "path" : "/nodes/{node}/ceph/pools",
18220 "text" : "pools"
56122987 18221 },
32d876b5
DM
18222 {
18223 "children" : [
18224 {
18225 "info" : {
18226 "DELETE" : {
18227 "description" : "Unset a ceph flag",
18228 "method" : "DELETE",
18229 "name" : "unset_flag",
18230 "parameters" : {
18231 "additionalProperties" : 0,
18232 "properties" : {
18233 "flag" : {
18234 "description" : "The ceph flag to set/unset",
18235 "enum" : [
18236 "full",
18237 "pause",
18238 "noup",
18239 "nodown",
18240 "noout",
18241 "noin",
18242 "nobackfill",
18243 "norebalance",
18244 "norecover",
18245 "noscrub",
18246 "nodeep-scrub",
18247 "notieragent"
18248 ],
18249 "type" : "string"
18250 },
18251 "node" : {
18252 "description" : "The cluster node name.",
18253 "format" : "pve-node",
18254 "type" : "string",
18255 "typetext" : "<string>"
18256 }
18257 }
18258 },
18259 "permissions" : {
18260 "check" : [
18261 "perm",
18262 "/",
18263 [
18264 "Sys.Modify"
18265 ]
18266 ]
18267 },
18268 "protected" : 1,
18269 "proxyto" : "node",
18270 "returns" : {
18271 "type" : "null"
18272 }
18273 },
18274 "POST" : {
18275 "description" : "Set a ceph flag",
18276 "method" : "POST",
18277 "name" : "set_flag",
18278 "parameters" : {
18279 "additionalProperties" : 0,
18280 "properties" : {
18281 "flag" : {
18282 "description" : "The ceph flag to set/unset",
18283 "enum" : [
18284 "full",
18285 "pause",
18286 "noup",
18287 "nodown",
18288 "noout",
18289 "noin",
18290 "nobackfill",
18291 "norebalance",
18292 "norecover",
18293 "noscrub",
18294 "nodeep-scrub",
18295 "notieragent"
18296 ],
18297 "type" : "string"
18298 },
18299 "node" : {
18300 "description" : "The cluster node name.",
18301 "format" : "pve-node",
18302 "type" : "string",
18303 "typetext" : "<string>"
18304 }
18305 }
18306 },
18307 "permissions" : {
18308 "check" : [
18309 "perm",
18310 "/",
18311 [
18312 "Sys.Modify"
18313 ]
18314 ]
18315 },
18316 "protected" : 1,
18317 "proxyto" : "node",
18318 "returns" : {
18319 "type" : "null"
18320 }
18321 }
18322 },
18323 "leaf" : 1,
18324 "path" : "/nodes/{node}/ceph/flags/{flag}",
18325 "text" : "{flag}"
18326 }
18327 ],
18328 "info" : {
18329 "GET" : {
18330 "description" : "get all set ceph flags",
18331 "method" : "GET",
18332 "name" : "get_flags",
18333 "parameters" : {
18334 "additionalProperties" : 0,
18335 "properties" : {
18336 "node" : {
18337 "description" : "The cluster node name.",
18338 "format" : "pve-node",
18339 "type" : "string",
18340 "typetext" : "<string>"
18341 }
18342 }
18343 },
18344 "permissions" : {
18345 "check" : [
18346 "perm",
18347 "/",
18348 [
18349 "Sys.Audit"
18350 ]
18351 ]
18352 },
18353 "protected" : 1,
18354 "proxyto" : "node",
18355 "returns" : {
18356 "type" : "string"
18357 }
18358 }
18359 },
18360 "leaf" : 0,
18361 "path" : "/nodes/{node}/ceph/flags",
18362 "text" : "flags"
18363 },
56122987 18364 {
56122987 18365 "info" : {
7aacca6f 18366 "GET" : {
44660702
DM
18367 "description" : "Get OSD crush map",
18368 "method" : "GET",
18369 "name" : "crush",
18370 "parameters" : {
18371 "additionalProperties" : 0,
18372 "properties" : {
18373 "node" : {
18374 "description" : "The cluster node name.",
18375 "format" : "pve-node",
013dc89f
DM
18376 "type" : "string",
18377 "typetext" : "<string>"
44660702
DM
18378 }
18379 }
18380 },
7aacca6f
DM
18381 "permissions" : {
18382 "check" : [
18383 "perm",
18384 "/",
18385 [
18386 "Sys.Audit",
18387 "Datastore.Audit"
18388 ],
18389 "any",
18390 1
18391 ]
18392 },
44660702 18393 "protected" : 1,
7aacca6f 18394 "proxyto" : "node",
56122987 18395 "returns" : {
7aacca6f 18396 "type" : "string"
44660702 18397 }
56122987
DM
18398 }
18399 },
44660702
DM
18400 "leaf" : 1,
18401 "path" : "/nodes/{node}/ceph/crush",
7aacca6f 18402 "text" : "crush"
56122987
DM
18403 },
18404 {
56122987 18405 "info" : {
7aacca6f 18406 "GET" : {
44660702
DM
18407 "description" : "Read ceph log",
18408 "method" : "GET",
18409 "name" : "log",
18410 "parameters" : {
18411 "additionalProperties" : 0,
18412 "properties" : {
18413 "limit" : {
18414 "minimum" : 0,
18415 "optional" : 1,
4bd7df8b 18416 "type" : "integer",
013dc89f 18417 "typetext" : "<integer> (0 - N)"
7aacca6f 18418 },
44660702
DM
18419 "node" : {
18420 "description" : "The cluster node name.",
18421 "format" : "pve-node",
013dc89f
DM
18422 "type" : "string",
18423 "typetext" : "<string>"
44660702
DM
18424 },
18425 "start" : {
18426 "minimum" : 0,
18427 "optional" : 1,
4bd7df8b 18428 "type" : "integer",
013dc89f 18429 "typetext" : "<integer> (0 - N)"
44660702 18430 }
7aacca6f 18431 }
56122987 18432 },
56122987
DM
18433 "permissions" : {
18434 "check" : [
18435 "perm",
7aacca6f 18436 "/nodes/{node}",
56122987 18437 [
7aacca6f 18438 "Sys.Syslog"
56122987
DM
18439 ]
18440 ]
18441 },
7aacca6f 18442 "protected" : 1,
44660702
DM
18443 "proxyto" : "node",
18444 "returns" : {
18445 "items" : {
18446 "properties" : {
18447 "n" : {
18448 "description" : "Line number",
18449 "type" : "integer"
18450 },
18451 "t" : {
18452 "description" : "Line text",
18453 "type" : "string"
18454 }
56122987 18455 },
44660702 18456 "type" : "object"
56122987 18457 },
44660702 18458 "type" : "array"
7aacca6f 18459 }
56122987
DM
18460 }
18461 },
18462 "leaf" : 1,
44660702
DM
18463 "path" : "/nodes/{node}/ceph/log",
18464 "text" : "log"
7aacca6f
DM
18465 }
18466 ],
44660702
DM
18467 "info" : {
18468 "GET" : {
18469 "description" : "Directory index.",
18470 "method" : "GET",
18471 "name" : "index",
18472 "parameters" : {
18473 "additionalProperties" : 0,
18474 "properties" : {
18475 "node" : {
18476 "description" : "The cluster node name.",
18477 "format" : "pve-node",
013dc89f
DM
18478 "type" : "string",
18479 "typetext" : "<string>"
44660702
DM
18480 }
18481 }
18482 },
18483 "permissions" : {
18484 "check" : [
18485 "perm",
18486 "/",
18487 [
18488 "Sys.Audit",
18489 "Datastore.Audit"
18490 ],
18491 "any",
18492 1
18493 ]
18494 },
18495 "returns" : {
18496 "items" : {
18497 "properties" : {},
18498 "type" : "object"
18499 },
18500 "links" : [
18501 {
18502 "href" : "{name}",
18503 "rel" : "child"
18504 }
18505 ],
18506 "type" : "array"
18507 }
18508 }
18509 },
7aacca6f 18510 "leaf" : 0,
44660702
DM
18511 "path" : "/nodes/{node}/ceph",
18512 "text" : "ceph"
7aacca6f
DM
18513 },
18514 {
4bd7df8b
DM
18515 "children" : [
18516 {
18517 "info" : {
18518 "GET" : {
18519 "description" : "Extract configuration from vzdump backup archive.",
18520 "method" : "GET",
18521 "name" : "extractconfig",
18522 "parameters" : {
18523 "additionalProperties" : 0,
18524 "properties" : {
18525 "node" : {
18526 "description" : "The cluster node name.",
18527 "format" : "pve-node",
013dc89f
DM
18528 "type" : "string",
18529 "typetext" : "<string>"
4bd7df8b
DM
18530 },
18531 "volume" : {
18532 "description" : "Volume identifier",
013dc89f
DM
18533 "type" : "string",
18534 "typetext" : "<string>"
4bd7df8b
DM
18535 }
18536 }
18537 },
18538 "permissions" : {
18539 "description" : "The user needs 'VM.Backup' permissions on the backed up guest ID, and 'Datastore.AllocateSpace' on the backup storage.",
18540 "user" : "all"
18541 },
18542 "protected" : 1,
18543 "proxyto" : "node",
18544 "returns" : {
18545 "type" : "string"
18546 }
18547 }
18548 },
18549 "leaf" : 1,
18550 "path" : "/nodes/{node}/vzdump/extractconfig",
18551 "text" : "extractconfig"
18552 }
18553 ],
7aacca6f
DM
18554 "info" : {
18555 "POST" : {
7aacca6f 18556 "description" : "Create backup.",
44660702 18557 "method" : "POST",
7aacca6f
DM
18558 "name" : "vzdump",
18559 "parameters" : {
44660702 18560 "additionalProperties" : 0,
7aacca6f 18561 "properties" : {
44660702
DM
18562 "all" : {
18563 "default" : 0,
18564 "description" : "Backup all known guest systems on this host.",
7aacca6f 18565 "optional" : 1,
013dc89f
DM
18566 "type" : "boolean",
18567 "typetext" : "<boolean>"
56122987 18568 },
44660702 18569 "bwlimit" : {
7aacca6f 18570 "default" : 0,
44660702
DM
18571 "description" : "Limit I/O bandwidth (KBytes per second).",
18572 "minimum" : 0,
7aacca6f 18573 "optional" : 1,
4bd7df8b 18574 "type" : "integer",
013dc89f 18575 "typetext" : "<integer> (0 - N)"
56122987 18576 },
44660702
DM
18577 "compress" : {
18578 "default" : "0",
18579 "description" : "Compress dump file.",
18580 "enum" : [
18581 "0",
18582 "1",
18583 "gzip",
18584 "lzo"
18585 ],
7aacca6f 18586 "optional" : 1,
44660702 18587 "type" : "string"
56122987 18588 },
44660702
DM
18589 "dumpdir" : {
18590 "description" : "Store resulting files to specified directory.",
7aacca6f 18591 "optional" : 1,
013dc89f
DM
18592 "type" : "string",
18593 "typetext" : "<string>"
7aacca6f 18594 },
44660702
DM
18595 "exclude" : {
18596 "description" : "Exclude specified guest systems (assumes --all)",
18597 "format" : "pve-vmid-list",
7aacca6f 18598 "optional" : 1,
013dc89f
DM
18599 "type" : "string",
18600 "typetext" : "<string>"
7aacca6f 18601 },
44660702
DM
18602 "exclude-path" : {
18603 "description" : "Exclude certain files/directories (shell globs).",
18604 "format" : "string-alist",
7aacca6f 18605 "optional" : 1,
013dc89f
DM
18606 "type" : "string",
18607 "typetext" : "<string>"
7aacca6f 18608 },
44660702
DM
18609 "ionice" : {
18610 "default" : 7,
18611 "description" : "Set CFQ ionice priority.",
18612 "maximum" : 8,
18613 "minimum" : 0,
18614 "optional" : 1,
4bd7df8b 18615 "type" : "integer",
013dc89f 18616 "typetext" : "<integer> (0 - 8)"
7aacca6f 18617 },
44660702
DM
18618 "lockwait" : {
18619 "default" : 180,
18620 "description" : "Maximal time to wait for the global lock (minutes).",
18621 "minimum" : 0,
7aacca6f 18622 "optional" : 1,
4bd7df8b 18623 "type" : "integer",
013dc89f 18624 "typetext" : "<integer> (0 - N)"
7aacca6f
DM
18625 },
18626 "mailnotification" : {
44660702 18627 "default" : "always",
7aacca6f
DM
18628 "description" : "Specify when to send an email",
18629 "enum" : [
18630 "always",
18631 "failure"
18632 ],
7aacca6f 18633 "optional" : 1,
44660702 18634 "type" : "string"
7aacca6f
DM
18635 },
18636 "mailto" : {
7aacca6f 18637 "description" : "Comma-separated list of email addresses that should receive email notifications.",
44660702 18638 "format" : "string-list",
7aacca6f 18639 "optional" : 1,
013dc89f
DM
18640 "type" : "string",
18641 "typetext" : "<string>"
56122987 18642 },
44660702
DM
18643 "maxfiles" : {
18644 "default" : 1,
18645 "description" : "Maximal number of backup files per guest system.",
18646 "minimum" : 1,
7aacca6f 18647 "optional" : 1,
4bd7df8b 18648 "type" : "integer",
013dc89f 18649 "typetext" : "<integer> (1 - N)"
56122987 18650 },
7aacca6f 18651 "mode" : {
44660702 18652 "default" : "snapshot",
7aacca6f
DM
18653 "description" : "Backup mode.",
18654 "enum" : [
18655 "snapshot",
18656 "suspend",
18657 "stop"
18658 ],
44660702
DM
18659 "optional" : 1,
18660 "type" : "string"
7aacca6f 18661 },
44660702
DM
18662 "node" : {
18663 "description" : "Only run if executed on this node.",
18664 "format" : "pve-node",
18665 "optional" : 1,
013dc89f
DM
18666 "type" : "string",
18667 "typetext" : "<string>"
44660702
DM
18668 },
18669 "pigz" : {
18670 "default" : 0,
18671 "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count.",
18672 "optional" : 1,
013dc89f
DM
18673 "type" : "integer",
18674 "typetext" : "<integer>"
44660702
DM
18675 },
18676 "quiet" : {
18677 "default" : 0,
18678 "description" : "Be quiet.",
18679 "optional" : 1,
013dc89f
DM
18680 "type" : "boolean",
18681 "typetext" : "<boolean>"
44660702
DM
18682 },
18683 "remove" : {
7aacca6f 18684 "default" : 1,
44660702 18685 "description" : "Remove old backup files if there are more than 'maxfiles' backup files.",
7aacca6f 18686 "optional" : 1,
013dc89f
DM
18687 "type" : "boolean",
18688 "typetext" : "<boolean>"
7aacca6f 18689 },
44660702
DM
18690 "script" : {
18691 "description" : "Use specified hook script.",
18692 "optional" : 1,
013dc89f
DM
18693 "type" : "string",
18694 "typetext" : "<string>"
44660702
DM
18695 },
18696 "size" : {
18697 "default" : 1024,
18698 "description" : "Unused, will be removed in a future release.",
18699 "minimum" : 500,
18700 "optional" : 1,
4bd7df8b 18701 "type" : "integer",
013dc89f 18702 "typetext" : "<integer> (500 - N)"
44660702
DM
18703 },
18704 "stdexcludes" : {
18705 "default" : 1,
18706 "description" : "Exclude temporary files and logs.",
18707 "optional" : 1,
013dc89f
DM
18708 "type" : "boolean",
18709 "typetext" : "<boolean>"
44660702
DM
18710 },
18711 "stdout" : {
18712 "description" : "Write tar to stdout, not to a file.",
7aacca6f 18713 "optional" : 1,
013dc89f
DM
18714 "type" : "boolean",
18715 "typetext" : "<boolean>"
44660702
DM
18716 },
18717 "stop" : {
7aacca6f 18718 "default" : 0,
44660702
DM
18719 "description" : "Stop runnig backup jobs on this host.",
18720 "optional" : 1,
013dc89f
DM
18721 "type" : "boolean",
18722 "typetext" : "<boolean>"
7aacca6f 18723 },
44660702
DM
18724 "stopwait" : {
18725 "default" : 10,
18726 "description" : "Maximal time to wait until a guest system is stopped (minutes).",
7aacca6f
DM
18727 "minimum" : 0,
18728 "optional" : 1,
4bd7df8b 18729 "type" : "integer",
013dc89f 18730 "typetext" : "<integer> (0 - N)"
7aacca6f 18731 },
44660702
DM
18732 "storage" : {
18733 "description" : "Store resulting file to this storage.",
18734 "format" : "pve-storage-id",
7aacca6f 18735 "optional" : 1,
013dc89f
DM
18736 "type" : "string",
18737 "typetext" : "<string>"
44660702
DM
18738 },
18739 "tmpdir" : {
18740 "description" : "Store temporary files to specified directory.",
18741 "optional" : 1,
013dc89f
DM
18742 "type" : "string",
18743 "typetext" : "<string>"
7aacca6f
DM
18744 },
18745 "vmid" : {
7aacca6f 18746 "description" : "The ID of the guest system you want to backup.",
44660702 18747 "format" : "pve-vmid-list",
7aacca6f 18748 "optional" : 1,
013dc89f
DM
18749 "type" : "string",
18750 "typetext" : "<string>"
7aacca6f 18751 }
7aacca6f
DM
18752 }
18753 },
7aacca6f 18754 "permissions" : {
de0983cb 18755 "description" : "The user needs 'VM.Backup' permissions on any VM, and 'Datastore.AllocateSpace' on the backup storage. The 'maxfiles', 'tmpdir', 'dumpdir', 'script', 'bwlimit' and 'ionice' parameters are restricted to the 'root@pam' user.",
44660702 18756 "user" : "all"
7aacca6f 18757 },
44660702 18758 "protected" : 1,
7aacca6f 18759 "proxyto" : "node",
7aacca6f 18760 "returns" : {
44660702 18761 "type" : "string"
7aacca6f
DM
18762 }
18763 }
18764 },
4bd7df8b 18765 "leaf" : 0,
44660702
DM
18766 "path" : "/nodes/{node}/vzdump",
18767 "text" : "vzdump"
18768 },
18769 {
7aacca6f
DM
18770 "children" : [
18771 {
7aacca6f
DM
18772 "children" : [
18773 {
7aacca6f
DM
18774 "info" : {
18775 "GET" : {
7aacca6f
DM
18776 "description" : "Read service properties",
18777 "method" : "GET",
18778 "name" : "service_state",
18779 "parameters" : {
44660702 18780 "additionalProperties" : 0,
7aacca6f
DM
18781 "properties" : {
18782 "node" : {
7aacca6f 18783 "description" : "The cluster node name.",
44660702 18784 "format" : "pve-node",
013dc89f
DM
18785 "type" : "string",
18786 "typetext" : "<string>"
7aacca6f
DM
18787 },
18788 "service" : {
44660702 18789 "description" : "Service ID",
7aacca6f
DM
18790 "enum" : [
18791 "pveproxy",
18792 "pvedaemon",
18793 "spiceproxy",
18794 "pvestatd",
18795 "pve-cluster",
18796 "corosync",
18797 "pve-firewall",
18798 "pvefw-logger",
18799 "pve-ha-crm",
18800 "pve-ha-lrm",
18801 "sshd",
18802 "syslog",
18803 "cron",
18804 "postfix",
18805 "ksmtuned",
18806 "systemd-timesyncd"
18807 ],
7aacca6f
DM
18808 "type" : "string"
18809 }
44660702 18810 }
56122987 18811 },
7aacca6f
DM
18812 "permissions" : {
18813 "check" : [
18814 "perm",
18815 "/nodes/{node}",
18816 [
44660702 18817 "Sys.Audit"
7aacca6f
DM
18818 ]
18819 ]
56122987 18820 },
44660702 18821 "protected" : 1,
7aacca6f 18822 "proxyto" : "node",
44660702
DM
18823 "returns" : {
18824 "properties" : {},
18825 "type" : "object"
18826 }
18827 }
18828 },
18829 "leaf" : 1,
18830 "path" : "/nodes/{node}/services/{service}/state",
18831 "text" : "state"
18832 },
18833 {
18834 "info" : {
18835 "POST" : {
18836 "description" : "Start service.",
7aacca6f
DM
18837 "method" : "POST",
18838 "name" : "service_start",
18839 "parameters" : {
44660702 18840 "additionalProperties" : 0,
7aacca6f 18841 "properties" : {
44660702
DM
18842 "node" : {
18843 "description" : "The cluster node name.",
18844 "format" : "pve-node",
013dc89f
DM
18845 "type" : "string",
18846 "typetext" : "<string>"
44660702 18847 },
7aacca6f 18848 "service" : {
44660702 18849 "description" : "Service ID",
7aacca6f
DM
18850 "enum" : [
18851 "pveproxy",
18852 "pvedaemon",
18853 "spiceproxy",
18854 "pvestatd",
18855 "pve-cluster",
18856 "corosync",
18857 "pve-firewall",
18858 "pvefw-logger",
18859 "pve-ha-crm",
18860 "pve-ha-lrm",
18861 "sshd",
18862 "syslog",
18863 "cron",
18864 "postfix",
18865 "ksmtuned",
18866 "systemd-timesyncd"
18867 ],
7aacca6f
DM
18868 "type" : "string"
18869 }
44660702 18870 }
56122987 18871 },
56122987
DM
18872 "permissions" : {
18873 "check" : [
18874 "perm",
18875 "/nodes/{node}",
18876 [
7aacca6f 18877 "Sys.Modify"
56122987
DM
18878 ]
18879 ]
7aacca6f 18880 },
7aacca6f 18881 "protected" : 1,
44660702
DM
18882 "proxyto" : "node",
18883 "returns" : {
18884 "type" : "string"
18885 }
18886 }
18887 },
18888 "leaf" : 1,
18889 "path" : "/nodes/{node}/services/{service}/start",
18890 "text" : "start"
18891 },
18892 {
18893 "info" : {
18894 "POST" : {
18895 "description" : "Stop service.",
18896 "method" : "POST",
7aacca6f 18897 "name" : "service_stop",
56122987 18898 "parameters" : {
7aacca6f 18899 "additionalProperties" : 0,
56122987
DM
18900 "properties" : {
18901 "node" : {
44660702 18902 "description" : "The cluster node name.",
56122987 18903 "format" : "pve-node",
013dc89f
DM
18904 "type" : "string",
18905 "typetext" : "<string>"
56122987
DM
18906 },
18907 "service" : {
44660702 18908 "description" : "Service ID",
56122987
DM
18909 "enum" : [
18910 "pveproxy",
18911 "pvedaemon",
18912 "spiceproxy",
18913 "pvestatd",
18914 "pve-cluster",
18915 "corosync",
18916 "pve-firewall",
18917 "pvefw-logger",
18918 "pve-ha-crm",
18919 "pve-ha-lrm",
18920 "sshd",
18921 "syslog",
18922 "cron",
18923 "postfix",
18924 "ksmtuned",
18925 "systemd-timesyncd"
18926 ],
56122987
DM
18927 "type" : "string"
18928 }
7aacca6f 18929 }
44660702 18930 },
56122987
DM
18931 "permissions" : {
18932 "check" : [
18933 "perm",
18934 "/nodes/{node}",
18935 [
18936 "Sys.Modify"
18937 ]
18938 ]
18939 },
44660702
DM
18940 "protected" : 1,
18941 "proxyto" : "node",
7aacca6f
DM
18942 "returns" : {
18943 "type" : "string"
44660702
DM
18944 }
18945 }
18946 },
18947 "leaf" : 1,
18948 "path" : "/nodes/{node}/services/{service}/stop",
18949 "text" : "stop"
18950 },
18951 {
18952 "info" : {
18953 "POST" : {
18954 "description" : "Restart service.",
18955 "method" : "POST",
18956 "name" : "service_restart",
56122987
DM
18957 "parameters" : {
18958 "additionalProperties" : 0,
18959 "properties" : {
7aacca6f
DM
18960 "node" : {
18961 "description" : "The cluster node name.",
44660702 18962 "format" : "pve-node",
013dc89f
DM
18963 "type" : "string",
18964 "typetext" : "<string>"
7aacca6f
DM
18965 },
18966 "service" : {
44660702 18967 "description" : "Service ID",
56122987
DM
18968 "enum" : [
18969 "pveproxy",
18970 "pvedaemon",
18971 "spiceproxy",
18972 "pvestatd",
18973 "pve-cluster",
18974 "corosync",
18975 "pve-firewall",
18976 "pvefw-logger",
18977 "pve-ha-crm",
18978 "pve-ha-lrm",
18979 "sshd",
18980 "syslog",
18981 "cron",
18982 "postfix",
18983 "ksmtuned",
18984 "systemd-timesyncd"
7aacca6f 18985 ],
7aacca6f 18986 "type" : "string"
56122987
DM
18987 }
18988 }
18989 },
44660702
DM
18990 "permissions" : {
18991 "check" : [
18992 "perm",
18993 "/nodes/{node}",
18994 [
18995 "Sys.Modify"
18996 ]
18997 ]
18998 },
18999 "protected" : 1,
19000 "proxyto" : "node",
19001 "returns" : {
19002 "type" : "string"
19003 }
56122987 19004 }
44660702
DM
19005 },
19006 "leaf" : 1,
19007 "path" : "/nodes/{node}/services/{service}/restart",
19008 "text" : "restart"
56122987
DM
19009 },
19010 {
56122987
DM
19011 "info" : {
19012 "POST" : {
44660702
DM
19013 "description" : "Reload service.",
19014 "method" : "POST",
7aacca6f 19015 "name" : "service_reload",
56122987
DM
19016 "parameters" : {
19017 "additionalProperties" : 0,
19018 "properties" : {
44660702
DM
19019 "node" : {
19020 "description" : "The cluster node name.",
19021 "format" : "pve-node",
013dc89f
DM
19022 "type" : "string",
19023 "typetext" : "<string>"
44660702 19024 },
56122987 19025 "service" : {
56122987
DM
19026 "description" : "Service ID",
19027 "enum" : [
19028 "pveproxy",
19029 "pvedaemon",
19030 "spiceproxy",
19031 "pvestatd",
19032 "pve-cluster",
19033 "corosync",
19034 "pve-firewall",
19035 "pvefw-logger",
19036 "pve-ha-crm",
19037 "pve-ha-lrm",
19038 "sshd",
19039 "syslog",
19040 "cron",
19041 "postfix",
19042 "ksmtuned",
19043 "systemd-timesyncd"
44660702
DM
19044 ],
19045 "type" : "string"
56122987
DM
19046 }
19047 }
19048 },
56122987
DM
19049 "permissions" : {
19050 "check" : [
19051 "perm",
19052 "/nodes/{node}",
19053 [
19054 "Sys.Modify"
19055 ]
19056 ]
19057 },
44660702 19058 "protected" : 1,
56122987 19059 "proxyto" : "node",
7aacca6f
DM
19060 "returns" : {
19061 "type" : "string"
56122987
DM
19062 }
19063 }
44660702
DM
19064 },
19065 "leaf" : 1,
19066 "path" : "/nodes/{node}/services/{service}/reload",
19067 "text" : "reload"
19068 }
19069 ],
19070 "info" : {
19071 "GET" : {
19072 "description" : "Directory index",
19073 "method" : "GET",
19074 "name" : "srvcmdidx",
19075 "parameters" : {
19076 "additionalProperties" : 0,
19077 "properties" : {
19078 "node" : {
19079 "description" : "The cluster node name.",
19080 "format" : "pve-node",
013dc89f
DM
19081 "type" : "string",
19082 "typetext" : "<string>"
44660702
DM
19083 },
19084 "service" : {
19085 "description" : "Service ID",
19086 "enum" : [
19087 "pveproxy",
19088 "pvedaemon",
19089 "spiceproxy",
19090 "pvestatd",
19091 "pve-cluster",
19092 "corosync",
19093 "pve-firewall",
19094 "pvefw-logger",
19095 "pve-ha-crm",
19096 "pve-ha-lrm",
19097 "sshd",
19098 "syslog",
19099 "cron",
19100 "postfix",
19101 "ksmtuned",
19102 "systemd-timesyncd"
19103 ],
19104 "type" : "string"
19105 }
19106 }
19107 },
19108 "permissions" : {
19109 "check" : [
19110 "perm",
19111 "/nodes/{node}",
19112 [
19113 "Sys.Audit"
19114 ]
19115 ]
19116 },
19117 "returns" : {
19118 "items" : {
19119 "properties" : {
19120 "subdir" : {
19121 "type" : "string"
19122 }
19123 },
19124 "type" : "object"
19125 },
19126 "links" : [
19127 {
19128 "href" : "{subdir}",
19129 "rel" : "child"
19130 }
19131 ],
19132 "type" : "array"
19133 }
19134 }
19135 },
19136 "leaf" : 0,
19137 "path" : "/nodes/{node}/services/{service}",
19138 "text" : "{service}"
19139 }
19140 ],
19141 "info" : {
19142 "GET" : {
19143 "description" : "Service list.",
19144 "method" : "GET",
19145 "name" : "index",
19146 "parameters" : {
19147 "additionalProperties" : 0,
19148 "properties" : {
19149 "node" : {
19150 "description" : "The cluster node name.",
19151 "format" : "pve-node",
013dc89f
DM
19152 "type" : "string",
19153 "typetext" : "<string>"
44660702
DM
19154 }
19155 }
19156 },
19157 "permissions" : {
19158 "check" : [
19159 "perm",
19160 "/nodes/{node}",
19161 [
19162 "Sys.Audit"
19163 ]
19164 ]
19165 },
19166 "protected" : 1,
19167 "proxyto" : "node",
19168 "returns" : {
19169 "items" : {
19170 "properties" : {},
19171 "type" : "object"
19172 },
19173 "links" : [
19174 {
19175 "href" : "{service}",
19176 "rel" : "child"
56122987 19177 }
44660702
DM
19178 ],
19179 "type" : "array"
19180 }
7aacca6f 19181 }
44660702 19182 },
7aacca6f 19183 "leaf" : 0,
44660702
DM
19184 "path" : "/nodes/{node}/services",
19185 "text" : "services"
7aacca6f
DM
19186 },
19187 {
7aacca6f
DM
19188 "info" : {
19189 "GET" : {
44660702
DM
19190 "description" : "Read subscription info.",
19191 "method" : "GET",
19192 "name" : "get",
7aacca6f 19193 "parameters" : {
44660702 19194 "additionalProperties" : 0,
7aacca6f
DM
19195 "properties" : {
19196 "node" : {
19197 "description" : "The cluster node name.",
44660702 19198 "format" : "pve-node",
013dc89f
DM
19199 "type" : "string",
19200 "typetext" : "<string>"
7aacca6f 19201 }
44660702
DM
19202 }
19203 },
19204 "permissions" : {
19205 "user" : "all"
7aacca6f 19206 },
7aacca6f
DM
19207 "proxyto" : "node",
19208 "returns" : {
19209 "type" : "object"
44660702 19210 }
7aacca6f 19211 },
44660702
DM
19212 "POST" : {
19213 "description" : "Update subscription info.",
19214 "method" : "POST",
19215 "name" : "update",
7aacca6f
DM
19216 "parameters" : {
19217 "additionalProperties" : 0,
19218 "properties" : {
44660702
DM
19219 "force" : {
19220 "default" : 0,
19221 "description" : "Always connect to server, even if we have up to date info inside local cache.",
19222 "optional" : 1,
013dc89f
DM
19223 "type" : "boolean",
19224 "typetext" : "<boolean>"
44660702 19225 },
7aacca6f 19226 "node" : {
7aacca6f 19227 "description" : "The cluster node name.",
44660702 19228 "format" : "pve-node",
013dc89f
DM
19229 "type" : "string",
19230 "typetext" : "<string>"
7aacca6f
DM
19231 }
19232 }
19233 },
7aacca6f 19234 "protected" : 1,
7aacca6f 19235 "proxyto" : "node",
44660702
DM
19236 "returns" : {
19237 "type" : "null"
19238 }
19239 },
19240 "PUT" : {
19241 "description" : "Set subscription key.",
19242 "method" : "PUT",
19243 "name" : "set",
7aacca6f
DM
19244 "parameters" : {
19245 "additionalProperties" : 0,
19246 "properties" : {
44660702
DM
19247 "key" : {
19248 "description" : "Proxmox VE subscription key",
013dc89f
DM
19249 "type" : "string",
19250 "typetext" : "<string>"
7aacca6f
DM
19251 },
19252 "node" : {
7aacca6f 19253 "description" : "The cluster node name.",
44660702 19254 "format" : "pve-node",
013dc89f
DM
19255 "type" : "string",
19256 "typetext" : "<string>"
7aacca6f
DM
19257 }
19258 }
19259 },
44660702
DM
19260 "protected" : 1,
19261 "proxyto" : "node",
7aacca6f
DM
19262 "returns" : {
19263 "type" : "null"
44660702 19264 }
7aacca6f
DM
19265 }
19266 },
44660702 19267 "leaf" : 1,
7aacca6f 19268 "path" : "/nodes/{node}/subscription",
44660702 19269 "text" : "subscription"
7aacca6f
DM
19270 },
19271 {
7aacca6f
DM
19272 "children" : [
19273 {
56122987 19274 "info" : {
7aacca6f 19275 "DELETE" : {
44660702
DM
19276 "description" : "Delete network device configuration",
19277 "method" : "DELETE",
19278 "name" : "delete_network",
19279 "parameters" : {
19280 "additionalProperties" : 0,
19281 "properties" : {
19282 "iface" : {
19283 "description" : "Network interface name.",
19284 "format" : "pve-iface",
19285 "maxLength" : 20,
19286 "minLength" : 2,
013dc89f
DM
19287 "type" : "string",
19288 "typetext" : "<string>"
44660702
DM
19289 },
19290 "node" : {
19291 "description" : "The cluster node name.",
19292 "format" : "pve-node",
013dc89f
DM
19293 "type" : "string",
19294 "typetext" : "<string>"
44660702
DM
19295 }
19296 }
7aacca6f
DM
19297 },
19298 "permissions" : {
19299 "check" : [
19300 "perm",
19301 "/nodes/{node}",
19302 [
19303 "Sys.Modify"
19304 ]
19305 ]
19306 },
44660702 19307 "protected" : 1,
7aacca6f 19308 "proxyto" : "node",
44660702
DM
19309 "returns" : {
19310 "type" : "null"
19311 }
19312 },
19313 "GET" : {
19314 "description" : "Read network device configuration",
19315 "method" : "GET",
19316 "name" : "network_config",
56122987 19317 "parameters" : {
44660702 19318 "additionalProperties" : 0,
56122987 19319 "properties" : {
7aacca6f 19320 "iface" : {
7aacca6f 19321 "description" : "Network interface name.",
44660702
DM
19322 "format" : "pve-iface",
19323 "maxLength" : 20,
7aacca6f 19324 "minLength" : 2,
013dc89f
DM
19325 "type" : "string",
19326 "typetext" : "<string>"
44660702
DM
19327 },
19328 "node" : {
19329 "description" : "The cluster node name.",
19330 "format" : "pve-node",
013dc89f
DM
19331 "type" : "string",
19332 "typetext" : "<string>"
56122987 19333 }
44660702 19334 }
7aacca6f
DM
19335 },
19336 "permissions" : {
19337 "check" : [
19338 "perm",
19339 "/nodes/{node}",
19340 [
44660702 19341 "Sys.Audit"
7aacca6f
DM
19342 ]
19343 ]
19344 },
19345 "proxyto" : "node",
44660702
DM
19346 "returns" : {
19347 "properties" : {
19348 "method" : {
19349 "type" : "string"
19350 },
19351 "type" : {
19352 "type" : "string"
19353 }
19354 },
19355 "type" : "object"
19356 }
19357 },
19358 "PUT" : {
7aacca6f
DM
19359 "description" : "Update network device configuration",
19360 "method" : "PUT",
19361 "name" : "update_network",
19362 "parameters" : {
19363 "additionalProperties" : 0,
19364 "properties" : {
7aacca6f 19365 "address" : {
44660702 19366 "description" : "IP address.",
7aacca6f 19367 "format" : "ipv4",
44660702 19368 "optional" : 1,
7aacca6f 19369 "requires" : "netmask",
013dc89f
DM
19370 "type" : "string",
19371 "typetext" : "<string>"
7aacca6f 19372 },
44660702
DM
19373 "address6" : {
19374 "description" : "IP address.",
19375 "format" : "ipv6",
19376 "optional" : 1,
19377 "requires" : "netmask6",
013dc89f
DM
19378 "type" : "string",
19379 "typetext" : "<string>"
7aacca6f
DM
19380 },
19381 "autostart" : {
44660702 19382 "description" : "Automatically start interface on boot.",
7aacca6f 19383 "optional" : 1,
013dc89f
DM
19384 "type" : "boolean",
19385 "typetext" : "<boolean>"
7aacca6f 19386 },
44660702
DM
19387 "bond_mode" : {
19388 "description" : "Bonding mode.",
7aacca6f 19389 "enum" : [
44660702
DM
19390 "balance-rr",
19391 "active-backup",
19392 "balance-xor",
19393 "broadcast",
19394 "802.3ad",
19395 "balance-tlb",
19396 "balance-alb",
19397 "balance-slb",
19398 "lacp-balance-slb",
19399 "lacp-balance-tcp"
19400 ],
7aacca6f 19401 "optional" : 1,
44660702 19402 "type" : "string"
7aacca6f 19403 },
44660702
DM
19404 "bond_xmit_hash_policy" : {
19405 "description" : "Selects the transmit hash policy to use for slave selection in balance-xor and 802.3ad modes.",
19406 "enum" : [
19407 "layer2",
19408 "layer2+3",
19409 "layer3+4"
19410 ],
7aacca6f 19411 "optional" : 1,
44660702 19412 "type" : "string"
7aacca6f 19413 },
44660702
DM
19414 "bridge_ports" : {
19415 "description" : "Specify the iterfaces you want to add to your bridge.",
19416 "format" : "pve-iface-list",
7aacca6f 19417 "optional" : 1,
013dc89f
DM
19418 "type" : "string",
19419 "typetext" : "<string>"
7aacca6f 19420 },
44660702
DM
19421 "bridge_vlan_aware" : {
19422 "description" : "Enable bridge vlan support.",
7aacca6f 19423 "optional" : 1,
013dc89f
DM
19424 "type" : "boolean",
19425 "typetext" : "<boolean>"
7aacca6f
DM
19426 },
19427 "comments" : {
44660702 19428 "description" : "Comments",
7aacca6f 19429 "optional" : 1,
013dc89f
DM
19430 "type" : "string",
19431 "typetext" : "<string>"
7aacca6f 19432 },
44660702
DM
19433 "comments6" : {
19434 "description" : "Comments",
7aacca6f 19435 "optional" : 1,
013dc89f
DM
19436 "type" : "string",
19437 "typetext" : "<string>"
7aacca6f 19438 },
44660702
DM
19439 "delete" : {
19440 "description" : "A list of settings you want to delete.",
19441 "format" : "pve-configid-list",
7aacca6f 19442 "optional" : 1,
013dc89f
DM
19443 "type" : "string",
19444 "typetext" : "<string>"
7aacca6f 19445 },
44660702
DM
19446 "gateway" : {
19447 "description" : "Default gateway address.",
19448 "format" : "ipv4",
7aacca6f 19449 "optional" : 1,
013dc89f
DM
19450 "type" : "string",
19451 "typetext" : "<string>"
7aacca6f 19452 },
44660702
DM
19453 "gateway6" : {
19454 "description" : "Default ipv6 gateway address.",
19455 "format" : "ipv6",
7aacca6f 19456 "optional" : 1,
013dc89f
DM
19457 "type" : "string",
19458 "typetext" : "<string>"
7aacca6f
DM
19459 },
19460 "iface" : {
44660702 19461 "description" : "Network interface name.",
7aacca6f
DM
19462 "format" : "pve-iface",
19463 "maxLength" : 20,
19464 "minLength" : 2,
013dc89f
DM
19465 "type" : "string",
19466 "typetext" : "<string>"
7aacca6f 19467 },
44660702
DM
19468 "netmask" : {
19469 "description" : "Network mask.",
19470 "format" : "ipv4mask",
7aacca6f 19471 "optional" : 1,
44660702 19472 "requires" : "address",
013dc89f
DM
19473 "type" : "string",
19474 "typetext" : "<string>"
7aacca6f
DM
19475 },
19476 "netmask6" : {
44660702 19477 "description" : "Network mask.",
7aacca6f 19478 "maximum" : 128,
44660702 19479 "minimum" : 0,
7aacca6f
DM
19480 "optional" : 1,
19481 "requires" : "address6",
4bd7df8b 19482 "type" : "integer",
013dc89f 19483 "typetext" : "<integer> (0 - 128)"
44660702 19484 },
7aacca6f 19485 "node" : {
44660702 19486 "description" : "The cluster node name.",
7aacca6f 19487 "format" : "pve-node",
013dc89f
DM
19488 "type" : "string",
19489 "typetext" : "<string>"
7aacca6f 19490 },
44660702
DM
19491 "ovs_bonds" : {
19492 "description" : "Specify the interfaces used by the bonding device.",
19493 "format" : "pve-iface-list",
19494 "optional" : 1,
013dc89f
DM
19495 "type" : "string",
19496 "typetext" : "<string>"
44660702
DM
19497 },
19498 "ovs_bridge" : {
19499 "description" : "The OVS bridge associated with a OVS port. This is required when you create an OVS port.",
19500 "format" : "pve-iface",
19501 "optional" : 1,
013dc89f
DM
19502 "type" : "string",
19503 "typetext" : "<string>"
44660702
DM
19504 },
19505 "ovs_options" : {
19506 "description" : "OVS interface options.",
19507 "maxLength" : 1024,
19508 "optional" : 1,
013dc89f
DM
19509 "type" : "string",
19510 "typetext" : "<string>"
44660702
DM
19511 },
19512 "ovs_ports" : {
19513 "description" : "Specify the iterfaces you want to add to your bridge.",
19514 "format" : "pve-iface-list",
19515 "optional" : 1,
013dc89f
DM
19516 "type" : "string",
19517 "typetext" : "<string>"
44660702
DM
19518 },
19519 "ovs_tag" : {
19520 "description" : "Specify a VLan tag (used by OVSPort, OVSIntPort, OVSBond)",
19521 "maximum" : 4094,
19522 "minimum" : 1,
19523 "optional" : 1,
4bd7df8b 19524 "type" : "integer",
013dc89f 19525 "typetext" : "<integer> (1 - 4094)"
44660702
DM
19526 },
19527 "slaves" : {
19528 "description" : "Specify the interfaces used by the bonding device.",
19529 "format" : "pve-iface-list",
19530 "optional" : 1,
013dc89f
DM
19531 "type" : "string",
19532 "typetext" : "<string>"
44660702
DM
19533 },
19534 "type" : {
19535 "description" : "Network interface type",
19536 "enum" : [
19537 "bridge",
19538 "bond",
19539 "eth",
19540 "alias",
19541 "vlan",
19542 "OVSBridge",
19543 "OVSBond",
19544 "OVSPort",
19545 "OVSIntPort",
19546 "unknown"
19547 ],
19548 "type" : "string"
7aacca6f
DM
19549 }
19550 }
19551 },
7aacca6f
DM
19552 "permissions" : {
19553 "check" : [
19554 "perm",
19555 "/nodes/{node}",
19556 [
44660702 19557 "Sys.Modify"
7aacca6f
DM
19558 ]
19559 ]
19560 },
44660702
DM
19561 "protected" : 1,
19562 "proxyto" : "node",
7aacca6f 19563 "returns" : {
44660702
DM
19564 "type" : "null"
19565 }
7aacca6f
DM
19566 }
19567 },
7aacca6f 19568 "leaf" : 1,
44660702
DM
19569 "path" : "/nodes/{node}/network/{iface}",
19570 "text" : "{iface}"
7aacca6f
DM
19571 }
19572 ],
7aacca6f 19573 "info" : {
44660702
DM
19574 "DELETE" : {
19575 "description" : "Revert network configuration changes.",
19576 "method" : "DELETE",
19577 "name" : "revert_network_changes",
7aacca6f
DM
19578 "parameters" : {
19579 "additionalProperties" : 0,
19580 "properties" : {
7aacca6f 19581 "node" : {
7aacca6f 19582 "description" : "The cluster node name.",
44660702 19583 "format" : "pve-node",
013dc89f
DM
19584 "type" : "string",
19585 "typetext" : "<string>"
7aacca6f
DM
19586 }
19587 }
44660702 19588 },
7aacca6f
DM
19589 "permissions" : {
19590 "check" : [
19591 "perm",
19592 "/nodes/{node}",
19593 [
19594 "Sys.Modify"
19595 ]
19596 ]
19597 },
44660702
DM
19598 "protected" : 1,
19599 "proxyto" : "node",
7aacca6f
DM
19600 "returns" : {
19601 "type" : "null"
44660702 19602 }
7aacca6f 19603 },
44660702
DM
19604 "GET" : {
19605 "description" : "List available networks",
19606 "method" : "GET",
19607 "name" : "index",
7aacca6f 19608 "parameters" : {
44660702 19609 "additionalProperties" : 0,
7aacca6f 19610 "properties" : {
7aacca6f 19611 "node" : {
44660702
DM
19612 "description" : "The cluster node name.",
19613 "format" : "pve-node",
013dc89f
DM
19614 "type" : "string",
19615 "typetext" : "<string>"
7aacca6f
DM
19616 },
19617 "type" : {
44660702 19618 "description" : "Only list specific interface types.",
7aacca6f
DM
19619 "enum" : [
19620 "bridge",
19621 "bond",
19622 "eth",
19623 "alias",
19624 "vlan",
19625 "OVSBridge",
19626 "OVSBond",
19627 "OVSPort",
19628 "OVSIntPort",
44660702 19629 "any_bridge"
7aacca6f 19630 ],
7aacca6f 19631 "optional" : 1,
44660702
DM
19632 "type" : "string"
19633 }
19634 }
19635 },
19636 "permissions" : {
19637 "user" : "all"
19638 },
19639 "proxyto" : "node",
19640 "returns" : {
19641 "items" : {
19642 "properties" : {},
19643 "type" : "object"
19644 },
19645 "links" : [
19646 {
19647 "href" : "{iface}",
19648 "rel" : "child"
19649 }
19650 ],
19651 "type" : "array"
19652 }
19653 },
19654 "POST" : {
19655 "description" : "Create network device configuration",
19656 "method" : "POST",
19657 "name" : "create_network",
19658 "parameters" : {
19659 "additionalProperties" : 0,
19660 "properties" : {
7aacca6f 19661 "address" : {
44660702
DM
19662 "description" : "IP address.",
19663 "format" : "ipv4",
19664 "optional" : 1,
7aacca6f 19665 "requires" : "netmask",
013dc89f
DM
19666 "type" : "string",
19667 "typetext" : "<string>"
44660702
DM
19668 },
19669 "address6" : {
7aacca6f 19670 "description" : "IP address.",
44660702
DM
19671 "format" : "ipv6",
19672 "optional" : 1,
19673 "requires" : "netmask6",
013dc89f
DM
19674 "type" : "string",
19675 "typetext" : "<string>"
44660702
DM
19676 },
19677 "autostart" : {
19678 "description" : "Automatically start interface on boot.",
7aacca6f 19679 "optional" : 1,
013dc89f
DM
19680 "type" : "boolean",
19681 "typetext" : "<boolean>"
7aacca6f
DM
19682 },
19683 "bond_mode" : {
19684 "description" : "Bonding mode.",
19685 "enum" : [
19686 "balance-rr",
19687 "active-backup",
19688 "balance-xor",
19689 "broadcast",
19690 "802.3ad",
19691 "balance-tlb",
19692 "balance-alb",
19693 "balance-slb",
19694 "lacp-balance-slb",
19695 "lacp-balance-tcp"
19696 ],
19697 "optional" : 1,
19698 "type" : "string"
19699 },
44660702
DM
19700 "bond_xmit_hash_policy" : {
19701 "description" : "Selects the transmit hash policy to use for slave selection in balance-xor and 802.3ad modes.",
19702 "enum" : [
19703 "layer2",
19704 "layer2+3",
19705 "layer3+4"
19706 ],
19707 "optional" : 1,
19708 "type" : "string"
19709 },
19710 "bridge_ports" : {
19711 "description" : "Specify the iterfaces you want to add to your bridge.",
7aacca6f 19712 "format" : "pve-iface-list",
7aacca6f 19713 "optional" : 1,
013dc89f
DM
19714 "type" : "string",
19715 "typetext" : "<string>"
7aacca6f 19716 },
44660702
DM
19717 "bridge_vlan_aware" : {
19718 "description" : "Enable bridge vlan support.",
7aacca6f 19719 "optional" : 1,
013dc89f
DM
19720 "type" : "boolean",
19721 "typetext" : "<boolean>"
7aacca6f 19722 },
44660702
DM
19723 "comments" : {
19724 "description" : "Comments",
7aacca6f 19725 "optional" : 1,
013dc89f
DM
19726 "type" : "string",
19727 "typetext" : "<string>"
44660702
DM
19728 },
19729 "comments6" : {
19730 "description" : "Comments",
19731 "optional" : 1,
013dc89f
DM
19732 "type" : "string",
19733 "typetext" : "<string>"
44660702
DM
19734 },
19735 "gateway" : {
19736 "description" : "Default gateway address.",
19737 "format" : "ipv4",
19738 "optional" : 1,
013dc89f
DM
19739 "type" : "string",
19740 "typetext" : "<string>"
44660702
DM
19741 },
19742 "gateway6" : {
19743 "description" : "Default ipv6 gateway address.",
19744 "format" : "ipv6",
19745 "optional" : 1,
013dc89f
DM
19746 "type" : "string",
19747 "typetext" : "<string>"
56122987 19748 },
7aacca6f 19749 "iface" : {
44660702 19750 "description" : "Network interface name.",
7aacca6f
DM
19751 "format" : "pve-iface",
19752 "maxLength" : 20,
44660702 19753 "minLength" : 2,
013dc89f
DM
19754 "type" : "string",
19755 "typetext" : "<string>"
56122987 19756 },
44660702
DM
19757 "netmask" : {
19758 "description" : "Network mask.",
19759 "format" : "ipv4mask",
7aacca6f 19760 "optional" : 1,
44660702 19761 "requires" : "address",
013dc89f
DM
19762 "type" : "string",
19763 "typetext" : "<string>"
7aacca6f 19764 },
44660702
DM
19765 "netmask6" : {
19766 "description" : "Network mask.",
19767 "maximum" : 128,
19768 "minimum" : 0,
7aacca6f 19769 "optional" : 1,
44660702 19770 "requires" : "address6",
4bd7df8b 19771 "type" : "integer",
013dc89f 19772 "typetext" : "<integer> (0 - 128)"
7aacca6f 19773 },
44660702
DM
19774 "node" : {
19775 "description" : "The cluster node name.",
19776 "format" : "pve-node",
013dc89f
DM
19777 "type" : "string",
19778 "typetext" : "<string>"
44660702
DM
19779 },
19780 "ovs_bonds" : {
19781 "description" : "Specify the interfaces used by the bonding device.",
19782 "format" : "pve-iface-list",
7aacca6f 19783 "optional" : 1,
013dc89f
DM
19784 "type" : "string",
19785 "typetext" : "<string>"
7aacca6f 19786 },
44660702
DM
19787 "ovs_bridge" : {
19788 "description" : "The OVS bridge associated with a OVS port. This is required when you create an OVS port.",
19789 "format" : "pve-iface",
19790 "optional" : 1,
013dc89f
DM
19791 "type" : "string",
19792 "typetext" : "<string>"
44660702
DM
19793 },
19794 "ovs_options" : {
19795 "description" : "OVS interface options.",
19796 "maxLength" : 1024,
19797 "optional" : 1,
013dc89f
DM
19798 "type" : "string",
19799 "typetext" : "<string>"
44660702
DM
19800 },
19801 "ovs_ports" : {
19802 "description" : "Specify the iterfaces you want to add to your bridge.",
19803 "format" : "pve-iface-list",
19804 "optional" : 1,
013dc89f
DM
19805 "type" : "string",
19806 "typetext" : "<string>"
44660702
DM
19807 },
19808 "ovs_tag" : {
19809 "description" : "Specify a VLan tag (used by OVSPort, OVSIntPort, OVSBond)",
19810 "maximum" : 4094,
19811 "minimum" : 1,
19812 "optional" : 1,
4bd7df8b 19813 "type" : "integer",
013dc89f 19814 "typetext" : "<integer> (1 - 4094)"
44660702
DM
19815 },
19816 "slaves" : {
19817 "description" : "Specify the interfaces used by the bonding device.",
19818 "format" : "pve-iface-list",
7aacca6f 19819 "optional" : 1,
013dc89f
DM
19820 "type" : "string",
19821 "typetext" : "<string>"
44660702
DM
19822 },
19823 "type" : {
19824 "description" : "Network interface type",
7aacca6f 19825 "enum" : [
44660702
DM
19826 "bridge",
19827 "bond",
19828 "eth",
19829 "alias",
19830 "vlan",
19831 "OVSBridge",
19832 "OVSBond",
19833 "OVSPort",
19834 "OVSIntPort",
19835 "unknown"
7aacca6f 19836 ],
44660702 19837 "type" : "string"
56122987 19838 }
44660702 19839 }
56122987 19840 },
56122987
DM
19841 "permissions" : {
19842 "check" : [
19843 "perm",
19844 "/nodes/{node}",
19845 [
7aacca6f 19846 "Sys.Modify"
44660702
DM
19847 ]
19848 ]
7aacca6f 19849 },
44660702
DM
19850 "protected" : 1,
19851 "proxyto" : "node",
19852 "returns" : {
19853 "type" : "null"
19854 }
19855 }
19856 },
19857 "leaf" : 0,
19858 "path" : "/nodes/{node}/network",
19859 "text" : "network"
19860 },
19861 {
19862 "children" : [
19863 {
7aacca6f
DM
19864 "children" : [
19865 {
19866 "info" : {
19867 "GET" : {
44660702 19868 "description" : "Read task log.",
7aacca6f
DM
19869 "method" : "GET",
19870 "name" : "read_task_log",
19871 "parameters" : {
44660702 19872 "additionalProperties" : 0,
7aacca6f 19873 "properties" : {
44660702
DM
19874 "limit" : {
19875 "minimum" : 0,
7aacca6f 19876 "optional" : 1,
4bd7df8b 19877 "type" : "integer",
013dc89f 19878 "typetext" : "<integer> (0 - N)"
7aacca6f
DM
19879 },
19880 "node" : {
19881 "description" : "The cluster node name.",
44660702 19882 "format" : "pve-node",
013dc89f
DM
19883 "type" : "string",
19884 "typetext" : "<string>"
7aacca6f 19885 },
44660702
DM
19886 "start" : {
19887 "minimum" : 0,
7aacca6f 19888 "optional" : 1,
4bd7df8b 19889 "type" : "integer",
013dc89f 19890 "typetext" : "<integer> (0 - N)"
44660702
DM
19891 },
19892 "upid" : {
013dc89f
DM
19893 "type" : "string",
19894 "typetext" : "<string>"
7aacca6f 19895 }
44660702
DM
19896 }
19897 },
19898 "permissions" : {
19899 "description" : "The user needs 'Sys.Audit' permissions on '/nodes/<node>' if the task does not belong to him.",
19900 "user" : "all"
7aacca6f
DM
19901 },
19902 "protected" : 1,
44660702 19903 "proxyto" : "node",
7aacca6f 19904 "returns" : {
7aacca6f 19905 "items" : {
7aacca6f
DM
19906 "properties" : {
19907 "n" : {
44660702
DM
19908 "description" : "Line number",
19909 "type" : "integer"
7aacca6f
DM
19910 },
19911 "t" : {
44660702
DM
19912 "description" : "Line text",
19913 "type" : "string"
7aacca6f 19914 }
44660702
DM
19915 },
19916 "type" : "object"
19917 },
19918 "type" : "array"
19919 }
7aacca6f 19920 }
56122987 19921 },
7aacca6f 19922 "leaf" : 1,
44660702
DM
19923 "path" : "/nodes/{node}/tasks/{upid}/log",
19924 "text" : "log"
7aacca6f
DM
19925 },
19926 {
7aacca6f
DM
19927 "info" : {
19928 "GET" : {
44660702
DM
19929 "description" : "Read task status.",
19930 "method" : "GET",
7aacca6f
DM
19931 "name" : "read_task_status",
19932 "parameters" : {
19933 "additionalProperties" : 0,
19934 "properties" : {
19935 "node" : {
7aacca6f 19936 "description" : "The cluster node name.",
44660702 19937 "format" : "pve-node",
013dc89f
DM
19938 "type" : "string",
19939 "typetext" : "<string>"
7aacca6f
DM
19940 },
19941 "upid" : {
013dc89f
DM
19942 "type" : "string",
19943 "typetext" : "<string>"
7aacca6f
DM
19944 }
19945 }
19946 },
7aacca6f
DM
19947 "permissions" : {
19948 "description" : "The user needs 'Sys.Audit' permissions on '/nodes/<node>' if the task does not belong to him.",
19949 "user" : "all"
56122987 19950 },
44660702 19951 "protected" : 1,
7aacca6f 19952 "proxyto" : "node",
7aacca6f
DM
19953 "returns" : {
19954 "properties" : {
19955 "pid" : {
19956 "type" : "integer"
19957 },
19958 "status" : {
7aacca6f
DM
19959 "enum" : [
19960 "running",
19961 "stopped"
44660702
DM
19962 ],
19963 "type" : "string"
7aacca6f
DM
19964 }
19965 },
19966 "type" : "object"
56122987 19967 }
7aacca6f 19968 }
44660702
DM
19969 },
19970 "leaf" : 1,
19971 "path" : "/nodes/{node}/tasks/{upid}/status",
19972 "text" : "status"
56122987 19973 }
7aacca6f 19974 ],
44660702
DM
19975 "info" : {
19976 "DELETE" : {
19977 "description" : "Stop a task.",
19978 "method" : "DELETE",
19979 "name" : "stop_task",
19980 "parameters" : {
19981 "additionalProperties" : 0,
19982 "properties" : {
19983 "node" : {
19984 "description" : "The cluster node name.",
19985 "format" : "pve-node",
013dc89f
DM
19986 "type" : "string",
19987 "typetext" : "<string>"
44660702
DM
19988 },
19989 "upid" : {
013dc89f
DM
19990 "type" : "string",
19991 "typetext" : "<string>"
44660702 19992 }
7aacca6f 19993 }
44660702
DM
19994 },
19995 "permissions" : {
19996 "description" : "The user needs 'Sys.Modify' permissions on '/nodes/<node>' if the task does not belong to him.",
19997 "user" : "all"
19998 },
19999 "protected" : 1,
20000 "proxyto" : "node",
20001 "returns" : {
20002 "type" : "null"
7aacca6f 20003 }
56122987 20004 },
44660702
DM
20005 "GET" : {
20006 "description" : "",
20007 "method" : "GET",
20008 "name" : "upid_index",
20009 "parameters" : {
20010 "additionalProperties" : 0,
20011 "properties" : {
20012 "node" : {
20013 "description" : "The cluster node name.",
20014 "format" : "pve-node",
013dc89f
DM
20015 "type" : "string",
20016 "typetext" : "<string>"
44660702
DM
20017 },
20018 "upid" : {
013dc89f
DM
20019 "type" : "string",
20020 "typetext" : "<string>"
44660702
DM
20021 }
20022 }
20023 },
20024 "permissions" : {
20025 "user" : "all"
20026 },
20027 "returns" : {
20028 "items" : {
20029 "properties" : {},
20030 "type" : "object"
20031 },
20032 "links" : [
20033 {
20034 "href" : "{name}",
20035 "rel" : "child"
20036 }
20037 ],
20038 "type" : "array"
56122987 20039 }
44660702 20040 }
56122987 20041 },
44660702
DM
20042 "leaf" : 0,
20043 "path" : "/nodes/{node}/tasks/{upid}",
20044 "text" : "{upid}"
20045 }
20046 ],
20047 "info" : {
20048 "GET" : {
7aacca6f 20049 "description" : "Read task list for one node (finished tasks).",
44660702
DM
20050 "method" : "GET",
20051 "name" : "node_tasks",
56122987 20052 "parameters" : {
7aacca6f 20053 "additionalProperties" : 0,
56122987 20054 "properties" : {
44660702 20055 "errors" : {
56122987 20056 "optional" : 1,
013dc89f
DM
20057 "type" : "boolean",
20058 "typetext" : "<boolean>"
56122987 20059 },
44660702 20060 "limit" : {
56122987 20061 "minimum" : 0,
56122987 20062 "optional" : 1,
4bd7df8b 20063 "type" : "integer",
013dc89f 20064 "typetext" : "<integer> (0 - N)"
56122987 20065 },
56122987
DM
20066 "node" : {
20067 "description" : "The cluster node name.",
44660702 20068 "format" : "pve-node",
013dc89f
DM
20069 "type" : "string",
20070 "typetext" : "<string>"
56122987 20071 },
44660702 20072 "start" : {
7aacca6f 20073 "minimum" : 0,
44660702 20074 "optional" : 1,
4bd7df8b 20075 "type" : "integer",
013dc89f 20076 "typetext" : "<integer> (0 - N)"
56122987 20077 },
7aacca6f 20078 "userfilter" : {
44660702 20079 "optional" : 1,
013dc89f
DM
20080 "type" : "string",
20081 "typetext" : "<string>"
44660702
DM
20082 },
20083 "vmid" : {
20084 "description" : "Only list tasks for this VM.",
20085 "format" : "pve-vmid",
20086 "minimum" : 1,
20087 "optional" : 1,
4bd7df8b 20088 "type" : "integer",
013dc89f 20089 "typetext" : "<integer> (1 - N)"
56122987
DM
20090 }
20091 }
20092 },
7aacca6f 20093 "permissions" : {
44660702 20094 "description" : "List task associated with the current user, or all task the user has 'Sys.Audit' permissions on /nodes/<node> (the <node> the task runs on).",
7aacca6f
DM
20095 "user" : "all"
20096 },
44660702 20097 "proxyto" : "node",
56122987
DM
20098 "returns" : {
20099 "items" : {
20100 "properties" : {
44660702 20101 "upid" : {
56122987
DM
20102 "type" : "string"
20103 }
20104 },
20105 "type" : "object"
20106 },
56122987
DM
20107 "links" : [
20108 {
44660702
DM
20109 "href" : "{upid}",
20110 "rel" : "child"
56122987 20111 }
44660702
DM
20112 ],
20113 "type" : "array"
56122987
DM
20114 }
20115 }
20116 },
44660702
DM
20117 "leaf" : 0,
20118 "path" : "/nodes/{node}/tasks",
20119 "text" : "tasks"
20120 },
20121 {
56122987
DM
20122 "children" : [
20123 {
56122987
DM
20124 "info" : {
20125 "GET" : {
7aacca6f 20126 "description" : "Scan zfs pool list on local node.",
44660702
DM
20127 "method" : "GET",
20128 "name" : "zfsscan",
56122987 20129 "parameters" : {
44660702 20130 "additionalProperties" : 0,
56122987 20131 "properties" : {
56122987
DM
20132 "node" : {
20133 "description" : "The cluster node name.",
44660702 20134 "format" : "pve-node",
013dc89f
DM
20135 "type" : "string",
20136 "typetext" : "<string>"
56122987 20137 }
44660702
DM
20138 }
20139 },
7aacca6f
DM
20140 "permissions" : {
20141 "check" : [
20142 "perm",
20143 "/storage",
20144 [
20145 "Datastore.Allocate"
20146 ]
20147 ]
20148 },
44660702
DM
20149 "protected" : 1,
20150 "proxyto" : "node",
56122987 20151 "returns" : {
56122987
DM
20152 "items" : {
20153 "properties" : {
44660702 20154 "pool" : {
56122987
DM
20155 "type" : "string"
20156 }
44660702
DM
20157 },
20158 "type" : "object"
20159 },
20160 "type" : "array"
20161 }
20162 }
20163 },
20164 "leaf" : 1,
20165 "path" : "/nodes/{node}/scan/zfs",
20166 "text" : "zfs"
20167 },
20168 {
20169 "info" : {
20170 "GET" : {
20171 "description" : "Scan remote NFS server.",
20172 "method" : "GET",
7aacca6f 20173 "name" : "nfsscan",
56122987 20174 "parameters" : {
44660702 20175 "additionalProperties" : 0,
56122987
DM
20176 "properties" : {
20177 "node" : {
7aacca6f 20178 "description" : "The cluster node name.",
44660702 20179 "format" : "pve-node",
013dc89f
DM
20180 "type" : "string",
20181 "typetext" : "<string>"
7aacca6f
DM
20182 },
20183 "server" : {
20184 "format" : "pve-storage-server",
013dc89f
DM
20185 "type" : "string",
20186 "typetext" : "<string>"
56122987 20187 }
44660702 20188 }
56122987 20189 },
56122987
DM
20190 "permissions" : {
20191 "check" : [
20192 "perm",
20193 "/storage",
20194 [
20195 "Datastore.Allocate"
20196 ]
20197 ]
20198 },
44660702 20199 "protected" : 1,
56122987 20200 "proxyto" : "node",
44660702
DM
20201 "returns" : {
20202 "items" : {
20203 "properties" : {
20204 "options" : {
20205 "type" : "string"
20206 },
20207 "path" : {
20208 "type" : "string"
20209 }
20210 },
20211 "type" : "object"
20212 },
20213 "type" : "array"
20214 }
20215 }
20216 },
20217 "leaf" : 1,
20218 "path" : "/nodes/{node}/scan/nfs",
20219 "text" : "nfs"
20220 },
20221 {
20222 "info" : {
20223 "GET" : {
20224 "description" : "Scan remote GlusterFS server.",
7aacca6f
DM
20225 "method" : "GET",
20226 "name" : "glusterfsscan",
56122987 20227 "parameters" : {
44660702 20228 "additionalProperties" : 0,
56122987 20229 "properties" : {
56122987 20230 "node" : {
44660702 20231 "description" : "The cluster node name.",
56122987 20232 "format" : "pve-node",
013dc89f
DM
20233 "type" : "string",
20234 "typetext" : "<string>"
7aacca6f
DM
20235 },
20236 "server" : {
20237 "format" : "pve-storage-server",
013dc89f
DM
20238 "type" : "string",
20239 "typetext" : "<string>"
56122987 20240 }
44660702
DM
20241 }
20242 },
20243 "permissions" : {
20244 "check" : [
20245 "perm",
20246 "/storage",
20247 [
20248 "Datastore.Allocate"
20249 ]
20250 ]
7aacca6f 20251 },
44660702
DM
20252 "protected" : 1,
20253 "proxyto" : "node",
20254 "returns" : {
20255 "items" : {
20256 "properties" : {
20257 "volname" : {
20258 "type" : "string"
20259 }
20260 },
20261 "type" : "object"
20262 },
20263 "type" : "array"
20264 }
56122987
DM
20265 }
20266 },
44660702
DM
20267 "leaf" : 1,
20268 "path" : "/nodes/{node}/scan/glusterfs",
7aacca6f 20269 "text" : "glusterfs"
56122987
DM
20270 },
20271 {
56122987
DM
20272 "info" : {
20273 "GET" : {
7aacca6f 20274 "description" : "Scan remote iSCSI server.",
44660702
DM
20275 "method" : "GET",
20276 "name" : "iscsiscan",
20277 "parameters" : {
20278 "additionalProperties" : 0,
20279 "properties" : {
20280 "node" : {
20281 "description" : "The cluster node name.",
20282 "format" : "pve-node",
013dc89f
DM
20283 "type" : "string",
20284 "typetext" : "<string>"
44660702
DM
20285 },
20286 "portal" : {
20287 "format" : "pve-storage-portal-dns",
013dc89f
DM
20288 "type" : "string",
20289 "typetext" : "<string>"
44660702
DM
20290 }
20291 }
20292 },
56122987
DM
20293 "permissions" : {
20294 "check" : [
20295 "perm",
20296 "/storage",
20297 [
20298 "Datastore.Allocate"
20299 ]
20300 ]
20301 },
44660702
DM
20302 "protected" : 1,
20303 "proxyto" : "node",
56122987 20304 "returns" : {
56122987
DM
20305 "items" : {
20306 "properties" : {
44660702 20307 "portal" : {
56122987
DM
20308 "type" : "string"
20309 },
44660702 20310 "target" : {
56122987
DM
20311 "type" : "string"
20312 }
20313 },
20314 "type" : "object"
56122987 20315 },
44660702
DM
20316 "type" : "array"
20317 }
56122987
DM
20318 }
20319 },
44660702 20320 "leaf" : 1,
7aacca6f 20321 "path" : "/nodes/{node}/scan/iscsi",
44660702 20322 "text" : "iscsi"
56122987
DM
20323 },
20324 {
56122987
DM
20325 "info" : {
20326 "GET" : {
44660702
DM
20327 "description" : "List local LVM volume groups.",
20328 "method" : "GET",
20329 "name" : "lvmscan",
20330 "parameters" : {
20331 "additionalProperties" : 0,
20332 "properties" : {
20333 "node" : {
20334 "description" : "The cluster node name.",
20335 "format" : "pve-node",
013dc89f
DM
20336 "type" : "string",
20337 "typetext" : "<string>"
56122987 20338 }
7aacca6f 20339 }
56122987 20340 },
56122987
DM
20341 "permissions" : {
20342 "check" : [
20343 "perm",
20344 "/storage",
20345 [
20346 "Datastore.Allocate"
20347 ]
20348 ]
20349 },
7aacca6f 20350 "protected" : 1,
44660702
DM
20351 "proxyto" : "node",
20352 "returns" : {
20353 "items" : {
20354 "properties" : {
20355 "vg" : {
20356 "type" : "string"
20357 }
20358 },
20359 "type" : "object"
20360 },
20361 "type" : "array"
7aacca6f 20362 }
56122987
DM
20363 }
20364 },
20365 "leaf" : 1,
44660702
DM
20366 "path" : "/nodes/{node}/scan/lvm",
20367 "text" : "lvm"
56122987
DM
20368 },
20369 {
56122987
DM
20370 "info" : {
20371 "GET" : {
44660702
DM
20372 "description" : "List local LVM Thin Pools.",
20373 "method" : "GET",
20374 "name" : "lvmthinscan",
56122987 20375 "parameters" : {
44660702 20376 "additionalProperties" : 0,
56122987
DM
20377 "properties" : {
20378 "node" : {
44660702 20379 "description" : "The cluster node name.",
56122987 20380 "format" : "pve-node",
013dc89f
DM
20381 "type" : "string",
20382 "typetext" : "<string>"
56122987
DM
20383 },
20384 "vg" : {
44660702 20385 "maxLength" : 100,
56122987 20386 "pattern" : "[a-zA-Z0-9\\.\\+\\_][a-zA-Z0-9\\.\\+\\_\\-]+",
44660702 20387 "type" : "string"
56122987 20388 }
44660702 20389 }
56122987 20390 },
7aacca6f
DM
20391 "permissions" : {
20392 "check" : [
20393 "perm",
20394 "/storage",
20395 [
20396 "Datastore.Allocate"
20397 ]
20398 ]
20399 },
44660702 20400 "protected" : 1,
7aacca6f 20401 "proxyto" : "node",
56122987 20402 "returns" : {
56122987
DM
20403 "items" : {
20404 "properties" : {
20405 "lv" : {
20406 "type" : "string"
20407 }
20408 },
20409 "type" : "object"
44660702
DM
20410 },
20411 "type" : "array"
7aacca6f 20412 }
56122987
DM
20413 }
20414 },
7aacca6f 20415 "leaf" : 1,
44660702
DM
20416 "path" : "/nodes/{node}/scan/lvmthin",
20417 "text" : "lvmthin"
56122987
DM
20418 },
20419 {
56122987
DM
20420 "info" : {
20421 "GET" : {
44660702
DM
20422 "description" : "List local USB devices.",
20423 "method" : "GET",
20424 "name" : "usbscan",
20425 "parameters" : {
20426 "additionalProperties" : 0,
20427 "properties" : {
20428 "node" : {
20429 "description" : "The cluster node name.",
20430 "format" : "pve-node",
013dc89f
DM
20431 "type" : "string",
20432 "typetext" : "<string>"
44660702
DM
20433 }
20434 }
20435 },
7aacca6f
DM
20436 "permissions" : {
20437 "check" : [
20438 "perm",
20439 "/",
20440 [
20441 "Sys.Modify"
20442 ]
20443 ]
20444 },
44660702 20445 "protected" : 1,
7aacca6f 20446 "proxyto" : "node",
56122987
DM
20447 "returns" : {
20448 "items" : {
20449 "properties" : {
44660702
DM
20450 "busnum" : {
20451 "type" : "integer"
56122987 20452 },
44660702
DM
20453 "class" : {
20454 "type" : "integer"
56122987 20455 },
7aacca6f 20456 "devnum" : {
56122987
DM
20457 "type" : "integer"
20458 },
44660702
DM
20459 "level" : {
20460 "type" : "integer"
20461 },
20462 "manufacturer" : {
20463 "optional" : 1,
7aacca6f
DM
20464 "type" : "string"
20465 },
44660702 20466 "port" : {
56122987
DM
20467 "type" : "integer"
20468 },
44660702
DM
20469 "prodid" : {
20470 "type" : "string"
56122987 20471 },
44660702
DM
20472 "product" : {
20473 "optional" : 1,
20474 "type" : "string"
20475 },
20476 "serial" : {
7aacca6f 20477 "optional" : 1,
56122987
DM
20478 "type" : "string"
20479 },
44660702 20480 "speed" : {
7aacca6f 20481 "type" : "string"
56122987 20482 },
44660702 20483 "usbpath" : {
56122987
DM
20484 "optional" : 1,
20485 "type" : "string"
20486 },
44660702
DM
20487 "vendid" : {
20488 "type" : "string"
56122987
DM
20489 }
20490 },
20491 "type" : "object"
7aacca6f
DM
20492 },
20493 "type" : "array"
44660702
DM
20494 }
20495 }
20496 },
20497 "leaf" : 1,
20498 "path" : "/nodes/{node}/scan/usb",
20499 "text" : "usb"
20500 }
20501 ],
20502 "info" : {
20503 "GET" : {
20504 "description" : "Index of available scan methods",
20505 "method" : "GET",
20506 "name" : "index",
20507 "parameters" : {
20508 "additionalProperties" : 0,
20509 "properties" : {
20510 "node" : {
20511 "description" : "The cluster node name.",
20512 "format" : "pve-node",
013dc89f
DM
20513 "type" : "string",
20514 "typetext" : "<string>"
44660702
DM
20515 }
20516 }
20517 },
20518 "permissions" : {
20519 "user" : "all"
20520 },
20521 "returns" : {
20522 "items" : {
20523 "properties" : {
20524 "method" : {
20525 "type" : "string"
56122987
DM
20526 }
20527 },
44660702
DM
20528 "type" : "object"
20529 },
20530 "links" : [
20531 {
20532 "href" : "{method}",
20533 "rel" : "child"
20534 }
20535 ],
20536 "type" : "array"
56122987
DM
20537 }
20538 }
44660702
DM
20539 },
20540 "leaf" : 0,
20541 "path" : "/nodes/{node}/scan",
7aacca6f 20542 "text" : "scan"
56122987
DM
20543 },
20544 {
56122987
DM
20545 "children" : [
20546 {
56122987
DM
20547 "children" : [
20548 {
7aacca6f
DM
20549 "children" : [
20550 {
20551 "info" : {
44660702
DM
20552 "DELETE" : {
20553 "description" : "Delete volume",
20554 "method" : "DELETE",
20555 "name" : "delete",
7aacca6f
DM
20556 "parameters" : {
20557 "additionalProperties" : 0,
20558 "properties" : {
7aacca6f
DM
20559 "node" : {
20560 "description" : "The cluster node name.",
44660702 20561 "format" : "pve-node",
013dc89f
DM
20562 "type" : "string",
20563 "typetext" : "<string>"
44660702
DM
20564 },
20565 "storage" : {
20566 "description" : "The storage identifier.",
20567 "format" : "pve-storage-id",
20568 "optional" : 1,
013dc89f
DM
20569 "type" : "string",
20570 "typetext" : "<string>"
7aacca6f
DM
20571 },
20572 "volume" : {
20573 "description" : "Volume identifier",
013dc89f
DM
20574 "type" : "string",
20575 "typetext" : "<string>"
7aacca6f
DM
20576 }
20577 }
20578 },
44660702
DM
20579 "permissions" : {
20580 "description" : "You need 'Datastore.Allocate' privilege on the storage (or 'Datastore.AllocateSpace' for backup volumes if you have VM.Backup privilege on the VM).",
20581 "user" : "all"
20582 },
20583 "protected" : 1,
20584 "proxyto" : "node",
20585 "returns" : {
20586 "type" : "null"
20587 }
7aacca6f 20588 },
44660702
DM
20589 "GET" : {
20590 "description" : "Get volume attributes",
20591 "method" : "GET",
20592 "name" : "info",
7aacca6f
DM
20593 "parameters" : {
20594 "additionalProperties" : 0,
20595 "properties" : {
7aacca6f
DM
20596 "node" : {
20597 "description" : "The cluster node name.",
44660702 20598 "format" : "pve-node",
013dc89f
DM
20599 "type" : "string",
20600 "typetext" : "<string>"
7aacca6f
DM
20601 },
20602 "storage" : {
7aacca6f 20603 "description" : "The storage identifier.",
44660702 20604 "format" : "pve-storage-id",
7aacca6f 20605 "optional" : 1,
013dc89f
DM
20606 "type" : "string",
20607 "typetext" : "<string>"
44660702
DM
20608 },
20609 "volume" : {
20610 "description" : "Volume identifier",
013dc89f
DM
20611 "type" : "string",
20612 "typetext" : "<string>"
7aacca6f
DM
20613 }
20614 }
20615 },
7aacca6f 20616 "permissions" : {
44660702 20617 "description" : "You need read access for the volume.",
7aacca6f
DM
20618 "user" : "all"
20619 },
44660702 20620 "protected" : 1,
7aacca6f 20621 "proxyto" : "node",
7aacca6f 20622 "returns" : {
44660702 20623 "type" : "object"
7aacca6f
DM
20624 }
20625 },
20626 "POST" : {
44660702
DM
20627 "description" : "Copy a volume. This is experimental code - do not use.",
20628 "method" : "POST",
20629 "name" : "copy",
7aacca6f
DM
20630 "parameters" : {
20631 "additionalProperties" : 0,
20632 "properties" : {
44660702
DM
20633 "node" : {
20634 "description" : "The cluster node name.",
20635 "format" : "pve-node",
013dc89f
DM
20636 "type" : "string",
20637 "typetext" : "<string>"
44660702
DM
20638 },
20639 "storage" : {
20640 "description" : "The storage identifier.",
20641 "format" : "pve-storage-id",
20642 "optional" : 1,
013dc89f
DM
20643 "type" : "string",
20644 "typetext" : "<string>"
44660702 20645 },
7aacca6f 20646 "target" : {
44660702 20647 "description" : "Target volume identifier",
013dc89f
DM
20648 "type" : "string",
20649 "typetext" : "<string>"
7aacca6f
DM
20650 },
20651 "target_node" : {
7aacca6f 20652 "description" : "Target node. Default is local node.",
44660702
DM
20653 "format" : "pve-node",
20654 "optional" : 1,
013dc89f
DM
20655 "type" : "string",
20656 "typetext" : "<string>"
7aacca6f
DM
20657 },
20658 "volume" : {
44660702 20659 "description" : "Source volume identifier",
013dc89f
DM
20660 "type" : "string",
20661 "typetext" : "<string>"
7aacca6f
DM
20662 }
20663 }
20664 },
7aacca6f
DM
20665 "protected" : 1,
20666 "proxyto" : "node",
20667 "returns" : {
20668 "type" : "string"
44660702 20669 }
7aacca6f
DM
20670 }
20671 },
7aacca6f 20672 "leaf" : 1,
44660702
DM
20673 "path" : "/nodes/{node}/storage/{storage}/content/{volume}",
20674 "text" : "{volume}"
7aacca6f
DM
20675 }
20676 ],
56122987
DM
20677 "info" : {
20678 "GET" : {
44660702
DM
20679 "description" : "List storage content.",
20680 "method" : "GET",
20681 "name" : "index",
20682 "parameters" : {
20683 "additionalProperties" : 0,
20684 "properties" : {
20685 "content" : {
20686 "description" : "Only list content of this type.",
20687 "format" : "pve-storage-content",
20688 "optional" : 1,
013dc89f
DM
20689 "type" : "string",
20690 "typetext" : "<string>"
44660702
DM
20691 },
20692 "node" : {
20693 "description" : "The cluster node name.",
20694 "format" : "pve-node",
013dc89f
DM
20695 "type" : "string",
20696 "typetext" : "<string>"
44660702
DM
20697 },
20698 "storage" : {
20699 "description" : "The storage identifier.",
20700 "format" : "pve-storage-id",
013dc89f
DM
20701 "type" : "string",
20702 "typetext" : "<string>"
44660702
DM
20703 },
20704 "vmid" : {
20705 "description" : "Only list images for this VM",
20706 "format" : "pve-vmid",
20707 "minimum" : 1,
20708 "optional" : 1,
4bd7df8b 20709 "type" : "integer",
013dc89f 20710 "typetext" : "<integer> (1 - N)"
44660702
DM
20711 }
20712 }
20713 },
7aacca6f
DM
20714 "permissions" : {
20715 "check" : [
20716 "perm",
20717 "/storage/{storage}",
20718 [
20719 "Datastore.Audit",
20720 "Datastore.AllocateSpace"
20721 ],
20722 "any",
20723 1
20724 ]
20725 },
44660702 20726 "protected" : 1,
7aacca6f 20727 "proxyto" : "node",
56122987 20728 "returns" : {
44660702
DM
20729 "items" : {
20730 "properties" : {
20731 "volid" : {
20732 "type" : "string"
20733 }
20734 },
20735 "type" : "object"
20736 },
20737 "links" : [
20738 {
20739 "href" : "{volid}",
20740 "rel" : "child"
20741 }
20742 ],
20743 "type" : "array"
20744 }
20745 },
20746 "POST" : {
20747 "description" : "Allocate disk images.",
20748 "method" : "POST",
20749 "name" : "create",
56122987 20750 "parameters" : {
44660702 20751 "additionalProperties" : 0,
56122987 20752 "properties" : {
44660702
DM
20753 "filename" : {
20754 "description" : "The name of the file to create.",
013dc89f
DM
20755 "type" : "string",
20756 "typetext" : "<string>"
44660702
DM
20757 },
20758 "format" : {
20759 "enum" : [
20760 "raw",
20761 "qcow2",
20762 "subvol"
20763 ],
20764 "optional" : 1,
20765 "requires" : "size",
20766 "type" : "string"
20767 },
20768 "node" : {
20769 "description" : "The cluster node name.",
20770 "format" : "pve-node",
013dc89f
DM
20771 "type" : "string",
20772 "typetext" : "<string>"
44660702
DM
20773 },
20774 "size" : {
20775 "description" : "Size in kilobyte (1024 bytes). Optional suffixes 'M' (megabyte, 1024K) and 'G' (gigabyte, 1024M)",
20776 "pattern" : "\\d+[MG]?",
20777 "type" : "string"
20778 },
56122987
DM
20779 "storage" : {
20780 "description" : "The storage identifier.",
44660702 20781 "format" : "pve-storage-id",
013dc89f
DM
20782 "type" : "string",
20783 "typetext" : "<string>"
56122987 20784 },
44660702
DM
20785 "vmid" : {
20786 "description" : "Specify owner VM",
20787 "format" : "pve-vmid",
20788 "minimum" : 1,
4bd7df8b 20789 "type" : "integer",
013dc89f 20790 "typetext" : "<integer> (1 - N)"
44660702
DM
20791 }
20792 }
20793 },
20794 "permissions" : {
20795 "check" : [
20796 "perm",
20797 "/storage/{storage}",
20798 [
20799 "Datastore.AllocateSpace"
20800 ]
20801 ]
20802 },
20803 "protected" : 1,
20804 "proxyto" : "node",
20805 "returns" : {
20806 "description" : "Volume identifier",
20807 "type" : "string"
20808 }
20809 }
20810 },
20811 "leaf" : 0,
20812 "path" : "/nodes/{node}/storage/{storage}/content",
20813 "text" : "content"
20814 },
20815 {
20816 "info" : {
20817 "GET" : {
20818 "description" : "Read storage status.",
20819 "method" : "GET",
20820 "name" : "read_status",
20821 "parameters" : {
20822 "additionalProperties" : 0,
20823 "properties" : {
56122987
DM
20824 "node" : {
20825 "description" : "The cluster node name.",
44660702 20826 "format" : "pve-node",
013dc89f
DM
20827 "type" : "string",
20828 "typetext" : "<string>"
44660702
DM
20829 },
20830 "storage" : {
20831 "description" : "The storage identifier.",
20832 "format" : "pve-storage-id",
013dc89f
DM
20833 "type" : "string",
20834 "typetext" : "<string>"
56122987 20835 }
44660702
DM
20836 }
20837 },
20838 "permissions" : {
20839 "check" : [
20840 "perm",
20841 "/storage/{storage}",
20842 [
20843 "Datastore.Audit",
20844 "Datastore.AllocateSpace"
20845 ],
20846 "any",
20847 1
20848 ]
56122987
DM
20849 },
20850 "protected" : 1,
44660702
DM
20851 "proxyto" : "node",
20852 "returns" : {
20853 "properties" : {},
20854 "type" : "object"
20855 }
56122987
DM
20856 }
20857 },
44660702
DM
20858 "leaf" : 1,
20859 "path" : "/nodes/{node}/storage/{storage}/status",
7aacca6f 20860 "text" : "status"
56122987
DM
20861 },
20862 {
56122987
DM
20863 "info" : {
20864 "GET" : {
44660702
DM
20865 "description" : "Read storage RRD statistics (returns PNG).",
20866 "method" : "GET",
20867 "name" : "rrd",
56122987 20868 "parameters" : {
44660702 20869 "additionalProperties" : 0,
56122987 20870 "properties" : {
44660702
DM
20871 "cf" : {
20872 "description" : "The RRD consolidation function",
20873 "enum" : [
20874 "AVERAGE",
20875 "MAX"
20876 ],
20877 "optional" : 1,
20878 "type" : "string"
20879 },
7aacca6f 20880 "ds" : {
7aacca6f 20881 "description" : "The list of datasources you want to display.",
44660702 20882 "format" : "pve-configid-list",
013dc89f
DM
20883 "type" : "string",
20884 "typetext" : "<string>"
56122987 20885 },
7aacca6f
DM
20886 "node" : {
20887 "description" : "The cluster node name.",
44660702 20888 "format" : "pve-node",
013dc89f
DM
20889 "type" : "string",
20890 "typetext" : "<string>"
56122987 20891 },
7aacca6f 20892 "storage" : {
7aacca6f 20893 "description" : "The storage identifier.",
44660702 20894 "format" : "pve-storage-id",
013dc89f
DM
20895 "type" : "string",
20896 "typetext" : "<string>"
44660702
DM
20897 },
20898 "timeframe" : {
20899 "description" : "Specify the time frame you are interested in.",
7aacca6f 20900 "enum" : [
44660702
DM
20901 "hour",
20902 "day",
20903 "week",
20904 "month",
20905 "year"
7aacca6f 20906 ],
44660702 20907 "type" : "string"
56122987 20908 }
44660702 20909 }
56122987
DM
20910 },
20911 "permissions" : {
20912 "check" : [
20913 "perm",
20914 "/storage/{storage}",
20915 [
20916 "Datastore.Audit",
20917 "Datastore.AllocateSpace"
20918 ],
20919 "any",
20920 1
20921 ]
20922 },
44660702
DM
20923 "protected" : 1,
20924 "proxyto" : "node",
7aacca6f
DM
20925 "returns" : {
20926 "properties" : {
20927 "filename" : {
20928 "type" : "string"
20929 }
20930 },
20931 "type" : "object"
20932 }
56122987
DM
20933 }
20934 },
20935 "leaf" : 1,
44660702
DM
20936 "path" : "/nodes/{node}/storage/{storage}/rrd",
20937 "text" : "rrd"
56122987
DM
20938 },
20939 {
56122987
DM
20940 "info" : {
20941 "GET" : {
44660702
DM
20942 "description" : "Read storage RRD statistics.",
20943 "method" : "GET",
20944 "name" : "rrddata",
56122987 20945 "parameters" : {
44660702 20946 "additionalProperties" : 0,
56122987 20947 "properties" : {
44660702
DM
20948 "cf" : {
20949 "description" : "The RRD consolidation function",
20950 "enum" : [
20951 "AVERAGE",
20952 "MAX"
20953 ],
20954 "optional" : 1,
20955 "type" : "string"
20956 },
7aacca6f 20957 "node" : {
7aacca6f 20958 "description" : "The cluster node name.",
44660702 20959 "format" : "pve-node",
013dc89f
DM
20960 "type" : "string",
20961 "typetext" : "<string>"
44660702
DM
20962 },
20963 "storage" : {
20964 "description" : "The storage identifier.",
20965 "format" : "pve-storage-id",
013dc89f
DM
20966 "type" : "string",
20967 "typetext" : "<string>"
7aacca6f 20968 },
56122987 20969 "timeframe" : {
7aacca6f 20970 "description" : "Specify the time frame you are interested in.",
56122987
DM
20971 "enum" : [
20972 "hour",
20973 "day",
20974 "week",
20975 "month",
20976 "year"
56122987 20977 ],
44660702 20978 "type" : "string"
56122987 20979 }
44660702 20980 }
7aacca6f 20981 },
7aacca6f
DM
20982 "permissions" : {
20983 "check" : [
20984 "perm",
20985 "/storage/{storage}",
20986 [
20987 "Datastore.Audit",
20988 "Datastore.AllocateSpace"
20989 ],
20990 "any",
20991 1
20992 ]
20993 },
44660702
DM
20994 "protected" : 1,
20995 "proxyto" : "node",
7aacca6f
DM
20996 "returns" : {
20997 "items" : {
44660702
DM
20998 "properties" : {},
20999 "type" : "object"
7aacca6f
DM
21000 },
21001 "type" : "array"
56122987
DM
21002 }
21003 }
7aacca6f 21004 },
7aacca6f 21005 "leaf" : 1,
44660702
DM
21006 "path" : "/nodes/{node}/storage/{storage}/rrddata",
21007 "text" : "rrddata"
56122987
DM
21008 },
21009 {
56122987
DM
21010 "info" : {
21011 "POST" : {
7aacca6f 21012 "description" : "Upload templates and ISO images.",
44660702
DM
21013 "method" : "POST",
21014 "name" : "upload",
56122987 21015 "parameters" : {
7aacca6f 21016 "additionalProperties" : 0,
56122987 21017 "properties" : {
56122987 21018 "content" : {
7aacca6f 21019 "description" : "Content type.",
44660702 21020 "format" : "pve-storage-content",
013dc89f
DM
21021 "type" : "string",
21022 "typetext" : "<string>"
56122987
DM
21023 },
21024 "filename" : {
44660702 21025 "description" : "The name of the file to create.",
013dc89f
DM
21026 "type" : "string",
21027 "typetext" : "<string>"
56122987
DM
21028 },
21029 "node" : {
21030 "description" : "The cluster node name.",
44660702 21031 "format" : "pve-node",
013dc89f
DM
21032 "type" : "string",
21033 "typetext" : "<string>"
44660702
DM
21034 },
21035 "storage" : {
21036 "description" : "The storage identifier.",
21037 "format" : "pve-storage-id",
013dc89f
DM
21038 "type" : "string",
21039 "typetext" : "<string>"
44660702
DM
21040 },
21041 "tmpfilename" : {
21042 "description" : "The source file name. This parameter is usually set by the REST handler. You can only overwrite it when connecting to the trustet port on localhost.",
21043 "optional" : 1,
013dc89f
DM
21044 "type" : "string",
21045 "typetext" : "<string>"
56122987 21046 }
7aacca6f 21047 }
56122987 21048 },
56122987
DM
21049 "permissions" : {
21050 "check" : [
21051 "perm",
21052 "/storage/{storage}",
21053 [
21054 "Datastore.AllocateTemplate"
21055 ]
21056 ]
44660702
DM
21057 },
21058 "protected" : 1,
21059 "returns" : {
21060 "type" : "string"
21061 }
21062 }
21063 },
21064 "leaf" : 1,
21065 "path" : "/nodes/{node}/storage/{storage}/upload",
21066 "text" : "upload"
21067 }
21068 ],
21069 "info" : {
21070 "GET" : {
21071 "description" : "",
21072 "method" : "GET",
21073 "name" : "diridx",
21074 "parameters" : {
21075 "additionalProperties" : 0,
21076 "properties" : {
21077 "node" : {
21078 "description" : "The cluster node name.",
21079 "format" : "pve-node",
013dc89f
DM
21080 "type" : "string",
21081 "typetext" : "<string>"
44660702
DM
21082 },
21083 "storage" : {
21084 "description" : "The storage identifier.",
21085 "format" : "pve-storage-id",
013dc89f
DM
21086 "type" : "string",
21087 "typetext" : "<string>"
56122987
DM
21088 }
21089 }
44660702
DM
21090 },
21091 "permissions" : {
21092 "check" : [
21093 "perm",
21094 "/storage/{storage}",
21095 [
21096 "Datastore.Audit",
21097 "Datastore.AllocateSpace"
21098 ],
21099 "any",
21100 1
21101 ]
21102 },
21103 "returns" : {
21104 "items" : {
21105 "properties" : {
21106 "subdir" : {
21107 "type" : "string"
21108 }
21109 },
21110 "type" : "object"
21111 },
21112 "links" : [
21113 {
21114 "href" : "{subdir}",
21115 "rel" : "child"
21116 }
21117 ],
21118 "type" : "array"
56122987
DM
21119 }
21120 }
44660702
DM
21121 },
21122 "leaf" : 0,
21123 "path" : "/nodes/{node}/storage/{storage}",
21124 "text" : "{storage}"
56122987
DM
21125 }
21126 ],
56122987
DM
21127 "info" : {
21128 "GET" : {
44660702
DM
21129 "description" : "Get status for all datastores.",
21130 "method" : "GET",
21131 "name" : "index",
21132 "parameters" : {
21133 "additionalProperties" : 0,
21134 "properties" : {
21135 "content" : {
21136 "description" : "Only list stores which support this content type.",
21137 "format" : "pve-storage-content-list",
21138 "optional" : 1,
013dc89f
DM
21139 "type" : "string",
21140 "typetext" : "<string>"
44660702
DM
21141 },
21142 "enabled" : {
21143 "default" : 0,
21144 "description" : "Only list stores which are enabled (not disabled in config).",
21145 "optional" : 1,
013dc89f
DM
21146 "type" : "boolean",
21147 "typetext" : "<boolean>"
44660702
DM
21148 },
21149 "node" : {
21150 "description" : "The cluster node name.",
21151 "format" : "pve-node",
013dc89f
DM
21152 "type" : "string",
21153 "typetext" : "<string>"
44660702
DM
21154 },
21155 "storage" : {
21156 "description" : "Only list status for specified storage",
21157 "format" : "pve-storage-id",
21158 "optional" : 1,
013dc89f
DM
21159 "type" : "string",
21160 "typetext" : "<string>"
44660702
DM
21161 },
21162 "target" : {
21163 "description" : "If target is different to 'node', we only lists shared storages which content is accessible on this 'node' and the specified 'target' node.",
21164 "format" : "pve-node",
21165 "optional" : 1,
013dc89f
DM
21166 "type" : "string",
21167 "typetext" : "<string>"
44660702
DM
21168 }
21169 }
21170 },
7aacca6f
DM
21171 "permissions" : {
21172 "description" : "Only list entries where you have 'Datastore.Audit' or 'Datastore.AllocateSpace' permissions on '/storage/<storage>'",
21173 "user" : "all"
21174 },
44660702 21175 "protected" : 1,
7aacca6f 21176 "proxyto" : "node",
56122987
DM
21177 "returns" : {
21178 "items" : {
56122987
DM
21179 "properties" : {
21180 "storage" : {
21181 "type" : "string"
21182 }
44660702
DM
21183 },
21184 "type" : "object"
56122987 21185 },
56122987
DM
21186 "links" : [
21187 {
7aacca6f
DM
21188 "href" : "{storage}",
21189 "rel" : "child"
56122987 21190 }
44660702
DM
21191 ],
21192 "type" : "array"
21193 }
56122987 21194 }
44660702
DM
21195 },
21196 "leaf" : 0,
21197 "path" : "/nodes/{node}/storage",
21198 "text" : "storage"
56122987 21199 },
2c0dde61
DM
21200 {
21201 "children" : [
21202 {
21203 "info" : {
21204 "GET" : {
21205 "description" : "List local disks.",
21206 "method" : "GET",
21207 "name" : "list",
21208 "parameters" : {
21209 "additionalProperties" : 0,
21210 "properties" : {
21211 "node" : {
21212 "description" : "The cluster node name.",
21213 "format" : "pve-node",
013dc89f
DM
21214 "type" : "string",
21215 "typetext" : "<string>"
2c0dde61
DM
21216 }
21217 }
21218 },
21219 "permissions" : {
21220 "check" : [
21221 "perm",
21222 "/",
21223 [
21224 "Sys.Audit",
21225 "Datastore.Audit"
21226 ],
21227 "any",
21228 1
21229 ]
21230 },
21231 "protected" : 1,
21232 "proxyto" : "node",
21233 "returns" : {
21234 "items" : {
21235 "properties" : {
21236 "devpath" : {
21237 "description" : "The device path",
21238 "type" : "string"
21239 },
21240 "gpt" : {
21241 "type" : "boolean"
21242 },
21243 "health" : {
21244 "optional" : 1,
21245 "type" : "string"
21246 },
21247 "model" : {
21248 "optional" : 1,
21249 "type" : "string"
21250 },
21251 "osdid" : {
21252 "type" : "integer"
21253 },
21254 "serial" : {
21255 "optional" : 1,
21256 "type" : "string"
21257 },
21258 "size" : {
21259 "type" : "integer"
21260 },
21261 "used" : {
21262 "optional" : 1,
21263 "type" : "string"
21264 },
21265 "vendor" : {
21266 "optional" : 1,
21267 "type" : "string"
21268 },
21269 "wwn" : {
21270 "optional" : 1,
21271 "type" : "string"
21272 }
21273 },
21274 "type" : "object"
21275 },
21276 "type" : "array"
21277 }
21278 }
21279 },
21280 "leaf" : 1,
21281 "path" : "/nodes/{node}/disks/list",
21282 "text" : "list"
21283 },
21284 {
21285 "info" : {
21286 "GET" : {
21287 "description" : "Get SMART Health of a disk.",
21288 "method" : "GET",
21289 "name" : "smart",
21290 "parameters" : {
21291 "additionalProperties" : 0,
21292 "properties" : {
21293 "disk" : {
21294 "description" : "Block device name",
21295 "pattern" : "^/dev/[a-zA-Z0-9\\/]+$",
21296 "type" : "string"
21297 },
21298 "healthonly" : {
21299 "description" : "If true returns only the health status",
21300 "optional" : 1,
013dc89f
DM
21301 "type" : "boolean",
21302 "typetext" : "<boolean>"
2c0dde61
DM
21303 },
21304 "node" : {
21305 "description" : "The cluster node name.",
21306 "format" : "pve-node",
013dc89f
DM
21307 "type" : "string",
21308 "typetext" : "<string>"
2c0dde61
DM
21309 }
21310 }
21311 },
21312 "permissions" : {
21313 "check" : [
21314 "perm",
21315 "/",
21316 [
21317 "Sys.Audit",
21318 "Datastore.Audit"
21319 ],
21320 "any",
21321 1
21322 ]
21323 },
21324 "protected" : 1,
21325 "proxyto" : "node",
21326 "returns" : {
de0983cb
DM
21327 "properties" : {
21328 "attributes" : {
21329 "optional" : 1,
21330 "type" : "array"
21331 },
21332 "health" : {
21333 "type" : "string"
21334 },
21335 "text" : {
21336 "optional" : 1,
21337 "type" : "string"
21338 },
21339 "type" : {
21340 "optional" : 1,
21341 "type" : "string"
21342 }
21343 },
2c0dde61
DM
21344 "type" : "object"
21345 }
21346 }
21347 },
21348 "leaf" : 1,
21349 "path" : "/nodes/{node}/disks/smart",
21350 "text" : "smart"
21351 },
21352 {
21353 "info" : {
21354 "POST" : {
21355 "description" : "Initialize Disk with GPT",
21356 "method" : "POST",
21357 "name" : "initgpt",
21358 "parameters" : {
21359 "additionalProperties" : 0,
21360 "properties" : {
21361 "disk" : {
21362 "description" : "Block device name",
21363 "pattern" : "^/dev/[a-zA-Z0-9\\/]+$",
21364 "type" : "string"
21365 },
21366 "node" : {
21367 "description" : "The cluster node name.",
21368 "format" : "pve-node",
013dc89f
DM
21369 "type" : "string",
21370 "typetext" : "<string>"
2c0dde61
DM
21371 },
21372 "uuid" : {
21373 "description" : "UUID for the GPT table",
21374 "maxLength" : 36,
21375 "optional" : 1,
21376 "pattern" : "[a-fA-F0-9\\-]+",
21377 "type" : "string"
21378 }
21379 }
21380 },
21381 "permissions" : {
21382 "check" : [
21383 "perm",
21384 "/",
21385 [
21386 "Sys.Modify"
21387 ]
21388 ]
21389 },
21390 "protected" : 1,
21391 "proxyto" : "node",
21392 "returns" : {
21393 "type" : "string"
21394 }
21395 }
21396 },
21397 "leaf" : 1,
21398 "path" : "/nodes/{node}/disks/initgpt",
21399 "text" : "initgpt"
21400 }
21401 ],
21402 "info" : {
21403 "GET" : {
21404 "description" : "Node index.",
21405 "method" : "GET",
21406 "name" : "index",
21407 "parameters" : {
21408 "additionalProperties" : 0,
21409 "properties" : {
21410 "node" : {
21411 "description" : "The cluster node name.",
21412 "format" : "pve-node",
013dc89f
DM
21413 "type" : "string",
21414 "typetext" : "<string>"
2c0dde61
DM
21415 }
21416 }
21417 },
21418 "permissions" : {
21419 "user" : "all"
21420 },
21421 "proxyto" : "node",
21422 "returns" : {
21423 "items" : {
21424 "properties" : {},
21425 "type" : "object"
21426 },
21427 "links" : [
21428 {
21429 "href" : "{name}",
21430 "rel" : "child"
21431 }
21432 ],
21433 "type" : "array"
21434 }
21435 }
21436 },
21437 "leaf" : 0,
21438 "path" : "/nodes/{node}/disks",
21439 "text" : "disks"
21440 },
56122987 21441 {
56122987
DM
21442 "children" : [
21443 {
21444 "info" : {
44660702
DM
21445 "GET" : {
21446 "description" : "List available updates.",
21447 "method" : "GET",
21448 "name" : "list_updates",
21449 "parameters" : {
21450 "additionalProperties" : 0,
21451 "properties" : {
21452 "node" : {
21453 "description" : "The cluster node name.",
21454 "format" : "pve-node",
013dc89f
DM
21455 "type" : "string",
21456 "typetext" : "<string>"
44660702
DM
21457 }
21458 }
7aacca6f
DM
21459 },
21460 "permissions" : {
21461 "check" : [
21462 "perm",
21463 "/nodes/{node}",
21464 [
21465 "Sys.Modify"
21466 ]
21467 ]
21468 },
44660702 21469 "protected" : 1,
56122987 21470 "proxyto" : "node",
44660702
DM
21471 "returns" : {
21472 "items" : {
21473 "properties" : {},
21474 "type" : "object"
21475 },
21476 "type" : "array"
21477 }
21478 },
21479 "POST" : {
21480 "description" : "This is used to resynchronize the package index files from their sources (apt-get update).",
7aacca6f
DM
21481 "method" : "POST",
21482 "name" : "update_database",
56122987
DM
21483 "parameters" : {
21484 "additionalProperties" : 0,
21485 "properties" : {
44660702
DM
21486 "node" : {
21487 "description" : "The cluster node name.",
21488 "format" : "pve-node",
013dc89f
DM
21489 "type" : "string",
21490 "typetext" : "<string>"
44660702 21491 },
56122987 21492 "notify" : {
56122987 21493 "default" : 0,
44660702
DM
21494 "description" : "Send notification mail about new packages (to email address specified for user 'root@pam').",
21495 "optional" : 1,
013dc89f
DM
21496 "type" : "boolean",
21497 "typetext" : "<boolean>"
56122987
DM
21498 },
21499 "quiet" : {
56122987 21500 "default" : 0,
44660702 21501 "description" : "Only produces output suitable for logging, omitting progress indicators.",
56122987 21502 "optional" : 1,
013dc89f
DM
21503 "type" : "boolean",
21504 "typetext" : "<boolean>"
56122987 21505 }
7aacca6f
DM
21506 }
21507 },
21508 "permissions" : {
21509 "check" : [
21510 "perm",
21511 "/nodes/{node}",
21512 [
21513 "Sys.Modify"
21514 ]
21515 ]
21516 },
44660702
DM
21517 "protected" : 1,
21518 "proxyto" : "node",
21519 "returns" : {
21520 "type" : "string"
21521 }
56122987
DM
21522 }
21523 },
7aacca6f 21524 "leaf" : 1,
44660702
DM
21525 "path" : "/nodes/{node}/apt/update",
21526 "text" : "update"
56122987
DM
21527 },
21528 {
56122987
DM
21529 "info" : {
21530 "GET" : {
44660702 21531 "description" : "Get package changelogs.",
56122987 21532 "method" : "GET",
7aacca6f 21533 "name" : "changelog",
56122987 21534 "parameters" : {
44660702 21535 "additionalProperties" : 0,
56122987
DM
21536 "properties" : {
21537 "name" : {
21538 "description" : "Package name.",
013dc89f
DM
21539 "type" : "string",
21540 "typetext" : "<string>"
56122987 21541 },
44660702
DM
21542 "node" : {
21543 "description" : "The cluster node name.",
21544 "format" : "pve-node",
013dc89f
DM
21545 "type" : "string",
21546 "typetext" : "<string>"
44660702 21547 },
56122987 21548 "version" : {
7aacca6f 21549 "description" : "Package version.",
44660702 21550 "optional" : 1,
013dc89f
DM
21551 "type" : "string",
21552 "typetext" : "<string>"
56122987 21553 }
44660702 21554 }
56122987 21555 },
44660702
DM
21556 "permissions" : {
21557 "check" : [
21558 "perm",
21559 "/nodes/{node}",
21560 [
21561 "Sys.Modify"
21562 ]
21563 ]
21564 },
21565 "proxyto" : "node",
21566 "returns" : {
21567 "type" : "string"
21568 }
56122987
DM
21569 }
21570 },
44660702
DM
21571 "leaf" : 1,
21572 "path" : "/nodes/{node}/apt/changelog",
7aacca6f 21573 "text" : "changelog"
56122987
DM
21574 },
21575 {
56122987
DM
21576 "info" : {
21577 "GET" : {
44660702
DM
21578 "description" : "Get package information for important Proxmox packages.",
21579 "method" : "GET",
7aacca6f
DM
21580 "name" : "versions",
21581 "parameters" : {
44660702 21582 "additionalProperties" : 0,
7aacca6f
DM
21583 "properties" : {
21584 "node" : {
44660702 21585 "description" : "The cluster node name.",
7aacca6f 21586 "format" : "pve-node",
013dc89f
DM
21587 "type" : "string",
21588 "typetext" : "<string>"
7aacca6f 21589 }
44660702 21590 }
7aacca6f 21591 },
56122987
DM
21592 "permissions" : {
21593 "check" : [
21594 "perm",
21595 "/nodes/{node}",
21596 [
21597 "Sys.Audit"
21598 ]
21599 ]
21600 },
7aacca6f 21601 "proxyto" : "node",
56122987
DM
21602 "returns" : {
21603 "items" : {
7aacca6f
DM
21604 "properties" : {},
21605 "type" : "object"
44660702
DM
21606 },
21607 "type" : "array"
56122987
DM
21608 }
21609 }
21610 },
44660702 21611 "leaf" : 1,
7aacca6f 21612 "path" : "/nodes/{node}/apt/versions",
44660702 21613 "text" : "versions"
56122987
DM
21614 }
21615 ],
56122987
DM
21616 "info" : {
21617 "GET" : {
44660702 21618 "description" : "Directory index for apt (Advanced Package Tool).",
7aacca6f 21619 "method" : "GET",
44660702 21620 "name" : "index",
7aacca6f
DM
21621 "parameters" : {
21622 "additionalProperties" : 0,
21623 "properties" : {
21624 "node" : {
44660702 21625 "description" : "The cluster node name.",
7aacca6f 21626 "format" : "pve-node",
013dc89f
DM
21627 "type" : "string",
21628 "typetext" : "<string>"
7aacca6f
DM
21629 }
21630 }
21631 },
7aacca6f
DM
21632 "permissions" : {
21633 "user" : "all"
21634 },
44660702
DM
21635 "returns" : {
21636 "items" : {
21637 "properties" : {
21638 "id" : {
21639 "type" : "string"
21640 }
21641 },
21642 "type" : "object"
21643 },
21644 "links" : [
21645 {
21646 "href" : "{id}",
21647 "rel" : "child"
21648 }
21649 ],
21650 "type" : "array"
21651 }
56122987 21652 }
7aacca6f 21653 },
44660702 21654 "leaf" : 0,
7aacca6f 21655 "path" : "/nodes/{node}/apt",
44660702 21656 "text" : "apt"
56122987
DM
21657 },
21658 {
56122987
DM
21659 "children" : [
21660 {
21661 "children" : [
21662 {
56122987
DM
21663 "info" : {
21664 "DELETE" : {
44660702 21665 "description" : "Delete rule.",
7aacca6f 21666 "method" : "DELETE",
44660702 21667 "name" : "delete_rule",
56122987
DM
21668 "parameters" : {
21669 "additionalProperties" : 0,
21670 "properties" : {
56122987
DM
21671 "digest" : {
21672 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702 21673 "maxLength" : 40,
56122987 21674 "optional" : 1,
013dc89f
DM
21675 "type" : "string",
21676 "typetext" : "<string>"
56122987 21677 },
44660702
DM
21678 "node" : {
21679 "description" : "The cluster node name.",
21680 "format" : "pve-node",
013dc89f
DM
21681 "type" : "string",
21682 "typetext" : "<string>"
44660702 21683 },
7aacca6f 21684 "pos" : {
7aacca6f 21685 "description" : "Update rule at position <pos>.",
44660702
DM
21686 "minimum" : 0,
21687 "optional" : 1,
4bd7df8b 21688 "type" : "integer",
013dc89f 21689 "typetext" : "<integer> (0 - N)"
56122987
DM
21690 }
21691 }
21692 },
44660702
DM
21693 "permissions" : {
21694 "check" : [
21695 "perm",
21696 "/nodes/{node}",
21697 [
21698 "Sys.Modify"
21699 ]
21700 ]
21701 },
21702 "protected" : 1,
21703 "proxyto" : "node",
56122987
DM
21704 "returns" : {
21705 "type" : "null"
44660702
DM
21706 }
21707 },
21708 "GET" : {
21709 "description" : "Get single rule data.",
21710 "method" : "GET",
21711 "name" : "get_rule",
21712 "parameters" : {
21713 "additionalProperties" : 0,
21714 "properties" : {
21715 "node" : {
21716 "description" : "The cluster node name.",
21717 "format" : "pve-node",
013dc89f
DM
21718 "type" : "string",
21719 "typetext" : "<string>"
44660702
DM
21720 },
21721 "pos" : {
21722 "description" : "Update rule at position <pos>.",
21723 "minimum" : 0,
21724 "optional" : 1,
4bd7df8b 21725 "type" : "integer",
013dc89f 21726 "typetext" : "<integer> (0 - N)"
44660702
DM
21727 }
21728 }
56122987 21729 },
56122987
DM
21730 "permissions" : {
21731 "check" : [
21732 "perm",
21733 "/nodes/{node}",
21734 [
44660702 21735 "Sys.Audit"
56122987
DM
21736 ]
21737 ]
44660702
DM
21738 },
21739 "proxyto" : "node",
21740 "returns" : {
21741 "properties" : {
21742 "pos" : {
21743 "type" : "integer"
21744 }
21745 },
21746 "type" : "object"
7aacca6f 21747 }
56122987
DM
21748 },
21749 "PUT" : {
44660702
DM
21750 "description" : "Modify rule data.",
21751 "method" : "PUT",
56122987 21752 "name" : "update_rule",
56122987 21753 "parameters" : {
44660702 21754 "additionalProperties" : 0,
56122987 21755 "properties" : {
44660702
DM
21756 "action" : {
21757 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
21758 "maxLength" : 20,
21759 "minLength" : 2,
56122987 21760 "optional" : 1,
44660702
DM
21761 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
21762 "type" : "string"
56122987 21763 },
7aacca6f 21764 "comment" : {
e94f0d56 21765 "description" : "Descriptive comment.",
56122987 21766 "optional" : 1,
013dc89f
DM
21767 "type" : "string",
21768 "typetext" : "<string>"
56122987 21769 },
44660702
DM
21770 "delete" : {
21771 "description" : "A list of settings you want to delete.",
21772 "format" : "pve-configid-list",
56122987 21773 "optional" : 1,
013dc89f
DM
21774 "type" : "string",
21775 "typetext" : "<string>"
56122987 21776 },
44660702
DM
21777 "dest" : {
21778 "description" : "Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
21779 "format" : "pve-fw-addr-spec",
56122987 21780 "optional" : 1,
013dc89f
DM
21781 "type" : "string",
21782 "typetext" : "<string>"
56122987 21783 },
44660702
DM
21784 "digest" : {
21785 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
21786 "maxLength" : 40,
56122987 21787 "optional" : 1,
013dc89f
DM
21788 "type" : "string",
21789 "typetext" : "<string>"
56122987 21790 },
7aacca6f 21791 "dport" : {
7aacca6f 21792 "description" : "Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
44660702
DM
21793 "format" : "pve-fw-dport-spec",
21794 "optional" : 1,
013dc89f
DM
21795 "type" : "string",
21796 "typetext" : "<string>"
7aacca6f 21797 },
44660702 21798 "enable" : {
e94f0d56 21799 "description" : "Flag to enable/disable a rule.",
44660702 21800 "minimum" : 0,
56122987 21801 "optional" : 1,
4bd7df8b 21802 "type" : "integer",
013dc89f 21803 "typetext" : "<integer> (0 - N)"
56122987 21804 },
7aacca6f 21805 "iface" : {
44660702 21806 "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.",
7aacca6f 21807 "format" : "pve-iface",
44660702 21808 "maxLength" : 20,
56122987 21809 "minLength" : 2,
44660702 21810 "optional" : 1,
013dc89f
DM
21811 "type" : "string",
21812 "typetext" : "<string>"
56122987 21813 },
44660702 21814 "macro" : {
e94f0d56 21815 "description" : "Use predefined standard macro.",
44660702
DM
21816 "maxLength" : 128,
21817 "optional" : 1,
013dc89f
DM
21818 "type" : "string",
21819 "typetext" : "<string>"
44660702
DM
21820 },
21821 "moveto" : {
21822 "description" : "Move rule to new position <moveto>. Other arguments are ignored.",
21823 "minimum" : 0,
7aacca6f 21824 "optional" : 1,
4bd7df8b 21825 "type" : "integer",
013dc89f 21826 "typetext" : "<integer> (0 - N)"
44660702
DM
21827 },
21828 "node" : {
21829 "description" : "The cluster node name.",
21830 "format" : "pve-node",
013dc89f
DM
21831 "type" : "string",
21832 "typetext" : "<string>"
56122987
DM
21833 },
21834 "pos" : {
44660702 21835 "description" : "Update rule at position <pos>.",
7aacca6f 21836 "minimum" : 0,
7aacca6f 21837 "optional" : 1,
4bd7df8b 21838 "type" : "integer",
013dc89f 21839 "typetext" : "<integer> (0 - N)"
7aacca6f 21840 },
44660702
DM
21841 "proto" : {
21842 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
21843 "format" : "pve-fw-protocol-spec",
7aacca6f 21844 "optional" : 1,
013dc89f
DM
21845 "type" : "string",
21846 "typetext" : "<string>"
7aacca6f 21847 },
44660702
DM
21848 "source" : {
21849 "description" : "Restrict packet source address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
21850 "format" : "pve-fw-addr-spec",
56122987 21851 "optional" : 1,
013dc89f
DM
21852 "type" : "string",
21853 "typetext" : "<string>"
7aacca6f 21854 },
44660702
DM
21855 "sport" : {
21856 "description" : "Restrict TCP/UDP source port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
21857 "format" : "pve-fw-sport-spec",
21858 "optional" : 1,
013dc89f
DM
21859 "type" : "string",
21860 "typetext" : "<string>"
44660702
DM
21861 },
21862 "type" : {
e94f0d56 21863 "description" : "Rule type.",
44660702
DM
21864 "enum" : [
21865 "in",
21866 "out",
21867 "group"
21868 ],
21869 "optional" : 1,
21870 "type" : "string"
56122987 21871 }
44660702 21872 }
56122987 21873 },
56122987
DM
21874 "permissions" : {
21875 "check" : [
21876 "perm",
21877 "/nodes/{node}",
21878 [
21879 "Sys.Modify"
21880 ]
21881 ]
7aacca6f 21882 },
44660702 21883 "protected" : 1,
7aacca6f 21884 "proxyto" : "node",
7aacca6f
DM
21885 "returns" : {
21886 "type" : "null"
56122987
DM
21887 }
21888 }
7aacca6f 21889 },
44660702 21890 "leaf" : 1,
7aacca6f 21891 "path" : "/nodes/{node}/firewall/rules/{pos}",
44660702 21892 "text" : "{pos}"
56122987
DM
21893 }
21894 ],
56122987
DM
21895 "info" : {
21896 "GET" : {
44660702
DM
21897 "description" : "List rules.",
21898 "method" : "GET",
21899 "name" : "get_rules",
21900 "parameters" : {
21901 "additionalProperties" : 0,
21902 "properties" : {
21903 "node" : {
21904 "description" : "The cluster node name.",
21905 "format" : "pve-node",
013dc89f
DM
21906 "type" : "string",
21907 "typetext" : "<string>"
44660702
DM
21908 }
21909 }
21910 },
21911 "permissions" : {
21912 "check" : [
21913 "perm",
21914 "/nodes/{node}",
21915 [
21916 "Sys.Audit"
21917 ]
21918 ]
21919 },
21920 "proxyto" : "node",
56122987 21921 "returns" : {
56122987
DM
21922 "items" : {
21923 "properties" : {
21924 "pos" : {
21925 "type" : "integer"
21926 }
44660702
DM
21927 },
21928 "type" : "object"
56122987 21929 },
7aacca6f
DM
21930 "links" : [
21931 {
21932 "href" : "{pos}",
21933 "rel" : "child"
21934 }
21935 ],
21936 "type" : "array"
44660702 21937 }
56122987
DM
21938 },
21939 "POST" : {
44660702 21940 "description" : "Create new rule.",
7aacca6f
DM
21941 "method" : "POST",
21942 "name" : "create_rule",
56122987 21943 "parameters" : {
44660702 21944 "additionalProperties" : 0,
56122987 21945 "properties" : {
7aacca6f 21946 "action" : {
7aacca6f 21947 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
44660702 21948 "maxLength" : 20,
7aacca6f
DM
21949 "minLength" : 2,
21950 "optional" : 0,
44660702
DM
21951 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
21952 "type" : "string"
56122987 21953 },
44660702 21954 "comment" : {
e94f0d56 21955 "description" : "Descriptive comment.",
56122987 21956 "optional" : 1,
013dc89f
DM
21957 "type" : "string",
21958 "typetext" : "<string>"
56122987 21959 },
44660702
DM
21960 "dest" : {
21961 "description" : "Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
21962 "format" : "pve-fw-addr-spec",
7aacca6f 21963 "optional" : 1,
013dc89f
DM
21964 "type" : "string",
21965 "typetext" : "<string>"
56122987 21966 },
44660702
DM
21967 "digest" : {
21968 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
21969 "maxLength" : 40,
21970 "optional" : 1,
013dc89f
DM
21971 "type" : "string",
21972 "typetext" : "<string>"
56122987 21973 },
44660702
DM
21974 "dport" : {
21975 "description" : "Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
21976 "format" : "pve-fw-dport-spec",
7aacca6f 21977 "optional" : 1,
013dc89f
DM
21978 "type" : "string",
21979 "typetext" : "<string>"
56122987 21980 },
44660702 21981 "enable" : {
e94f0d56 21982 "description" : "Flag to enable/disable a rule.",
44660702
DM
21983 "minimum" : 0,
21984 "optional" : 1,
4bd7df8b 21985 "type" : "integer",
013dc89f 21986 "typetext" : "<integer> (0 - N)"
44660702 21987 },
7aacca6f 21988 "iface" : {
44660702 21989 "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.",
7aacca6f 21990 "format" : "pve-iface",
56122987 21991 "maxLength" : 20,
7aacca6f 21992 "minLength" : 2,
7aacca6f 21993 "optional" : 1,
013dc89f
DM
21994 "type" : "string",
21995 "typetext" : "<string>"
56122987 21996 },
44660702 21997 "macro" : {
e94f0d56 21998 "description" : "Use predefined standard macro.",
44660702 21999 "maxLength" : 128,
7aacca6f 22000 "optional" : 1,
013dc89f
DM
22001 "type" : "string",
22002 "typetext" : "<string>"
56122987 22003 },
44660702
DM
22004 "node" : {
22005 "description" : "The cluster node name.",
22006 "format" : "pve-node",
013dc89f
DM
22007 "type" : "string",
22008 "typetext" : "<string>"
44660702
DM
22009 },
22010 "pos" : {
22011 "description" : "Update rule at position <pos>.",
22012 "minimum" : 0,
22013 "optional" : 1,
4bd7df8b 22014 "type" : "integer",
013dc89f 22015 "typetext" : "<integer> (0 - N)"
44660702
DM
22016 },
22017 "proto" : {
22018 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
22019 "format" : "pve-fw-protocol-spec",
56122987 22020 "optional" : 1,
013dc89f
DM
22021 "type" : "string",
22022 "typetext" : "<string>"
56122987 22023 },
7aacca6f 22024 "source" : {
7aacca6f 22025 "description" : "Restrict packet source address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists.",
44660702
DM
22026 "format" : "pve-fw-addr-spec",
22027 "optional" : 1,
013dc89f
DM
22028 "type" : "string",
22029 "typetext" : "<string>"
7aacca6f 22030 },
44660702
DM
22031 "sport" : {
22032 "description" : "Restrict TCP/UDP source port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\\d+:\\d+', for example '80:85', and you can use comma separated list to match several ports or ranges.",
22033 "format" : "pve-fw-sport-spec",
7aacca6f 22034 "optional" : 1,
013dc89f
DM
22035 "type" : "string",
22036 "typetext" : "<string>"
44660702
DM
22037 },
22038 "type" : {
e94f0d56 22039 "description" : "Rule type.",
44660702
DM
22040 "enum" : [
22041 "in",
22042 "out",
22043 "group"
22044 ],
22045 "optional" : 0,
22046 "type" : "string"
56122987 22047 }
44660702 22048 }
7aacca6f 22049 },
56122987
DM
22050 "permissions" : {
22051 "check" : [
22052 "perm",
22053 "/nodes/{node}",
22054 [
22055 "Sys.Modify"
22056 ]
22057 ]
22058 },
44660702
DM
22059 "protected" : 1,
22060 "proxyto" : "node",
22061 "returns" : {
22062 "type" : "null"
22063 }
56122987
DM
22064 }
22065 },
44660702 22066 "leaf" : 0,
7aacca6f 22067 "path" : "/nodes/{node}/firewall/rules",
44660702 22068 "text" : "rules"
56122987
DM
22069 },
22070 {
56122987 22071 "info" : {
44660702
DM
22072 "GET" : {
22073 "description" : "Get host firewall options.",
22074 "method" : "GET",
22075 "name" : "get_options",
56122987 22076 "parameters" : {
7aacca6f 22077 "additionalProperties" : 0,
56122987 22078 "properties" : {
44660702
DM
22079 "node" : {
22080 "description" : "The cluster node name.",
22081 "format" : "pve-node",
013dc89f
DM
22082 "type" : "string",
22083 "typetext" : "<string>"
44660702
DM
22084 }
22085 }
22086 },
22087 "permissions" : {
22088 "check" : [
22089 "perm",
22090 "/nodes/{node}",
22091 [
22092 "Sys.Audit"
22093 ]
22094 ]
22095 },
22096 "proxyto" : "node",
22097 "returns" : {
22098 "properties" : {
22099 "enable" : {
22100 "description" : "Enable host firewall rules.",
7aacca6f 22101 "optional" : 1,
44660702 22102 "type" : "boolean"
7aacca6f 22103 },
44660702
DM
22104 "log_level_in" : {
22105 "description" : "Log level for incoming traffic.",
56122987
DM
22106 "enum" : [
22107 "emerg",
22108 "alert",
22109 "crit",
22110 "err",
22111 "warning",
22112 "notice",
22113 "info",
22114 "debug",
22115 "nolog"
22116 ],
56122987 22117 "optional" : 1,
44660702
DM
22118 "type" : "string"
22119 },
22120 "log_level_out" : {
22121 "description" : "Log level for outgoing traffic.",
56122987
DM
22122 "enum" : [
22123 "emerg",
22124 "alert",
22125 "crit",
22126 "err",
22127 "warning",
22128 "notice",
22129 "info",
22130 "debug",
22131 "nolog"
22132 ],
44660702
DM
22133 "optional" : 1,
22134 "type" : "string"
22135 },
22136 "ndp" : {
22137 "description" : "Enable NDP.",
22138 "optional" : 1,
22139 "type" : "boolean"
22140 },
22141 "nf_conntrack_max" : {
22142 "description" : "Maximum number of tracked connections.",
22143 "minimum" : 32768,
22144 "optional" : 1,
22145 "type" : "integer"
22146 },
22147 "nf_conntrack_tcp_timeout_established" : {
22148 "description" : "Conntrack established timeout.",
22149 "minimum" : 7875,
22150 "optional" : 1,
22151 "type" : "integer"
22152 },
22153 "nosmurfs" : {
22154 "description" : "Enable SMURFS filter.",
22155 "optional" : 1,
22156 "type" : "boolean"
56122987 22157 },
7aacca6f 22158 "smurf_log_level" : {
44660702 22159 "description" : "Log level for SMURFS filter.",
56122987
DM
22160 "enum" : [
22161 "emerg",
22162 "alert",
22163 "crit",
22164 "err",
22165 "warning",
22166 "notice",
22167 "info",
22168 "debug",
22169 "nolog"
7aacca6f 22170 ],
7aacca6f
DM
22171 "optional" : 1,
22172 "type" : "string"
56122987 22173 },
44660702
DM
22174 "tcp_flags_log_level" : {
22175 "description" : "Log level for illegal tcp flags filter.",
56122987
DM
22176 "enum" : [
22177 "emerg",
22178 "alert",
22179 "crit",
22180 "err",
22181 "warning",
22182 "notice",
22183 "info",
22184 "debug",
22185 "nolog"
22186 ],
44660702
DM
22187 "optional" : 1,
22188 "type" : "string"
7aacca6f 22189 },
44660702
DM
22190 "tcpflags" : {
22191 "description" : "Filter illegal combinations of TCP flags.",
56122987 22192 "optional" : 1,
44660702 22193 "type" : "boolean"
56122987 22194 }
44660702
DM
22195 },
22196 "type" : "object"
7aacca6f 22197 }
56122987 22198 },
44660702
DM
22199 "PUT" : {
22200 "description" : "Set Firewall options.",
22201 "method" : "PUT",
22202 "name" : "set_options",
7aacca6f 22203 "parameters" : {
44660702 22204 "additionalProperties" : 0,
7aacca6f 22205 "properties" : {
44660702
DM
22206 "delete" : {
22207 "description" : "A list of settings you want to delete.",
22208 "format" : "pve-configid-list",
7aacca6f 22209 "optional" : 1,
013dc89f
DM
22210 "type" : "string",
22211 "typetext" : "<string>"
56122987 22212 },
44660702
DM
22213 "digest" : {
22214 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
22215 "maxLength" : 40,
22216 "optional" : 1,
013dc89f
DM
22217 "type" : "string",
22218 "typetext" : "<string>"
56122987 22219 },
44660702
DM
22220 "enable" : {
22221 "description" : "Enable host firewall rules.",
7aacca6f 22222 "optional" : 1,
013dc89f
DM
22223 "type" : "boolean",
22224 "typetext" : "<boolean>"
44660702
DM
22225 },
22226 "log_level_in" : {
22227 "description" : "Log level for incoming traffic.",
56122987
DM
22228 "enum" : [
22229 "emerg",
22230 "alert",
22231 "crit",
22232 "err",
22233 "warning",
22234 "notice",
22235 "info",
22236 "debug",
22237 "nolog"
44660702 22238 ],
7aacca6f 22239 "optional" : 1,
44660702 22240 "type" : "string"
7aacca6f 22241 },
44660702
DM
22242 "log_level_out" : {
22243 "description" : "Log level for outgoing traffic.",
56122987
DM
22244 "enum" : [
22245 "emerg",
22246 "alert",
22247 "crit",
22248 "err",
22249 "warning",
22250 "notice",
22251 "info",
22252 "debug",
22253 "nolog"
22254 ],
22255 "optional" : 1,
7aacca6f 22256 "type" : "string"
56122987 22257 },
44660702
DM
22258 "ndp" : {
22259 "description" : "Enable NDP.",
7aacca6f 22260 "optional" : 1,
013dc89f
DM
22261 "type" : "boolean",
22262 "typetext" : "<boolean>"
44660702
DM
22263 },
22264 "nf_conntrack_max" : {
22265 "description" : "Maximum number of tracked connections.",
22266 "minimum" : 32768,
22267 "optional" : 1,
4bd7df8b 22268 "type" : "integer",
013dc89f 22269 "typetext" : "<integer> (32768 - N)"
44660702
DM
22270 },
22271 "nf_conntrack_tcp_timeout_established" : {
22272 "description" : "Conntrack established timeout.",
22273 "minimum" : 7875,
22274 "optional" : 1,
4bd7df8b 22275 "type" : "integer",
013dc89f 22276 "typetext" : "<integer> (7875 - N)"
44660702
DM
22277 },
22278 "node" : {
22279 "description" : "The cluster node name.",
22280 "format" : "pve-node",
013dc89f
DM
22281 "type" : "string",
22282 "typetext" : "<string>"
44660702
DM
22283 },
22284 "nosmurfs" : {
22285 "description" : "Enable SMURFS filter.",
22286 "optional" : 1,
013dc89f
DM
22287 "type" : "boolean",
22288 "typetext" : "<boolean>"
44660702
DM
22289 },
22290 "smurf_log_level" : {
22291 "description" : "Log level for SMURFS filter.",
56122987
DM
22292 "enum" : [
22293 "emerg",
22294 "alert",
22295 "crit",
22296 "err",
22297 "warning",
22298 "notice",
22299 "info",
22300 "debug",
22301 "nolog"
44660702
DM
22302 ],
22303 "optional" : 1,
22304 "type" : "string"
56122987 22305 },
44660702
DM
22306 "tcp_flags_log_level" : {
22307 "description" : "Log level for illegal tcp flags filter.",
56122987
DM
22308 "enum" : [
22309 "emerg",
22310 "alert",
22311 "crit",
22312 "err",
22313 "warning",
22314 "notice",
22315 "info",
22316 "debug",
22317 "nolog"
22318 ],
44660702
DM
22319 "optional" : 1,
22320 "type" : "string"
7aacca6f 22321 },
44660702
DM
22322 "tcpflags" : {
22323 "description" : "Filter illegal combinations of TCP flags.",
56122987 22324 "optional" : 1,
013dc89f
DM
22325 "type" : "boolean",
22326 "typetext" : "<boolean>"
56122987 22327 }
7aacca6f 22328 }
56122987 22329 },
44660702
DM
22330 "permissions" : {
22331 "check" : [
22332 "perm",
22333 "/nodes/{node}",
22334 [
22335 "Sys.Modify"
22336 ]
22337 ]
22338 },
22339 "protected" : 1,
22340 "proxyto" : "node",
22341 "returns" : {
22342 "type" : "null"
22343 }
7aacca6f
DM
22344 }
22345 },
44660702
DM
22346 "leaf" : 1,
22347 "path" : "/nodes/{node}/firewall/options",
7aacca6f
DM
22348 "text" : "options"
22349 },
22350 {
7aacca6f
DM
22351 "info" : {
22352 "GET" : {
44660702
DM
22353 "description" : "Read firewall log",
22354 "method" : "GET",
7aacca6f 22355 "name" : "log",
56122987 22356 "parameters" : {
44660702 22357 "additionalProperties" : 0,
56122987 22358 "properties" : {
7aacca6f 22359 "limit" : {
44660702 22360 "minimum" : 0,
7aacca6f 22361 "optional" : 1,
4bd7df8b 22362 "type" : "integer",
013dc89f 22363 "typetext" : "<integer> (0 - N)"
7aacca6f 22364 },
56122987 22365 "node" : {
7aacca6f 22366 "description" : "The cluster node name.",
44660702 22367 "format" : "pve-node",
013dc89f
DM
22368 "type" : "string",
22369 "typetext" : "<string>"
44660702
DM
22370 },
22371 "start" : {
22372 "minimum" : 0,
22373 "optional" : 1,
4bd7df8b 22374 "type" : "integer",
013dc89f 22375 "typetext" : "<integer> (0 - N)"
56122987 22376 }
44660702 22377 }
7aacca6f 22378 },
56122987
DM
22379 "permissions" : {
22380 "check" : [
22381 "perm",
22382 "/nodes/{node}",
22383 [
22384 "Sys.Syslog"
22385 ]
22386 ]
22387 },
44660702
DM
22388 "protected" : 1,
22389 "proxyto" : "node",
56122987
DM
22390 "returns" : {
22391 "items" : {
56122987 22392 "properties" : {
56122987 22393 "n" : {
44660702
DM
22394 "description" : "Line number",
22395 "type" : "integer"
7aacca6f
DM
22396 },
22397 "t" : {
44660702
DM
22398 "description" : "Line text",
22399 "type" : "string"
56122987 22400 }
44660702
DM
22401 },
22402 "type" : "object"
56122987
DM
22403 },
22404 "type" : "array"
7aacca6f 22405 }
56122987
DM
22406 }
22407 },
44660702
DM
22408 "leaf" : 1,
22409 "path" : "/nodes/{node}/firewall/log",
7aacca6f 22410 "text" : "log"
56122987
DM
22411 }
22412 ],
22413 "info" : {
22414 "GET" : {
44660702
DM
22415 "description" : "Directory index.",
22416 "method" : "GET",
22417 "name" : "index",
56122987 22418 "parameters" : {
44660702 22419 "additionalProperties" : 0,
56122987
DM
22420 "properties" : {
22421 "node" : {
22422 "description" : "The cluster node name.",
44660702 22423 "format" : "pve-node",
013dc89f
DM
22424 "type" : "string",
22425 "typetext" : "<string>"
56122987 22426 }
44660702 22427 }
56122987 22428 },
7aacca6f
DM
22429 "permissions" : {
22430 "user" : "all"
22431 },
56122987
DM
22432 "returns" : {
22433 "items" : {
22434 "properties" : {},
22435 "type" : "object"
22436 },
56122987
DM
22437 "links" : [
22438 {
44660702
DM
22439 "href" : "{name}",
22440 "rel" : "child"
56122987 22441 }
44660702
DM
22442 ],
22443 "type" : "array"
22444 }
56122987 22445 }
7aacca6f 22446 },
44660702 22447 "leaf" : 0,
7aacca6f 22448 "path" : "/nodes/{node}/firewall",
44660702 22449 "text" : "firewall"
56122987
DM
22450 },
22451 {
56122987
DM
22452 "info" : {
22453 "GET" : {
44660702
DM
22454 "description" : "API version details",
22455 "method" : "GET",
22456 "name" : "version",
56122987 22457 "parameters" : {
44660702 22458 "additionalProperties" : 0,
56122987
DM
22459 "properties" : {
22460 "node" : {
56122987 22461 "description" : "The cluster node name.",
44660702 22462 "format" : "pve-node",
013dc89f
DM
22463 "type" : "string",
22464 "typetext" : "<string>"
56122987 22465 }
44660702 22466 }
56122987 22467 },
56122987 22468 "permissions" : {
7aacca6f 22469 "user" : "all"
56122987 22470 },
56122987 22471 "proxyto" : "node",
56122987 22472 "returns" : {
56122987 22473 "properties" : {
44660702 22474 "release" : {
56122987
DM
22475 "type" : "string"
22476 },
44660702 22477 "repoid" : {
7aacca6f
DM
22478 "type" : "string"
22479 },
22480 "version" : {
22481 "type" : "string"
22482 }
44660702
DM
22483 },
22484 "type" : "object"
7aacca6f 22485 }
56122987
DM
22486 }
22487 },
56122987 22488 "leaf" : 1,
44660702
DM
22489 "path" : "/nodes/{node}/version",
22490 "text" : "version"
56122987
DM
22491 },
22492 {
56122987
DM
22493 "info" : {
22494 "GET" : {
7aacca6f 22495 "description" : "Read node status",
44660702 22496 "method" : "GET",
7aacca6f 22497 "name" : "status",
56122987 22498 "parameters" : {
44660702 22499 "additionalProperties" : 0,
56122987
DM
22500 "properties" : {
22501 "node" : {
7aacca6f 22502 "description" : "The cluster node name.",
44660702 22503 "format" : "pve-node",
013dc89f
DM
22504 "type" : "string",
22505 "typetext" : "<string>"
56122987 22506 }
44660702 22507 }
56122987 22508 },
56122987
DM
22509 "permissions" : {
22510 "check" : [
22511 "perm",
22512 "/nodes/{node}",
22513 [
22514 "Sys.Audit"
22515 ]
22516 ]
44660702
DM
22517 },
22518 "proxyto" : "node",
22519 "returns" : {
22520 "properties" : {},
22521 "type" : "object"
7aacca6f
DM
22522 }
22523 },
22524 "POST" : {
44660702
DM
22525 "description" : "Reboot or shutdown a node.",
22526 "method" : "POST",
7aacca6f 22527 "name" : "node_cmd",
56122987 22528 "parameters" : {
44660702 22529 "additionalProperties" : 0,
56122987 22530 "properties" : {
7aacca6f
DM
22531 "command" : {
22532 "description" : "Specify the command.",
56122987 22533 "enum" : [
7aacca6f
DM
22534 "reboot",
22535 "shutdown"
56122987
DM
22536 ],
22537 "type" : "string"
44660702
DM
22538 },
22539 "node" : {
22540 "description" : "The cluster node name.",
22541 "format" : "pve-node",
013dc89f
DM
22542 "type" : "string",
22543 "typetext" : "<string>"
56122987 22544 }
44660702 22545 }
7aacca6f 22546 },
7aacca6f
DM
22547 "permissions" : {
22548 "check" : [
22549 "perm",
22550 "/nodes/{node}",
22551 [
22552 "Sys.PowerMgmt"
22553 ]
22554 ]
22555 },
44660702 22556 "protected" : 1,
7aacca6f 22557 "proxyto" : "node",
7aacca6f
DM
22558 "returns" : {
22559 "type" : "null"
56122987
DM
22560 }
22561 }
22562 },
7aacca6f 22563 "leaf" : 1,
44660702
DM
22564 "path" : "/nodes/{node}/status",
22565 "text" : "status"
56122987
DM
22566 },
22567 {
56122987
DM
22568 "info" : {
22569 "GET" : {
44660702
DM
22570 "description" : "Read tap/vm network device interface counters",
22571 "method" : "GET",
22572 "name" : "netstat",
22573 "parameters" : {
22574 "additionalProperties" : 0,
22575 "properties" : {
22576 "node" : {
22577 "description" : "The cluster node name.",
22578 "format" : "pve-node",
013dc89f
DM
22579 "type" : "string",
22580 "typetext" : "<string>"
44660702 22581 }
56122987
DM
22582 }
22583 },
22584 "permissions" : {
22585 "check" : [
22586 "perm",
22587 "/nodes/{node}",
22588 [
7aacca6f 22589 "Sys.Audit"
56122987
DM
22590 ]
22591 ]
22592 },
7aacca6f 22593 "proxyto" : "node",
44660702
DM
22594 "returns" : {
22595 "items" : {
22596 "properties" : {},
22597 "type" : "object"
22598 },
22599 "type" : "array"
22600 }
7aacca6f
DM
22601 }
22602 },
44660702
DM
22603 "leaf" : 1,
22604 "path" : "/nodes/{node}/netstat",
7aacca6f
DM
22605 "text" : "netstat"
22606 },
22607 {
22608 "info" : {
22609 "POST" : {
7aacca6f 22610 "description" : "Execute multiple commands in order.",
7aacca6f 22611 "method" : "POST",
7aacca6f 22612 "name" : "execute",
56122987
DM
22613 "parameters" : {
22614 "additionalProperties" : 0,
22615 "properties" : {
7aacca6f
DM
22616 "commands" : {
22617 "description" : "JSON encoded array of commands.",
013dc89f
DM
22618 "type" : "string",
22619 "typetext" : "<string>"
56122987
DM
22620 },
22621 "node" : {
44660702 22622 "description" : "The cluster node name.",
56122987 22623 "format" : "pve-node",
013dc89f
DM
22624 "type" : "string",
22625 "typetext" : "<string>"
56122987
DM
22626 }
22627 }
44660702
DM
22628 },
22629 "permissions" : {
22630 "check" : [
22631 "perm",
22632 "/nodes/{node}",
22633 [
22634 "Sys.Audit"
22635 ]
22636 ]
22637 },
22638 "protected" : 1,
22639 "proxyto" : "node",
22640 "returns" : {
22641 "properties" : {},
22642 "type" : "array"
56122987
DM
22643 }
22644 }
22645 },
56122987 22646 "leaf" : 1,
44660702
DM
22647 "path" : "/nodes/{node}/execute",
22648 "text" : "execute"
56122987
DM
22649 },
22650 {
22651 "info" : {
7aacca6f 22652 "GET" : {
44660702
DM
22653 "description" : "Read node RRD statistics (returns PNG)",
22654 "method" : "GET",
7aacca6f 22655 "name" : "rrd",
56122987 22656 "parameters" : {
7aacca6f 22657 "additionalProperties" : 0,
56122987 22658 "properties" : {
44660702
DM
22659 "cf" : {
22660 "description" : "The RRD consolidation function",
22661 "enum" : [
22662 "AVERAGE",
22663 "MAX"
22664 ],
22665 "optional" : 1,
22666 "type" : "string"
22667 },
7aacca6f 22668 "ds" : {
7aacca6f 22669 "description" : "The list of datasources you want to display.",
44660702 22670 "format" : "pve-configid-list",
013dc89f
DM
22671 "type" : "string",
22672 "typetext" : "<string>"
44660702
DM
22673 },
22674 "node" : {
22675 "description" : "The cluster node name.",
22676 "format" : "pve-node",
013dc89f
DM
22677 "type" : "string",
22678 "typetext" : "<string>"
7aacca6f
DM
22679 },
22680 "timeframe" : {
22681 "description" : "Specify the time frame you are interested in.",
22682 "enum" : [
22683 "hour",
22684 "day",
22685 "week",
22686 "month",
22687 "year"
22688 ],
22689 "type" : "string"
56122987 22690 }
7aacca6f 22691 }
56122987 22692 },
56122987 22693 "permissions" : {
56122987
DM
22694 "check" : [
22695 "perm",
22696 "/nodes/{node}",
22697 [
7aacca6f 22698 "Sys.Audit"
56122987
DM
22699 ]
22700 ]
22701 },
7aacca6f 22702 "protected" : 1,
56122987 22703 "returns" : {
56122987 22704 "properties" : {
7aacca6f 22705 "filename" : {
56122987
DM
22706 "type" : "string"
22707 }
44660702
DM
22708 },
22709 "type" : "object"
22710 }
56122987
DM
22711 }
22712 },
44660702 22713 "leaf" : 1,
7aacca6f 22714 "path" : "/nodes/{node}/rrd",
44660702 22715 "text" : "rrd"
56122987
DM
22716 },
22717 {
22718 "info" : {
7aacca6f 22719 "GET" : {
44660702
DM
22720 "description" : "Read node RRD statistics",
22721 "method" : "GET",
7aacca6f 22722 "name" : "rrddata",
56122987 22723 "parameters" : {
44660702 22724 "additionalProperties" : 0,
56122987 22725 "properties" : {
7aacca6f 22726 "cf" : {
7aacca6f
DM
22727 "description" : "The RRD consolidation function",
22728 "enum" : [
22729 "AVERAGE",
22730 "MAX"
44660702
DM
22731 ],
22732 "optional" : 1,
22733 "type" : "string"
56122987
DM
22734 },
22735 "node" : {
44660702 22736 "description" : "The cluster node name.",
56122987 22737 "format" : "pve-node",
013dc89f
DM
22738 "type" : "string",
22739 "typetext" : "<string>"
56122987 22740 },
7aacca6f 22741 "timeframe" : {
7aacca6f
DM
22742 "description" : "Specify the time frame you are interested in.",
22743 "enum" : [
22744 "hour",
22745 "day",
22746 "week",
22747 "month",
22748 "year"
44660702
DM
22749 ],
22750 "type" : "string"
56122987 22751 }
56122987
DM
22752 }
22753 },
56122987
DM
22754 "permissions" : {
22755 "check" : [
22756 "perm",
22757 "/nodes/{node}",
22758 [
44660702 22759 "Sys.Audit"
56122987
DM
22760 ]
22761 ]
7aacca6f 22762 },
44660702 22763 "protected" : 1,
56122987 22764 "returns" : {
7aacca6f 22765 "items" : {
44660702 22766 "properties" : {},
7aacca6f
DM
22767 "type" : "object"
22768 },
22769 "type" : "array"
44660702
DM
22770 }
22771 }
22772 },
22773 "leaf" : 1,
22774 "path" : "/nodes/{node}/rrddata",
22775 "text" : "rrddata"
22776 },
22777 {
22778 "info" : {
22779 "GET" : {
22780 "description" : "Read system log",
22781 "method" : "GET",
22782 "name" : "syslog",
56122987 22783 "parameters" : {
44660702 22784 "additionalProperties" : 0,
56122987 22785 "properties" : {
44660702
DM
22786 "limit" : {
22787 "minimum" : 0,
7aacca6f 22788 "optional" : 1,
4bd7df8b 22789 "type" : "integer",
013dc89f 22790 "typetext" : "<integer> (0 - N)"
7aacca6f 22791 },
56122987 22792 "node" : {
7aacca6f 22793 "description" : "The cluster node name.",
44660702 22794 "format" : "pve-node",
013dc89f
DM
22795 "type" : "string",
22796 "typetext" : "<string>"
56122987 22797 },
44660702
DM
22798 "since" : {
22799 "description" : "Display all log since this date-time string.",
22800 "optional" : 1,
22801 "pattern" : "^\\d{4}-\\d{2}-\\d{2}( \\d{2}:\\d{2}(:\\d{2})?)?$",
22802 "type" : "string"
22803 },
22804 "start" : {
7aacca6f
DM
22805 "minimum" : 0,
22806 "optional" : 1,
4bd7df8b 22807 "type" : "integer",
013dc89f 22808 "typetext" : "<integer> (0 - N)"
7aacca6f
DM
22809 },
22810 "until" : {
22811 "description" : "Display all log until this date-time string.",
7aacca6f 22812 "optional" : 1,
44660702 22813 "pattern" : "^\\d{4}-\\d{2}-\\d{2}( \\d{2}:\\d{2}(:\\d{2})?)?$",
56122987
DM
22814 "type" : "string"
22815 }
44660702 22816 }
56122987 22817 },
44660702
DM
22818 "permissions" : {
22819 "check" : [
22820 "perm",
22821 "/nodes/{node}",
22822 [
22823 "Sys.Syslog"
22824 ]
22825 ]
22826 },
22827 "protected" : 1,
22828 "proxyto" : "node",
22829 "returns" : {
22830 "items" : {
22831 "properties" : {
22832 "n" : {
22833 "description" : "Line number",
22834 "type" : "integer"
22835 },
22836 "t" : {
22837 "description" : "Line text",
22838 "type" : "string"
22839 }
22840 },
22841 "type" : "object"
22842 },
22843 "type" : "array"
22844 }
56122987
DM
22845 }
22846 },
44660702
DM
22847 "leaf" : 1,
22848 "path" : "/nodes/{node}/syslog",
7aacca6f 22849 "text" : "syslog"
56122987
DM
22850 },
22851 {
56122987
DM
22852 "info" : {
22853 "POST" : {
44660702
DM
22854 "description" : "Creates a VNC Shell proxy.",
22855 "method" : "POST",
22856 "name" : "vncshell",
22857 "parameters" : {
22858 "additionalProperties" : 0,
56122987 22859 "properties" : {
44660702
DM
22860 "node" : {
22861 "description" : "The cluster node name.",
22862 "format" : "pve-node",
013dc89f
DM
22863 "type" : "string",
22864 "typetext" : "<string>"
7aacca6f 22865 },
44660702
DM
22866 "upgrade" : {
22867 "default" : 0,
22868 "description" : "Run 'apt-get dist-upgrade' instead of normal shell.",
22869 "optional" : 1,
013dc89f
DM
22870 "type" : "boolean",
22871 "typetext" : "<boolean>"
7aacca6f 22872 },
44660702
DM
22873 "websocket" : {
22874 "description" : "use websocket instead of standard vnc.",
22875 "optional" : 1,
013dc89f
DM
22876 "type" : "boolean",
22877 "typetext" : "<boolean>"
56122987 22878 }
44660702 22879 }
56122987 22880 },
56122987
DM
22881 "permissions" : {
22882 "check" : [
22883 "perm",
7aacca6f 22884 "/nodes/{node}",
56122987 22885 [
7aacca6f 22886 "Sys.Console"
56122987 22887 ]
44660702
DM
22888 ],
22889 "description" : "Restricted to users on realm 'pam'"
56122987 22890 },
44660702
DM
22891 "protected" : 1,
22892 "returns" : {
22893 "additionalProperties" : 0,
56122987 22894 "properties" : {
44660702
DM
22895 "cert" : {
22896 "type" : "string"
7aacca6f 22897 },
44660702
DM
22898 "port" : {
22899 "type" : "integer"
7aacca6f 22900 },
44660702
DM
22901 "ticket" : {
22902 "type" : "string"
22903 },
22904 "upid" : {
22905 "type" : "string"
22906 },
22907 "user" : {
22908 "type" : "string"
56122987 22909 }
44660702
DM
22910 }
22911 }
56122987
DM
22912 }
22913 },
7aacca6f 22914 "leaf" : 1,
44660702
DM
22915 "path" : "/nodes/{node}/vncshell",
22916 "text" : "vncshell"
56122987
DM
22917 },
22918 {
22919 "info" : {
22920 "GET" : {
7aacca6f 22921 "description" : "Opens a weksocket for VNC traffic.",
44660702
DM
22922 "method" : "GET",
22923 "name" : "vncwebsocket",
56122987 22924 "parameters" : {
44660702 22925 "additionalProperties" : 0,
56122987
DM
22926 "properties" : {
22927 "node" : {
22928 "description" : "The cluster node name.",
44660702 22929 "format" : "pve-node",
013dc89f
DM
22930 "type" : "string",
22931 "typetext" : "<string>"
7aacca6f
DM
22932 },
22933 "port" : {
7aacca6f
DM
22934 "description" : "Port number returned by previous vncproxy call.",
22935 "maximum" : 5999,
44660702 22936 "minimum" : 5900,
4bd7df8b 22937 "type" : "integer",
013dc89f 22938 "typetext" : "<integer> (5900 - 5999)"
44660702
DM
22939 },
22940 "vncticket" : {
22941 "description" : "Ticket from previous call to vncproxy.",
22942 "maxLength" : 512,
013dc89f
DM
22943 "type" : "string",
22944 "typetext" : "<string>"
56122987 22945 }
44660702 22946 }
56122987 22947 },
56122987
DM
22948 "permissions" : {
22949 "check" : [
22950 "perm",
22951 "/nodes/{node}",
22952 [
7aacca6f 22953 "Sys.Console"
56122987 22954 ]
44660702
DM
22955 ],
22956 "description" : "Restricted to users on realm 'pam'. You also need to pass a valid ticket (vncticket)."
22957 },
22958 "returns" : {
22959 "properties" : {
22960 "port" : {
22961 "type" : "string"
22962 }
22963 },
22964 "type" : "object"
7aacca6f 22965 }
56122987
DM
22966 }
22967 },
44660702 22968 "leaf" : 1,
7aacca6f 22969 "path" : "/nodes/{node}/vncwebsocket",
44660702 22970 "text" : "vncwebsocket"
56122987
DM
22971 },
22972 {
22973 "info" : {
22974 "POST" : {
44660702 22975 "description" : "Creates a SPICE shell.",
7aacca6f 22976 "method" : "POST",
44660702 22977 "name" : "spiceshell",
56122987 22978 "parameters" : {
7aacca6f 22979 "additionalProperties" : 0,
56122987 22980 "properties" : {
7aacca6f 22981 "node" : {
44660702 22982 "description" : "The cluster node name.",
56122987 22983 "format" : "pve-node",
013dc89f
DM
22984 "type" : "string",
22985 "typetext" : "<string>"
7aacca6f 22986 },
44660702
DM
22987 "proxy" : {
22988 "description" : "SPICE proxy server. This can be used by the client to specify the proxy server. All nodes in a cluster runs 'spiceproxy', so it is up to the client to choose one. By default, we return the node where the VM is currently running. As resonable setting is to use same node you use to connect to the API (This is window.location.hostname for the JS GUI).",
22989 "format" : "address",
22990 "optional" : 1,
013dc89f
DM
22991 "type" : "string",
22992 "typetext" : "<string>"
7aacca6f 22993 },
44660702
DM
22994 "upgrade" : {
22995 "default" : 0,
22996 "description" : "Run 'apt-get dist-upgrade' instead of normal shell.",
22997 "optional" : 1,
013dc89f
DM
22998 "type" : "boolean",
22999 "typetext" : "<boolean>"
56122987 23000 }
7aacca6f 23001 }
56122987 23002 },
56122987
DM
23003 "permissions" : {
23004 "check" : [
23005 "perm",
7aacca6f 23006 "/nodes/{node}",
56122987 23007 [
7aacca6f 23008 "Sys.Console"
56122987 23009 ]
7aacca6f
DM
23010 ],
23011 "description" : "Restricted to users on realm 'pam'"
44660702
DM
23012 },
23013 "protected" : 1,
23014 "proxyto" : "node",
23015 "returns" : {
23016 "additionalProperties" : 1,
23017 "description" : "Returned values can be directly passed to the 'remote-viewer' application.",
23018 "properties" : {
23019 "host" : {
23020 "type" : "string"
23021 },
23022 "password" : {
23023 "type" : "string"
23024 },
23025 "proxy" : {
23026 "type" : "string"
23027 },
23028 "tls-port" : {
23029 "type" : "integer"
23030 },
23031 "type" : {
23032 "type" : "string"
23033 }
23034 }
7aacca6f 23035 }
56122987
DM
23036 }
23037 },
56122987 23038 "leaf" : 1,
44660702
DM
23039 "path" : "/nodes/{node}/spiceshell",
23040 "text" : "spiceshell"
56122987
DM
23041 },
23042 {
56122987 23043 "info" : {
7aacca6f 23044 "GET" : {
44660702 23045 "description" : "Read DNS settings.",
7aacca6f 23046 "method" : "GET",
44660702
DM
23047 "name" : "dns",
23048 "parameters" : {
7aacca6f
DM
23049 "additionalProperties" : 0,
23050 "properties" : {
44660702
DM
23051 "node" : {
23052 "description" : "The cluster node name.",
23053 "format" : "pve-node",
013dc89f
DM
23054 "type" : "string",
23055 "typetext" : "<string>"
7aacca6f
DM
23056 }
23057 }
23058 },
7aacca6f
DM
23059 "permissions" : {
23060 "check" : [
23061 "perm",
23062 "/nodes/{node}",
23063 [
23064 "Sys.Audit"
23065 ]
23066 ]
23067 },
44660702
DM
23068 "proxyto" : "node",
23069 "returns" : {
56122987
DM
23070 "additionalProperties" : 0,
23071 "properties" : {
44660702
DM
23072 "dns1" : {
23073 "description" : "First name server IP address.",
23074 "optional" : 1,
23075 "type" : "string"
23076 },
23077 "dns2" : {
23078 "description" : "Second name server IP address.",
23079 "optional" : 1,
23080 "type" : "string"
23081 },
23082 "dns3" : {
23083 "description" : "Third name server IP address.",
23084 "optional" : 1,
23085 "type" : "string"
23086 },
23087 "search" : {
23088 "description" : "Search domain for host-name lookup.",
23089 "optional" : 1,
23090 "type" : "string"
7aacca6f 23091 }
44660702
DM
23092 },
23093 "type" : "object"
23094 }
7aacca6f
DM
23095 },
23096 "PUT" : {
44660702
DM
23097 "description" : "Write DNS settings.",
23098 "method" : "PUT",
7aacca6f
DM
23099 "name" : "update_dns",
23100 "parameters" : {
23101 "additionalProperties" : 0,
23102 "properties" : {
44660702
DM
23103 "dns1" : {
23104 "description" : "First name server IP address.",
23105 "format" : "ip",
23106 "optional" : 1,
013dc89f
DM
23107 "type" : "string",
23108 "typetext" : "<string>"
7aacca6f 23109 },
44660702
DM
23110 "dns2" : {
23111 "description" : "Second name server IP address.",
23112 "format" : "ip",
7aacca6f 23113 "optional" : 1,
013dc89f
DM
23114 "type" : "string",
23115 "typetext" : "<string>"
7aacca6f 23116 },
44660702
DM
23117 "dns3" : {
23118 "description" : "Third name server IP address.",
23119 "format" : "ip",
7aacca6f 23120 "optional" : 1,
013dc89f
DM
23121 "type" : "string",
23122 "typetext" : "<string>"
7aacca6f
DM
23123 },
23124 "node" : {
44660702 23125 "description" : "The cluster node name.",
56122987 23126 "format" : "pve-node",
013dc89f
DM
23127 "type" : "string",
23128 "typetext" : "<string>"
7aacca6f 23129 },
44660702
DM
23130 "search" : {
23131 "description" : "Search domain for host-name lookup.",
013dc89f
DM
23132 "type" : "string",
23133 "typetext" : "<string>"
56122987
DM
23134 }
23135 }
23136 },
23137 "permissions" : {
23138 "check" : [
23139 "perm",
7aacca6f 23140 "/nodes/{node}",
56122987 23141 [
7aacca6f 23142 "Sys.Modify"
56122987
DM
23143 ]
23144 ]
23145 },
44660702 23146 "protected" : 1,
7aacca6f 23147 "proxyto" : "node",
56122987 23148 "returns" : {
7aacca6f
DM
23149 "type" : "null"
23150 }
56122987 23151 }
44660702
DM
23152 },
23153 "leaf" : 1,
23154 "path" : "/nodes/{node}/dns",
23155 "text" : "dns"
56122987
DM
23156 },
23157 {
23158 "info" : {
7aacca6f 23159 "GET" : {
7aacca6f 23160 "description" : "Read server time and time zone settings.",
44660702
DM
23161 "method" : "GET",
23162 "name" : "time",
56122987 23163 "parameters" : {
44660702 23164 "additionalProperties" : 0,
56122987
DM
23165 "properties" : {
23166 "node" : {
44660702 23167 "description" : "The cluster node name.",
56122987 23168 "format" : "pve-node",
013dc89f
DM
23169 "type" : "string",
23170 "typetext" : "<string>"
56122987 23171 }
44660702 23172 }
56122987
DM
23173 },
23174 "permissions" : {
23175 "check" : [
23176 "perm",
7aacca6f 23177 "/nodes/{node}",
56122987 23178 [
7aacca6f 23179 "Sys.Audit"
56122987
DM
23180 ]
23181 ]
44660702
DM
23182 },
23183 "proxyto" : "node",
23184 "returns" : {
23185 "additionalProperties" : 0,
23186 "properties" : {
23187 "localtime" : {
23188 "description" : "Seconds since 1970-01-01 00:00:00 (local time)",
23189 "minimum" : 1297163644,
23190 "type" : "integer"
23191 },
23192 "time" : {
23193 "description" : "Seconds since 1970-01-01 00:00:00 UTC.",
23194 "minimum" : 1297163644,
23195 "type" : "integer"
23196 },
23197 "timezone" : {
23198 "description" : "Time zone",
23199 "type" : "string"
23200 }
23201 },
23202 "type" : "object"
7aacca6f
DM
23203 }
23204 },
23205 "PUT" : {
7aacca6f 23206 "description" : "Set time zone.",
44660702
DM
23207 "method" : "PUT",
23208 "name" : "set_timezone",
23209 "parameters" : {
23210 "additionalProperties" : 0,
23211 "properties" : {
23212 "node" : {
23213 "description" : "The cluster node name.",
23214 "format" : "pve-node",
013dc89f
DM
23215 "type" : "string",
23216 "typetext" : "<string>"
44660702
DM
23217 },
23218 "timezone" : {
23219 "description" : "Time zone. The file '/usr/share/zoneinfo/zone.tab' contains the list of valid names.",
013dc89f
DM
23220 "type" : "string",
23221 "typetext" : "<string>"
44660702
DM
23222 }
23223 }
23224 },
7aacca6f
DM
23225 "permissions" : {
23226 "check" : [
23227 "perm",
23228 "/nodes/{node}",
23229 [
23230 "Sys.Modify"
23231 ]
23232 ]
56122987 23233 },
7aacca6f 23234 "protected" : 1,
44660702
DM
23235 "proxyto" : "node",
23236 "returns" : {
23237 "type" : "null"
23238 }
7aacca6f
DM
23239 }
23240 },
7aacca6f 23241 "leaf" : 1,
44660702
DM
23242 "path" : "/nodes/{node}/time",
23243 "text" : "time"
7aacca6f
DM
23244 },
23245 {
23246 "info" : {
44660702
DM
23247 "GET" : {
23248 "description" : "Get list of appliances.",
23249 "method" : "GET",
23250 "name" : "aplinfo",
7aacca6f
DM
23251 "parameters" : {
23252 "additionalProperties" : 0,
23253 "properties" : {
7aacca6f 23254 "node" : {
44660702 23255 "description" : "The cluster node name.",
7aacca6f 23256 "format" : "pve-node",
013dc89f
DM
23257 "type" : "string",
23258 "typetext" : "<string>"
7aacca6f
DM
23259 }
23260 }
56122987 23261 },
7aacca6f 23262 "permissions" : {
44660702 23263 "user" : "all"
56122987 23264 },
44660702 23265 "proxyto" : "node",
7aacca6f
DM
23266 "returns" : {
23267 "items" : {
44660702
DM
23268 "properties" : {},
23269 "type" : "object"
7aacca6f
DM
23270 },
23271 "type" : "array"
44660702
DM
23272 }
23273 },
23274 "POST" : {
23275 "description" : "Download appliance templates.",
23276 "method" : "POST",
23277 "name" : "apl_download",
7aacca6f
DM
23278 "parameters" : {
23279 "additionalProperties" : 0,
23280 "properties" : {
23281 "node" : {
7aacca6f 23282 "description" : "The cluster node name.",
44660702 23283 "format" : "pve-node",
013dc89f
DM
23284 "type" : "string",
23285 "typetext" : "<string>"
44660702
DM
23286 },
23287 "storage" : {
4bd7df8b 23288 "description" : "The storage where the template will be stored",
44660702 23289 "format" : "pve-storage-id",
013dc89f
DM
23290 "type" : "string",
23291 "typetext" : "<string>"
44660702
DM
23292 },
23293 "template" : {
23294 "description" : "The template wich will downloaded",
23295 "maxLength" : 255,
013dc89f
DM
23296 "type" : "string",
23297 "typetext" : "<string>"
7aacca6f
DM
23298 }
23299 }
56122987 23300 },
7aacca6f 23301 "permissions" : {
44660702
DM
23302 "check" : [
23303 "perm",
23304 "/storage/{storage}",
23305 [
23306 "Datastore.AllocateTemplate"
23307 ]
23308 ]
23309 },
23310 "protected" : 1,
23311 "proxyto" : "node",
23312 "returns" : {
23313 "type" : "string"
7aacca6f
DM
23314 }
23315 }
23316 },
7aacca6f 23317 "leaf" : 1,
44660702
DM
23318 "path" : "/nodes/{node}/aplinfo",
23319 "text" : "aplinfo"
7aacca6f
DM
23320 },
23321 {
23322 "info" : {
23323 "GET" : {
44660702
DM
23324 "description" : "Gather various systems information about a node",
23325 "method" : "GET",
23326 "name" : "report",
7aacca6f 23327 "parameters" : {
44660702 23328 "additionalProperties" : 0,
7aacca6f
DM
23329 "properties" : {
23330 "node" : {
7aacca6f 23331 "description" : "The cluster node name.",
44660702 23332 "format" : "pve-node",
013dc89f
DM
23333 "type" : "string",
23334 "typetext" : "<string>"
7aacca6f 23335 }
44660702 23336 }
56122987 23337 },
7aacca6f
DM
23338 "permissions" : {
23339 "check" : [
23340 "perm",
23341 "/nodes/{node}",
23342 [
23343 "Sys.Audit"
23344 ]
23345 ]
56122987 23346 },
44660702 23347 "protected" : 1,
7aacca6f
DM
23348 "proxyto" : "node",
23349 "returns" : {
56122987 23350 "type" : "string"
7aacca6f
DM
23351 }
23352 }
23353 },
7aacca6f 23354 "leaf" : 1,
44660702
DM
23355 "path" : "/nodes/{node}/report",
23356 "text" : "report"
7aacca6f
DM
23357 },
23358 {
7aacca6f
DM
23359 "info" : {
23360 "POST" : {
44660702 23361 "description" : "Start all VMs and containers (when onboot=1).",
7aacca6f 23362 "method" : "POST",
44660702 23363 "name" : "startall",
7aacca6f 23364 "parameters" : {
44660702 23365 "additionalProperties" : 0,
7aacca6f
DM
23366 "properties" : {
23367 "force" : {
44660702 23368 "description" : "force if onboot=0.",
7aacca6f 23369 "optional" : 1,
013dc89f
DM
23370 "type" : "boolean",
23371 "typetext" : "<boolean>"
7aacca6f
DM
23372 },
23373 "node" : {
7aacca6f 23374 "description" : "The cluster node name.",
44660702 23375 "format" : "pve-node",
013dc89f
DM
23376 "type" : "string",
23377 "typetext" : "<string>"
52e44c50
FG
23378 },
23379 "vms" : {
23380 "description" : "Only consider Guests with these IDs.",
23381 "format" : "pve-vmid-list",
23382 "optional" : 1,
23383 "type" : "string",
23384 "typetext" : "<string>"
7aacca6f 23385 }
44660702 23386 }
56122987 23387 },
7aacca6f
DM
23388 "permissions" : {
23389 "check" : [
23390 "perm",
23391 "/",
23392 [
23393 "VM.PowerMgmt"
23394 ]
23395 ]
44660702
DM
23396 },
23397 "protected" : 1,
23398 "proxyto" : "node",
23399 "returns" : {
23400 "type" : "string"
7aacca6f
DM
23401 }
23402 }
23403 },
44660702 23404 "leaf" : 1,
7aacca6f 23405 "path" : "/nodes/{node}/startall",
44660702 23406 "text" : "startall"
7aacca6f
DM
23407 },
23408 {
7aacca6f
DM
23409 "info" : {
23410 "POST" : {
23411 "description" : "Stop all VMs and Containers.",
44660702
DM
23412 "method" : "POST",
23413 "name" : "stopall",
7aacca6f 23414 "parameters" : {
44660702 23415 "additionalProperties" : 0,
7aacca6f
DM
23416 "properties" : {
23417 "node" : {
44660702 23418 "description" : "The cluster node name.",
7aacca6f 23419 "format" : "pve-node",
013dc89f
DM
23420 "type" : "string",
23421 "typetext" : "<string>"
52e44c50
FG
23422 },
23423 "vms" : {
23424 "description" : "Only consider Guests with these IDs.",
23425 "format" : "pve-vmid-list",
23426 "optional" : 1,
23427 "type" : "string",
23428 "typetext" : "<string>"
7aacca6f 23429 }
44660702 23430 }
56122987 23431 },
7aacca6f
DM
23432 "permissions" : {
23433 "check" : [
23434 "perm",
23435 "/",
23436 [
44660702 23437 "VM.PowerMgmt"
7aacca6f
DM
23438 ]
23439 ]
56122987 23440 },
44660702 23441 "protected" : 1,
7aacca6f 23442 "proxyto" : "node",
44660702
DM
23443 "returns" : {
23444 "type" : "string"
23445 }
23446 }
56122987 23447 },
44660702
DM
23448 "leaf" : 1,
23449 "path" : "/nodes/{node}/stopall",
23450 "text" : "stopall"
23451 },
23452 {
23453 "info" : {
23454 "POST" : {
23455 "description" : "Migrate all VMs and Containers.",
23456 "method" : "POST",
23457 "name" : "migrateall",
23458 "parameters" : {
23459 "additionalProperties" : 0,
23460 "properties" : {
23461 "maxworkers" : {
23462 "description" : "Maximal number of parallel migration job. If not set use 'max_workers' from datacenter.cfg, one of both must be set!",
23463 "minimum" : 1,
23464 "optional" : 1,
4bd7df8b 23465 "type" : "integer",
013dc89f 23466 "typetext" : "<integer> (1 - N)"
44660702
DM
23467 },
23468 "node" : {
23469 "description" : "The cluster node name.",
23470 "format" : "pve-node",
013dc89f
DM
23471 "type" : "string",
23472 "typetext" : "<string>"
44660702
DM
23473 },
23474 "target" : {
23475 "description" : "Target node.",
23476 "format" : "pve-node",
013dc89f
DM
23477 "type" : "string",
23478 "typetext" : "<string>"
52e44c50
FG
23479 },
23480 "vms" : {
23481 "description" : "Only consider Guests with these IDs.",
23482 "format" : "pve-vmid-list",
23483 "optional" : 1,
23484 "type" : "string",
23485 "typetext" : "<string>"
44660702
DM
23486 }
23487 }
23488 },
23489 "permissions" : {
23490 "check" : [
23491 "perm",
23492 "/",
23493 [
23494 "VM.Migrate"
23495 ]
23496 ]
23497 },
23498 "protected" : 1,
23499 "proxyto" : "node",
23500 "returns" : {
23501 "type" : "string"
23502 }
23503 }
56122987 23504 },
44660702
DM
23505 "leaf" : 1,
23506 "path" : "/nodes/{node}/migrateall",
23507 "text" : "migrateall"
23508 }
23509 ],
23510 "info" : {
23511 "GET" : {
23512 "description" : "Node index.",
23513 "method" : "GET",
23514 "name" : "index",
23515 "parameters" : {
23516 "additionalProperties" : 0,
23517 "properties" : {
23518 "node" : {
23519 "description" : "The cluster node name.",
23520 "format" : "pve-node",
013dc89f
DM
23521 "type" : "string",
23522 "typetext" : "<string>"
44660702
DM
23523 }
23524 }
56122987 23525 },
44660702
DM
23526 "permissions" : {
23527 "user" : "all"
56122987 23528 },
44660702
DM
23529 "returns" : {
23530 "items" : {
23531 "properties" : {},
23532 "type" : "object"
23533 },
23534 "links" : [
23535 {
23536 "href" : "{name}",
23537 "rel" : "child"
23538 }
56122987 23539 ],
44660702 23540 "type" : "array"
7aacca6f
DM
23541 }
23542 }
23543 },
44660702
DM
23544 "leaf" : 0,
23545 "path" : "/nodes/{node}",
23546 "text" : "{node}"
23547 }
23548 ],
23549 "info" : {
7aacca6f 23550 "GET" : {
44660702 23551 "description" : "Cluster node index.",
7aacca6f 23552 "method" : "GET",
44660702 23553 "name" : "index",
7aacca6f 23554 "parameters" : {
7aacca6f
DM
23555 "additionalProperties" : 0
23556 },
23557 "permissions" : {
7aacca6f
DM
23558 "user" : "all"
23559 },
44660702
DM
23560 "returns" : {
23561 "items" : {
23562 "properties" : {},
23563 "type" : "object"
23564 },
23565 "links" : [
23566 {
23567 "href" : "{node}",
23568 "rel" : "child"
23569 }
23570 ],
23571 "type" : "array"
23572 }
7aacca6f
DM
23573 }
23574 },
44660702
DM
23575 "leaf" : 0,
23576 "path" : "/nodes",
23577 "text" : "nodes"
23578 },
23579 {
7aacca6f
DM
23580 "children" : [
23581 {
7aacca6f 23582 "info" : {
44660702
DM
23583 "DELETE" : {
23584 "description" : "Delete storage configuration.",
23585 "method" : "DELETE",
23586 "name" : "delete",
7aacca6f
DM
23587 "parameters" : {
23588 "additionalProperties" : 0,
23589 "properties" : {
23590 "storage" : {
7aacca6f 23591 "description" : "The storage identifier.",
44660702 23592 "format" : "pve-storage-id",
013dc89f
DM
23593 "type" : "string",
23594 "typetext" : "<string>"
7aacca6f
DM
23595 }
23596 }
56122987 23597 },
7aacca6f
DM
23598 "permissions" : {
23599 "check" : [
23600 "perm",
23601 "/storage",
23602 [
23603 "Datastore.Allocate"
23604 ]
23605 ]
56122987 23606 },
44660702
DM
23607 "protected" : 1,
23608 "returns" : {
23609 "type" : "null"
23610 }
23611 },
23612 "GET" : {
23613 "description" : "Read storage configuration.",
23614 "method" : "GET",
23615 "name" : "read",
7aacca6f
DM
23616 "parameters" : {
23617 "additionalProperties" : 0,
23618 "properties" : {
23619 "storage" : {
44660702 23620 "description" : "The storage identifier.",
7aacca6f 23621 "format" : "pve-storage-id",
013dc89f
DM
23622 "type" : "string",
23623 "typetext" : "<string>"
7aacca6f
DM
23624 }
23625 }
23626 },
44660702
DM
23627 "permissions" : {
23628 "check" : [
23629 "perm",
23630 "/storage/{storage}",
23631 [
23632 "Datastore.Allocate"
23633 ]
23634 ]
23635 },
23636 "returns" : {}
7aacca6f
DM
23637 },
23638 "PUT" : {
44660702
DM
23639 "description" : "Update storage configuration.",
23640 "method" : "PUT",
23641 "name" : "update",
23642 "parameters" : {
23643 "additionalProperties" : 0,
23644 "properties" : {
23645 "blocksize" : {
23646 "description" : "block size",
7aacca6f 23647 "optional" : 1,
013dc89f
DM
23648 "type" : "string",
23649 "typetext" : "<string>"
7aacca6f 23650 },
44660702
DM
23651 "comstar_hg" : {
23652 "description" : "host group for comstar views",
23653 "optional" : 1,
013dc89f
DM
23654 "type" : "string",
23655 "typetext" : "<string>"
7aacca6f 23656 },
44660702
DM
23657 "comstar_tg" : {
23658 "description" : "target group for comstar views",
7aacca6f 23659 "optional" : 1,
013dc89f
DM
23660 "type" : "string",
23661 "typetext" : "<string>"
7aacca6f 23662 },
44660702
DM
23663 "content" : {
23664 "description" : "Allowed content types.\n\nNOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs.\n",
23665 "format" : "pve-storage-content-list",
7aacca6f 23666 "optional" : 1,
013dc89f
DM
23667 "type" : "string",
23668 "typetext" : "<string>"
7aacca6f 23669 },
44660702
DM
23670 "delete" : {
23671 "description" : "A list of settings you want to delete.",
23672 "format" : "pve-configid-list",
23673 "maxLength" : 4096,
7aacca6f 23674 "optional" : 1,
013dc89f
DM
23675 "type" : "string",
23676 "typetext" : "<string>"
7aacca6f
DM
23677 },
23678 "digest" : {
44660702 23679 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
7aacca6f 23680 "maxLength" : 40,
7aacca6f 23681 "optional" : 1,
013dc89f
DM
23682 "type" : "string",
23683 "typetext" : "<string>"
7aacca6f 23684 },
44660702
DM
23685 "disable" : {
23686 "description" : "Flag to disable the storage.",
23687 "optional" : 1,
013dc89f
DM
23688 "type" : "boolean",
23689 "typetext" : "<boolean>"
7aacca6f
DM
23690 },
23691 "format" : {
23692 "description" : "Default image format.",
44660702 23693 "format" : "pve-storage-format",
7aacca6f 23694 "optional" : 1,
013dc89f
DM
23695 "type" : "string",
23696 "typetext" : "<string>"
7aacca6f 23697 },
2c0dde61
DM
23698 "is_mountpoint" : {
23699 "default" : "no",
23700 "description" : "Assume the directory is an externally managed mountpoint. If nothing is mounted the storage will be considered offline.",
23701 "optional" : 1,
013dc89f
DM
23702 "type" : "boolean",
23703 "typetext" : "<boolean>"
2c0dde61 23704 },
44660702
DM
23705 "krbd" : {
23706 "description" : "Access rbd through krbd kernel module.",
7aacca6f 23707 "optional" : 1,
013dc89f
DM
23708 "type" : "boolean",
23709 "typetext" : "<boolean>"
7aacca6f 23710 },
44660702
DM
23711 "maxfiles" : {
23712 "description" : "Maximal number of backup files per VM. Use '0' for unlimted.",
23713 "minimum" : 0,
23714 "optional" : 1,
4bd7df8b 23715 "type" : "integer",
013dc89f 23716 "typetext" : "<integer> (0 - N)"
4bd7df8b
DM
23717 },
23718 "mkdir" : {
23719 "default" : "yes",
23720 "description" : "Create the directory if it doesn't exist.",
23721 "optional" : 1,
013dc89f
DM
23722 "type" : "boolean",
23723 "typetext" : "<boolean>"
7aacca6f
DM
23724 },
23725 "nodes" : {
44660702 23726 "description" : "List of cluster node names.",
7aacca6f
DM
23727 "format" : "pve-node-list",
23728 "optional" : 1,
013dc89f
DM
23729 "type" : "string",
23730 "typetext" : "<string>"
7aacca6f 23731 },
44660702
DM
23732 "nowritecache" : {
23733 "description" : "disable write caching on the target",
7aacca6f 23734 "optional" : 1,
013dc89f
DM
23735 "type" : "boolean",
23736 "typetext" : "<boolean>"
7aacca6f
DM
23737 },
23738 "options" : {
7aacca6f 23739 "description" : "NFS mount options (see 'man nfs')",
44660702
DM
23740 "format" : "pve-storage-options",
23741 "optional" : 1,
013dc89f
DM
23742 "type" : "string",
23743 "typetext" : "<string>"
44660702
DM
23744 },
23745 "pool" : {
23746 "description" : "Pool.",
23747 "optional" : 1,
013dc89f
DM
23748 "type" : "string",
23749 "typetext" : "<string>"
44660702
DM
23750 },
23751 "redundancy" : {
23752 "default" : 2,
23753 "description" : "The redundancy count specifies the number of nodes to which the resource should be deployed. It must be at least 1 and at most the number of nodes in the cluster.",
23754 "maximum" : 16,
23755 "minimum" : 1,
23756 "optional" : 1,
4bd7df8b 23757 "type" : "integer",
013dc89f 23758 "typetext" : "<integer> (1 - 16)"
44660702
DM
23759 },
23760 "saferemove" : {
23761 "description" : "Zero-out data when removing LVs.",
23762 "optional" : 1,
013dc89f
DM
23763 "type" : "boolean",
23764 "typetext" : "<boolean>"
7aacca6f
DM
23765 },
23766 "saferemove_throughput" : {
44660702 23767 "description" : "Wipe throughput (cstream -t parameter value).",
7aacca6f 23768 "optional" : 1,
013dc89f
DM
23769 "type" : "string",
23770 "typetext" : "<string>"
7aacca6f 23771 },
44660702
DM
23772 "server" : {
23773 "description" : "Server IP or DNS name.",
23774 "format" : "pve-storage-server",
7aacca6f 23775 "optional" : 1,
013dc89f
DM
23776 "type" : "string",
23777 "typetext" : "<string>"
7aacca6f 23778 },
44660702
DM
23779 "server2" : {
23780 "description" : "Backup volfile server IP or DNS name.",
23781 "format" : "pve-storage-server",
7aacca6f 23782 "optional" : 1,
44660702 23783 "requires" : "server",
013dc89f
DM
23784 "type" : "string",
23785 "typetext" : "<string>"
44660702
DM
23786 },
23787 "shared" : {
23788 "description" : "Mark storage as shared.",
23789 "optional" : 1,
013dc89f
DM
23790 "type" : "boolean",
23791 "typetext" : "<boolean>"
44660702
DM
23792 },
23793 "sparse" : {
23794 "description" : "use sparse volumes",
23795 "optional" : 1,
013dc89f
DM
23796 "type" : "boolean",
23797 "typetext" : "<boolean>"
44660702
DM
23798 },
23799 "storage" : {
23800 "description" : "The storage identifier.",
23801 "format" : "pve-storage-id",
013dc89f
DM
23802 "type" : "string",
23803 "typetext" : "<string>"
44660702 23804 },
4bd7df8b
DM
23805 "tagged_only" : {
23806 "description" : "Only use logical volumes tagged with 'pve-vm-ID'.",
23807 "optional" : 1,
013dc89f
DM
23808 "type" : "boolean",
23809 "typetext" : "<boolean>"
4bd7df8b 23810 },
44660702
DM
23811 "transport" : {
23812 "description" : "Gluster transport: tcp or rdma",
23813 "enum" : [
23814 "tcp",
23815 "rdma",
23816 "unix"
23817 ],
23818 "optional" : 1,
23819 "type" : "string"
7aacca6f
DM
23820 },
23821 "username" : {
23822 "description" : "RBD Id.",
44660702 23823 "optional" : 1,
013dc89f
DM
23824 "type" : "string",
23825 "typetext" : "<string>"
7aacca6f 23826 }
44660702
DM
23827 },
23828 "type" : "object"
23829 },
23830 "permissions" : {
23831 "check" : [
23832 "perm",
23833 "/storage",
23834 [
23835 "Datastore.Allocate"
23836 ]
23837 ]
23838 },
23839 "protected" : 1,
23840 "returns" : {
23841 "type" : "null"
23842 }
23843 }
23844 },
23845 "leaf" : 1,
23846 "path" : "/storage/{storage}",
23847 "text" : "{storage}"
23848 }
23849 ],
23850 "info" : {
23851 "GET" : {
23852 "description" : "Storage index.",
23853 "method" : "GET",
23854 "name" : "index",
23855 "parameters" : {
23856 "additionalProperties" : 0,
23857 "properties" : {
23858 "type" : {
23859 "description" : "Only list storage of specific type",
23860 "enum" : [
23861 "dir",
23862 "drbd",
23863 "glusterfs",
23864 "iscsi",
23865 "iscsidirect",
23866 "lvm",
23867 "lvmthin",
23868 "nfs",
23869 "rbd",
23870 "sheepdog",
23871 "zfs",
23872 "zfspool"
23873 ],
23874 "optional" : 1,
23875 "type" : "string"
23876 }
23877 }
23878 },
23879 "permissions" : {
23880 "description" : "Only list entries where you have 'Datastore.Audit' or 'Datastore.AllocateSpace' permissions on '/storage/<storage>'",
23881 "user" : "all"
23882 },
23883 "returns" : {
23884 "items" : {
23885 "properties" : {
23886 "storage" : {
23887 "type" : "string"
7aacca6f 23888 }
56122987 23889 },
44660702
DM
23890 "type" : "object"
23891 },
23892 "links" : [
23893 {
23894 "href" : "{storage}",
23895 "rel" : "child"
23896 }
23897 ],
23898 "type" : "array"
23899 }
23900 },
23901 "POST" : {
23902 "description" : "Create a new storage.",
23903 "method" : "POST",
23904 "name" : "create",
23905 "parameters" : {
23906 "additionalProperties" : 0,
23907 "properties" : {
23908 "authsupported" : {
23909 "description" : "Authsupported.",
23910 "optional" : 1,
013dc89f
DM
23911 "type" : "string",
23912 "typetext" : "<string>"
44660702
DM
23913 },
23914 "base" : {
23915 "description" : "Base volume. This volume is automatically activated.",
23916 "format" : "pve-volume-id",
23917 "optional" : 1,
013dc89f
DM
23918 "type" : "string",
23919 "typetext" : "<string>"
44660702
DM
23920 },
23921 "blocksize" : {
23922 "description" : "block size",
23923 "optional" : 1,
013dc89f
DM
23924 "type" : "string",
23925 "typetext" : "<string>"
44660702
DM
23926 },
23927 "comstar_hg" : {
23928 "description" : "host group for comstar views",
23929 "optional" : 1,
013dc89f
DM
23930 "type" : "string",
23931 "typetext" : "<string>"
44660702
DM
23932 },
23933 "comstar_tg" : {
23934 "description" : "target group for comstar views",
23935 "optional" : 1,
013dc89f
DM
23936 "type" : "string",
23937 "typetext" : "<string>"
44660702
DM
23938 },
23939 "content" : {
23940 "description" : "Allowed content types.\n\nNOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs.\n",
23941 "format" : "pve-storage-content-list",
23942 "optional" : 1,
013dc89f
DM
23943 "type" : "string",
23944 "typetext" : "<string>"
44660702
DM
23945 },
23946 "disable" : {
23947 "description" : "Flag to disable the storage.",
23948 "optional" : 1,
013dc89f
DM
23949 "type" : "boolean",
23950 "typetext" : "<boolean>"
44660702
DM
23951 },
23952 "export" : {
23953 "description" : "NFS export path.",
23954 "format" : "pve-storage-path",
23955 "optional" : 1,
013dc89f
DM
23956 "type" : "string",
23957 "typetext" : "<string>"
44660702
DM
23958 },
23959 "format" : {
23960 "description" : "Default image format.",
23961 "format" : "pve-storage-format",
23962 "optional" : 1,
013dc89f
DM
23963 "type" : "string",
23964 "typetext" : "<string>"
44660702 23965 },
2c0dde61
DM
23966 "is_mountpoint" : {
23967 "default" : "no",
23968 "description" : "Assume the directory is an externally managed mountpoint. If nothing is mounted the storage will be considered offline.",
23969 "optional" : 1,
013dc89f
DM
23970 "type" : "boolean",
23971 "typetext" : "<boolean>"
2c0dde61 23972 },
44660702
DM
23973 "iscsiprovider" : {
23974 "description" : "iscsi provider",
23975 "optional" : 1,
013dc89f
DM
23976 "type" : "string",
23977 "typetext" : "<string>"
44660702
DM
23978 },
23979 "krbd" : {
23980 "description" : "Access rbd through krbd kernel module.",
23981 "optional" : 1,
013dc89f
DM
23982 "type" : "boolean",
23983 "typetext" : "<boolean>"
56122987 23984 },
44660702
DM
23985 "maxfiles" : {
23986 "description" : "Maximal number of backup files per VM. Use '0' for unlimted.",
23987 "minimum" : 0,
23988 "optional" : 1,
4bd7df8b 23989 "type" : "integer",
013dc89f 23990 "typetext" : "<integer> (0 - N)"
4bd7df8b
DM
23991 },
23992 "mkdir" : {
23993 "default" : "yes",
23994 "description" : "Create the directory if it doesn't exist.",
23995 "optional" : 1,
013dc89f
DM
23996 "type" : "boolean",
23997 "typetext" : "<boolean>"
7aacca6f 23998 },
44660702
DM
23999 "monhost" : {
24000 "description" : "Monitors daemon ips.",
4bd7df8b 24001 "format" : "pve-storage-portal-dns-list",
44660702 24002 "optional" : 1,
013dc89f
DM
24003 "type" : "string",
24004 "typetext" : "<string>"
7aacca6f 24005 },
44660702
DM
24006 "nodes" : {
24007 "description" : "List of cluster node names.",
24008 "format" : "pve-node-list",
24009 "optional" : 1,
013dc89f
DM
24010 "type" : "string",
24011 "typetext" : "<string>"
7aacca6f 24012 },
44660702
DM
24013 "nowritecache" : {
24014 "description" : "disable write caching on the target",
24015 "optional" : 1,
013dc89f
DM
24016 "type" : "boolean",
24017 "typetext" : "<boolean>"
44660702
DM
24018 },
24019 "options" : {
24020 "description" : "NFS mount options (see 'man nfs')",
24021 "format" : "pve-storage-options",
24022 "optional" : 1,
013dc89f
DM
24023 "type" : "string",
24024 "typetext" : "<string>"
44660702
DM
24025 },
24026 "path" : {
24027 "description" : "File system path.",
24028 "format" : "pve-storage-path",
24029 "optional" : 1,
013dc89f
DM
24030 "type" : "string",
24031 "typetext" : "<string>"
44660702
DM
24032 },
24033 "pool" : {
24034 "description" : "Pool.",
24035 "optional" : 1,
013dc89f
DM
24036 "type" : "string",
24037 "typetext" : "<string>"
44660702
DM
24038 },
24039 "portal" : {
24040 "description" : "iSCSI portal (IP or DNS name with optional port).",
24041 "format" : "pve-storage-portal-dns",
24042 "optional" : 1,
013dc89f
DM
24043 "type" : "string",
24044 "typetext" : "<string>"
44660702
DM
24045 },
24046 "redundancy" : {
24047 "default" : 2,
24048 "description" : "The redundancy count specifies the number of nodes to which the resource should be deployed. It must be at least 1 and at most the number of nodes in the cluster.",
24049 "maximum" : 16,
24050 "minimum" : 1,
24051 "optional" : 1,
4bd7df8b 24052 "type" : "integer",
013dc89f 24053 "typetext" : "<integer> (1 - 16)"
44660702
DM
24054 },
24055 "saferemove" : {
24056 "description" : "Zero-out data when removing LVs.",
24057 "optional" : 1,
013dc89f
DM
24058 "type" : "boolean",
24059 "typetext" : "<boolean>"
44660702
DM
24060 },
24061 "saferemove_throughput" : {
24062 "description" : "Wipe throughput (cstream -t parameter value).",
24063 "optional" : 1,
013dc89f
DM
24064 "type" : "string",
24065 "typetext" : "<string>"
44660702
DM
24066 },
24067 "server" : {
24068 "description" : "Server IP or DNS name.",
24069 "format" : "pve-storage-server",
24070 "optional" : 1,
013dc89f
DM
24071 "type" : "string",
24072 "typetext" : "<string>"
44660702
DM
24073 },
24074 "server2" : {
24075 "description" : "Backup volfile server IP or DNS name.",
24076 "format" : "pve-storage-server",
24077 "optional" : 1,
24078 "requires" : "server",
013dc89f
DM
24079 "type" : "string",
24080 "typetext" : "<string>"
44660702
DM
24081 },
24082 "shared" : {
24083 "description" : "Mark storage as shared.",
24084 "optional" : 1,
013dc89f
DM
24085 "type" : "boolean",
24086 "typetext" : "<boolean>"
44660702
DM
24087 },
24088 "sparse" : {
24089 "description" : "use sparse volumes",
24090 "optional" : 1,
013dc89f
DM
24091 "type" : "boolean",
24092 "typetext" : "<boolean>"
44660702
DM
24093 },
24094 "storage" : {
24095 "description" : "The storage identifier.",
24096 "format" : "pve-storage-id",
013dc89f
DM
24097 "type" : "string",
24098 "typetext" : "<string>"
44660702 24099 },
4bd7df8b
DM
24100 "tagged_only" : {
24101 "description" : "Only use logical volumes tagged with 'pve-vm-ID'.",
24102 "optional" : 1,
013dc89f
DM
24103 "type" : "boolean",
24104 "typetext" : "<boolean>"
4bd7df8b 24105 },
44660702
DM
24106 "target" : {
24107 "description" : "iSCSI target.",
24108 "optional" : 1,
013dc89f
DM
24109 "type" : "string",
24110 "typetext" : "<string>"
44660702
DM
24111 },
24112 "thinpool" : {
24113 "description" : "LVM thin pool LV name.",
24114 "format" : "pve-storage-vgname",
24115 "optional" : 1,
013dc89f
DM
24116 "type" : "string",
24117 "typetext" : "<string>"
44660702
DM
24118 },
24119 "transport" : {
24120 "description" : "Gluster transport: tcp or rdma",
24121 "enum" : [
24122 "tcp",
24123 "rdma",
24124 "unix"
7aacca6f 24125 ],
44660702
DM
24126 "optional" : 1,
24127 "type" : "string"
56122987 24128 },
44660702
DM
24129 "type" : {
24130 "description" : "Storage type.",
24131 "enum" : [
24132 "dir",
24133 "drbd",
24134 "glusterfs",
24135 "iscsi",
24136 "iscsidirect",
24137 "lvm",
24138 "lvmthin",
24139 "nfs",
24140 "rbd",
24141 "sheepdog",
24142 "zfs",
24143 "zfspool"
24144 ],
24145 "type" : "string"
56122987 24146 },
44660702
DM
24147 "username" : {
24148 "description" : "RBD Id.",
24149 "optional" : 1,
013dc89f
DM
24150 "type" : "string",
24151 "typetext" : "<string>"
7aacca6f 24152 },
44660702
DM
24153 "vgname" : {
24154 "description" : "Volume group name.",
24155 "format" : "pve-storage-vgname",
24156 "optional" : 1,
013dc89f
DM
24157 "type" : "string",
24158 "typetext" : "<string>"
44660702
DM
24159 },
24160 "volume" : {
24161 "description" : "Glusterfs Volume.",
24162 "optional" : 1,
013dc89f
DM
24163 "type" : "string",
24164 "typetext" : "<string>"
44660702
DM
24165 }
24166 },
24167 "type" : "object"
24168 },
24169 "permissions" : {
24170 "check" : [
24171 "perm",
24172 "/storage",
24173 [
24174 "Datastore.Allocate"
24175 ]
24176 ]
56122987 24177 },
44660702
DM
24178 "protected" : 1,
24179 "returns" : {
24180 "type" : "null"
24181 }
24182 }
24183 },
24184 "leaf" : 0,
24185 "path" : "/storage",
24186 "text" : "storage"
24187 },
24188 {
24189 "children" : [
24190 {
56122987
DM
24191 "children" : [
24192 {
56122987 24193 "info" : {
44660702
DM
24194 "DELETE" : {
24195 "description" : "Delete user.",
24196 "method" : "DELETE",
24197 "name" : "delete_user",
56122987 24198 "parameters" : {
7aacca6f 24199 "additionalProperties" : 0,
56122987 24200 "properties" : {
56122987 24201 "userid" : {
56122987
DM
24202 "description" : "User ID",
24203 "format" : "pve-userid",
44660702 24204 "maxLength" : 64,
013dc89f
DM
24205 "type" : "string",
24206 "typetext" : "<string>"
56122987 24207 }
7aacca6f 24208 }
56122987 24209 },
56122987
DM
24210 "permissions" : {
24211 "check" : [
44660702 24212 "and",
56122987 24213 [
44660702
DM
24214 "userid-param",
24215 "Realm.AllocateUser"
56122987 24216 ],
44660702
DM
24217 [
24218 "userid-group",
24219 [
24220 "User.Modify"
24221 ]
24222 ]
56122987 24223 ]
7aacca6f 24224 },
44660702 24225 "protected" : 1,
56122987
DM
24226 "returns" : {
24227 "type" : "null"
44660702 24228 }
7aacca6f 24229 },
44660702
DM
24230 "GET" : {
24231 "description" : "Get user configuration.",
24232 "method" : "GET",
24233 "name" : "read_user",
56122987
DM
24234 "parameters" : {
24235 "additionalProperties" : 0,
24236 "properties" : {
24237 "userid" : {
44660702 24238 "description" : "User ID",
56122987 24239 "format" : "pve-userid",
44660702 24240 "maxLength" : 64,
013dc89f
DM
24241 "type" : "string",
24242 "typetext" : "<string>"
56122987
DM
24243 }
24244 }
24245 },
56122987
DM
24246 "permissions" : {
24247 "check" : [
44660702 24248 "userid-group",
56122987 24249 [
44660702
DM
24250 "User.Modify",
24251 "Sys.Audit"
56122987
DM
24252 ]
24253 ]
24254 },
56122987 24255 "returns" : {
7aacca6f 24256 "additionalProperties" : 0,
56122987 24257 "properties" : {
44660702
DM
24258 "comment" : {
24259 "optional" : 1,
24260 "type" : "string"
56122987 24261 },
44660702
DM
24262 "email" : {
24263 "optional" : 1,
24264 "type" : "string"
7aacca6f
DM
24265 },
24266 "enable" : {
24267 "type" : "boolean"
24268 },
44660702
DM
24269 "expire" : {
24270 "optional" : 1,
24271 "type" : "integer"
24272 },
24273 "firstname" : {
56122987
DM
24274 "optional" : 1,
24275 "type" : "string"
24276 },
44660702
DM
24277 "groups" : {
24278 "type" : "array"
56122987 24279 },
44660702
DM
24280 "keys" : {
24281 "optional" : 1,
24282 "type" : "string"
7aacca6f 24283 },
44660702
DM
24284 "lastname" : {
24285 "optional" : 1,
24286 "type" : "string"
56122987 24287 }
7aacca6f 24288 }
44660702
DM
24289 }
24290 },
24291 "PUT" : {
24292 "description" : "Update user configuration.",
24293 "method" : "PUT",
24294 "name" : "update_user",
56122987 24295 "parameters" : {
44660702 24296 "additionalProperties" : 0,
56122987 24297 "properties" : {
44660702
DM
24298 "append" : {
24299 "optional" : 1,
24300 "requires" : "groups",
013dc89f
DM
24301 "type" : "boolean",
24302 "typetext" : "<boolean>"
44660702
DM
24303 },
24304 "comment" : {
24305 "optional" : 1,
013dc89f
DM
24306 "type" : "string",
24307 "typetext" : "<string>"
44660702
DM
24308 },
24309 "email" : {
24310 "format" : "email-opt",
24311 "optional" : 1,
013dc89f
DM
24312 "type" : "string",
24313 "typetext" : "<string>"
44660702
DM
24314 },
24315 "enable" : {
24316 "description" : "Enable/disable the account.",
24317 "optional" : 1,
013dc89f
DM
24318 "type" : "boolean",
24319 "typetext" : "<boolean>"
44660702
DM
24320 },
24321 "expire" : {
24322 "description" : "Account expiration date (seconds since epoch). '0' means no expiration date.",
24323 "minimum" : 0,
24324 "optional" : 1,
4bd7df8b 24325 "type" : "integer",
013dc89f 24326 "typetext" : "<integer> (0 - N)"
44660702
DM
24327 },
24328 "firstname" : {
24329 "optional" : 1,
013dc89f
DM
24330 "type" : "string",
24331 "typetext" : "<string>"
44660702
DM
24332 },
24333 "groups" : {
24334 "format" : "pve-groupid-list",
24335 "optional" : 1,
013dc89f
DM
24336 "type" : "string",
24337 "typetext" : "<string>"
44660702
DM
24338 },
24339 "keys" : {
24340 "description" : "Keys for two factor auth (yubico).",
24341 "optional" : 1,
013dc89f
DM
24342 "type" : "string",
24343 "typetext" : "<string>"
44660702
DM
24344 },
24345 "lastname" : {
24346 "optional" : 1,
013dc89f
DM
24347 "type" : "string",
24348 "typetext" : "<string>"
44660702 24349 },
56122987 24350 "userid" : {
56122987
DM
24351 "description" : "User ID",
24352 "format" : "pve-userid",
44660702 24353 "maxLength" : 64,
013dc89f
DM
24354 "type" : "string",
24355 "typetext" : "<string>"
56122987 24356 }
44660702 24357 }
56122987 24358 },
56122987
DM
24359 "permissions" : {
24360 "check" : [
24361 "userid-group",
24362 [
44660702
DM
24363 "User.Modify"
24364 ],
24365 "groups_param",
24366 1
56122987
DM
24367 ]
24368 },
44660702
DM
24369 "protected" : 1,
24370 "returns" : {
24371 "type" : "null"
24372 }
56122987
DM
24373 }
24374 },
44660702
DM
24375 "leaf" : 1,
24376 "path" : "/access/users/{userid}",
7aacca6f 24377 "text" : "{userid}"
56122987 24378 }
7aacca6f 24379 ],
56122987 24380 "info" : {
7aacca6f 24381 "GET" : {
44660702
DM
24382 "description" : "User index.",
24383 "method" : "GET",
7aacca6f 24384 "name" : "index",
56122987 24385 "parameters" : {
44660702
DM
24386 "additionalProperties" : 0,
24387 "properties" : {
24388 "enabled" : {
24389 "description" : "Optional filter for enable property.",
24390 "optional" : 1,
013dc89f
DM
24391 "type" : "boolean",
24392 "typetext" : "<boolean>"
44660702
DM
24393 }
24394 }
24395 },
24396 "permissions" : {
24397 "description" : "The returned list is restricted to users where you have 'User.Modify' or 'Sys.Audit' permissions on '/access/groups' or on a group the user belongs too. But it always includes the current (authenticated) user.",
24398 "user" : "all"
56122987 24399 },
7aacca6f 24400 "returns" : {
7aacca6f
DM
24401 "items" : {
24402 "properties" : {
44660702 24403 "userid" : {
7aacca6f
DM
24404 "type" : "string"
24405 }
24406 },
24407 "type" : "object"
24408 },
44660702
DM
24409 "links" : [
24410 {
24411 "href" : "{userid}",
24412 "rel" : "child"
24413 }
24414 ],
7aacca6f
DM
24415 "type" : "array"
24416 }
24417 },
24418 "POST" : {
44660702 24419 "description" : "Create new user.",
7aacca6f 24420 "method" : "POST",
44660702 24421 "name" : "create_user",
56122987 24422 "parameters" : {
7aacca6f
DM
24423 "additionalProperties" : 0,
24424 "properties" : {
44660702
DM
24425 "comment" : {
24426 "optional" : 1,
013dc89f
DM
24427 "type" : "string",
24428 "typetext" : "<string>"
7aacca6f 24429 },
44660702
DM
24430 "email" : {
24431 "format" : "email-opt",
24432 "optional" : 1,
013dc89f
DM
24433 "type" : "string",
24434 "typetext" : "<string>"
44660702
DM
24435 },
24436 "enable" : {
24437 "default" : 1,
24438 "description" : "Enable the account (default). You can set this to '0' to disable the accout",
24439 "optional" : 1,
013dc89f
DM
24440 "type" : "boolean",
24441 "typetext" : "<boolean>"
44660702
DM
24442 },
24443 "expire" : {
24444 "description" : "Account expiration date (seconds since epoch). '0' means no expiration date.",
24445 "minimum" : 0,
24446 "optional" : 1,
4bd7df8b 24447 "type" : "integer",
013dc89f 24448 "typetext" : "<integer> (0 - N)"
44660702
DM
24449 },
24450 "firstname" : {
24451 "optional" : 1,
013dc89f
DM
24452 "type" : "string",
24453 "typetext" : "<string>"
44660702
DM
24454 },
24455 "groups" : {
24456 "format" : "pve-groupid-list",
24457 "optional" : 1,
013dc89f
DM
24458 "type" : "string",
24459 "typetext" : "<string>"
44660702
DM
24460 },
24461 "keys" : {
24462 "description" : "Keys for two factor auth (yubico).",
24463 "optional" : 1,
013dc89f
DM
24464 "type" : "string",
24465 "typetext" : "<string>"
44660702
DM
24466 },
24467 "lastname" : {
7aacca6f 24468 "optional" : 1,
013dc89f
DM
24469 "type" : "string",
24470 "typetext" : "<string>"
44660702
DM
24471 },
24472 "password" : {
24473 "description" : "Initial password.",
24474 "maxLength" : 64,
24475 "minLength" : 5,
24476 "optional" : 1,
013dc89f
DM
24477 "type" : "string",
24478 "typetext" : "<string>"
44660702
DM
24479 },
24480 "userid" : {
24481 "description" : "User ID",
24482 "format" : "pve-userid",
24483 "maxLength" : 64,
013dc89f
DM
24484 "type" : "string",
24485 "typetext" : "<string>"
56122987 24486 }
7aacca6f 24487 }
56122987 24488 },
44660702
DM
24489 "permissions" : {
24490 "check" : [
24491 "and",
24492 [
24493 "userid-param",
24494 "Realm.AllocateUser"
24495 ],
24496 [
24497 "userid-group",
24498 [
24499 "User.Modify"
24500 ],
24501 "groups_param",
24502 1
24503 ]
24504 ],
24505 "description" : "You need 'Realm.AllocateUser' on '/access/realm/<realm>' on the realm of user <userid>, and 'User.Modify' permissions to '/access/groups/<group>' for any group specified (or 'User.Modify' on '/access/groups' if you pass no groups."
24506 },
24507 "protected" : 1,
24508 "returns" : {
24509 "type" : "null"
24510 }
56122987
DM
24511 }
24512 },
44660702
DM
24513 "leaf" : 0,
24514 "path" : "/access/users",
24515 "text" : "users"
24516 },
24517 {
56122987
DM
24518 "children" : [
24519 {
56122987
DM
24520 "info" : {
24521 "DELETE" : {
44660702
DM
24522 "description" : "Delete group.",
24523 "method" : "DELETE",
24524 "name" : "delete_group",
24525 "parameters" : {
24526 "additionalProperties" : 0,
24527 "properties" : {
24528 "groupid" : {
24529 "format" : "pve-groupid",
013dc89f
DM
24530 "type" : "string",
24531 "typetext" : "<string>"
44660702
DM
24532 }
24533 }
24534 },
7aacca6f
DM
24535 "permissions" : {
24536 "check" : [
24537 "perm",
24538 "/access/groups",
24539 [
24540 "Group.Allocate"
24541 ]
24542 ]
24543 },
7aacca6f 24544 "protected" : 1,
7aacca6f
DM
24545 "returns" : {
24546 "type" : "null"
44660702 24547 }
7aacca6f 24548 },
44660702
DM
24549 "GET" : {
24550 "description" : "Get group configuration.",
24551 "method" : "GET",
24552 "name" : "read_group",
24553 "parameters" : {
24554 "additionalProperties" : 0,
24555 "properties" : {
24556 "groupid" : {
24557 "format" : "pve-groupid",
013dc89f
DM
24558 "type" : "string",
24559 "typetext" : "<string>"
44660702
DM
24560 }
24561 }
56122987 24562 },
7aacca6f
DM
24563 "permissions" : {
24564 "check" : [
24565 "perm",
24566 "/access/groups",
24567 [
44660702 24568 "Sys.Audit",
7aacca6f 24569 "Group.Allocate"
44660702
DM
24570 ],
24571 "any",
24572 1
7aacca6f
DM
24573 ]
24574 },
7aacca6f 24575 "returns" : {
44660702 24576 "additionalProperties" : 0,
7aacca6f
DM
24577 "properties" : {
24578 "comment" : {
44660702
DM
24579 "optional" : 1,
24580 "type" : "string"
7aacca6f
DM
24581 },
24582 "members" : {
24583 "items" : {
24584 "type" : "string"
24585 },
24586 "type" : "array"
24587 }
24588 },
44660702
DM
24589 "type" : "object"
24590 }
24591 },
24592 "PUT" : {
24593 "description" : "Update group data.",
24594 "method" : "PUT",
24595 "name" : "update_group",
56122987 24596 "parameters" : {
44660702 24597 "additionalProperties" : 0,
56122987 24598 "properties" : {
44660702
DM
24599 "comment" : {
24600 "optional" : 1,
013dc89f
DM
24601 "type" : "string",
24602 "typetext" : "<string>"
44660702 24603 },
56122987
DM
24604 "groupid" : {
24605 "format" : "pve-groupid",
013dc89f
DM
24606 "type" : "string",
24607 "typetext" : "<string>"
56122987 24608 }
44660702 24609 }
56122987 24610 },
56122987
DM
24611 "permissions" : {
24612 "check" : [
24613 "perm",
24614 "/access/groups",
24615 [
24616 "Group.Allocate"
44660702 24617 ]
56122987
DM
24618 ]
24619 },
44660702
DM
24620 "protected" : 1,
24621 "returns" : {
24622 "type" : "null"
24623 }
7aacca6f
DM
24624 }
24625 },
7aacca6f 24626 "leaf" : 1,
44660702
DM
24627 "path" : "/access/groups/{groupid}",
24628 "text" : "{groupid}"
24629 }
24630 ],
24631 "info" : {
24632 "GET" : {
24633 "description" : "Group index.",
24634 "method" : "GET",
24635 "name" : "index",
24636 "parameters" : {
24637 "additionalProperties" : 0
24638 },
24639 "permissions" : {
24640 "description" : "The returned list is restricted to groups where you have 'User.Modify', 'Sys.Audit' or 'Group.Allocate' permissions on /access/groups/<group>.",
24641 "user" : "all"
24642 },
24643 "returns" : {
24644 "items" : {
24645 "properties" : {
24646 "groupid" : {
24647 "type" : "string"
24648 }
24649 },
24650 "type" : "object"
24651 },
24652 "links" : [
24653 {
24654 "href" : "{groupid}",
24655 "rel" : "child"
24656 }
24657 ],
24658 "type" : "array"
24659 }
24660 },
24661 "POST" : {
24662 "description" : "Create new group.",
24663 "method" : "POST",
24664 "name" : "create_group",
24665 "parameters" : {
24666 "additionalProperties" : 0,
24667 "properties" : {
24668 "comment" : {
24669 "optional" : 1,
013dc89f
DM
24670 "type" : "string",
24671 "typetext" : "<string>"
44660702
DM
24672 },
24673 "groupid" : {
24674 "format" : "pve-groupid",
013dc89f
DM
24675 "type" : "string",
24676 "typetext" : "<string>"
44660702
DM
24677 }
24678 }
24679 },
24680 "permissions" : {
24681 "check" : [
24682 "perm",
24683 "/access/groups",
24684 [
24685 "Group.Allocate"
24686 ]
24687 ]
24688 },
24689 "protected" : 1,
24690 "returns" : {
24691 "type" : "null"
24692 }
7aacca6f 24693 }
44660702 24694 },
7aacca6f 24695 "leaf" : 0,
44660702
DM
24696 "path" : "/access/groups",
24697 "text" : "groups"
7aacca6f
DM
24698 },
24699 {
24700 "children" : [
24701 {
7aacca6f 24702 "info" : {
7aacca6f 24703 "DELETE" : {
7aacca6f 24704 "description" : "Delete role.",
44660702 24705 "method" : "DELETE",
7aacca6f 24706 "name" : "delete_role",
56122987
DM
24707 "parameters" : {
24708 "additionalProperties" : 0,
24709 "properties" : {
7aacca6f
DM
24710 "roleid" : {
24711 "format" : "pve-roleid",
013dc89f
DM
24712 "type" : "string",
24713 "typetext" : "<string>"
56122987
DM
24714 }
24715 }
24716 },
56122987
DM
24717 "permissions" : {
24718 "check" : [
24719 "perm",
7aacca6f 24720 "/access",
56122987 24721 [
7aacca6f
DM
24722 "Sys.Modify"
24723 ]
56122987 24724 ]
44660702
DM
24725 },
24726 "protected" : 1,
24727 "returns" : {
24728 "type" : "null"
56122987
DM
24729 }
24730 },
44660702
DM
24731 "GET" : {
24732 "description" : "Get role configuration.",
24733 "method" : "GET",
24734 "name" : "read_role",
24735 "parameters" : {
24736 "additionalProperties" : 0,
24737 "properties" : {
24738 "roleid" : {
24739 "format" : "pve-roleid",
013dc89f
DM
24740 "type" : "string",
24741 "typetext" : "<string>"
44660702
DM
24742 }
24743 }
24744 },
7aacca6f 24745 "permissions" : {
44660702 24746 "user" : "all"
56122987 24747 },
44660702
DM
24748 "returns" : {}
24749 },
24750 "PUT" : {
24751 "description" : "Create new role.",
24752 "method" : "PUT",
24753 "name" : "update_role",
56122987
DM
24754 "parameters" : {
24755 "additionalProperties" : 0,
24756 "properties" : {
7aacca6f 24757 "append" : {
44660702 24758 "optional" : 1,
7aacca6f 24759 "requires" : "privs",
013dc89f
DM
24760 "type" : "boolean",
24761 "typetext" : "<boolean>"
7aacca6f
DM
24762 },
24763 "privs" : {
24764 "format" : "pve-priv-list",
013dc89f
DM
24765 "type" : "string",
24766 "typetext" : "<string>"
44660702
DM
24767 },
24768 "roleid" : {
24769 "format" : "pve-roleid",
013dc89f
DM
24770 "type" : "string",
24771 "typetext" : "<string>"
56122987
DM
24772 }
24773 }
24774 },
44660702
DM
24775 "permissions" : {
24776 "check" : [
24777 "perm",
24778 "/access",
24779 [
24780 "Sys.Modify"
24781 ]
24782 ]
24783 },
56122987 24784 "protected" : 1,
7aacca6f
DM
24785 "returns" : {
24786 "type" : "null"
56122987
DM
24787 }
24788 }
24789 },
44660702 24790 "leaf" : 1,
7aacca6f 24791 "path" : "/access/roles/{roleid}",
44660702 24792 "text" : "{roleid}"
56122987
DM
24793 }
24794 ],
56122987 24795 "info" : {
7aacca6f
DM
24796 "GET" : {
24797 "description" : "Role index.",
44660702 24798 "method" : "GET",
7aacca6f 24799 "name" : "index",
56122987 24800 "parameters" : {
56122987
DM
24801 "additionalProperties" : 0
24802 },
7aacca6f
DM
24803 "permissions" : {
24804 "user" : "all"
24805 },
56122987 24806 "returns" : {
7aacca6f 24807 "items" : {
7aacca6f
DM
24808 "properties" : {
24809 "roleid" : {
24810 "type" : "string"
24811 }
44660702
DM
24812 },
24813 "type" : "object"
24814 },
24815 "links" : [
24816 {
24817 "href" : "{roleid}",
24818 "rel" : "child"
7aacca6f 24819 }
44660702
DM
24820 ],
24821 "type" : "array"
24822 }
7aacca6f
DM
24823 },
24824 "POST" : {
24825 "description" : "Create new role.",
44660702
DM
24826 "method" : "POST",
24827 "name" : "create_role",
7aacca6f
DM
24828 "parameters" : {
24829 "additionalProperties" : 0,
24830 "properties" : {
7aacca6f
DM
24831 "privs" : {
24832 "format" : "pve-priv-list",
24833 "optional" : 1,
013dc89f
DM
24834 "type" : "string",
24835 "typetext" : "<string>"
44660702
DM
24836 },
24837 "roleid" : {
24838 "format" : "pve-roleid",
013dc89f
DM
24839 "type" : "string",
24840 "typetext" : "<string>"
7aacca6f
DM
24841 }
24842 }
24843 },
44660702
DM
24844 "permissions" : {
24845 "check" : [
24846 "perm",
24847 "/access",
24848 [
24849 "Sys.Modify"
24850 ]
24851 ]
24852 },
24853 "protected" : 1,
7aacca6f
DM
24854 "returns" : {
24855 "type" : "null"
24856 }
24857 }
24858 },
44660702 24859 "leaf" : 0,
7aacca6f 24860 "path" : "/access/roles",
44660702 24861 "text" : "roles"
7aacca6f
DM
24862 },
24863 {
24864 "info" : {
56122987 24865 "GET" : {
44660702
DM
24866 "description" : "Get Access Control List (ACLs).",
24867 "method" : "GET",
24868 "name" : "read_acl",
7aacca6f
DM
24869 "parameters" : {
24870 "additionalProperties" : 0
24871 },
44660702
DM
24872 "permissions" : {
24873 "description" : "The returned list is restricted to objects where you have rights to modify permissions.",
24874 "user" : "all"
24875 },
56122987 24876 "returns" : {
56122987 24877 "items" : {
44660702 24878 "additionalProperties" : 0,
56122987 24879 "properties" : {
7aacca6f
DM
24880 "path" : {
24881 "type" : "string"
24882 },
44660702
DM
24883 "propagate" : {
24884 "type" : "boolean"
24885 },
24886 "roleid" : {
24887 "type" : "string"
24888 },
7aacca6f
DM
24889 "type" : {
24890 "enum" : [
24891 "user",
24892 "group"
24893 ],
24894 "type" : "string"
24895 },
7aacca6f
DM
24896 "ugid" : {
24897 "type" : "string"
56122987 24898 }
7aacca6f 24899 },
44660702 24900 "type" : "object"
7aacca6f
DM
24901 },
24902 "type" : "array"
44660702 24903 }
7aacca6f
DM
24904 },
24905 "PUT" : {
44660702
DM
24906 "description" : "Update Access Control List (add or remove permissions).",
24907 "method" : "PUT",
7aacca6f
DM
24908 "name" : "update_acl",
24909 "parameters" : {
24910 "additionalProperties" : 0,
24911 "properties" : {
24912 "delete" : {
44660702 24913 "description" : "Remove permissions (instead of adding it).",
7aacca6f 24914 "optional" : 1,
013dc89f
DM
24915 "type" : "boolean",
24916 "typetext" : "<boolean>"
7aacca6f 24917 },
44660702
DM
24918 "groups" : {
24919 "description" : "List of groups.",
24920 "format" : "pve-groupid-list",
7aacca6f 24921 "optional" : 1,
013dc89f
DM
24922 "type" : "string",
24923 "typetext" : "<string>"
7aacca6f
DM
24924 },
24925 "path" : {
24926 "description" : "Access control path",
013dc89f
DM
24927 "type" : "string",
24928 "typetext" : "<string>"
7aacca6f 24929 },
7aacca6f 24930 "propagate" : {
44660702 24931 "default" : 1,
7aacca6f 24932 "description" : "Allow to propagate (inherit) permissions.",
7aacca6f 24933 "optional" : 1,
013dc89f
DM
24934 "type" : "boolean",
24935 "typetext" : "<boolean>"
7aacca6f 24936 },
44660702
DM
24937 "roles" : {
24938 "description" : "List of roles.",
24939 "format" : "pve-roleid-list",
013dc89f
DM
24940 "type" : "string",
24941 "typetext" : "<string>"
44660702
DM
24942 },
24943 "users" : {
24944 "description" : "List of users.",
24945 "format" : "pve-userid-list",
7aacca6f 24946 "optional" : 1,
013dc89f
DM
24947 "type" : "string",
24948 "typetext" : "<string>"
56122987
DM
24949 }
24950 }
24951 },
56122987 24952 "permissions" : {
7aacca6f
DM
24953 "check" : [
24954 "perm-modify",
24955 "{path}"
24956 ]
24957 },
7aacca6f
DM
24958 "protected" : 1,
24959 "returns" : {
24960 "type" : "null"
44660702 24961 }
56122987
DM
24962 }
24963 },
7aacca6f 24964 "leaf" : 1,
44660702
DM
24965 "path" : "/access/acl",
24966 "text" : "acl"
7aacca6f
DM
24967 },
24968 {
56122987
DM
24969 "children" : [
24970 {
56122987 24971 "info" : {
44660702
DM
24972 "DELETE" : {
24973 "description" : "Delete an authentication server.",
24974 "method" : "DELETE",
24975 "name" : "delete",
24976 "parameters" : {
24977 "additionalProperties" : 0,
24978 "properties" : {
24979 "realm" : {
24980 "description" : "Authentication domain ID",
24981 "format" : "pve-realm",
24982 "maxLength" : 32,
013dc89f
DM
24983 "type" : "string",
24984 "typetext" : "<string>"
56122987 24985 }
44660702 24986 }
56122987 24987 },
56122987
DM
24988 "permissions" : {
24989 "check" : [
24990 "perm",
7aacca6f 24991 "/access/realm",
56122987 24992 [
7aacca6f 24993 "Realm.Allocate"
56122987
DM
24994 ]
24995 ]
24996 },
7aacca6f 24997 "protected" : 1,
7aacca6f
DM
24998 "returns" : {
24999 "type" : "null"
44660702 25000 }
7aacca6f 25001 },
44660702
DM
25002 "GET" : {
25003 "description" : "Get auth server configuration.",
25004 "method" : "GET",
25005 "name" : "read",
56122987 25006 "parameters" : {
44660702 25007 "additionalProperties" : 0,
56122987 25008 "properties" : {
7aacca6f 25009 "realm" : {
44660702 25010 "description" : "Authentication domain ID",
7aacca6f
DM
25011 "format" : "pve-realm",
25012 "maxLength" : 32,
013dc89f
DM
25013 "type" : "string",
25014 "typetext" : "<string>"
56122987 25015 }
44660702 25016 }
7aacca6f 25017 },
7aacca6f
DM
25018 "permissions" : {
25019 "check" : [
25020 "perm",
25021 "/access/realm",
25022 [
44660702
DM
25023 "Realm.Allocate",
25024 "Sys.Audit"
25025 ],
25026 "any",
25027 1
7aacca6f 25028 ]
44660702
DM
25029 },
25030 "returns" : {}
7aacca6f 25031 },
44660702
DM
25032 "PUT" : {
25033 "description" : "Update authentication server settings.",
25034 "method" : "PUT",
25035 "name" : "update",
7aacca6f 25036 "parameters" : {
44660702 25037 "additionalProperties" : 0,
7aacca6f 25038 "properties" : {
44660702
DM
25039 "base_dn" : {
25040 "description" : "LDAP base domain name",
25041 "maxLength" : 256,
25042 "optional" : 1,
25043 "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*",
25044 "type" : "string"
25045 },
4bd7df8b
DM
25046 "bind_dn" : {
25047 "description" : "LDAP bind domain name",
25048 "maxLength" : 256,
25049 "optional" : 1,
25050 "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*",
25051 "type" : "string"
25052 },
44660702
DM
25053 "comment" : {
25054 "description" : "Description.",
25055 "maxLength" : 4096,
25056 "optional" : 1,
013dc89f
DM
25057 "type" : "string",
25058 "typetext" : "<string>"
44660702
DM
25059 },
25060 "default" : {
25061 "description" : "Use this as default realm",
25062 "optional" : 1,
013dc89f
DM
25063 "type" : "boolean",
25064 "typetext" : "<boolean>"
44660702
DM
25065 },
25066 "delete" : {
25067 "description" : "A list of settings you want to delete.",
25068 "format" : "pve-configid-list",
25069 "maxLength" : 4096,
25070 "optional" : 1,
013dc89f
DM
25071 "type" : "string",
25072 "typetext" : "<string>"
44660702
DM
25073 },
25074 "digest" : {
25075 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
25076 "maxLength" : 40,
25077 "optional" : 1,
013dc89f
DM
25078 "type" : "string",
25079 "typetext" : "<string>"
44660702
DM
25080 },
25081 "domain" : {
25082 "description" : "AD domain name",
25083 "maxLength" : 256,
25084 "optional" : 1,
25085 "pattern" : "\\S+",
25086 "type" : "string"
25087 },
25088 "port" : {
25089 "description" : "Server port.",
25090 "maximum" : 65535,
25091 "minimum" : 1,
25092 "optional" : 1,
4bd7df8b 25093 "type" : "integer",
013dc89f 25094 "typetext" : "<integer> (1 - 65535)"
44660702 25095 },
7aacca6f 25096 "realm" : {
7aacca6f
DM
25097 "description" : "Authentication domain ID",
25098 "format" : "pve-realm",
44660702 25099 "maxLength" : 32,
013dc89f
DM
25100 "type" : "string",
25101 "typetext" : "<string>"
44660702
DM
25102 },
25103 "secure" : {
25104 "description" : "Use secure LDAPS protocol.",
25105 "optional" : 1,
013dc89f
DM
25106 "type" : "boolean",
25107 "typetext" : "<boolean>"
44660702
DM
25108 },
25109 "server1" : {
25110 "description" : "Server IP address (or DNS name)",
25111 "format" : "address",
25112 "maxLength" : 256,
25113 "optional" : 1,
013dc89f
DM
25114 "type" : "string",
25115 "typetext" : "<string>"
44660702
DM
25116 },
25117 "server2" : {
25118 "description" : "Fallback Server IP address (or DNS name)",
25119 "format" : "address",
25120 "maxLength" : 256,
25121 "optional" : 1,
013dc89f
DM
25122 "type" : "string",
25123 "typetext" : "<string>"
44660702
DM
25124 },
25125 "tfa" : {
25126 "description" : "Use Two-factor authentication.",
25127 "format" : "pve-tfa-config",
25128 "maxLength" : 128,
25129 "optional" : 1,
013dc89f
DM
25130 "type" : "string",
25131 "typetext" : "<string>"
44660702
DM
25132 },
25133 "user_attr" : {
25134 "description" : "LDAP user attribute name",
25135 "maxLength" : 256,
25136 "optional" : 1,
25137 "pattern" : "\\S{2,}",
25138 "type" : "string"
7aacca6f 25139 }
56122987 25140 },
44660702 25141 "type" : "object"
56122987 25142 },
7aacca6f
DM
25143 "permissions" : {
25144 "check" : [
25145 "perm",
25146 "/access/realm",
25147 [
44660702
DM
25148 "Realm.Allocate"
25149 ]
7aacca6f
DM
25150 ]
25151 },
44660702
DM
25152 "protected" : 1,
25153 "returns" : {
25154 "type" : "null"
25155 }
56122987 25156 }
44660702
DM
25157 },
25158 "leaf" : 1,
25159 "path" : "/access/domains/{realm}",
25160 "text" : "{realm}"
56122987 25161 }
7aacca6f 25162 ],
56122987
DM
25163 "info" : {
25164 "GET" : {
44660702
DM
25165 "description" : "Authentication domain index.",
25166 "method" : "GET",
25167 "name" : "index",
25168 "parameters" : {
25169 "additionalProperties" : 0
25170 },
25171 "permissions" : {
25172 "description" : "Anyone can access that, because we need that list for the login box (before the user is authenticated).",
25173 "user" : "world"
25174 },
56122987 25175 "returns" : {
56122987
DM
25176 "items" : {
25177 "properties" : {
7aacca6f 25178 "comment" : {
52e44c50 25179 "description" : "A comment. The GUI use this text when you select a domain (Realm) on the login window.",
7aacca6f
DM
25180 "optional" : 1,
25181 "type" : "string"
25182 },
56122987
DM
25183 "realm" : {
25184 "type" : "string"
25185 },
25186 "tfa" : {
7aacca6f 25187 "description" : "Two-factor authentication provider.",
56122987
DM
25188 "enum" : [
25189 "yubico",
25190 "oath"
25191 ],
44660702
DM
25192 "optional" : 1,
25193 "type" : "string"
56122987
DM
25194 }
25195 },
25196 "type" : "object"
44660702
DM
25197 },
25198 "links" : [
25199 {
25200 "href" : "{realm}",
25201 "rel" : "child"
25202 }
25203 ],
25204 "type" : "array"
25205 }
56122987
DM
25206 },
25207 "POST" : {
7aacca6f 25208 "description" : "Add an authentication server.",
44660702 25209 "method" : "POST",
7aacca6f 25210 "name" : "create",
56122987 25211 "parameters" : {
44660702 25212 "additionalProperties" : 0,
56122987 25213 "properties" : {
44660702
DM
25214 "base_dn" : {
25215 "description" : "LDAP base domain name",
56122987 25216 "maxLength" : 256,
44660702
DM
25217 "optional" : 1,
25218 "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*",
7aacca6f 25219 "type" : "string"
56122987 25220 },
4bd7df8b
DM
25221 "bind_dn" : {
25222 "description" : "LDAP bind domain name",
25223 "maxLength" : 256,
25224 "optional" : 1,
25225 "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*",
25226 "type" : "string"
25227 },
44660702
DM
25228 "comment" : {
25229 "description" : "Description.",
25230 "maxLength" : 4096,
56122987 25231 "optional" : 1,
013dc89f
DM
25232 "type" : "string",
25233 "typetext" : "<string>"
56122987 25234 },
44660702
DM
25235 "default" : {
25236 "description" : "Use this as default realm",
7aacca6f 25237 "optional" : 1,
013dc89f
DM
25238 "type" : "boolean",
25239 "typetext" : "<boolean>"
56122987 25240 },
44660702
DM
25241 "domain" : {
25242 "description" : "AD domain name",
25243 "maxLength" : 256,
7aacca6f 25244 "optional" : 1,
44660702
DM
25245 "pattern" : "\\S+",
25246 "type" : "string"
56122987 25247 },
7aacca6f 25248 "port" : {
44660702 25249 "description" : "Server port.",
7aacca6f 25250 "maximum" : 65535,
44660702 25251 "minimum" : 1,
7aacca6f 25252 "optional" : 1,
4bd7df8b 25253 "type" : "integer",
013dc89f 25254 "typetext" : "<integer> (1 - 65535)"
56122987 25255 },
44660702
DM
25256 "realm" : {
25257 "description" : "Authentication domain ID",
25258 "format" : "pve-realm",
25259 "maxLength" : 32,
013dc89f
DM
25260 "type" : "string",
25261 "typetext" : "<string>"
44660702
DM
25262 },
25263 "secure" : {
25264 "description" : "Use secure LDAPS protocol.",
7aacca6f 25265 "optional" : 1,
013dc89f
DM
25266 "type" : "boolean",
25267 "typetext" : "<boolean>"
56122987 25268 },
44660702
DM
25269 "server1" : {
25270 "description" : "Server IP address (or DNS name)",
25271 "format" : "address",
25272 "maxLength" : 256,
25273 "optional" : 1,
013dc89f
DM
25274 "type" : "string",
25275 "typetext" : "<string>"
56122987 25276 },
44660702
DM
25277 "server2" : {
25278 "description" : "Fallback Server IP address (or DNS name)",
25279 "format" : "address",
7aacca6f 25280 "maxLength" : 256,
7aacca6f 25281 "optional" : 1,
013dc89f
DM
25282 "type" : "string",
25283 "typetext" : "<string>"
7aacca6f 25284 },
44660702
DM
25285 "tfa" : {
25286 "description" : "Use Two-factor authentication.",
25287 "format" : "pve-tfa-config",
25288 "maxLength" : 128,
25289 "optional" : 1,
013dc89f
DM
25290 "type" : "string",
25291 "typetext" : "<string>"
44660702
DM
25292 },
25293 "type" : {
25294 "description" : "Realm type.",
25295 "enum" : [
25296 "ad",
25297 "ldap",
25298 "pam",
25299 "pve"
25300 ],
25301 "type" : "string"
25302 },
25303 "user_attr" : {
25304 "description" : "LDAP user attribute name",
7aacca6f 25305 "maxLength" : 256,
7aacca6f 25306 "optional" : 1,
44660702
DM
25307 "pattern" : "\\S{2,}",
25308 "type" : "string"
7aacca6f
DM
25309 }
25310 },
7aacca6f 25311 "type" : "object"
56122987 25312 },
7aacca6f
DM
25313 "permissions" : {
25314 "check" : [
25315 "perm",
25316 "/access/realm",
25317 [
25318 "Realm.Allocate"
25319 ]
25320 ]
44660702
DM
25321 },
25322 "protected" : 1,
25323 "returns" : {
25324 "type" : "null"
7aacca6f 25325 }
56122987 25326 }
7aacca6f 25327 },
44660702 25328 "leaf" : 0,
56122987 25329 "path" : "/access/domains",
44660702 25330 "text" : "domains"
56122987
DM
25331 },
25332 {
56122987 25333 "info" : {
44660702
DM
25334 "GET" : {
25335 "description" : "Dummy. Useful for formaters which want to priovde a login page.",
25336 "method" : "GET",
25337 "name" : "get_ticket",
25338 "parameters" : {
25339 "additionalProperties" : 0
25340 },
25341 "permissions" : {
25342 "user" : "world"
25343 },
25344 "returns" : {
25345 "type" : "null"
25346 }
25347 },
56122987 25348 "POST" : {
44660702 25349 "description" : "Create or verify authentication ticket.",
56122987 25350 "method" : "POST",
44660702
DM
25351 "name" : "create_ticket",
25352 "parameters" : {
25353 "additionalProperties" : 0,
56122987 25354 "properties" : {
44660702
DM
25355 "otp" : {
25356 "description" : "One-time password for Two-factor authentication.",
7aacca6f 25357 "optional" : 1,
013dc89f
DM
25358 "type" : "string",
25359 "typetext" : "<string>"
56122987 25360 },
7aacca6f
DM
25361 "password" : {
25362 "description" : "The secret password. This can also be a valid ticket.",
013dc89f
DM
25363 "type" : "string",
25364 "typetext" : "<string>"
7aacca6f 25365 },
44660702
DM
25366 "path" : {
25367 "description" : "Verify ticket, and check if user have access 'privs' on 'path'",
7aacca6f 25368 "maxLength" : 64,
56122987 25369 "optional" : 1,
56122987 25370 "requires" : "privs",
013dc89f
DM
25371 "type" : "string",
25372 "typetext" : "<string>"
44660702
DM
25373 },
25374 "privs" : {
7aacca6f 25375 "description" : "Verify ticket, and check if user have access 'privs' on 'path'",
44660702
DM
25376 "format" : "pve-priv-list",
25377 "maxLength" : 64,
56122987 25378 "optional" : 1,
44660702 25379 "requires" : "path",
013dc89f
DM
25380 "type" : "string",
25381 "typetext" : "<string>"
56122987
DM
25382 },
25383 "realm" : {
56122987 25384 "description" : "You can optionally pass the realm using this parameter. Normally the realm is simply added to the username <username>@<relam>.",
44660702 25385 "format" : "pve-realm",
7aacca6f 25386 "maxLength" : 32,
44660702 25387 "optional" : 1,
013dc89f
DM
25388 "type" : "string",
25389 "typetext" : "<string>"
56122987
DM
25390 },
25391 "username" : {
25392 "description" : "User name",
44660702 25393 "maxLength" : 64,
013dc89f
DM
25394 "type" : "string",
25395 "typetext" : "<string>"
56122987 25396 }
44660702 25397 }
7aacca6f 25398 },
56122987 25399 "permissions" : {
44660702 25400 "description" : "You need to pass valid credientials.",
56122987
DM
25401 "user" : "world"
25402 },
44660702 25403 "protected" : 1,
7aacca6f 25404 "returns" : {
56122987 25405 "properties" : {
44660702
DM
25406 "CSRFPreventionToken" : {
25407 "optional" : 1,
25408 "type" : "string"
56122987 25409 },
44660702
DM
25410 "ticket" : {
25411 "optional" : 1,
25412 "type" : "string"
25413 },
25414 "username" : {
56122987
DM
25415 "type" : "string"
25416 }
25417 },
44660702 25418 "type" : "object"
7aacca6f 25419 }
7aacca6f
DM
25420 }
25421 },
44660702
DM
25422 "leaf" : 1,
25423 "path" : "/access/ticket",
25424 "text" : "ticket"
7aacca6f 25425 },
56122987 25426 {
56122987 25427 "info" : {
7aacca6f 25428 "PUT" : {
44660702 25429 "description" : "Change user password.",
7aacca6f 25430 "method" : "PUT",
44660702 25431 "name" : "change_passsword",
56122987
DM
25432 "parameters" : {
25433 "additionalProperties" : 0,
25434 "properties" : {
44660702
DM
25435 "password" : {
25436 "description" : "The new password.",
25437 "maxLength" : 64,
25438 "minLength" : 5,
013dc89f
DM
25439 "type" : "string",
25440 "typetext" : "<string>"
7aacca6f 25441 },
44660702
DM
25442 "userid" : {
25443 "description" : "User ID",
25444 "format" : "pve-userid",
25445 "maxLength" : 64,
013dc89f
DM
25446 "type" : "string",
25447 "typetext" : "<string>"
56122987 25448 }
7aacca6f 25449 }
56122987
DM
25450 },
25451 "permissions" : {
25452 "check" : [
44660702 25453 "or",
56122987 25454 [
44660702
DM
25455 "userid-param",
25456 "self"
25457 ],
25458 [
25459 "and",
25460 [
25461 "userid-param",
25462 "Realm.AllocateUser"
25463 ],
25464 [
25465 "userid-group",
25466 [
25467 "User.Modify"
25468 ]
25469 ]
56122987 25470 ]
7aacca6f 25471 ],
44660702 25472 "description" : "Each user is allowed to change his own password. A user can change the password of another user if he has 'Realm.AllocateUser' (on the realm of user <userid>) and 'User.Modify' permission on /access/groups/<group> on a group where user <userid> is member of."
56122987 25473 },
44660702 25474 "protected" : 1,
7aacca6f
DM
25475 "returns" : {
25476 "type" : "null"
44660702
DM
25477 }
25478 }
25479 },
25480 "leaf" : 1,
25481 "path" : "/access/password",
25482 "text" : "password"
25483 }
25484 ],
25485 "info" : {
25486 "GET" : {
25487 "description" : "Directory index.",
25488 "method" : "GET",
25489 "name" : "index",
25490 "parameters" : {
25491 "additionalProperties" : 0
25492 },
25493 "permissions" : {
25494 "user" : "all"
25495 },
25496 "returns" : {
25497 "items" : {
25498 "properties" : {
25499 "subdir" : {
25500 "type" : "string"
25501 }
7aacca6f 25502 },
44660702
DM
25503 "type" : "object"
25504 },
25505 "links" : [
25506 {
25507 "href" : "{subdir}",
25508 "rel" : "child"
25509 }
25510 ],
25511 "type" : "array"
25512 }
25513 }
25514 },
25515 "leaf" : 0,
25516 "path" : "/access",
25517 "text" : "access"
25518 },
25519 {
25520 "children" : [
25521 {
25522 "info" : {
25523 "DELETE" : {
7aacca6f 25524 "description" : "Delete pool.",
44660702
DM
25525 "method" : "DELETE",
25526 "name" : "delete_pool",
7aacca6f
DM
25527 "parameters" : {
25528 "additionalProperties" : 0,
25529 "properties" : {
25530 "poolid" : {
25531 "format" : "pve-poolid",
013dc89f
DM
25532 "type" : "string",
25533 "typetext" : "<string>"
7aacca6f
DM
25534 }
25535 }
25536 },
56122987
DM
25537 "permissions" : {
25538 "check" : [
25539 "perm",
25540 "/pool/{poolid}",
25541 [
25542 "Pool.Allocate"
25543 ]
44660702
DM
25544 ],
25545 "description" : "You can only delete empty pools (no members)."
25546 },
25547 "protected" : 1,
25548 "returns" : {
25549 "type" : "null"
7aacca6f
DM
25550 }
25551 },
25552 "GET" : {
25553 "description" : "Get pool configuration.",
44660702 25554 "method" : "GET",
7aacca6f 25555 "name" : "read_pool",
56122987 25556 "parameters" : {
44660702 25557 "additionalProperties" : 0,
56122987
DM
25558 "properties" : {
25559 "poolid" : {
44660702 25560 "format" : "pve-poolid",
013dc89f
DM
25561 "type" : "string",
25562 "typetext" : "<string>"
56122987 25563 }
44660702 25564 }
56122987 25565 },
56122987 25566 "permissions" : {
56122987
DM
25567 "check" : [
25568 "perm",
25569 "/pool/{poolid}",
25570 [
25571 "Pool.Allocate"
25572 ]
25573 ]
25574 },
7aacca6f 25575 "returns" : {
44660702 25576 "additionalProperties" : 0,
56122987 25577 "properties" : {
44660702
DM
25578 "comment" : {
25579 "optional" : 1,
25580 "type" : "string"
25581 },
7aacca6f 25582 "members" : {
7aacca6f
DM
25583 "items" : {
25584 "additionalProperties" : 1,
7aacca6f 25585 "properties" : {
7aacca6f
DM
25586 "id" : {
25587 "type" : "string"
25588 },
25589 "node" : {
25590 "type" : "string"
25591 },
44660702
DM
25592 "storage" : {
25593 "optional" : 1,
25594 "type" : "string"
25595 },
7aacca6f 25596 "type" : {
7aacca6f
DM
25597 "enum" : [
25598 "qemu",
25599 "lxc",
25600 "openvz",
25601 "storage"
44660702
DM
25602 ],
25603 "type" : "string"
25604 },
25605 "vmid" : {
25606 "optional" : 1,
25607 "type" : "integer"
7aacca6f 25608 }
44660702
DM
25609 },
25610 "type" : "object"
25611 },
25612 "type" : "array"
25613 }
25614 },
25615 "type" : "object"
25616 }
25617 },
25618 "PUT" : {
25619 "description" : "Update pool data.",
25620 "method" : "PUT",
25621 "name" : "update_pool",
25622 "parameters" : {
25623 "additionalProperties" : 0,
25624 "properties" : {
56122987
DM
25625 "comment" : {
25626 "optional" : 1,
013dc89f
DM
25627 "type" : "string",
25628 "typetext" : "<string>"
44660702
DM
25629 },
25630 "delete" : {
25631 "description" : "Remove vms/storage (instead of adding it).",
25632 "optional" : 1,
013dc89f
DM
25633 "type" : "boolean",
25634 "typetext" : "<boolean>"
44660702
DM
25635 },
25636 "poolid" : {
25637 "format" : "pve-poolid",
013dc89f
DM
25638 "type" : "string",
25639 "typetext" : "<string>"
44660702
DM
25640 },
25641 "storage" : {
25642 "description" : "List of storage IDs.",
25643 "format" : "pve-storage-id-list",
25644 "optional" : 1,
013dc89f
DM
25645 "type" : "string",
25646 "typetext" : "<string>"
44660702
DM
25647 },
25648 "vms" : {
25649 "description" : "List of virtual machines.",
25650 "format" : "pve-vmid-list",
25651 "optional" : 1,
013dc89f
DM
25652 "type" : "string",
25653 "typetext" : "<string>"
56122987 25654 }
44660702
DM
25655 }
25656 },
25657 "permissions" : {
25658 "check" : [
25659 "perm",
25660 "/pool/{poolid}",
25661 [
25662 "Pool.Allocate"
25663 ]
25664 ],
25665 "description" : "You also need the right to modify permissions on any object you add/delete."
25666 },
25667 "protected" : 1,
25668 "returns" : {
25669 "type" : "null"
56122987
DM
25670 }
25671 }
25672 },
44660702
DM
25673 "leaf" : 1,
25674 "path" : "/pools/{poolid}",
7aacca6f 25675 "text" : "{poolid}"
56122987 25676 }
7aacca6f 25677 ],
56122987
DM
25678 "info" : {
25679 "GET" : {
44660702
DM
25680 "description" : "Pool index.",
25681 "method" : "GET",
25682 "name" : "index",
25683 "parameters" : {
25684 "additionalProperties" : 0
25685 },
25686 "permissions" : {
25687 "description" : "List all pools where you have Pool.Allocate or VM.Allocate permissions on /pool/<pool>.",
25688 "user" : "all"
25689 },
56122987 25690 "returns" : {
44660702
DM
25691 "items" : {
25692 "properties" : {
25693 "poolid" : {
25694 "type" : "string"
25695 }
56122987 25696 },
44660702
DM
25697 "type" : "object"
25698 },
25699 "links" : [
25700 {
25701 "href" : "{poolid}",
25702 "rel" : "child"
25703 }
25704 ],
25705 "type" : "array"
25706 }
25707 },
25708 "POST" : {
25709 "description" : "Create new pool.",
25710 "method" : "POST",
25711 "name" : "create_pool",
25712 "parameters" : {
25713 "additionalProperties" : 0,
25714 "properties" : {
25715 "comment" : {
25716 "optional" : 1,
013dc89f
DM
25717 "type" : "string",
25718 "typetext" : "<string>"
7aacca6f 25719 },
44660702
DM
25720 "poolid" : {
25721 "format" : "pve-poolid",
013dc89f
DM
25722 "type" : "string",
25723 "typetext" : "<string>"
56122987
DM
25724 }
25725 }
25726 },
56122987 25727 "permissions" : {
44660702
DM
25728 "check" : [
25729 "perm",
25730 "/pool/{poolid}",
25731 [
25732 "Pool.Allocate"
25733 ]
25734 ]
56122987 25735 },
44660702
DM
25736 "protected" : 1,
25737 "returns" : {
25738 "type" : "null"
25739 }
25740 }
25741 },
25742 "leaf" : 0,
25743 "path" : "/pools",
25744 "text" : "pools"
25745 },
25746 {
25747 "info" : {
25748 "GET" : {
25749 "description" : "API version details. The result also includes the global datacenter confguration.",
25750 "method" : "GET",
25751 "name" : "version",
7aacca6f
DM
25752 "parameters" : {
25753 "additionalProperties" : 0
25754 },
44660702
DM
25755 "permissions" : {
25756 "user" : "all"
25757 },
25758 "returns" : {
25759 "properties" : {
25760 "release" : {
25761 "type" : "string"
25762 },
25763 "repoid" : {
25764 "type" : "string"
25765 },
25766 "version" : {
25767 "type" : "string"
25768 }
25769 },
25770 "type" : "object"
25771 }
56122987
DM
25772 }
25773 },
44660702
DM
25774 "leaf" : 1,
25775 "path" : "/version",
56122987
DM
25776 "text" : "version"
25777 }
25778]
25779;
25780