Compute Management/Host Related Interfaces/PCI Device Related APIs
POSTPCI Device Related APIsSince 3.5.0SynchronousAuth Required
Attach Mdev Device Sliced from PCI Device to VM
Attach Mdev Device Sliced from PCI Device to VM
Execution Availability
Try It Out
Submit a mock request using the current auth context and example-driven inputs.
Path Parameters
Request Inputs
Path Parameters
mdevDeviceUuidStringRequiredMDEV device UUID
vmInstanceUuidStringRequiredVirtual Machine UUID
Body Fields
systemTagsListSystem tags
userTagsListUser tags
Responses
Endpoint
POST/zstack/v1/mdev-devices/{mdevDeviceUuid}/vm-instances/{vmInstanceUuid}
/zstack/v1/mdev-devices/{mdevDeviceUuid}/vm-instances/{vmInstanceUuid}
Request Example
curl -X POST 'http://{host}/zstack/v1/mdev-devices/{mdevDeviceUuid}/vm-instances/{vmInstanceUuid}' -H 'Authorization: OAuth {sessionUuid}' -H 'Content-Type: application/json;charset=UTF-8' -d '{"systemTags":["<systemTags>"],"userTags":["<userTags>"]}'
Response Example
200{ "inventory": { "uuid": "0eae7167f0db486aace15529dbc38be9", "name": "GRID M60-2A", "parentUuid": "9ab8975b943f4b8f82450629386ddf74", "hostUuid": "f6db3ae1ef974f539b340851b11bb750", "mdevSpecUuid": "c4ee001ad1924cc398f3d17c89a12bfb", "type": "GPU_Video_Controller", "state": "Enabled", "status": "Active", "chooser": "None", "createDate": "Nov 14, 2017 10:20:57 PM", "lastOpDate": "Nov 14, 2017 10:20:57 PM" } }Change History
This API has no change history records yet.
