xref: /cloud-hypervisor/vmm/src/api/openapi/cloud-hypervisor.yaml (revision dce82a34d06b200be8f336788d7421608a74e95d)
18916dad2SSamuel Ortizopenapi: 3.0.1
28916dad2SSamuel Ortizinfo:
38916dad2SSamuel Ortiz  title: Cloud Hypervisor API
48916dad2SSamuel Ortiz  description: Local HTTP based API for managing and inspecting a cloud-hypervisor virtual machine.
58916dad2SSamuel Ortiz  license:
68916dad2SSamuel Ortiz    name: Apache 2.0
78916dad2SSamuel Ortiz    url: http://www.apache.org/licenses/LICENSE-2.0.html
88916dad2SSamuel Ortiz  version: 0.3.0
98916dad2SSamuel Ortiz
108916dad2SSamuel Ortizservers:
118916dad2SSamuel Ortiz  - url: http://localhost/api/v1
128916dad2SSamuel Ortiz
138916dad2SSamuel Ortizpaths:
14a5186514SJose Carlos Venegas Munoz  /vmm.ping:
158916dad2SSamuel Ortiz    get:
16a5186514SJose Carlos Venegas Munoz      summary: Ping the VMM to check for API server availability
178916dad2SSamuel Ortiz      responses:
188916dad2SSamuel Ortiz        200:
198916dad2SSamuel Ortiz          description: The VMM information
208916dad2SSamuel Ortiz          content:
218916dad2SSamuel Ortiz            application/json:
228916dad2SSamuel Ortiz              schema:
2351fdc488SRob Bradford                $ref: "#/components/schemas/VmmPingResponse"
248916dad2SSamuel Ortiz
25a95fa1c4SSamuel Ortiz  /vmm.shutdown:
26a95fa1c4SSamuel Ortiz    put:
27a95fa1c4SSamuel Ortiz      summary: Shuts the cloud-hypervisor VMM.
28a95fa1c4SSamuel Ortiz      operationId: shutdownVMM
29a95fa1c4SSamuel Ortiz      responses:
303dde848cSSamuel Ortiz        204:
31a95fa1c4SSamuel Ortiz          description: The VMM successfully shutdown.
32a95fa1c4SSamuel Ortiz
338916dad2SSamuel Ortiz  /vm.info:
348916dad2SSamuel Ortiz    get:
358916dad2SSamuel Ortiz      summary: Returns general information about the cloud-hypervisor Virtual Machine (VM) instance.
368916dad2SSamuel Ortiz      responses:
378916dad2SSamuel Ortiz        200:
388916dad2SSamuel Ortiz          description: The VM information
398916dad2SSamuel Ortiz          content:
408916dad2SSamuel Ortiz            application/json:
418916dad2SSamuel Ortiz              schema:
4251fdc488SRob Bradford                $ref: "#/components/schemas/VmInfo"
438916dad2SSamuel Ortiz
44522d8c84SRob Bradford  /vm.counters:
45522d8c84SRob Bradford    get:
46522d8c84SRob Bradford      summary: Get counters from the VM
47522d8c84SRob Bradford      responses:
48522d8c84SRob Bradford        200:
49522d8c84SRob Bradford          description: The VM counters
50522d8c84SRob Bradford          content:
51522d8c84SRob Bradford            application/json:
52522d8c84SRob Bradford              schema:
5351fdc488SRob Bradford                $ref: "#/components/schemas/VmCounters"
54522d8c84SRob Bradford
558916dad2SSamuel Ortiz  /vm.create:
568916dad2SSamuel Ortiz    put:
578916dad2SSamuel Ortiz      summary: Create the cloud-hypervisor Virtual Machine (VM) instance. The instance is not booted, only created.
588916dad2SSamuel Ortiz      operationId: createVM
598916dad2SSamuel Ortiz      requestBody:
608916dad2SSamuel Ortiz        description: The VM configuration
618916dad2SSamuel Ortiz        content:
628916dad2SSamuel Ortiz          application/json:
638916dad2SSamuel Ortiz            schema:
6451fdc488SRob Bradford              $ref: "#/components/schemas/VmConfig"
658916dad2SSamuel Ortiz        required: true
668916dad2SSamuel Ortiz      responses:
673dde848cSSamuel Ortiz        204:
688916dad2SSamuel Ortiz          description: The VM instance was successfully created.
698916dad2SSamuel Ortiz
708916dad2SSamuel Ortiz  /vm.delete:
718916dad2SSamuel Ortiz    put:
728916dad2SSamuel Ortiz      summary: Delete the cloud-hypervisor Virtual Machine (VM) instance.
738916dad2SSamuel Ortiz      operationId: deleteVM
748916dad2SSamuel Ortiz      responses:
753dde848cSSamuel Ortiz        204:
768916dad2SSamuel Ortiz          description: The VM instance was successfully deleted.
778916dad2SSamuel Ortiz
788916dad2SSamuel Ortiz  /vm.boot:
798916dad2SSamuel Ortiz    put:
808916dad2SSamuel Ortiz      summary: Boot the previously created VM instance.
818916dad2SSamuel Ortiz      operationId: bootVM
828916dad2SSamuel Ortiz      responses:
833dde848cSSamuel Ortiz        204:
848916dad2SSamuel Ortiz          description: The VM instance successfully booted.
858916dad2SSamuel Ortiz        404:
868916dad2SSamuel Ortiz          description: The VM instance could not boot because it is not created yet
878916dad2SSamuel Ortiz
884ac0cb9cSSamuel Ortiz  /vm.pause:
894ac0cb9cSSamuel Ortiz    put:
904ac0cb9cSSamuel Ortiz      summary: Pause a previously booted VM instance.
914ac0cb9cSSamuel Ortiz      operationId: pauseVM
924ac0cb9cSSamuel Ortiz      responses:
933dde848cSSamuel Ortiz        204:
944ac0cb9cSSamuel Ortiz          description: The VM instance successfully paused.
954ac0cb9cSSamuel Ortiz        404:
964ac0cb9cSSamuel Ortiz          description: The VM instance could not pause because it is not created yet
974ac0cb9cSSamuel Ortiz        405:
984ac0cb9cSSamuel Ortiz          description: The VM instance could not pause because it is not booted.
994ac0cb9cSSamuel Ortiz
100dbbd04a4SSamuel Ortiz  /vm.resume:
101dbbd04a4SSamuel Ortiz    put:
102dbbd04a4SSamuel Ortiz      summary: Resume a previously paused VM instance.
103dbbd04a4SSamuel Ortiz      operationId: resumeVM
104dbbd04a4SSamuel Ortiz      responses:
1053dde848cSSamuel Ortiz        204:
106dbbd04a4SSamuel Ortiz          description: The VM instance successfully paused.
107dbbd04a4SSamuel Ortiz        404:
108dbbd04a4SSamuel Ortiz          description: The VM instance could not resume because it is not booted yet
109dbbd04a4SSamuel Ortiz        405:
110dbbd04a4SSamuel Ortiz          description: The VM instance could not resume because it is not paused.
111dbbd04a4SSamuel Ortiz
1128916dad2SSamuel Ortiz  /vm.shutdown:
1138916dad2SSamuel Ortiz    put:
1148916dad2SSamuel Ortiz      summary: Shut the VM instance down.
1158916dad2SSamuel Ortiz      operationId: shutdownVM
1168916dad2SSamuel Ortiz      responses:
1173dde848cSSamuel Ortiz        204:
1188916dad2SSamuel Ortiz          description: The VM instance successfully shut down.
1198916dad2SSamuel Ortiz        404:
1208916dad2SSamuel Ortiz          description: The VM instance could not shut down because is not created.
1218916dad2SSamuel Ortiz        405:
1228916dad2SSamuel Ortiz          description: The VM instance could not shut down because it is not started.
1238916dad2SSamuel Ortiz
1248916dad2SSamuel Ortiz  /vm.reboot:
1258916dad2SSamuel Ortiz    put:
1268916dad2SSamuel Ortiz      summary: Reboot the VM instance.
1278916dad2SSamuel Ortiz      operationId: rebootVM
1288916dad2SSamuel Ortiz      responses:
1293dde848cSSamuel Ortiz        204:
1308916dad2SSamuel Ortiz          description: The VM instance successfully rebooted.
1318916dad2SSamuel Ortiz        404:
1328916dad2SSamuel Ortiz          description: The VM instance could not reboot because it is not created.
1338916dad2SSamuel Ortiz        405:
1348916dad2SSamuel Ortiz          description: The VM instance could not reboot because it is not booted.
1358916dad2SSamuel Ortiz
13668d90cbeSRob Bradford  /vm.power-button:
13768d90cbeSRob Bradford    put:
13868d90cbeSRob Bradford      summary: Trigger a power button in the VM
13968d90cbeSRob Bradford      operationId: power-buttonVM
14068d90cbeSRob Bradford      responses:
14168d90cbeSRob Bradford        204:
14268d90cbeSRob Bradford          description: Power button successfully triggered in the VM
14368d90cbeSRob Bradford        404:
14468d90cbeSRob Bradford          description: The button could not be triggered because it is not created yet
14568d90cbeSRob Bradford        405:
14668d90cbeSRob Bradford          description: The button could not be triggered because it is not booted.
14768d90cbeSRob Bradford
14886339b4cSRob Bradford  /vm.resize:
14986339b4cSRob Bradford    put:
15086339b4cSRob Bradford      summary: Resize the VM
15186339b4cSRob Bradford      requestBody:
15286339b4cSRob Bradford        description: The target size for the VM
15386339b4cSRob Bradford        content:
15486339b4cSRob Bradford          application/json:
15586339b4cSRob Bradford            schema:
15651fdc488SRob Bradford              $ref: "#/components/schemas/VmResize"
15786339b4cSRob Bradford        required: true
15899e608c2SJose Carlos Venegas Munoz      responses:
15999e608c2SJose Carlos Venegas Munoz        204:
16099e608c2SJose Carlos Venegas Munoz          description: The VM instance was successfully resized.
16199e608c2SJose Carlos Venegas Munoz        404:
16299e608c2SJose Carlos Venegas Munoz          description: The VM instance could not be resized because it is not created.
163d0225fe6SFabiano Fidêncio        429:
164d0225fe6SFabiano Fidêncio          description: The VM instance could not be resized because a cpu removal is still pending.
16599e608c2SJose Carlos Venegas Munoz
166015c7841SSebastien Boeuf  /vm.resize-zone:
167015c7841SSebastien Boeuf    put:
168015c7841SSebastien Boeuf      summary: Resize a memory zone
169015c7841SSebastien Boeuf      requestBody:
170015c7841SSebastien Boeuf        description: The target size for the memory zone
171015c7841SSebastien Boeuf        content:
172015c7841SSebastien Boeuf          application/json:
173015c7841SSebastien Boeuf            schema:
17451fdc488SRob Bradford              $ref: "#/components/schemas/VmResizeZone"
175015c7841SSebastien Boeuf        required: true
176015c7841SSebastien Boeuf      responses:
177015c7841SSebastien Boeuf        204:
178015c7841SSebastien Boeuf          description: The memory zone was successfully resized.
179015c7841SSebastien Boeuf        500:
180015c7841SSebastien Boeuf          description: The memory zone could not be resized.
181015c7841SSebastien Boeuf
1820e58741aSSebastien Boeuf  /vm.add-device:
1830e58741aSSebastien Boeuf    put:
1840e58741aSSebastien Boeuf      summary: Add a new device to the VM
1850e58741aSSebastien Boeuf      requestBody:
1860e58741aSSebastien Boeuf        description: The path of the new device
1870e58741aSSebastien Boeuf        content:
1880e58741aSSebastien Boeuf          application/json:
1890e58741aSSebastien Boeuf            schema:
190b4e39427SFabiano Fidêncio              $ref: "#/components/schemas/DeviceConfig"
1910e58741aSSebastien Boeuf        required: true
1920e58741aSSebastien Boeuf      responses:
193b62d5d22SSebastien Boeuf        200:
1940e58741aSSebastien Boeuf          description: The new device was successfully added to the VM instance.
195b62d5d22SSebastien Boeuf          content:
196b62d5d22SSebastien Boeuf            application/json:
197b62d5d22SSebastien Boeuf              schema:
19851fdc488SRob Bradford                $ref: "#/components/schemas/PciDeviceInfo"
1995752a2a4SFabiano Fidêncio        204:
2005752a2a4SFabiano Fidêncio          description: The new device was successfully (cold) added to the VM instance.
2010e58741aSSebastien Boeuf        404:
2020e58741aSSebastien Boeuf          description: The new device could not be added to the VM instance.
2030e58741aSSebastien Boeuf
2046cbdb9aaSSebastien Boeuf  /vm.remove-device:
2056cbdb9aaSSebastien Boeuf    put:
2066cbdb9aaSSebastien Boeuf      summary: Remove a device from the VM
2076cbdb9aaSSebastien Boeuf      requestBody:
2086cbdb9aaSSebastien Boeuf        description: The identifier of the device
2096cbdb9aaSSebastien Boeuf        content:
2106cbdb9aaSSebastien Boeuf          application/json:
2116cbdb9aaSSebastien Boeuf            schema:
21251fdc488SRob Bradford              $ref: "#/components/schemas/VmRemoveDevice"
2136cbdb9aaSSebastien Boeuf        required: true
2146cbdb9aaSSebastien Boeuf      responses:
2156cbdb9aaSSebastien Boeuf        204:
2166cbdb9aaSSebastien Boeuf          description: The device was successfully removed from the VM instance.
2176cbdb9aaSSebastien Boeuf        404:
2186cbdb9aaSSebastien Boeuf          description: The device could not be removed from the VM instance.
2196cbdb9aaSSebastien Boeuf
22082cad99cSRob Bradford  /vm.add-disk:
22182cad99cSRob Bradford    put:
22282cad99cSRob Bradford      summary: Add a new disk to the VM
22382cad99cSRob Bradford      requestBody:
22482cad99cSRob Bradford        description: The details of the new disk
22582cad99cSRob Bradford        content:
22682cad99cSRob Bradford          application/json:
22782cad99cSRob Bradford            schema:
22851fdc488SRob Bradford              $ref: "#/components/schemas/DiskConfig"
22982cad99cSRob Bradford        required: true
23082cad99cSRob Bradford      responses:
231b62d5d22SSebastien Boeuf        200:
23282cad99cSRob Bradford          description: The new disk was successfully added to the VM instance.
233b62d5d22SSebastien Boeuf          content:
234b62d5d22SSebastien Boeuf            application/json:
235b62d5d22SSebastien Boeuf              schema:
23651fdc488SRob Bradford                $ref: "#/components/schemas/PciDeviceInfo"
2375752a2a4SFabiano Fidêncio        204:
2385752a2a4SFabiano Fidêncio          description: The new disk was successfully (cold) added to the VM instance.
23982cad99cSRob Bradford        500:
24082cad99cSRob Bradford          description: The new disk could not be added to the VM instance.
24182cad99cSRob Bradford
242bb2139a4SDean Sheather  /vm.add-fs:
243bb2139a4SDean Sheather    put:
244bb2139a4SDean Sheather      summary: Add a new virtio-fs device to the VM
245bb2139a4SDean Sheather      requestBody:
246bb2139a4SDean Sheather        description: The details of the new virtio-fs
247bb2139a4SDean Sheather        content:
248bb2139a4SDean Sheather          application/json:
249bb2139a4SDean Sheather            schema:
25051fdc488SRob Bradford              $ref: "#/components/schemas/FsConfig"
251bb2139a4SDean Sheather        required: true
252bb2139a4SDean Sheather      responses:
253b62d5d22SSebastien Boeuf        200:
254bb2139a4SDean Sheather          description: The new device was successfully added to the VM instance.
255b62d5d22SSebastien Boeuf          content:
256b62d5d22SSebastien Boeuf            application/json:
257b62d5d22SSebastien Boeuf              schema:
25851fdc488SRob Bradford                $ref: "#/components/schemas/PciDeviceInfo"
2595752a2a4SFabiano Fidêncio        204:
2605752a2a4SFabiano Fidêncio          description: The new device was successfully (cold) added to the VM instance.
261bb2139a4SDean Sheather        500:
262bb2139a4SDean Sheather          description: The new device could not be added to the VM instance.
263bb2139a4SDean Sheather
26475878dd9SRob Bradford  /vm.add-pmem:
26575878dd9SRob Bradford    put:
26675878dd9SRob Bradford      summary: Add a new pmem device to the VM
26775878dd9SRob Bradford      requestBody:
26875878dd9SRob Bradford        description: The details of the new pmem device
26975878dd9SRob Bradford        content:
27075878dd9SRob Bradford          application/json:
27175878dd9SRob Bradford            schema:
27251fdc488SRob Bradford              $ref: "#/components/schemas/PmemConfig"
27375878dd9SRob Bradford        required: true
27475878dd9SRob Bradford      responses:
275b62d5d22SSebastien Boeuf        200:
27675878dd9SRob Bradford          description: The new device was successfully added to the VM instance.
277b62d5d22SSebastien Boeuf          content:
278b62d5d22SSebastien Boeuf            application/json:
279b62d5d22SSebastien Boeuf              schema:
28051fdc488SRob Bradford                $ref: "#/components/schemas/PciDeviceInfo"
2815752a2a4SFabiano Fidêncio        204:
2825752a2a4SFabiano Fidêncio          description: The new device was successfully (cold) added to the VM instance.
28375878dd9SRob Bradford        500:
28475878dd9SRob Bradford          description: The new device could not be added to the VM instance.
28575878dd9SRob Bradford
2866244beb9SRob Bradford  /vm.add-net:
2876244beb9SRob Bradford    put:
2886244beb9SRob Bradford      summary: Add a new network device to the VM
2896244beb9SRob Bradford      requestBody:
2906244beb9SRob Bradford        description: The details of the new network device
2916244beb9SRob Bradford        content:
2926244beb9SRob Bradford          application/json:
2936244beb9SRob Bradford            schema:
29451fdc488SRob Bradford              $ref: "#/components/schemas/NetConfig"
2956244beb9SRob Bradford        required: true
2966244beb9SRob Bradford      responses:
297b62d5d22SSebastien Boeuf        200:
2986244beb9SRob Bradford          description: The new device was successfully added to the VM instance.
299b62d5d22SSebastien Boeuf          content:
300b62d5d22SSebastien Boeuf            application/json:
301b62d5d22SSebastien Boeuf              schema:
30251fdc488SRob Bradford                $ref: "#/components/schemas/PciDeviceInfo"
3035752a2a4SFabiano Fidêncio        204:
3045752a2a4SFabiano Fidêncio          description: The new device was successfully (cold) added to the VM instance.
3056244beb9SRob Bradford        500:
3066244beb9SRob Bradford          description: The new device could not be added to the VM instance.
3076244beb9SRob Bradford
3088de7448dSRob Bradford  /vm.add-vsock:
3098de7448dSRob Bradford    put:
3108de7448dSRob Bradford      summary: Add a new vsock device to the VM
3118de7448dSRob Bradford      requestBody:
3128de7448dSRob Bradford        description: The details of the new vsock device
3138de7448dSRob Bradford        content:
3148de7448dSRob Bradford          application/json:
3158de7448dSRob Bradford            schema:
31651fdc488SRob Bradford              $ref: "#/components/schemas/VsockConfig"
3178de7448dSRob Bradford        required: true
3188de7448dSRob Bradford      responses:
319b62d5d22SSebastien Boeuf        200:
3208de7448dSRob Bradford          description: The new device was successfully added to the VM instance.
321b62d5d22SSebastien Boeuf          content:
322b62d5d22SSebastien Boeuf            application/json:
323b62d5d22SSebastien Boeuf              schema:
32451fdc488SRob Bradford                $ref: "#/components/schemas/PciDeviceInfo"
3255752a2a4SFabiano Fidêncio        204:
3265752a2a4SFabiano Fidêncio          description: The new device was successfully (cold) added to the VM instance.
3278de7448dSRob Bradford        500:
3288de7448dSRob Bradford          description: The new device could not be added to the VM instance.
3298de7448dSRob Bradford
3303fea5f53SSebastien Boeuf  /vm.add-vdpa:
3313fea5f53SSebastien Boeuf    put:
3323fea5f53SSebastien Boeuf      summary: Add a new vDPA device to the VM
3333fea5f53SSebastien Boeuf      requestBody:
3343fea5f53SSebastien Boeuf        description: The details of the new vDPA device
3353fea5f53SSebastien Boeuf        content:
3363fea5f53SSebastien Boeuf          application/json:
3373fea5f53SSebastien Boeuf            schema:
33851fdc488SRob Bradford              $ref: "#/components/schemas/VdpaConfig"
3393fea5f53SSebastien Boeuf        required: true
3403fea5f53SSebastien Boeuf      responses:
3413fea5f53SSebastien Boeuf        200:
3423fea5f53SSebastien Boeuf          description: The new vDPA device was successfully added to the VM instance.
3433fea5f53SSebastien Boeuf          content:
3443fea5f53SSebastien Boeuf            application/json:
3453fea5f53SSebastien Boeuf              schema:
34651fdc488SRob Bradford                $ref: "#/components/schemas/PciDeviceInfo"
3473fea5f53SSebastien Boeuf        204:
3483fea5f53SSebastien Boeuf          description: The new vDPA device was successfully (cold) added to the VM instance.
3493fea5f53SSebastien Boeuf        500:
3503fea5f53SSebastien Boeuf          description: The new vDPA device could not be added to the VM instance.
3518de7448dSRob Bradford
3522b457584SRui Chang  /vm.add-user-device:
3532b457584SRui Chang    put:
3542b457584SRui Chang      requestBody:
3552b457584SRui Chang        content:
3562b457584SRui Chang          application/json:
3572b457584SRui Chang            schema:
3582b457584SRui Chang              $ref: '#/components/schemas/VmAddUserDevice'
3592b457584SRui Chang        description: The path of the new device
3602b457584SRui Chang        required: true
3612b457584SRui Chang      responses:
3622b457584SRui Chang        "200":
3632b457584SRui Chang          content:
3642b457584SRui Chang            application/json:
3652b457584SRui Chang              schema:
3662b457584SRui Chang                $ref: '#/components/schemas/PciDeviceInfo'
3672b457584SRui Chang          description: The new device was successfully added to the VM instance.
3682b457584SRui Chang        "204":
3692b457584SRui Chang          description: The new device was successfully (cold) added to the VM instance.
3702b457584SRui Chang        "404":
3712b457584SRui Chang          description: The new device could not be added to the VM instance.
3722b457584SRui Chang      summary: Add a new userspace device to the VM
3732b457584SRui Chang
3748f300bedSSamuel Ortiz  /vm.snapshot:
3758f300bedSSamuel Ortiz    put:
3768f300bedSSamuel Ortiz      summary: Returns a VM snapshot.
3778f300bedSSamuel Ortiz      requestBody:
3788f300bedSSamuel Ortiz        description: The snapshot configuration
3798f300bedSSamuel Ortiz        content:
3808f300bedSSamuel Ortiz          application/json:
3818f300bedSSamuel Ortiz            schema:
38251fdc488SRob Bradford              $ref: "#/components/schemas/VmSnapshotConfig"
3838f300bedSSamuel Ortiz        required: true
3848f300bedSSamuel Ortiz      responses:
3858f300bedSSamuel Ortiz        204:
3868f300bedSSamuel Ortiz          description: The VM instance was successfully snapshotted.
3878f300bedSSamuel Ortiz        404:
3888f300bedSSamuel Ortiz          description: The VM instance could not be snapshotted because it is not created.
3898f300bedSSamuel Ortiz        405:
3908f300bedSSamuel Ortiz          description: The VM instance could not be snapshotted because it is not booted.
3918f300bedSSamuel Ortiz
392dbeb9228SYi Wang  /vm.coredump:
393dbeb9228SYi Wang    put:
394dbeb9228SYi Wang      summary: Takes a VM coredump.
395dbeb9228SYi Wang      requestBody:
396dbeb9228SYi Wang        description: The coredump configuration
397dbeb9228SYi Wang        content:
398dbeb9228SYi Wang          application/json:
399dbeb9228SYi Wang            schema:
40051fdc488SRob Bradford              $ref: "#/components/schemas/VmCoredumpData"
401dbeb9228SYi Wang        required: true
402dbeb9228SYi Wang      responses:
403dbeb9228SYi Wang        204:
404dbeb9228SYi Wang          description: The VM instance was successfully coredumped.
405dbeb9228SYi Wang        404:
406dbeb9228SYi Wang          description: The VM instance could not be coredumped because it is not created.
407dbeb9228SYi Wang        405:
408dbeb9228SYi Wang          description: The VM instance could not be coredumped because it is not booted.
409dbeb9228SYi Wang
410c72bf0b3SYi Wang  /vmm.nmi:
411c72bf0b3SYi Wang    put:
412c72bf0b3SYi Wang      summary: Inject an NMI.
413c72bf0b3SYi Wang      responses:
414c72bf0b3SYi Wang        204:
415c72bf0b3SYi Wang          description: The NMI successfully injected.
416c72bf0b3SYi Wang
4178f300bedSSamuel Ortiz  /vm.restore:
4188f300bedSSamuel Ortiz    put:
4198f300bedSSamuel Ortiz      summary: Restore a VM from a snapshot.
4208f300bedSSamuel Ortiz      requestBody:
4218f300bedSSamuel Ortiz        description: The restore configuration
4228f300bedSSamuel Ortiz        content:
4238f300bedSSamuel Ortiz          application/json:
4248f300bedSSamuel Ortiz            schema:
42551fdc488SRob Bradford              $ref: "#/components/schemas/RestoreConfig"
4268f300bedSSamuel Ortiz        required: true
4278f300bedSSamuel Ortiz      responses:
4288f300bedSSamuel Ortiz        204:
4298f300bedSSamuel Ortiz          description: The VM instance was successfully restored.
4308f300bedSSamuel Ortiz        404:
4318f300bedSSamuel Ortiz          description: The VM instance could not be restored because it is already created.
4328f300bedSSamuel Ortiz
4338fb64859SBo Chen  /vm.receive-migration:
4348fb64859SBo Chen    put:
4358fb64859SBo Chen      summary: Receive a VM migration from URL
4368fb64859SBo Chen      requestBody:
4378fb64859SBo Chen        description: The URL for the reception of migration state
4388fb64859SBo Chen        content:
4398fb64859SBo Chen          application/json:
4408fb64859SBo Chen            schema:
44151fdc488SRob Bradford              $ref: "#/components/schemas/ReceiveMigrationData"
4428fb64859SBo Chen        required: true
4438fb64859SBo Chen      responses:
4448fb64859SBo Chen        204:
4458fb64859SBo Chen          description: The VM migration was successfully received.
4468fb64859SBo Chen        500:
4478fb64859SBo Chen          description: The VM migration could not be received.
4488fb64859SBo Chen
4498fb64859SBo Chen  /vm.send-migration:
4508fb64859SBo Chen    put:
4518fb64859SBo Chen      summary: Send a VM migration to URL
4528fb64859SBo Chen      requestBody:
4538fb64859SBo Chen        description: The URL for sending the migration state
4548fb64859SBo Chen        content:
4558fb64859SBo Chen          application/json:
4568fb64859SBo Chen            schema:
45751fdc488SRob Bradford              $ref: "#/components/schemas/SendMigrationData"
4588fb64859SBo Chen        required: true
4598fb64859SBo Chen      responses:
4608fb64859SBo Chen        204:
4618fb64859SBo Chen          description: The VM migration was successfully sent.
4628fb64859SBo Chen        500:
4638fb64859SBo Chen          description: The VM migration could not be sent.
4648fb64859SBo Chen
4658916dad2SSamuel Ortizcomponents:
4668916dad2SSamuel Ortiz  schemas:
467a5186514SJose Carlos Venegas Munoz    VmmPingResponse:
4688916dad2SSamuel Ortiz      required:
4698916dad2SSamuel Ortiz        - version
4708916dad2SSamuel Ortiz      type: object
4718916dad2SSamuel Ortiz      properties:
472346ee09eSOmer Faruk Bayram        build_version:
473346ee09eSOmer Faruk Bayram          type: string
4748916dad2SSamuel Ortiz        version:
4758916dad2SSamuel Ortiz          type: string
476346ee09eSOmer Faruk Bayram        pid:
477346ee09eSOmer Faruk Bayram          type: integer
478346ee09eSOmer Faruk Bayram          format: int64
479ff651e0eSBo Chen        features:
480ff651e0eSBo Chen          type: array
481ff651e0eSBo Chen          items:
482ff651e0eSBo Chen            type: string
4838916dad2SSamuel Ortiz      description: Virtual Machine Monitor information
4848916dad2SSamuel Ortiz
4858916dad2SSamuel Ortiz    VmInfo:
4868916dad2SSamuel Ortiz      required:
4878916dad2SSamuel Ortiz        - config
4888916dad2SSamuel Ortiz        - state
4898916dad2SSamuel Ortiz      type: object
4908916dad2SSamuel Ortiz      properties:
4916af2f576SSamuel Ortiz        config:
49251fdc488SRob Bradford          $ref: "#/components/schemas/VmConfig"
4938916dad2SSamuel Ortiz        state:
4948916dad2SSamuel Ortiz          type: string
495d6e69019SBin Liu          enum: [Created, Running, Shutdown, Paused]
496c75f8b2fSHui Zhu        memory_actual_size:
497c75f8b2fSHui Zhu          type: integer
498c75f8b2fSHui Zhu          format: int64
499280d4fb2SRob Bradford        device_tree:
500280d4fb2SRob Bradford          type: object
501280d4fb2SRob Bradford          additionalProperties:
50251fdc488SRob Bradford            $ref: "#/components/schemas/DeviceNode"
5038916dad2SSamuel Ortiz      description: Virtual Machine information
5048916dad2SSamuel Ortiz
505280d4fb2SRob Bradford    DeviceNode:
506280d4fb2SRob Bradford      type: object
507280d4fb2SRob Bradford      properties:
508280d4fb2SRob Bradford        id:
509280d4fb2SRob Bradford          type: string
510280d4fb2SRob Bradford        resources:
511280d4fb2SRob Bradford          type: array
512280d4fb2SRob Bradford          items:
513280d4fb2SRob Bradford            # Rust enum type (with data) which can't be better represented here
514280d4fb2SRob Bradford            type: object
515280d4fb2SRob Bradford        children:
516280d4fb2SRob Bradford          type: array
517280d4fb2SRob Bradford          items:
518280d4fb2SRob Bradford            type: string
519280d4fb2SRob Bradford        pci_bdf:
520dd77070fSFabiano Fidêncio          type: string
521280d4fb2SRob Bradford
522522d8c84SRob Bradford    VmCounters:
523522d8c84SRob Bradford      type: object
524522d8c84SRob Bradford      additionalProperties:
525522d8c84SRob Bradford        type: object
526522d8c84SRob Bradford        additionalProperties:
527522d8c84SRob Bradford          type: integer
528c54452c0SJulio Montes          format: int64
529522d8c84SRob Bradford
530b62d5d22SSebastien Boeuf    PciDeviceInfo:
531b62d5d22SSebastien Boeuf      required:
532b62d5d22SSebastien Boeuf        - id
533b62d5d22SSebastien Boeuf        - bdf
534b62d5d22SSebastien Boeuf      type: object
535b62d5d22SSebastien Boeuf      properties:
536b62d5d22SSebastien Boeuf        id:
537b62d5d22SSebastien Boeuf          type: string
538b62d5d22SSebastien Boeuf        bdf:
539b62d5d22SSebastien Boeuf          type: string
540b62d5d22SSebastien Boeuf      description: Information about a PCI device
541b62d5d22SSebastien Boeuf
5428c22c03eSRob Bradford    PayloadConfig:
5438c22c03eSRob Bradford      type: object
5448c22c03eSRob Bradford      properties:
5452115a415SBo Chen        firmware:
5462115a415SBo Chen          type: string
5478c22c03eSRob Bradford        kernel:
5488c22c03eSRob Bradford          type: string
5498c22c03eSRob Bradford        cmdline:
5508c22c03eSRob Bradford          type: string
5518c22c03eSRob Bradford        initramfs:
5528c22c03eSRob Bradford          type: string
553524f26abSAnatol Belski        igvm:
554524f26abSAnatol Belski          type: string
555524f26abSAnatol Belski        host_data:
556524f26abSAnatol Belski          type: string
5578c22c03eSRob Bradford      description: Payloads to boot in guest
5588c22c03eSRob Bradford
5598916dad2SSamuel Ortiz    VmConfig:
5608916dad2SSamuel Ortiz      required:
5618c22c03eSRob Bradford        - payload
5628916dad2SSamuel Ortiz      type: object
5638916dad2SSamuel Ortiz      properties:
5648916dad2SSamuel Ortiz        cpus:
56551fdc488SRob Bradford          $ref: "#/components/schemas/CpusConfig"
5668916dad2SSamuel Ortiz        memory:
56751fdc488SRob Bradford          $ref: "#/components/schemas/MemoryConfig"
5688c22c03eSRob Bradford        payload:
5698c22c03eSRob Bradford          $ref: "#/components/schemas/PayloadConfig"
570c297d8d7SThomas Barrett        rate_limit_groups:
571c297d8d7SThomas Barrett          type: array
572c297d8d7SThomas Barrett          items:
573c297d8d7SThomas Barrett            $ref: "#/components/schemas/RateLimitGroupConfig"
5748916dad2SSamuel Ortiz        disks:
5758916dad2SSamuel Ortiz          type: array
5768916dad2SSamuel Ortiz          items:
57751fdc488SRob Bradford            $ref: "#/components/schemas/DiskConfig"
5788916dad2SSamuel Ortiz        net:
5798916dad2SSamuel Ortiz          type: array
5808916dad2SSamuel Ortiz          items:
58151fdc488SRob Bradford            $ref: "#/components/schemas/NetConfig"
5828916dad2SSamuel Ortiz        rng:
58351fdc488SRob Bradford          $ref: "#/components/schemas/RngConfig"
5841d479e5eSSebastien Boeuf        balloon:
58551fdc488SRob Bradford          $ref: "#/components/schemas/BalloonConfig"
5868916dad2SSamuel Ortiz        fs:
5878916dad2SSamuel Ortiz          type: array
5888916dad2SSamuel Ortiz          items:
58951fdc488SRob Bradford            $ref: "#/components/schemas/FsConfig"
5908916dad2SSamuel Ortiz        pmem:
5918916dad2SSamuel Ortiz          type: array
5928916dad2SSamuel Ortiz          items:
59351fdc488SRob Bradford            $ref: "#/components/schemas/PmemConfig"
5948916dad2SSamuel Ortiz        serial:
59551fdc488SRob Bradford          $ref: "#/components/schemas/ConsoleConfig"
5968916dad2SSamuel Ortiz        console:
59751fdc488SRob Bradford          $ref: "#/components/schemas/ConsoleConfig"
598e50a6411SPhilipp Schuster        debug_console:
599e50a6411SPhilipp Schuster          $ref: "#/components/schemas/DebugConsoleConfig"
6008916dad2SSamuel Ortiz        devices:
6018916dad2SSamuel Ortiz          type: array
6028916dad2SSamuel Ortiz          items:
60351fdc488SRob Bradford            $ref: "#/components/schemas/DeviceConfig"
60472169686SSebastien Boeuf        vdpa:
60572169686SSebastien Boeuf          type: array
60672169686SSebastien Boeuf          items:
60751fdc488SRob Bradford            $ref: "#/components/schemas/VdpaConfig"
6088916dad2SSamuel Ortiz        vsock:
60951fdc488SRob Bradford          $ref: "#/components/schemas/VsockConfig"
610d9244e9fSSebastien Boeuf        sgx_epc:
611d9244e9fSSebastien Boeuf          type: array
612d9244e9fSSebastien Boeuf          items:
61351fdc488SRob Bradford            $ref: "#/components/schemas/SgxEpcConfig"
61442f963d6SSebastien Boeuf        numa:
61542f963d6SSebastien Boeuf          type: array
61642f963d6SSebastien Boeuf          items:
61751fdc488SRob Bradford            $ref: "#/components/schemas/NumaConfig"
6186e0aa56fSSebastien Boeuf        iommu:
6196e0aa56fSSebastien Boeuf          type: boolean
6206e0aa56fSSebastien Boeuf          default: false
621885ee956SRob Bradford        watchdog:
622885ee956SRob Bradford          type: boolean
623885ee956SRob Bradford          default: false
624108af5a2SLucas Jacques        pvpanic:
625108af5a2SLucas Jacques          type: boolean
626108af5a2SLucas Jacques          default: false
627e7e856d8SThomas Barrett        pci_segments:
628e7e856d8SThomas Barrett          type: array
629e7e856d8SThomas Barrett          items:
630e7e856d8SThomas Barrett            $ref: "#/components/schemas/PciSegmentConfig"
63157184f11SRob Bradford        platform:
63251fdc488SRob Bradford          $ref: "#/components/schemas/PlatformConfig"
6337122e298SPraveen K Paladugu        tpm:
6347122e298SPraveen K Paladugu          $ref: "#/components/schemas/TpmConfig"
635be9f57dcSPraveen K Paladugu        landlock_enable:
636be9f57dcSPraveen K Paladugu          type: boolean
637be9f57dcSPraveen K Paladugu          default: false
638be9f57dcSPraveen K Paladugu        landlock_rules:
639be9f57dcSPraveen K Paladugu          type: array
640be9f57dcSPraveen K Paladugu          items:
641be9f57dcSPraveen K Paladugu            $ref: "#/components/schemas/LandlockConfig"
6428916dad2SSamuel Ortiz      description: Virtual machine configuration
6438916dad2SSamuel Ortiz
644932c8c97SSebastien Boeuf    CpuAffinity:
6453dd01443SKaihang Zhang      required:
6463dd01443SKaihang Zhang        - vcpu
6473dd01443SKaihang Zhang        - host_cpus
648932c8c97SSebastien Boeuf      type: object
649932c8c97SSebastien Boeuf      properties:
650932c8c97SSebastien Boeuf        vcpu:
651932c8c97SSebastien Boeuf          type: integer
652932c8c97SSebastien Boeuf        host_cpus:
653932c8c97SSebastien Boeuf          type: array
654932c8c97SSebastien Boeuf          items:
655932c8c97SSebastien Boeuf            type: integer
656932c8c97SSebastien Boeuf
6576b0df31eSWilliam Douglas    CpuFeatures:
6586b0df31eSWilliam Douglas      type: object
6596b0df31eSWilliam Douglas      properties:
6606b0df31eSWilliam Douglas        amx:
6616b0df31eSWilliam Douglas          type: boolean
6626b0df31eSWilliam Douglas
6634a0439a9SRob Bradford    CpuTopology:
6644a0439a9SRob Bradford      type: object
6654a0439a9SRob Bradford      properties:
6664a0439a9SRob Bradford        threads_per_core:
6674a0439a9SRob Bradford          type: integer
6684a0439a9SRob Bradford        cores_per_die:
6694a0439a9SRob Bradford          type: integer
6704a0439a9SRob Bradford        dies_per_package:
6714a0439a9SRob Bradford          type: integer
6724a0439a9SRob Bradford        packages:
6734a0439a9SRob Bradford          type: integer
6744a0439a9SRob Bradford
6755a722258SSebastien Boeuf    CpusConfig:
6768916dad2SSamuel Ortiz      required:
677c8b3041eSRob Bradford        - boot_vcpus
67899e608c2SJose Carlos Venegas Munoz        - max_vcpus
679c8b3041eSRob Bradford      type: object
680c8b3041eSRob Bradford      properties:
68113503061SRob Bradford        boot_vcpus:
682c8b3041eSRob Bradford          minimum: 1
683c8b3041eSRob Bradford          type: integer
68413503061SRob Bradford        max_vcpus:
6858916dad2SSamuel Ortiz          minimum: 1
6868916dad2SSamuel Ortiz          type: integer
6874a0439a9SRob Bradford        topology:
68851fdc488SRob Bradford          $ref: "#/components/schemas/CpuTopology"
689335a4e1cSSebastien Boeuf        kvm_hyperv:
690335a4e1cSSebastien Boeuf          type: boolean
691335a4e1cSSebastien Boeuf          default: false
69252ad7888SSebastien Boeuf        max_phys_bits:
69352ad7888SSebastien Boeuf          type: integer
694932c8c97SSebastien Boeuf        affinity:
695932c8c97SSebastien Boeuf          type: array
696932c8c97SSebastien Boeuf          items:
69751fdc488SRob Bradford            $ref: "#/components/schemas/CpuAffinity"
6986b0df31eSWilliam Douglas        features:
69951fdc488SRob Bradford          $ref: "#/components/schemas/CpuFeatures"
7008916dad2SSamuel Ortiz
701e7e856d8SThomas Barrett    PciSegmentConfig:
702e7e856d8SThomas Barrett      required:
703e7e856d8SThomas Barrett        - pci_segment
704e7e856d8SThomas Barrett      type: object
705e7e856d8SThomas Barrett      properties:
706e7e856d8SThomas Barrett        pci_segment:
707e7e856d8SThomas Barrett          type: integer
708e7e856d8SThomas Barrett          format: int16
709e7e856d8SThomas Barrett        mmio32_aperture_weight:
710e7e856d8SThomas Barrett          type: integer
711e7e856d8SThomas Barrett          format: int32
712e7e856d8SThomas Barrett        mmio64_aperture_weight:
713e7e856d8SThomas Barrett          type: integer
714e7e856d8SThomas Barrett          format: int32
715e7e856d8SThomas Barrett
71657184f11SRob Bradford    PlatformConfig:
71757184f11SRob Bradford      type: object
71857184f11SRob Bradford      properties:
71957184f11SRob Bradford        num_pci_segments:
72057184f11SRob Bradford          type: integer
72157184f11SRob Bradford          format: int16
72257184f11SRob Bradford        iommu_segments:
72357184f11SRob Bradford          type: array
72457184f11SRob Bradford          items:
72557184f11SRob Bradford            type: integer
72657184f11SRob Bradford            format: int16
72774ca38f7SNikolay Edigaryev        iommu_address_width:
72874ca38f7SNikolay Edigaryev          type: integer
72974ca38f7SNikolay Edigaryev          format: uint8
730adb3dcdcSRob Bradford        serial_number:
731adb3dcdcSRob Bradford          type: string
73265f42c1fSlizhaoxin1        uuid:
73365f42c1fSlizhaoxin1          type: string
73453aecf93SWei Liu        oem_strings:
73553aecf93SWei Liu          type: array
73653aecf93SWei Liu          items:
73753aecf93SWei Liu            type: string
7383793ffe8SSebastien Boeuf        tdx:
7393793ffe8SSebastien Boeuf          type: boolean
7403793ffe8SSebastien Boeuf          default: false
741524f26abSAnatol Belski        sev_snp:
742524f26abSAnatol Belski          type: boolean
743524f26abSAnatol Belski          default: false
74457184f11SRob Bradford
745be475ddcSSebastien Boeuf    MemoryZoneConfig:
746be475ddcSSebastien Boeuf      required:
7473ff82b4bSSebastien Boeuf        - id
748be475ddcSSebastien Boeuf        - size
749be475ddcSSebastien Boeuf      type: object
750be475ddcSSebastien Boeuf      properties:
7513ff82b4bSSebastien Boeuf        id:
7523ff82b4bSSebastien Boeuf          type: string
753be475ddcSSebastien Boeuf        size:
754be475ddcSSebastien Boeuf          type: integer
755be475ddcSSebastien Boeuf          format: int64
756c89b8e06SRob Bradford        file:
757c89b8e06SRob Bradford          type: string
758be475ddcSSebastien Boeuf        mergeable:
759be475ddcSSebastien Boeuf          type: boolean
760be475ddcSSebastien Boeuf          default: false
761be475ddcSSebastien Boeuf        shared:
762be475ddcSSebastien Boeuf          type: boolean
763be475ddcSSebastien Boeuf          default: false
764be475ddcSSebastien Boeuf        hugepages:
765be475ddcSSebastien Boeuf          type: boolean
766be475ddcSSebastien Boeuf          default: false
767b91b829aSRob Bradford        hugepage_size:
768b91b829aSRob Bradford          type: integer
769b91b829aSRob Bradford          format: int64
770e6f585a3SSebastien Boeuf        host_numa_node:
771274c001eSSebastien Boeuf          type: integer
772668c563dSJulio Montes          format: int32
773c645a72cSSebastien Boeuf        hotplug_size:
774c645a72cSSebastien Boeuf          type: integer
775c645a72cSSebastien Boeuf          format: int64
7764e1b78e1SSebastien Boeuf        hotplugged_size:
7774e1b78e1SSebastien Boeuf          type: integer
7784e1b78e1SSebastien Boeuf          format: int64
77908021087SYu Li        prefault:
78008021087SYu Li          type: boolean
78108021087SYu Li          default: false
782be475ddcSSebastien Boeuf
7838916dad2SSamuel Ortiz    MemoryConfig:
7848916dad2SSamuel Ortiz      required:
7858916dad2SSamuel Ortiz        - size
7868916dad2SSamuel Ortiz      type: object
7878916dad2SSamuel Ortiz      properties:
7888916dad2SSamuel Ortiz        size:
7898916dad2SSamuel Ortiz          type: integer
790b930b3fbSSamuel Ortiz          format: int64
791a31ffef0SJose Carlos Venegas Munoz        hotplug_size:
792a31ffef0SJose Carlos Venegas Munoz          type: integer
793a31ffef0SJose Carlos Venegas Munoz          format: int64
7944e1b78e1SSebastien Boeuf        hotplugged_size:
7954e1b78e1SSebastien Boeuf          type: integer
7964e1b78e1SSebastien Boeuf          format: int64
797880f62baSSebastien Boeuf        mergeable:
798880f62baSSebastien Boeuf          type: boolean
799880f62baSSebastien Boeuf          default: false
80015d9ec01SHui Zhu        hotplug_method:
80115d9ec01SHui Zhu          type: string
802b82bb559SBo Chen          default: "Acpi"
8033f42f86dSBo Chen        shared:
8043f42f86dSBo Chen          type: boolean
8053f42f86dSBo Chen          default: false
8063f42f86dSBo Chen        hugepages:
8073f42f86dSBo Chen          type: boolean
8083f42f86dSBo Chen          default: false
809b91b829aSRob Bradford        hugepage_size:
810b91b829aSRob Bradford          type: integer
811b91b829aSRob Bradford          format: int64
81208021087SYu Li        prefault:
81308021087SYu Li          type: boolean
81408021087SYu Li          default: false
8156230929dSRob Bradford        thp:
8166230929dSRob Bradford          type: boolean
8176230929dSRob Bradford          default: true
818be475ddcSSebastien Boeuf        zones:
819be475ddcSSebastien Boeuf          type: array
820be475ddcSSebastien Boeuf          items:
82151fdc488SRob Bradford            $ref: "#/components/schemas/MemoryZoneConfig"
8228916dad2SSamuel Ortiz
823ebcbab73SBo Chen    TokenBucket:
824ebcbab73SBo Chen      required:
825ebcbab73SBo Chen        - size
826ebcbab73SBo Chen        - refill_time
827ebcbab73SBo Chen      type: object
828ebcbab73SBo Chen      properties:
829ebcbab73SBo Chen        size:
830ebcbab73SBo Chen          type: integer
831fdeb4f7cSFabiano Fidêncio          format: int64
832ebcbab73SBo Chen          minimum: 0
833ebcbab73SBo Chen          description: The total number of tokens this bucket can hold.
834ebcbab73SBo Chen        one_time_burst:
835ebcbab73SBo Chen          type: integer
836fdeb4f7cSFabiano Fidêncio          format: int64
837ebcbab73SBo Chen          minimum: 0
838ebcbab73SBo Chen          description: The initial size of a token bucket.
839ebcbab73SBo Chen        refill_time:
840ebcbab73SBo Chen          type: integer
841fdeb4f7cSFabiano Fidêncio          format: int64
842ebcbab73SBo Chen          minimum: 0
843ebcbab73SBo Chen          description: The amount of milliseconds it takes for the bucket to refill.
844ebcbab73SBo Chen      description:
845ebcbab73SBo Chen        Defines a token bucket with a maximum capacity (_size_), an initial burst size
846ebcbab73SBo Chen        (_one_time_burst_) and an interval for refilling purposes (_refill_time_).
847ebcbab73SBo Chen        The refill-rate is derived from _size_ and _refill_time_, and it is the constant
848ebcbab73SBo Chen        rate at which the tokens replenish. The refill process only starts happening after
849ebcbab73SBo Chen        the initial burst budget is consumed.
850ebcbab73SBo Chen        Consumption from the token bucket is unbounded in speed which allows for bursts
851ebcbab73SBo Chen        bound in size by the amount of tokens available.
852ebcbab73SBo Chen        Once the token bucket is empty, consumption speed is bound by the refill-rate.
853ebcbab73SBo Chen
854ebcbab73SBo Chen    RateLimiterConfig:
855ebcbab73SBo Chen      type: object
856ebcbab73SBo Chen      properties:
857ebcbab73SBo Chen        bandwidth:
85851fdc488SRob Bradford          $ref: "#/components/schemas/TokenBucket"
859ebcbab73SBo Chen        ops:
86051fdc488SRob Bradford          $ref: "#/components/schemas/TokenBucket"
861ebcbab73SBo Chen      description:
862ebcbab73SBo Chen        Defines an IO rate limiter with independent bytes/s and ops/s limits.
863ebcbab73SBo Chen        Limits are defined by configuring each of the _bandwidth_ and _ops_ token buckets.
864ebcbab73SBo Chen
865c297d8d7SThomas Barrett    RateLimitGroupConfig:
866c297d8d7SThomas Barrett      required:
867c297d8d7SThomas Barrett        - id
868c297d8d7SThomas Barrett        - rate_limiter_config
869c297d8d7SThomas Barrett      type: object
870c297d8d7SThomas Barrett      properties:
871c297d8d7SThomas Barrett        id:
872c297d8d7SThomas Barrett          type: string
873c297d8d7SThomas Barrett        rate_limiter_config:
874c297d8d7SThomas Barrett          $ref: "#/components/schemas/RateLimiterConfig"
875c297d8d7SThomas Barrett
876035c4b20Sacarp    VirtQueueAffinity:
877035c4b20Sacarp      required:
878035c4b20Sacarp        - queue_index
879035c4b20Sacarp        - host_cpus
880035c4b20Sacarp      type: object
881035c4b20Sacarp      properties:
882035c4b20Sacarp        queue_index:
883035c4b20Sacarp          type: integer
884035c4b20Sacarp        host_cpus:
885035c4b20Sacarp          type: array
886035c4b20Sacarp          items:
887035c4b20Sacarp            type: integer
888035c4b20Sacarp
8898916dad2SSamuel Ortiz    DiskConfig:
8908916dad2SSamuel Ortiz      type: object
8918916dad2SSamuel Ortiz      properties:
8928916dad2SSamuel Ortiz        path:
8938916dad2SSamuel Ortiz          type: string
8949de75533SSamuel Ortiz        readonly:
8959de75533SSamuel Ortiz          type: boolean
896056f5481SSergio Lopez          default: false
897378dd812SSergio Lopez        direct:
898378dd812SSergio Lopez          type: boolean
899378dd812SSergio Lopez          default: false
9004b8d7e71SSebastien Boeuf        iommu:
9014b8d7e71SSebastien Boeuf          type: boolean
9024b8d7e71SSebastien Boeuf          default: false
90308e47ebdSSebastien Boeuf        num_queues:
90408e47ebdSSebastien Boeuf          type: integer
90508e47ebdSSebastien Boeuf          default: 1
90608e47ebdSSebastien Boeuf        queue_size:
90708e47ebdSSebastien Boeuf          type: integer
90808e47ebdSSebastien Boeuf          default: 128
9099de75533SSamuel Ortiz        vhost_user:
9109de75533SSamuel Ortiz          type: boolean
9119de75533SSamuel Ortiz          default: false
9129de75533SSamuel Ortiz        vhost_socket:
9139de75533SSamuel Ortiz          type: string
914ebcbab73SBo Chen        rate_limiter_config:
91551fdc488SRob Bradford          $ref: "#/components/schemas/RateLimiterConfig"
916438be0daSRob Bradford        pci_segment:
917438be0daSRob Bradford          type: integer
918438be0daSRob Bradford          format: int16
9199d1f95a3SRob Bradford        id:
9209d1f95a3SRob Bradford          type: string
921c4e8e653SThomas Barrett        serial:
922c4e8e653SThomas Barrett          type: string
923c297d8d7SThomas Barrett        rate_limit_group:
924c297d8d7SThomas Barrett          type: string
9251811e24aSThomas Barrett        queue_affinity:
926035c4b20Sacarp          type: array
927035c4b20Sacarp          items:
928035c4b20Sacarp            $ref: "#/components/schemas/VirtQueueAffinity"
9298916dad2SSamuel Ortiz
9308916dad2SSamuel Ortiz    NetConfig:
9318916dad2SSamuel Ortiz      type: object
9328916dad2SSamuel Ortiz      properties:
9338916dad2SSamuel Ortiz        tap:
9348916dad2SSamuel Ortiz          type: string
9358916dad2SSamuel Ortiz        ip:
9368916dad2SSamuel Ortiz          type: string
937befd342dSSebastien Boeuf          default: "192.168.249.1"
938*dce82a34SGregory Anders          description: IPv4 or IPv6 address
9398916dad2SSamuel Ortiz        mask:
9408916dad2SSamuel Ortiz          type: string
941befd342dSSebastien Boeuf          default: "255.255.255.0"
942*dce82a34SGregory Anders          description: Must be a valid IPv4 netmask if ip is an IPv4 address or a valid IPv6 netmask if ip is an IPv6 address.
9438916dad2SSamuel Ortiz        mac:
9448916dad2SSamuel Ortiz          type: string
94576dbf85bSSebastien Boeuf        host_mac:
94676dbf85bSSebastien Boeuf          type: string
94776dbf85bSSebastien Boeuf        mtu:
94876dbf85bSSebastien Boeuf          type: integer
94920c4ed82SSebastien Boeuf        iommu:
95020c4ed82SSebastien Boeuf          type: boolean
95120c4ed82SSebastien Boeuf          default: false
952404316eeSCathy Zhang        num_queues:
953404316eeSCathy Zhang          type: integer
954404316eeSCathy Zhang          default: 2
955404316eeSCathy Zhang        queue_size:
956404316eeSCathy Zhang          type: integer
957404316eeSCathy Zhang          default: 256
958a831aa21SRob Bradford        vhost_user:
959a831aa21SRob Bradford          type: boolean
960a831aa21SRob Bradford          default: false
961a831aa21SRob Bradford        vhost_socket:
962a831aa21SRob Bradford          type: string
963b5c6b04bSSebastien Boeuf        vhost_mode:
964b5c6b04bSSebastien Boeuf          type: string
965b82bb559SBo Chen          default: "Client"
9669d1f95a3SRob Bradford        id:
9679d1f95a3SRob Bradford          type: string
968438be0daSRob Bradford        pci_segment:
969438be0daSRob Bradford          type: integer
970438be0daSRob Bradford          format: int16
9715d8de623SBo Chen        rate_limiter_config:
97251fdc488SRob Bradford          $ref: "#/components/schemas/RateLimiterConfig"
9738916dad2SSamuel Ortiz
9748916dad2SSamuel Ortiz    RngConfig:
9758916dad2SSamuel Ortiz      required:
9768916dad2SSamuel Ortiz        - src
9778916dad2SSamuel Ortiz      type: object
9788916dad2SSamuel Ortiz      properties:
9798916dad2SSamuel Ortiz        src:
9808916dad2SSamuel Ortiz          type: string
981fb476938SSebastien Boeuf        iommu:
982fb476938SSebastien Boeuf          type: boolean
983fb476938SSebastien Boeuf          default: false
9848916dad2SSamuel Ortiz
9851d479e5eSSebastien Boeuf    BalloonConfig:
9861d479e5eSSebastien Boeuf      required:
9871d479e5eSSebastien Boeuf        - size
9881d479e5eSSebastien Boeuf      type: object
9891d479e5eSSebastien Boeuf      properties:
9901d479e5eSSebastien Boeuf        size:
9911d479e5eSSebastien Boeuf          type: integer
9921d479e5eSSebastien Boeuf          format: int64
993aa27f0e7SFei Li        deflate_on_oom:
994aa27f0e7SFei Li          type: boolean
995aa27f0e7SFei Li          default: false
996052f38faSSebastien Boeuf          description: Deflate balloon when the guest is under memory pressure.
997052f38faSSebastien Boeuf        free_page_reporting:
998052f38faSSebastien Boeuf          type: boolean
999052f38faSSebastien Boeuf          default: false
1000052f38faSSebastien Boeuf          description: Enable guest to report free pages.
10011d479e5eSSebastien Boeuf
10028916dad2SSamuel Ortiz    FsConfig:
10038916dad2SSamuel Ortiz      required:
100427063192SJulio Montes        - num_queues
100527063192SJulio Montes        - queue_size
1006a8cdf2f0SBo Chen        - socket
100727063192SJulio Montes        - tag
10088916dad2SSamuel Ortiz      type: object
10098916dad2SSamuel Ortiz      properties:
10108916dad2SSamuel Ortiz        tag:
10118916dad2SSamuel Ortiz          type: string
1012a8cdf2f0SBo Chen        socket:
10138916dad2SSamuel Ortiz          type: string
10148916dad2SSamuel Ortiz        num_queues:
10158916dad2SSamuel Ortiz          type: integer
1016ee528ae8SSebastien Boeuf          default: 1
10178916dad2SSamuel Ortiz        queue_size:
10188916dad2SSamuel Ortiz          type: integer
1019ee528ae8SSebastien Boeuf          default: 1024
1020438be0daSRob Bradford        pci_segment:
1021438be0daSRob Bradford          type: integer
1022438be0daSRob Bradford          format: int16
10239d1f95a3SRob Bradford        id:
10249d1f95a3SRob Bradford          type: string
10258916dad2SSamuel Ortiz
10268916dad2SSamuel Ortiz    PmemConfig:
10278916dad2SSamuel Ortiz      required:
10288916dad2SSamuel Ortiz        - file
10298916dad2SSamuel Ortiz      type: object
10308916dad2SSamuel Ortiz      properties:
10318916dad2SSamuel Ortiz        file:
10328916dad2SSamuel Ortiz          type: string
10338916dad2SSamuel Ortiz        size:
10348916dad2SSamuel Ortiz          type: integer
1035b930b3fbSSamuel Ortiz          format: int64
103663869bdeSSebastien Boeuf        iommu:
103763869bdeSSebastien Boeuf          type: boolean
103863869bdeSSebastien Boeuf          default: false
1039f7197e84SRob Bradford        discard_writes:
1040f7197e84SRob Bradford          type: boolean
1041f7197e84SRob Bradford          default: false
1042438be0daSRob Bradford        pci_segment:
1043438be0daSRob Bradford          type: integer
1044438be0daSRob Bradford          format: int16
10459d1f95a3SRob Bradford        id:
10469d1f95a3SRob Bradford          type: string
10478916dad2SSamuel Ortiz
10488916dad2SSamuel Ortiz    ConsoleConfig:
10498916dad2SSamuel Ortiz      required:
10508916dad2SSamuel Ortiz        - mode
10518916dad2SSamuel Ortiz      type: object
10528916dad2SSamuel Ortiz      properties:
10538916dad2SSamuel Ortiz        file:
10548916dad2SSamuel Ortiz          type: string
10556d1077fcSPraveen K Paladugu        socket:
10566d1077fcSPraveen K Paladugu          type: string
10578916dad2SSamuel Ortiz        mode:
10588916dad2SSamuel Ortiz          type: string
105981bd07fcSRob Bradford          enum: ["Off", "Pty", "Tty", "File", "Socket", "Null"]
106032d07e40SSebastien Boeuf        iommu:
106132d07e40SSebastien Boeuf          type: boolean
106232d07e40SSebastien Boeuf          default: false
10638916dad2SSamuel Ortiz
1064e50a6411SPhilipp Schuster    DebugConsoleConfig:
1065e50a6411SPhilipp Schuster      required:
1066e50a6411SPhilipp Schuster        - mode
1067e50a6411SPhilipp Schuster      type: object
1068e50a6411SPhilipp Schuster      properties:
1069e50a6411SPhilipp Schuster        file:
1070e50a6411SPhilipp Schuster          type: string
1071e50a6411SPhilipp Schuster        mode:
1072e50a6411SPhilipp Schuster          type: string
1073e50a6411SPhilipp Schuster          enum: ["Off", "Pty", "Tty", "File", "Null"]
1074e50a6411SPhilipp Schuster        iobase:
1075e50a6411SPhilipp Schuster          type: integer
1076e50a6411SPhilipp Schuster
10778916dad2SSamuel Ortiz    DeviceConfig:
10788916dad2SSamuel Ortiz      required:
10798916dad2SSamuel Ortiz        - path
10808916dad2SSamuel Ortiz      type: object
10818916dad2SSamuel Ortiz      properties:
10828916dad2SSamuel Ortiz        path:
10838916dad2SSamuel Ortiz          type: string
10845fc3f37cSSebastien Boeuf        iommu:
10855fc3f37cSSebastien Boeuf          type: boolean
10865fc3f37cSSebastien Boeuf          default: false
1087438be0daSRob Bradford        pci_segment:
1088438be0daSRob Bradford          type: integer
1089438be0daSRob Bradford          format: int16
10909023444aSSebastien Boeuf        id:
10919023444aSSebastien Boeuf          type: string
1092b750c332SThomas Barrett        x_nv_gpudirect_clique:
1093b750c332SThomas Barrett          type: integer
1094b750c332SThomas Barrett          format: int8
10957122e298SPraveen K Paladugu    TpmConfig:
10967122e298SPraveen K Paladugu      required:
10977122e298SPraveen K Paladugu        - socket
10987122e298SPraveen K Paladugu      type: object
10997122e298SPraveen K Paladugu      properties:
11007122e298SPraveen K Paladugu        socket:
11017122e298SPraveen K Paladugu          type: string
11027122e298SPraveen K Paladugu
110372169686SSebastien Boeuf    VdpaConfig:
110472169686SSebastien Boeuf      required:
110572169686SSebastien Boeuf        - path
110672169686SSebastien Boeuf        - num_queues
110772169686SSebastien Boeuf      type: object
110872169686SSebastien Boeuf      properties:
110972169686SSebastien Boeuf        path:
111072169686SSebastien Boeuf          type: string
111172169686SSebastien Boeuf        num_queues:
111272169686SSebastien Boeuf          type: integer
111372169686SSebastien Boeuf          default: 1
1114e76a5969SSebastien Boeuf        iommu:
1115e76a5969SSebastien Boeuf          type: boolean
1116e76a5969SSebastien Boeuf          default: false
111772169686SSebastien Boeuf        pci_segment:
111872169686SSebastien Boeuf          type: integer
111972169686SSebastien Boeuf          format: int16
112072169686SSebastien Boeuf        id:
112172169686SSebastien Boeuf          type: string
112272169686SSebastien Boeuf
11238916dad2SSamuel Ortiz    VsockConfig:
11248916dad2SSamuel Ortiz      required:
11258916dad2SSamuel Ortiz        - cid
1126a8cdf2f0SBo Chen        - socket
11278916dad2SSamuel Ortiz      type: object
11288916dad2SSamuel Ortiz      properties:
11298916dad2SSamuel Ortiz        cid:
11308916dad2SSamuel Ortiz          type: integer
1131ab16af29SJose Carlos Venegas Munoz          format: int64
11328916dad2SSamuel Ortiz          minimum: 3
11338916dad2SSamuel Ortiz          description: Guest Vsock CID
1134a8cdf2f0SBo Chen        socket:
11358916dad2SSamuel Ortiz          type: string
11368916dad2SSamuel Ortiz          description: Path to UNIX domain socket, used to proxy vsock connections.
1137278ab05cSSebastien Boeuf        iommu:
1138278ab05cSSebastien Boeuf          type: boolean
1139278ab05cSSebastien Boeuf          default: false
1140438be0daSRob Bradford        pci_segment:
1141438be0daSRob Bradford          type: integer
1142438be0daSRob Bradford          format: int16
1143bf09a1e6SRob Bradford        id:
1144bf09a1e6SRob Bradford          type: string
114586339b4cSRob Bradford
1146d9244e9fSSebastien Boeuf    SgxEpcConfig:
1147d9244e9fSSebastien Boeuf      required:
11489aedabe1SSebastien Boeuf        - id
1149d9244e9fSSebastien Boeuf        - size
1150d9244e9fSSebastien Boeuf      type: object
1151d9244e9fSSebastien Boeuf      properties:
11529aedabe1SSebastien Boeuf        id:
11539aedabe1SSebastien Boeuf          type: string
1154d9244e9fSSebastien Boeuf        size:
1155d9244e9fSSebastien Boeuf          type: integer
1156c54452c0SJulio Montes          format: int64
1157d9244e9fSSebastien Boeuf        prefault:
1158d9244e9fSSebastien Boeuf          type: boolean
1159d9244e9fSSebastien Boeuf          default: false
1160d9244e9fSSebastien Boeuf
1161a5a29134SSebastien Boeuf    NumaDistance:
1162a5a29134SSebastien Boeuf      required:
1163a5a29134SSebastien Boeuf        - destination
1164a5a29134SSebastien Boeuf        - distance
1165a5a29134SSebastien Boeuf      type: object
1166a5a29134SSebastien Boeuf      properties:
1167a5a29134SSebastien Boeuf        destination:
1168a5a29134SSebastien Boeuf          type: integer
1169668c563dSJulio Montes          format: int32
1170a5a29134SSebastien Boeuf        distance:
1171a5a29134SSebastien Boeuf          type: integer
1172668c563dSJulio Montes          format: int32
1173a5a29134SSebastien Boeuf
117442f963d6SSebastien Boeuf    NumaConfig:
117542f963d6SSebastien Boeuf      required:
1176e15dba29SSebastien Boeuf        - guest_numa_id
117742f963d6SSebastien Boeuf      type: object
117842f963d6SSebastien Boeuf      properties:
1179e15dba29SSebastien Boeuf        guest_numa_id:
118042f963d6SSebastien Boeuf          type: integer
1181668c563dSJulio Montes          format: int32
118242f963d6SSebastien Boeuf        cpus:
118342f963d6SSebastien Boeuf          type: array
118442f963d6SSebastien Boeuf          items:
118542f963d6SSebastien Boeuf            type: integer
1186668c563dSJulio Montes            format: int32
1187a5a29134SSebastien Boeuf        distances:
1188a5a29134SSebastien Boeuf          type: array
1189a5a29134SSebastien Boeuf          items:
119051fdc488SRob Bradford            $ref: "#/components/schemas/NumaDistance"
1191dc423243SSebastien Boeuf        memory_zones:
1192dc423243SSebastien Boeuf          type: array
1193dc423243SSebastien Boeuf          items:
1194dc423243SSebastien Boeuf            type: string
11956b710209SSebastien Boeuf        sgx_epc_sections:
11966b710209SSebastien Boeuf          type: array
11976b710209SSebastien Boeuf          items:
11986b710209SSebastien Boeuf            type: string
11993029fbeaSThomas Barrett        pci_segments:
12003029fbeaSThomas Barrett          type: array
12013029fbeaSThomas Barrett          items:
12023029fbeaSThomas Barrett            type: integer
12033029fbeaSThomas Barrett            format: int32
120442f963d6SSebastien Boeuf
120586339b4cSRob Bradford    VmResize:
120686339b4cSRob Bradford      type: object
120786339b4cSRob Bradford      properties:
120813503061SRob Bradford        desired_vcpus:
120986339b4cSRob Bradford          minimum: 1
121086339b4cSRob Bradford          type: integer
121182fce5a4SRob Bradford        desired_ram:
121240b38a42SJose Carlos Venegas Munoz          description: desired memory ram in bytes
121382fce5a4SRob Bradford          type: integer
121440b38a42SJose Carlos Venegas Munoz          format: int64
1215f4e39192SSebastien Boeuf        desired_balloon:
1216f4e39192SSebastien Boeuf          description: desired balloon size in bytes
12178ffbc3d0SHui Zhu          type: integer
12188ffbc3d0SHui Zhu          format: int64
12190e58741aSSebastien Boeuf
1220015c7841SSebastien Boeuf    VmResizeZone:
1221015c7841SSebastien Boeuf      type: object
1222015c7841SSebastien Boeuf      properties:
1223015c7841SSebastien Boeuf        id:
1224015c7841SSebastien Boeuf          type: string
1225015c7841SSebastien Boeuf        desired_ram:
1226015c7841SSebastien Boeuf          description: desired memory zone size in bytes
1227015c7841SSebastien Boeuf          type: integer
1228015c7841SSebastien Boeuf          format: int64
1229015c7841SSebastien Boeuf
12306cbdb9aaSSebastien Boeuf    VmRemoveDevice:
12316cbdb9aaSSebastien Boeuf      type: object
12326cbdb9aaSSebastien Boeuf      properties:
12336cbdb9aaSSebastien Boeuf        id:
12346cbdb9aaSSebastien Boeuf          type: string
123539d4f817SSamuel Ortiz
123639d4f817SSamuel Ortiz    VmSnapshotConfig:
123739d4f817SSamuel Ortiz      type: object
123839d4f817SSamuel Ortiz      properties:
123939d4f817SSamuel Ortiz        destination_url:
124039d4f817SSamuel Ortiz          type: string
12418f300bedSSamuel Ortiz
1242dbeb9228SYi Wang    VmCoredumpData:
1243dbeb9228SYi Wang      type: object
1244dbeb9228SYi Wang      properties:
1245dbeb9228SYi Wang        destination_url:
1246dbeb9228SYi Wang          type: string
1247dbeb9228SYi Wang
12480ea706faSSebastien Boeuf    RestoreConfig:
12490ea706faSSebastien Boeuf      required:
12500ea706faSSebastien Boeuf        - source_url
12518f300bedSSamuel Ortiz      type: object
12528f300bedSSamuel Ortiz      properties:
12538f300bedSSamuel Ortiz        source_url:
12548f300bedSSamuel Ortiz          type: string
12550ea706faSSebastien Boeuf        prefault:
12560ea706faSSebastien Boeuf          type: boolean
12578fb64859SBo Chen
12588fb64859SBo Chen    ReceiveMigrationData:
12596c1fe07dSFeng Ye      required:
12606c1fe07dSFeng Ye        - receiver_url
12618fb64859SBo Chen      type: object
12628fb64859SBo Chen      properties:
12638fb64859SBo Chen        receiver_url:
12648fb64859SBo Chen          type: string
12658fb64859SBo Chen
12668fb64859SBo Chen    SendMigrationData:
126700fbd774SSebastien Boeuf      required:
126800fbd774SSebastien Boeuf        - destination_url
12698fb64859SBo Chen      type: object
12708fb64859SBo Chen      properties:
12718fb64859SBo Chen        destination_url:
12728fb64859SBo Chen          type: string
127370f7f64eSRob Bradford        local:
127470f7f64eSRob Bradford          type: boolean
12752b457584SRui Chang
12762b457584SRui Chang    VmAddUserDevice:
12772b457584SRui Chang      required:
12782b457584SRui Chang        - socket
12792b457584SRui Chang      type: object
12802b457584SRui Chang      properties:
12812b457584SRui Chang        socket:
12822b457584SRui Chang          type: string
1283be9f57dcSPraveen K Paladugu
1284be9f57dcSPraveen K Paladugu    LandlockConfig:
1285be9f57dcSPraveen K Paladugu      required:
1286be9f57dcSPraveen K Paladugu        - path
1287be9f57dcSPraveen K Paladugu        - access
1288be9f57dcSPraveen K Paladugu      type: object
1289be9f57dcSPraveen K Paladugu      properties:
1290be9f57dcSPraveen K Paladugu        path:
1291be9f57dcSPraveen K Paladugu          type: string
1292be9f57dcSPraveen K Paladugu        access:
1293be9f57dcSPraveen K Paladugu          type: string
1294